    001    package cpw.mods.fml.client;
    002
    003    import cpw.mods.fml.common.IFMLHandledException;
    004    import cpw.mods.fml.common.Side;
    005    import cpw.mods.fml.common.asm.SideOnly;
    006    import net.minecraft.src.FontRenderer;
    007    import net.minecraft.src.GuiErrorScreen;
    008
    009    /**
    010     * If a mod throws this exception during loading, it will be called back to render
    011     * the error screen through the methods below. This error will not be cleared, and will
    012     * not allow the game to carry on, but might be useful if your mod wishes to report
    013     * a fatal configuration error in a pretty way.
    014     *
    015     * Throw this through a proxy. It won't work on the dedicated server environment.
    016     * @author cpw
    017     *
    018     */
    019    @SideOnly(Side.CLIENT)
    020    public abstract class CustomModLoadingErrorDisplayException extends RuntimeException implements IFMLHandledException
    021    {
    022        /**
    023         * Called after the GUI is inited by the parent code. You can do extra stuff here, maybe?
    024         *
    025         * @param errorScreen The error screen we're painting
    026         * @param fontRenderer A font renderer for you
    027         */
    028        public abstract void initGui(GuiErrorScreen errorScreen, FontRenderer fontRenderer);
    029
    030        /**
    031         * Draw your error to the screen.
    032         *
    033         * <br/><em>Warning: Minecraft is in a deep error state.</em> <strong>All</strong> it can do is stop.
    034         * Do not try and do anything involving complex user interaction here.
    035         *
    036         * @param errorScreen The error screen to draw to
    037         * @param fontRenderer A font renderer for you
    038         * @param mouseRelX Mouse X
    039         * @param mouseRelY Mouse Y
    040         * @param tickTime tick time
    041         */
    042        public abstract void drawScreen(GuiErrorScreen errorScreen, FontRenderer fontRenderer, int mouseRelX, int mouseRelY, float tickTime);
    043    }