From 7e4825472f433d4d7e6116f94c219d05642bc418 Mon Sep 17 00:00:00 2001 From: jojo Date: Fri, 22 May 2020 17:46:03 +0200 Subject: [PATCH] Remove FacingEnemy Math.PI Add FacingEnemy 180 --- FightSystem_API/src/de/steamwar/fightsystem/Config.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/FightSystem_API/src/de/steamwar/fightsystem/Config.java b/FightSystem_API/src/de/steamwar/fightsystem/Config.java index 20d5cc7..5aae3ab 100644 --- a/FightSystem_API/src/de/steamwar/fightsystem/Config.java +++ b/FightSystem_API/src/de/steamwar/fightsystem/Config.java @@ -252,8 +252,8 @@ public class Config { World world = Bukkit.getWorlds().get(0); double yaw = Math.toDegrees(Math.atan2(TeamBluetoReddistanceZ, TeamBluetoReddistanceX)); double pitch = Math.toDegrees(Math.atan2(Math.sqrt(TeamBluetoReddistanceZ * TeamBluetoReddistanceZ + TeamBluetoReddistanceX * TeamBluetoReddistanceX), TeamBluetoReddistanceY) + Math.PI); - double yawInverted = ((yaw + 90 + 180) * Math.PI) / 180; - double pitchInverted = ((90 - pitch) * Math.PI) / 180; + double yawInverted = ((yaw + 90 + 180) * 180) / 180; + double pitchInverted = ((90 - pitch) * 180) / 180; TeamBlueSpawn = new Location(world, TeamBluePasteX + 0.5 + teamBlueSpawnOffsetX,