Skip to content

Commit

Permalink
fix: post game start event twice
Browse files Browse the repository at this point in the history
  • Loading branch information
mouse0w0 committed Jul 7, 2019
1 parent 59e8a55 commit 2ead592
Showing 1 changed file with 0 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@
import nullengine.client.sound.EngineSoundManager;
import nullengine.enginemod.EngineModListeners;
import nullengine.event.engine.EngineEvent;
import nullengine.event.game.GameStartEvent;
import nullengine.game.Game;
import nullengine.logic.Ticker;
import nullengine.mod.ModContainer;
Expand Down Expand Up @@ -209,10 +208,8 @@ public void startGame(Game game) {
throw new IllegalArgumentException("Game must be GameClient");
}

eventBus.post(new GameStartEvent.Pre(game));
this.game = (GameClient) Objects.requireNonNull(game);
game.init();
eventBus.post(new GameStartEvent.Post(game));
}

@Override
Expand Down

0 comments on commit 2ead592

Please sign in to comment.