Ejemplo n.º 1
0
  /** This is adding broadcast to player. */
  public final void addPacketBroadcastMask(BroadcastMode mode) {
    packetBroadcastMask |= mode.mask();

    PacketBroadcaster.getInstance().add(this);

    // Debug
    if (log.isDebugEnabled())
      log.debug("PacketBroadcaster: Packet " + mode.name() + " added to player " + this.getName());
  }
Ejemplo n.º 2
0
  /** This is removing broadcast from player. */
  public final void removePacketBroadcastMask(BroadcastMode mode) {
    packetBroadcastMask &= ~mode.mask();

    // Debug
    if (log.isDebugEnabled())
      log.debug(
          "PacketBroadcaster: Packet "
              + mode.name()
              + " removed from player "
              + ((Player) this).getName());
  }
Ejemplo n.º 3
0
  /** This is removing broadcast from player. */
  public final void removePacketBroadcastMask(BroadcastMode mode) {
    packetBroadcastMask &= ~mode.mask();

    // Debug
    if (log.isDebugEnabled())
      log.debug(
          "PacketBroadcaster: Packet "
              + mode.name()
              + " removed from player "
              + this.getName()); // fix
    // ClassCastException
  }