Allow all camera rotation axis to be ignored separately during rendering

This commit is contained in:
johni0702
2015-07-17 12:43:02 +02:00
parent d360ee5e2e
commit fdd2c7ecf7
3 changed files with 18 additions and 7 deletions

View File

@@ -373,11 +373,14 @@ public class CustomEntityRenderer<D extends CaptureData> implements eu.crushedpi
}
protected void orientCamera(float partialTicks) {
if (options.isIgnoreCameraRotation()) {
Entity entity = mc.getRenderViewEntity();
// Stop the minecraft code from doing any rotation
entity.prevRotationPitch = entity.rotationPitch = 0;
Entity entity = mc.getRenderViewEntity();
if (options.getIgnoreCameraRotation()[0]) {
entity.prevRotationYaw = entity.rotationYaw = 0;
}
if (options.getIgnoreCameraRotation()[1]) {
entity.prevRotationPitch = entity.rotationPitch = 0;
}
if (options.getIgnoreCameraRotation()[2]) {
ReplayHandler.setCameraTilt(0);
}