mirror of
https://github.com/darksaid98/SiegeEngines.git
synced 2026-12-03 06:28:55 +00:00
new settings
This commit is contained in:
1 parent
a7cf287a20
commit
57a8be7cd3
8 files changed
+13
-9
No files matched your search
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -65,6 +65,7 @@ public class EntityProjectile implements CrunchProjectile{
|
|||||||
Arrow arr = (Arrow) arrow;
|
Arrow arr = (Arrow) arrow;
|
||||||
arr.setDamage(8);
|
arr.setDamage(8);
|
||||||
arr.setShooter(player);
|
arr.setShooter(player);
|
||||||
|
//arr.setBasePotionData(arg0);
|
||||||
}
|
}
|
||||||
// MiscDisguise miscDisguise = new MiscDisguise(DisguiseType.DROPPED_ITEM, Material.IRON_NUGGET);
|
// MiscDisguise miscDisguise = new MiscDisguise(DisguiseType.DROPPED_ITEM, Material.IRON_NUGGET);
|
||||||
// DisguiseAPI.disguiseEntity(arrow, miscDisguise);
|
// DisguiseAPI.disguiseEntity(arrow, miscDisguise);
|
||||||
|
|||||||
@@ -566,13 +566,14 @@ public class ClickHandler implements Listener {
|
|||||||
stand.setInvisible(false);
|
stand.setInvisible(false);
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
stand.setInvisible(true);
|
if (equipment.AllowInvisibleStand) {
|
||||||
|
stand.setInvisible(true);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
if (itemInHand.getType().equals(equipment.FuelMaterial)) {
|
if (itemInHand.getType().equals(equipment.FuelMaterial)) {
|
||||||
if (!equipment.LoadFuel(player)) {
|
if (!equipment.LoadFuel(player)) {
|
||||||
player.sendMessage("Could not load powder.");
|
player.sendMessage("Could not load Fuel.");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (itemInHand.getType().equals(Material.FLINT)) {
|
if (itemInHand.getType().equals(Material.FLINT)) {
|
||||||
@@ -580,7 +581,7 @@ public class ClickHandler implements Listener {
|
|||||||
equipment.Fire(player, 6);
|
equipment.Fire(player, 6);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
player.sendMessage("Cannon is not loaded");
|
player.sendMessage("Equipment is not loaded");
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -588,7 +589,7 @@ public class ClickHandler implements Listener {
|
|||||||
if (equipment.Projectiles.containsKey(itemInHand.getType()) && equipment.AmmoHolder.LoadedProjectile == 0){
|
if (equipment.Projectiles.containsKey(itemInHand.getType()) && equipment.AmmoHolder.LoadedProjectile == 0){
|
||||||
equipment.AmmoHolder.LoadedProjectile = 1;
|
equipment.AmmoHolder.LoadedProjectile = 1;
|
||||||
equipment.AmmoHolder.MaterialName = (Material) itemInHand.getType();
|
equipment.AmmoHolder.MaterialName = (Material) itemInHand.getType();
|
||||||
player.sendMessage("Adding projectile to cannon");
|
player.sendMessage("Adding projectile to equipment");
|
||||||
itemInHand.setAmount(itemInHand.getAmount() - 1);
|
itemInHand.setAmount(itemInHand.getAmount() - 1);
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
|
|||||||
@@ -334,7 +334,9 @@ public class CrunchSiegeCore extends JavaPlugin {
|
|||||||
stand.setBasePlate(false);
|
stand.setBasePlate(false);
|
||||||
ent.addPotionEffect(new PotionEffect(PotionEffectType.INVISIBILITY, 2000000, 1));
|
ent.addPotionEffect(new PotionEffect(PotionEffectType.INVISIBILITY, 2000000, 1));
|
||||||
// stand.setSmall(true);
|
// stand.setSmall(true);
|
||||||
stand.setInvisible(true);
|
if (equip.AllowInvisibleStand) {
|
||||||
|
stand.setInvisible(true);
|
||||||
|
}
|
||||||
stand.setGravity(false);
|
stand.setGravity(false);
|
||||||
//stand.setSmall(true);
|
//stand.setSmall(true);
|
||||||
ent.getEquipment().setHelmet(item);
|
ent.getEquipment().setHelmet(item);
|
||||||
|
|||||||
@@ -43,7 +43,7 @@ public class SiegeEquipment implements Cloneable {
|
|||||||
public int XOffset = 7;
|
public int XOffset = 7;
|
||||||
public int YOffset = 0;
|
public int YOffset = 0;
|
||||||
public int MaxFuel = 5;
|
public int MaxFuel = 5;
|
||||||
public int PlacementOffsetY = 0;
|
public double PlacementOffsetY = 0;
|
||||||
public float VelocityPerFuel = 0.75f;
|
public float VelocityPerFuel = 0.75f;
|
||||||
public Material FuelMaterial = Material.GUNPOWDER;
|
public Material FuelMaterial = Material.GUNPOWDER;
|
||||||
public long NextShotTime = System.currentTimeMillis();
|
public long NextShotTime = System.currentTimeMillis();
|
||||||
@@ -59,7 +59,7 @@ public class SiegeEquipment implements Cloneable {
|
|||||||
public Boolean RotateStandHead = true;
|
public Boolean RotateStandHead = true;
|
||||||
public Boolean HasFired = false;
|
public Boolean HasFired = false;
|
||||||
public Boolean HasReloaded = false;
|
public Boolean HasReloaded = false;
|
||||||
|
public Boolean AllowInvisibleStand = true;
|
||||||
public int TaskNumber;
|
public int TaskNumber;
|
||||||
|
|
||||||
public int ReadyModelNumber;
|
public int ReadyModelNumber;
|
||||||
@@ -83,7 +83,7 @@ public class SiegeEquipment implements Cloneable {
|
|||||||
if (AmmoHolder.LoadedFuel == this.MaxFuel) {
|
if (AmmoHolder.LoadedFuel == this.MaxFuel) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
if (player.getInventory().containsAtLeast(fuelItem, 1)) {
|
if (player.getInventory().containsAtLeast(fuelItem, 1) || fuelItem.getType() == Material.AIR) {
|
||||||
if (CanLoadFuel()) {
|
if (CanLoadFuel()) {
|
||||||
AmmoHolder.LoadedFuel += 1;
|
AmmoHolder.LoadedFuel += 1;
|
||||||
SaveState();
|
SaveState();
|
||||||
|
|||||||
Reference in new issue
Block a user