mirror of
https://github.com/Sollace/Unicopia.git
synced 2025-02-01 03:26:44 +01:00
Fix server crash when updating bat ponies
This commit is contained in:
parent
a57d1cf642
commit
e8646a7daf
1 changed files with 8 additions and 1 deletions
|
@ -1,8 +1,10 @@
|
||||||
package com.minelittlepony.unicopia.util;
|
package com.minelittlepony.unicopia.util;
|
||||||
|
|
||||||
import com.minelittlepony.unicopia.client.UnicopiaClient;
|
import com.minelittlepony.unicopia.client.UnicopiaClient;
|
||||||
|
import com.minelittlepony.unicopia.server.world.UnicopiaWorldProperties;
|
||||||
|
|
||||||
import net.minecraft.entity.Entity;
|
import net.minecraft.entity.Entity;
|
||||||
|
import net.minecraft.server.world.ServerWorld;
|
||||||
import net.minecraft.util.hit.HitResult.Type;
|
import net.minecraft.util.hit.HitResult.Type;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.util.math.MathHelper;
|
import net.minecraft.util.math.MathHelper;
|
||||||
|
@ -32,7 +34,12 @@ public interface MeteorlogicalUtil {
|
||||||
playerAngle = 1 - playerAngle;
|
playerAngle = 1 - playerAngle;
|
||||||
}
|
}
|
||||||
|
|
||||||
playerYaw += UnicopiaClient.getInstance().tangentalSkyAngle.getValue();
|
if (world.isClient()) {
|
||||||
|
playerYaw += UnicopiaClient.getInstance().tangentalSkyAngle.getValue();
|
||||||
|
} else {
|
||||||
|
playerYaw += UnicopiaWorldProperties.forWorld((ServerWorld)world).getTangentalSkyAngle();
|
||||||
|
}
|
||||||
|
|
||||||
playerYaw = Math.abs(playerYaw);
|
playerYaw = Math.abs(playerYaw);
|
||||||
|
|
||||||
// check if day,
|
// check if day,
|
||||||
|
|
Loading…
Reference in a new issue