Archiviert
13
0
Dieser Commit ist enthalten in:
Yaruma3341 2020-02-02 00:12:54 +01:00
Ursprung ddfba678be
Commit 0eef172b86

Datei anzeigen

@ -18,7 +18,7 @@ public class ShieldListener implements Listener {
double radius = 2.5D; double radius = 2.5D;
double multiplyer = 1.1D; double multiplyer = 1.1D;
float height = 0.8F; float height = 1.0F;
@EventHandler @EventHandler
public void handlePlayerMove(PlayerMoveEvent event) { public void handlePlayerMove(PlayerMoveEvent event) {
@ -46,7 +46,7 @@ public class ShieldListener implements Listener {
double y = location.getY() - playerLocation.getY(); double y = location.getY() - playerLocation.getY();
double z = location.getZ() - playerLocation.getZ(); double z = location.getZ() - playerLocation.getZ();
entityPlayer.setVelocity(new Vector(x, y, z).multiply(multiplyer).add(new Vector(0.0F, height, 0.0F))); entityPlayer.setVelocity(new Vector(x, y, z).multiply(multiplyer)/*.add(new Vector(0.0F, height, 0.0F))*/);
} }
} else { } else {
for(Entity entity : nearbyEntities) { for(Entity entity : nearbyEntities) {
@ -67,7 +67,7 @@ public class ShieldListener implements Listener {
double y = playerLocation.getY() - location.getY(); double y = playerLocation.getY() - location.getY();
double z = playerLocation.getZ() - location.getZ(); double z = playerLocation.getZ() - location.getZ();
player.setVelocity(new Vector(x, y, z).multiply(multiplyer).add(new Vector(0.0F, height, 0.0F))); player.setVelocity(new Vector(x, y, z).multiply(multiplyer)/*.add(new Vector(0.0F, height, 0.0F))*/);
} }
} }
} }