2015-08-29 14:33:25 +02:00
|
|
|
/*
|
2016-05-16 22:52:27 +02:00
|
|
|
* This file ("GuiAAAchievements.java") is part of the Actually Additions mod for Minecraft.
|
2015-08-29 14:33:25 +02:00
|
|
|
* It is created and owned by Ellpeck and distributed
|
|
|
|
* under the Actually Additions License to be found at
|
2016-05-16 22:52:27 +02:00
|
|
|
* http://ellpeck.de/actaddlicense
|
2015-08-29 14:33:25 +02:00
|
|
|
* View the source code at https://github.com/Ellpeck/ActuallyAdditions
|
|
|
|
*
|
2016-05-16 22:54:42 +02:00
|
|
|
* © 2015-2016 Ellpeck
|
2015-08-29 14:33:25 +02:00
|
|
|
*/
|
|
|
|
|
2016-01-05 04:47:35 +01:00
|
|
|
package de.ellpeck.actuallyadditions.mod.booklet;
|
2015-08-28 21:17:09 +02:00
|
|
|
|
2016-01-05 04:47:35 +01:00
|
|
|
import de.ellpeck.actuallyadditions.mod.achievement.InitAchievements;
|
2016-01-16 20:06:25 +01:00
|
|
|
import de.ellpeck.actuallyadditions.mod.util.ModUtil;
|
2015-08-28 21:17:09 +02:00
|
|
|
import net.minecraft.client.gui.GuiScreen;
|
|
|
|
import net.minecraft.client.gui.achievement.GuiAchievements;
|
|
|
|
import net.minecraft.stats.StatFileWriter;
|
2016-01-07 18:20:59 +01:00
|
|
|
import net.minecraftforge.fml.relauncher.ReflectionHelper;
|
2015-08-28 21:17:09 +02:00
|
|
|
|
2015-09-30 19:18:13 +02:00
|
|
|
/**
|
|
|
|
* (Partially excerpted from Botania by Vazkii with permission, thanks!)
|
|
|
|
*/
|
2015-08-28 21:17:09 +02:00
|
|
|
public class GuiAAAchievements extends GuiAchievements{
|
|
|
|
|
|
|
|
public GuiAAAchievements(GuiScreen screen, StatFileWriter writer){
|
|
|
|
super(screen, writer);
|
2016-01-16 20:06:25 +01:00
|
|
|
try{
|
|
|
|
ReflectionHelper.setPrivateValue(GuiAchievements.class, this, InitAchievements.pageNumber, 20);
|
|
|
|
}
|
|
|
|
catch(Exception e){
|
|
|
|
ModUtil.LOGGER.error("Something went wrong trying to open the Achievements GUI!", e);
|
|
|
|
}
|
2015-08-28 21:17:09 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
@Override
|
|
|
|
public void initGui(){
|
|
|
|
super.initGui();
|
2016-01-08 15:21:05 +01:00
|
|
|
this.buttonList.get(1).displayString = InitAchievements.theAchievementPage.getName();
|
2015-08-28 21:17:09 +02:00
|
|
|
}
|
|
|
|
}
|