MinecraftForge/MinecraftForge — pull request #802 by HoBoS-TaCo (2013-09-28 07:08:08+00:00)
Title: Added custom EnumGameTypes

These additions will allow custom EnumGameTypes to be added which also appear correctly in world select, world create and with the gamemode command.

All mods need to do is:
```java
EnumGameType gameType = EnumHelper.addGameType("CUSTOM", "3", "customType");
LanguageRegistry.instance().addStringLocalization("gameMode.customType", "Custom Mode");
LanguageRegistry.instance().addStringLocalization("selectWorld.gameMode.customType", "Custom");
LanguageRegistry.instance().addStringLocalization("selectWorld.gameMode.customType.line1", "This is Custom Mode, it ");
LanguageRegistry.instance().addStringLocalization("selectWorld.gameMode.customType.line2", "is very fun.");
GameTypeManager.registerGameType(gameType);
```

* When mods implementing custom game types are removed worlds using these types automatically switch back to survival mode.
* ```EnumHelperClient.addGameType(String, int, String)``` was moved to EnumHelperClient as it's used on the server as well.
* PlayerControllerMP changes were due to the HUD not displaying on custom game modes.