mirror of
https://github.com/Creators-of-Create/Create.git
synced 2024-12-15 22:03:41 +01:00
Ponder fix-ups
- Input window elements no longer use integer coordinates - Comfy reading is now a config option and persists across ponder UIs - Disabled editor mode
This commit is contained in:
parent
ff4a9e5c78
commit
389b2e0e90
4 changed files with 25 additions and 12 deletions
|
@ -3,7 +3,7 @@ package com.simibubi.create.foundation.config;
|
|||
public class CClient extends ConfigBase {
|
||||
|
||||
public ConfigGroup client = group(0, "client",
|
||||
"Client-only settings - If you're looking for general settings, look inside your worlds serverconfig folder!");
|
||||
"Client-only settings - If you're looking for general settings, look inside your worlds serverconfig folder!");
|
||||
public ConfigBool tooltips = b(true, "enableTooltips", "Show item descriptions on Shift and controls on Ctrl.");
|
||||
public ConfigBool enableOverstressedTooltip =
|
||||
b(true, "enableOverstressedTooltip", "Display a tooltip when looking at overstressed components.");
|
||||
|
@ -12,13 +12,18 @@ public class CClient extends ConfigBase {
|
|||
public ConfigFloat fanParticleDensity = f(.5f, 0, 1, "fanParticleDensity");
|
||||
public ConfigBool rainbowDebug =
|
||||
b(true, "enableRainbowDebug", "Show colourful debug information while the F3-Menu is open.");
|
||||
|
||||
public ConfigBool experimentalRendering =
|
||||
b(true, "experimentalRendering", "Use modern OpenGL features to drastically increase performance.");
|
||||
public ConfigInt overlayOffsetX = i(20, Integer.MIN_VALUE, Integer.MAX_VALUE, "overlayOffsetX",
|
||||
"Offset the overlay from goggle- and hover- information by this many pixels on the X axis; Use /create overlay");
|
||||
public ConfigInt overlayOffsetY = i(0, Integer.MIN_VALUE, Integer.MAX_VALUE, "overlayOffsetY",
|
||||
"Offset the overlay from goggle- and hover- information by this many pixels on the Y axis; Use /create overlay");
|
||||
public ConfigBool smoothPlacementIndicator = b(false, "smoothPlacementIndicator",
|
||||
"Use an alternative indicator when showing where the assisted placement ends up relative to your crosshair");
|
||||
|
||||
public ConfigInt overlayOffsetX = i(20, Integer.MIN_VALUE, Integer.MAX_VALUE, "overlayOffsetX", "Offset the overlay from goggle- and hover- information by this many pixels on the X axis; Use /create overlay");
|
||||
public ConfigInt overlayOffsetY = i(0, Integer.MIN_VALUE, Integer.MAX_VALUE, "overlayOffsetY", "Offset the overlay from goggle- and hover- information by this many pixels on the Y axis; Use /create overlay");
|
||||
public ConfigBool smoothPlacementIndicator = b(false, "smoothPlacementIndicator", "Use an alternative indicator when showing where the assisted placement ends up relative to your crosshair");
|
||||
public ConfigGroup ponder = group(1, "ponder", "Ponder settings");
|
||||
public ConfigBool comfyReading =
|
||||
b(false, "comfyReading", "Slow down a ponder scene whenever there is text on screen.");
|
||||
|
||||
@Override
|
||||
public String getName() {
|
||||
|
|
|
@ -12,6 +12,7 @@ import org.lwjgl.opengl.GL11;
|
|||
|
||||
import com.mojang.blaze3d.matrix.MatrixStack;
|
||||
import com.mojang.blaze3d.systems.RenderSystem;
|
||||
import com.simibubi.create.foundation.config.AllConfigs;
|
||||
import com.simibubi.create.foundation.gui.AllGuiTextures;
|
||||
import com.simibubi.create.foundation.gui.AllIcons;
|
||||
import com.simibubi.create.foundation.gui.GuiGameElement;
|
||||
|
@ -80,7 +81,6 @@ public class PonderUI extends NavigatableSimiScreen {
|
|||
PonderChapter chapter = null;
|
||||
|
||||
private boolean userViewMode;
|
||||
private boolean slowTextMode;
|
||||
private boolean identifyMode;
|
||||
private ItemStack hoveredTooltipItem;
|
||||
private BlockPos hoveredBlockPos;
|
||||
|
@ -205,7 +205,7 @@ public class PonderUI extends NavigatableSimiScreen {
|
|||
.fade(0, -1));
|
||||
|
||||
widgets.add(slowMode = new PonderButton(width - 20 - 31, bY, () -> {
|
||||
slowTextMode = !slowTextMode;
|
||||
setComfyReadingEnabled(!isComfyReadingEnabled());
|
||||
}).showing(AllIcons.I_MTD_SLOW_MODE)
|
||||
.fade(0, -1));
|
||||
|
||||
|
@ -269,7 +269,7 @@ public class PonderUI extends NavigatableSimiScreen {
|
|||
PonderScene activeScene = scenes.get(index);
|
||||
|
||||
extendedTickLength = 0;
|
||||
if (slowTextMode)
|
||||
if (isComfyReadingEnabled())
|
||||
activeScene.forEachVisible(TextWindowElement.class, twe -> extendedTickLength = 2);
|
||||
|
||||
if (extendedTickTimer == 0) {
|
||||
|
@ -616,7 +616,7 @@ public class PonderUI extends NavigatableSimiScreen {
|
|||
userMode.dim();
|
||||
}
|
||||
|
||||
if (slowTextMode)
|
||||
if (isComfyReadingEnabled())
|
||||
slowMode.flash();
|
||||
else
|
||||
slowMode.dim();
|
||||
|
@ -981,4 +981,12 @@ public class PonderUI extends NavigatableSimiScreen {
|
|||
hoveredTooltipItem = ItemStack.EMPTY;
|
||||
}
|
||||
|
||||
public boolean isComfyReadingEnabled() {
|
||||
return AllConfigs.CLIENT.comfyReading.get();
|
||||
}
|
||||
|
||||
public void setComfyReadingEnabled(boolean slowTextMode) {
|
||||
AllConfigs.CLIENT.comfyReading.set(slowTextMode);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -8,7 +8,7 @@ import net.minecraft.block.Blocks;
|
|||
|
||||
public class PonderIndex {
|
||||
|
||||
public static final boolean EDITOR_MODE = true;
|
||||
public static final boolean EDITOR_MODE = false;
|
||||
|
||||
public static void register() {
|
||||
// Register storyboards here
|
||||
|
|
|
@ -84,8 +84,8 @@ public class InputWindowElement extends AnimatedOverlayElement {
|
|||
int width = 0;
|
||||
int height = 0;
|
||||
|
||||
int xFade = direction == Pointing.RIGHT ? -1 : direction == Pointing.LEFT ? 1 : 0;
|
||||
int yFade = direction == Pointing.DOWN ? -1 : direction == Pointing.UP ? 1 : 0;
|
||||
float xFade = direction == Pointing.RIGHT ? -1 : direction == Pointing.LEFT ? 1 : 0;
|
||||
float yFade = direction == Pointing.DOWN ? -1 : direction == Pointing.UP ? 1 : 0;
|
||||
xFade *= 10 * (1 - fade);
|
||||
yFade *= 10 * (1 - fade);
|
||||
|
||||
|
|
Loading…
Reference in a new issue