001package cpw.mods.fml.client;
002
003import net.minecraft.client.gui.GuiErrorScreen;
004import cpw.mods.fml.common.Loader;
005import cpw.mods.fml.common.WrongMinecraftVersionException;
006import cpw.mods.fml.common.versioning.ArtifactVersion;
007
008public class GuiWrongMinecraft extends GuiErrorScreen
009{
010    private WrongMinecraftVersionException wrongMC;
011    public GuiWrongMinecraft(WrongMinecraftVersionException wrongMC)
012    {
013        this.wrongMC = wrongMC;
014    }
015    @Override
016
017    /**
018     * Adds the buttons (and other controls) to the screen in question.
019     */
020    public void initGui()
021    {
022        super.initGui();
023    }
024    @Override
025
026    /**
027     * Draws the screen and all the components in it.
028     */
029    public void drawScreen(int par1, int par2, float par3)
030    {
031        this.drawDefaultBackground();
032        int offset = 75;
033        this.drawCenteredString(this.fontRenderer, "Forge Mod Loader has found a problem with your minecraft installation", this.width / 2, offset, 0xFFFFFF);
034        offset+=10;
035        this.drawCenteredString(this.fontRenderer, String.format("The mod listed below does not want to run in Minecraft version %s", Loader.instance().getMinecraftModContainer().getVersion()), this.width / 2, offset, 0xFFFFFF);
036        offset+=5;
037        offset+=10;
038        this.drawCenteredString(this.fontRenderer, String.format("%s (%s) wants Minecraft %s", wrongMC.mod.getName(), wrongMC.mod.getModId(), wrongMC.mod.acceptableMinecraftVersionRange()), this.width / 2, offset, 0xEEEEEE);
039        offset+=20;
040        this.drawCenteredString(this.fontRenderer, "The file 'ForgeModLoader-client-0.log' contains more information", this.width / 2, offset, 0xFFFFFF);
041    }
042}