When initially asked to Log in, rename "Cancel" to "Skip" button to indicate that the user doesn't have to log in in order to use the mod

This commit is contained in:
CrushedPixel
2015-08-07 12:23:58 +02:00
parent 6e07bde07c
commit 40aaf7fbef
5 changed files with 13 additions and 5 deletions

View File

@@ -78,10 +78,16 @@ public class GuiLoginPrompt extends AbstractGuiScreen<GuiLoginPrompt> {
password.onTextChanged(contentValidation);
}
public GuiLoginPrompt(net.minecraft.client.gui.GuiScreen parent, net.minecraft.client.gui.GuiScreen successScreen) {
public GuiLoginPrompt(net.minecraft.client.gui.GuiScreen parent,
net.minecraft.client.gui.GuiScreen successScreen, boolean manuallyTriggered) {
this.parent = parent;
this.successScreen = successScreen;
//if the login prompt was opened automatically (on mod startup), show a "skip" instead of "cancel" button
if(!manuallyTriggered) {
cancelButton.setI18nLabel("replaymod.gui.login.skip");
}
setLayout(new CustomLayout<GuiLoginPrompt>() {
@Override
protected void layout(GuiLoginPrompt container, int width, int height) {