@Environment(value=CLIENT) public class EditGameRulesScreen extends Screen
Modifier and Type | Class and Description |
---|---|
class |
EditGameRulesScreen.AbstractRuleWidget |
class |
EditGameRulesScreen.BooleanRuleWidget |
class |
EditGameRulesScreen.IntRuleWidget |
class |
EditGameRulesScreen.NamedRuleWidget |
class |
EditGameRulesScreen.RuleCategoryWidget |
class |
EditGameRulesScreen.RuleListWidget |
(package private) static interface |
EditGameRulesScreen.RuleWidgetFactory<T extends GameRules.Rule<T>> |
Modifier and Type | Field and Description |
---|---|
private ButtonWidget |
doneButton |
private GameRules |
gameRules |
private Set<EditGameRulesScreen.AbstractRuleWidget> |
invalidRuleWidgets |
private EditGameRulesScreen.RuleListWidget |
ruleListWidget |
private Consumer<Optional<GameRules>> |
ruleSaver |
private List<OrderedText> |
tooltip |
buttons, children, client, height, itemRenderer, passEvents, textRenderer, title, width
GUI_ICONS_TEXTURE, OPTIONS_BACKGROUND_TEXTURE, STATS_ICON_TEXTURE
Constructor and Description |
---|
EditGameRulesScreen(GameRules gameRules,
Consumer<Optional<GameRules>> ruleSaveConsumer) |
Modifier and Type | Method and Description |
---|---|
protected void |
init()
Called when a screen should be initialized.
|
private void |
markInvalid(EditGameRulesScreen.AbstractRuleWidget ruleWidget) |
private void |
markValid(EditGameRulesScreen.AbstractRuleWidget ruleWidget) |
void |
onClose() |
void |
removed() |
void |
render(MatrixStack matrices,
int mouseX,
int mouseY,
float delta) |
private void |
setTooltipDescription(List<OrderedText> description) |
private void |
updateDoneButton() |
addButton, addChild, children, filesDragged, getNarrationMessage, getTitle, getTooltipFromItem, handleTextClick, hasAltDown, hasControlDown, hasShiftDown, init, insertText, isCopy, isCut, isMouseOver, isPaste, isPauseScreen, isSelectAll, isValidCharacterForName, keyPressed, renderBackground, renderBackground, renderBackgroundTexture, renderOrderedTooltip, renderTextHoverEffect, renderTooltip, renderTooltip, renderTooltip, resize, sendMessage, sendMessage, shouldCloseOnEsc, tick, wrapScreenError
getFocused, isDragging, setDragging, setFocused
drawCenteredString, drawCenteredText, drawHorizontalLine, drawSprite, drawStringWithShadow, drawTexture, drawTexture, drawTexture, drawTexture, drawTextWithShadow, drawVerticalLine, fill, fillGradient, fillGradient, getZOffset, method_29343, setZOffset
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
changeFocus, charTyped, focusOn, hoveredElement, keyReleased, mouseClicked, mouseDragged, mouseReleased, mouseScrolled, setInitialFocus
mouseMoved
private EditGameRulesScreen.RuleListWidget ruleListWidget
private final Set<EditGameRulesScreen.AbstractRuleWidget> invalidRuleWidgets
private ButtonWidget doneButton
@Nullable private List<OrderedText> tooltip
private final GameRules gameRules
protected void init()
This method is called when this screen is opened
or resized.
public void render(MatrixStack matrices, int mouseX, int mouseY, float delta)
private void setTooltipDescription(@Nullable List<OrderedText> description)
private void updateDoneButton()
private void markInvalid(EditGameRulesScreen.AbstractRuleWidget ruleWidget)
private void markValid(EditGameRulesScreen.AbstractRuleWidget ruleWidget)