SNakes!!
This commit is contained in:
parent
e371b75401
commit
cbab8861d8
@ -61,7 +61,7 @@ public class SnakeCreature extends EventCreature<Silverfish>
|
|||||||
for (int i = 0; i < getHealth() / 50; i++)
|
for (int i = 0; i < getHealth() / 50; i++)
|
||||||
{
|
{
|
||||||
SnakeSegment tail = new SnakeSegment(getSpawnLocation().toVector().subtract(dir.clone().multiply(-i)),
|
SnakeSegment tail = new SnakeSegment(getSpawnLocation().toVector().subtract(dir.clone().multiply(-i)),
|
||||||
new ItemStack(i == 0 ? Material.EMERALD_BLOCK : Material.STONE));
|
new ItemStack(i == 0 ? Material.CHEST : Material.DROPPER));
|
||||||
|
|
||||||
_segments.add(tail);
|
_segments.add(tail);
|
||||||
}
|
}
|
||||||
|
@ -76,9 +76,9 @@ public class SnakeSegment
|
|||||||
packet1 = teleportPacket;
|
packet1 = teleportPacket;
|
||||||
}
|
}
|
||||||
|
|
||||||
toMove.normalize();
|
Vector vec = new Vector(UtilAlg.GetPitch(toMove), UtilAlg.GetYaw(toMove), 0);
|
||||||
|
|
||||||
if (toMove.equals(_prevDir))
|
if (vec.equals(_prevDir))
|
||||||
{
|
{
|
||||||
return new Packet[]
|
return new Packet[]
|
||||||
{
|
{
|
||||||
@ -86,14 +86,14 @@ public class SnakeSegment
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
_prevDir = toMove;
|
_prevDir = vec;
|
||||||
|
|
||||||
DataWatcher watcher = new DataWatcher(null);
|
DataWatcher watcher = new DataWatcher(null);
|
||||||
watcher.a(0, (byte) 32);
|
watcher.a(0, (byte) 0);
|
||||||
watcher.a(1, 0);
|
watcher.a(1, 0);
|
||||||
watcher.a(10, (byte) 0);
|
watcher.a(10, (byte) 0);
|
||||||
|
|
||||||
watcher.a(11, toMove);
|
watcher.a(11, vec);
|
||||||
|
|
||||||
for (int i = 12; i < 17; i++)
|
for (int i = 12; i < 17; i++)
|
||||||
{
|
{
|
||||||
@ -121,7 +121,7 @@ public class SnakeSegment
|
|||||||
PacketPlayOutSpawnEntityLiving packet = new PacketPlayOutSpawnEntityLiving();
|
PacketPlayOutSpawnEntityLiving packet = new PacketPlayOutSpawnEntityLiving();
|
||||||
|
|
||||||
DataWatcher watcher = new DataWatcher(null);
|
DataWatcher watcher = new DataWatcher(null);
|
||||||
watcher.a(0, (byte) 32);
|
watcher.a(0, (byte) 0);
|
||||||
watcher.a(1, 0);
|
watcher.a(1, 0);
|
||||||
|
|
||||||
packet.a = getId();
|
packet.a = getId();
|
||||||
|
@ -17,7 +17,7 @@ public class SpiderBoss extends WorldEvent
|
|||||||
public SpiderBoss(DamageManager damageManager, BlockRestore blockRestore, ConditionManager conditionManager,
|
public SpiderBoss(DamageManager damageManager, BlockRestore blockRestore, ConditionManager conditionManager,
|
||||||
Location cornerLocation)
|
Location cornerLocation)
|
||||||
{
|
{
|
||||||
super(damageManager, blockRestore, conditionManager, "Brood Mother", cornerLocation);
|
super(damageManager, blockRestore, conditionManager, "Brood Mother", cornerLocation, "schematic/Golem.schematic");
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -137,7 +137,7 @@ public class SpiderCreature extends EventCreature<Spider>
|
|||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
ability = (BossAbility) entry.getKey().getConstructor(GolemCreature.class).newInstance(this);
|
ability = (BossAbility) entry.getKey().getConstructor(SpiderCreature.class).newInstance(this);
|
||||||
|
|
||||||
if (ability.getTarget() == null)
|
if (ability.getTarget() == null)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user