Package games.stendhal.server.events

Examples of games.stendhal.server.events.PlayerLoggedOnEvent


   */
  private void updatePlayerNameListForPlayersOnLogin(final Player playerToNotifyAbout) {
    SingletonRepository.getRuleProcessor().getOnlinePlayers().forAllPlayersExecute(new Task<Player>() {
      public void execute(final Player player) {
        if(playerToNotifyAbout.isGhost()) {
          playerToNotifyAbout.addEvent(new PlayerLoggedOnEvent(player.getName()));
          if (player.isGhost()) {
            player.addEvent(new PlayerLoggedOnEvent(playerToNotifyAbout.getName()));
          }
        } else {
          player.addEvent(new PlayerLoggedOnEvent(playerToNotifyAbout.getName()));
          if (!player.isGhost()) {
            playerToNotifyAbout.addEvent(new PlayerLoggedOnEvent(player.getName()));
          }
        }
      }
    });
  }
View Full Code Here

TOP

Related Classes of games.stendhal.server.events.PlayerLoggedOnEvent

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.