diff options
author | Lorenz <ESs95s3P5z8Pheb> | 2022-07-08 23:34:20 +0200 |
---|---|---|
committer | Lorenz <ESs95s3P5z8Pheb> | 2022-07-08 23:34:20 +0200 |
commit | 5a609c48b9d0ebb89c19627cd6dbbff21fc8324a (patch) | |
tree | 82d644a99141b8d62af2e5a999dcbbfa77b0f520 /src/main/java/at/lorenz/mod/mixinhooks | |
parent | 5ac4f2123f2750a6a8d8a6ad1bb9c6e0177c270e (diff) | |
download | skyhanni-5a609c48b9d0ebb89c19627cd6dbbff21fc8324a.tar.gz skyhanni-5a609c48b9d0ebb89c19627cd6dbbff21fc8324a.tar.bz2 skyhanni-5a609c48b9d0ebb89c19627cd6dbbff21fc8324a.zip |
add hide exp bottles support
Diffstat (limited to 'src/main/java/at/lorenz/mod/mixinhooks')
-rw-r--r-- | src/main/java/at/lorenz/mod/mixinhooks/RenderManagerHook.kt | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/src/main/java/at/lorenz/mod/mixinhooks/RenderManagerHook.kt b/src/main/java/at/lorenz/mod/mixinhooks/RenderManagerHook.kt new file mode 100644 index 000000000..69242d651 --- /dev/null +++ b/src/main/java/at/lorenz/mod/mixinhooks/RenderManagerHook.kt @@ -0,0 +1,25 @@ +package at.lorenz.mod.mixinhooks + +import at.lorenz.mod.events.CheckRenderEntityEvent +import net.minecraft.client.renderer.culling.ICamera +import net.minecraft.entity.Entity +import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable + +fun shouldRender( + entityIn: Entity, + camera: ICamera, + camX: Double, + camY: Double, + camZ: Double, + cir: CallbackInfoReturnable<Boolean> +) { + if ( + CheckRenderEntityEvent( + entityIn, + camera, + camX, + camY, + camZ + ).postAndCatch() + ) cir.returnValue = false +}
\ No newline at end of file |