Skip to content

Commit

Permalink
This is a FML event, should be in mod class
Browse files Browse the repository at this point in the history
Signed-off-by: Chris Sanders <zidane@outlook.com>
  • Loading branch information
Chris Sanders committed Jul 8, 2014
1 parent bd6bc12 commit aa31206
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
6 changes: 0 additions & 6 deletions src/main/java/org/obsidianbox/obsidian/GameListener.java
Original file line number Diff line number Diff line change
Expand Up @@ -104,10 +104,4 @@ public void onGuiOpen(GuiOpenEvent event) {
public void onPlayerJoin(PlayerEvent.PlayerLoggedInEvent event) {
game.getPipeline().sendTo(new AddonListMessage(), event.player);
}

@SubscribeEvent
public void onMissingMismappings(FMLMissingMappingsEvent.MissingMapping event) {
game.getLogger().info(game.getSide().toString() + " fired MissingMappingsEvent!");
event.ignore();
}
}
7 changes: 7 additions & 0 deletions src/main/java/org/obsidianbox/obsidian/ObsidianMod.java
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
import cpw.mods.fml.common.Mod;
import cpw.mods.fml.common.Mod.EventHandler;
import cpw.mods.fml.common.event.FMLInitializationEvent;
import cpw.mods.fml.common.event.FMLMissingMappingsEvent;
import cpw.mods.fml.common.event.FMLPostInitializationEvent;
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
import cpw.mods.fml.common.network.FMLNetworkEvent;
Expand Down Expand Up @@ -181,6 +182,12 @@ public void onClientConnectedToServerEvent(FMLNetworkEvent.ClientConnectedToServ
}
}

@EventHandler
public void onMissingMismappings(FMLMissingMappingsEvent.MissingMapping event) {
game.getLogger().info(game.getSide().toString() + " fired MissingMappingsEvent!");
event.ignore();
}

@SideOnly(Side.CLIENT)
private void setupRenderer() {
final GuiRenderer guiRenderer = new GuiRenderer(game);
Expand Down

0 comments on commit aa31206

Please sign in to comment.