mirror of
https://github.com/GTNewHorizons/CraftTweaker.git
synced 2026-11-26 23:03:12 +00:00
[ci skip] spotlessApply with the new settings
This commit is contained in:
1 parent
6b208b98bc
commit
a309488cdf
214 files changed
+9283
-9265
No files matched your search
@@ -4,57 +4,43 @@ import net.minecraft.client.gui.GuiButton;
|
||||
import net.minecraft.client.gui.GuiScreen;
|
||||
|
||||
/**
|
||||
* This screen is shown when a client has been modified with a permanent
|
||||
* modification and the player logs into a game with a different script. It asks
|
||||
* the player to restart the game.
|
||||
* This screen is shown when a client has been modified with a permanent modification and the player logs into a game
|
||||
* with a different script. It asks the player to restart the game.
|
||||
*
|
||||
* @author Stan Hebben
|
||||
*/
|
||||
public class GuiCannotRemodify extends GuiScreen {
|
||||
private final String message1;
|
||||
private final String message2;
|
||||
private final String message3;
|
||||
|
||||
public GuiCannotRemodify(String message1, String message2, String message3) {
|
||||
this.message1 = message1;
|
||||
this.message2 = message2;
|
||||
this.message3 = message3;
|
||||
}
|
||||
private final String message1;
|
||||
private final String message2;
|
||||
private final String message3;
|
||||
|
||||
@Override
|
||||
public void initGui() {
|
||||
this.buttonList.clear();
|
||||
this.buttonList.add(
|
||||
new GuiButton(0, this.width / 2 - 100, this.height / 4 + 120 + 12, "Close")
|
||||
);
|
||||
}
|
||||
public GuiCannotRemodify(String message1, String message2, String message3) {
|
||||
this.message1 = message1;
|
||||
this.message2 = message2;
|
||||
this.message3 = message3;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void drawScreen(int par1, int par2, float par3) {
|
||||
this.drawDefaultBackground();
|
||||
this.drawCenteredString(
|
||||
this.fontRendererObj,
|
||||
message1,
|
||||
this.width / 2, this.height / 2 - 40,
|
||||
11184810);
|
||||
this.drawCenteredString(
|
||||
this.fontRendererObj,
|
||||
message2,
|
||||
this.width / 2, this.height / 2 - 20,
|
||||
11184810);
|
||||
this.drawCenteredString(
|
||||
this.fontRendererObj,
|
||||
message3,
|
||||
this.width / 2, this.height / 2 - 0,
|
||||
11184810);
|
||||
@Override
|
||||
public void initGui() {
|
||||
this.buttonList.clear();
|
||||
this.buttonList.add(new GuiButton(0, this.width / 2 - 100, this.height / 4 + 120 + 12, "Close"));
|
||||
}
|
||||
|
||||
super.drawScreen(par1, par2, par3);
|
||||
}
|
||||
@Override
|
||||
public void drawScreen(int par1, int par2, float par3) {
|
||||
this.drawDefaultBackground();
|
||||
this.drawCenteredString(this.fontRendererObj, message1, this.width / 2, this.height / 2 - 40, 11184810);
|
||||
this.drawCenteredString(this.fontRendererObj, message2, this.width / 2, this.height / 2 - 20, 11184810);
|
||||
this.drawCenteredString(this.fontRendererObj, message3, this.width / 2, this.height / 2 - 0, 11184810);
|
||||
|
||||
@Override
|
||||
protected void actionPerformed(GuiButton par1GuiButton) {
|
||||
if (par1GuiButton.id == 0) {
|
||||
System.exit(0);
|
||||
}
|
||||
}
|
||||
super.drawScreen(par1, par2, par3);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void actionPerformed(GuiButton par1GuiButton) {
|
||||
if (par1GuiButton.id == 0) {
|
||||
System.exit(0);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user