rotation fix
This commit is contained in:
parent
03da4485b3
commit
16012285e0
@ -170,9 +170,7 @@ public class Catapult extends SiegeWeapon
|
||||
return;
|
||||
}
|
||||
|
||||
System.out.println(getPoint(_yaw));
|
||||
|
||||
ArmorStand stand = (ArmorStand) getEntity("Point_" + getPoint(_yaw));
|
||||
ArmorStand stand = (ArmorStand) getEntity("Point_" + getPoint(Math.toDegrees(((ArmorStand) getEntity("WEAPON")).getHeadPose().getY())));
|
||||
|
||||
stand.setPassenger(getRider());
|
||||
}
|
||||
@ -184,7 +182,7 @@ public class Catapult extends SiegeWeapon
|
||||
|
||||
protected boolean OverrideMount(Player player)
|
||||
{
|
||||
ArmorStand stand = (ArmorStand) getEntity("Point_" + getPoint(_yaw));
|
||||
ArmorStand stand = (ArmorStand) getEntity("Point_" + getPoint(Math.toDegrees(((ArmorStand) getEntity("WEAPON")).getHeadPose().getY())));
|
||||
|
||||
stand.setPassenger(player);
|
||||
|
||||
|
@ -211,11 +211,6 @@ public abstract class SiegeWeapon implements Listener
|
||||
ArmorStand armorStand = (ArmorStand) getEntity("WEAPON");
|
||||
double standYaw = _yaw % 360;
|
||||
|
||||
if (getRider() == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
if (getRider() != null)
|
||||
{
|
||||
double riderYaw = (getRider().getLocation().getYaw() + (_invertRotation ? 180 : 0)) % 360;
|
||||
|
Loading…
Reference in New Issue
Block a user