public void event(BombermanEvents event) { switch (event) { case KILL_MEAT_CHOPPER: increaseScore(); break; case KILL_DESTROY_WALL: increaseScore(); break; case KILL_BOMBERMAN: gameOver(); break; } if (listener != null) { listener.event(event.name()); } }
/** * Борда может файрить ивенты юзера с помощью этого метода * * @param event тип ивента */ public void event(Events event) { switch (event) { case CATCH_BOMB: gameOver(); break; case CATCH_GOLD: increaseScore(); break; case CATCH_SHIT: decreaseScore(); break; } if (listener != null) { listener.event(event); } }
private void fire(MinesweeperEvents event) { if (listener != null) { listener.event(event); } }