Implemented review changes
This commit is contained in:
@@ -39,7 +39,7 @@ To access the **Replay Mod Settings** from the Main Menu click the **"Replay Vie
|
|||||||
While playing, you can click the 'Mods' button in the Pause screen to reach **Replay Mod Settings** if you use Minecraft 1.12.2 and below, or have the mod [Mod Menu](https://www.curseforge.com/minecraft/mc-mods/modmenu) installed.
|
While playing, you can click the 'Mods' button in the Pause screen to reach **Replay Mod Settings** if you use Minecraft 1.12.2 and below, or have the mod [Mod Menu](https://www.curseforge.com/minecraft/mc-mods/modmenu) installed.
|
||||||
|
|
||||||
When in a Replay, you can either bind a hotkey to the **Replay Mod Settings** in Minecraft's Control settings
|
When in a Replay, you can either bind a hotkey to the **Replay Mod Settings** in Minecraft's Control settings
|
||||||
or use the hotkey GUI by clicking on the arrow button in the lower left corner.
|
or use the hotkey GUI by clicking on the hamburger button in the lower left corner.
|
||||||
|
|
||||||
# Recording [recording]
|
# Recording [recording]
|
||||||

|

|
||||||
|
|||||||
@@ -19,18 +19,11 @@ public class QuickMode extends EventRegistrations implements Extra {
|
|||||||
|
|
||||||
private final IGuiImage indicator = new GuiImage().setTexture(ReplayMod.TEXTURE, 40, 100, 16, 16).setSize(16, 16);
|
private final IGuiImage indicator = new GuiImage().setTexture(ReplayMod.TEXTURE, 40, 100, 16, 16).setSize(16, 16);
|
||||||
|
|
||||||
private MinecraftClient mc;
|
|
||||||
private boolean active;
|
private boolean active;
|
||||||
//#if MC>=11400
|
|
||||||
private double originalGamma;
|
|
||||||
//#else
|
|
||||||
//$$ private float originalGamma;
|
|
||||||
//#endif
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void register(final ReplayMod mod) throws Exception {
|
public void register(final ReplayMod mod) throws Exception {
|
||||||
this.module = ReplayModReplay.instance;
|
this.module = ReplayModReplay.instance;
|
||||||
this.mc = mod.getMinecraft();
|
|
||||||
|
|
||||||
mod.getKeyBindingRegistry().registerKeyBinding("replaymod.input.quickmode", Keyboard.KEY_Q, new Runnable() {
|
mod.getKeyBindingRegistry().registerKeyBinding("replaymod.input.quickmode", Keyboard.KEY_Q, new Runnable() {
|
||||||
@Override
|
@Override
|
||||||
@@ -39,15 +32,15 @@ public class QuickMode extends EventRegistrations implements Extra {
|
|||||||
if (replayHandler == null) {
|
if (replayHandler == null) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
active = !active;
|
|
||||||
updateIndicator(replayHandler.getOverlay());
|
updateIndicator(replayHandler.getOverlay());
|
||||||
replayHandler.getReplaySender().setSyncModeAndWait();
|
replayHandler.getReplaySender().setSyncModeAndWait();
|
||||||
mod.runLater(() ->
|
mod.runLater(() -> {
|
||||||
replayHandler.ensureQuickModeInitialized(() -> {
|
replayHandler.ensureQuickModeInitialized(() -> {
|
||||||
replayHandler.setQuickMode(active);
|
active = !active;
|
||||||
replayHandler.getReplaySender().setAsyncMode(true);
|
replayHandler.setQuickMode(active);
|
||||||
})
|
replayHandler.getReplaySender().setAsyncMode(true);
|
||||||
);
|
});
|
||||||
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -60,7 +53,7 @@ public class QuickMode extends EventRegistrations implements Extra {
|
|||||||
|
|
||||||
private void updateIndicator(GuiReplayOverlay overlay) {
|
private void updateIndicator(GuiReplayOverlay overlay) {
|
||||||
if (active) {
|
if (active) {
|
||||||
overlay.statusIndicatorPanel.addElements(new HorizontalLayout.Data(2), indicator);
|
overlay.statusIndicatorPanel.addElements(new HorizontalLayout.Data(1), indicator);
|
||||||
} else {
|
} else {
|
||||||
overlay.statusIndicatorPanel.removeElement(indicator);
|
overlay.statusIndicatorPanel.removeElement(indicator);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -124,17 +124,6 @@ public class ReplayModReplay implements Module {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
registry.registerKeyBinding("replaymod.input.quickmode", Keyboard.KEY_Q, () -> {
|
|
||||||
if (replayHandler != null) {
|
|
||||||
replayHandler.getReplaySender().setSyncModeAndWait();
|
|
||||||
core.runLater(() ->
|
|
||||||
replayHandler.ensureQuickModeInitialized(() -> {
|
|
||||||
replayHandler.setQuickMode(!replayHandler.isQuickMode());
|
|
||||||
replayHandler.getReplaySender().setAsyncMode(true);
|
|
||||||
}));
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
core.getKeyBindingRegistry().registerKeyBinding("replaymod.input.rollclockwise", Keyboard.KEY_L, () -> {
|
core.getKeyBindingRegistry().registerKeyBinding("replaymod.input.rollclockwise", Keyboard.KEY_L, () -> {
|
||||||
// Noop, actual handling logic in CameraEntity#update
|
// Noop, actual handling logic in CameraEntity#update
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user