use of dev.hypnotic.ui.OptionsScreen in project Hypnotic-Client by Hypnotic-Development.
the class ClientPlayerEntityMixin method tick.
@Inject(method = "tick", at = @At("HEAD"), cancellable = true)
public void tick(CallbackInfo ci) {
for (Mod mod : ModuleManager.INSTANCE.modules) {
if (mc.player != null) {
if (mod.isBinding() && mc.currentScreen == null) {
try {
mc.setScreen(new BindingScreen(mod, null));
} catch (Exception e) {
}
}
if (mod.isEnabled())
mod.onTick();
mod.onTickDisabled();
}
}
for (HudModule mod : HudManager.INSTANCE.hudModules) {
if (mc.player != null) {
if (mod.isEnabled())
mod.onTick();
mod.onTickDisabled();
}
}
RenderUtils.INSTANCE.onTick();
if (mc.world != null)
BaritoneAPI.getSettings().chatControl.value = false;
OptionsScreen options = OptionsScreen.INSTANCE;
BaritoneAPI.getSettings().allowBreak.value = options.allowBreak.isEnabled();
BaritoneAPI.getSettings().allowParkour.value = options.allowParkour.isEnabled();
BaritoneAPI.getSettings().allowParkourAscend.value = options.allowParkour.isEnabled();
BaritoneAPI.getSettings().allowParkourPlace.value = options.allowParkour.isEnabled();
BaritoneAPI.getSettings().allowDownward.value = options.allowParkour.isEnabled();
BaritoneAPI.getSettings().allowDiagonalAscend.value = options.allowParkour.isEnabled();
BaritoneAPI.getSettings().allowDiagonalDescend.value = options.allowParkour.isEnabled();
BaritoneAPI.getSettings().chatControl.value = options.chatControl.isEnabled();
BaritoneAPI.getSettings().allowPlace.value = options.allowPlace.isEnabled();
BaritoneAPI.getSettings().allowInventory.value = options.allowInventory.isEnabled();
BaritoneAPI.getSettings().assumeWalkOnWater.value = options.assumeJesus.isEnabled();
BaritoneAPI.getSettings().assumeWalkOnLava.value = options.assumeJesus.isEnabled();
BaritoneAPI.getSettings().assumeStep.value = options.assumeStep.isEnabled();
BaritoneAPI.getSettings().assumeSafeWalk.value = options.assumeSafewalk.isEnabled();
}
Aggregations