ggz.client.mod
Class ModEvent

java.lang.Object
  extended by ggz.client.mod.ModEvent

public class ModEvent
extends java.lang.Object

Callback events. Each of these is a possible GGZmod event. For each event, the table may register a handler with GGZmod to handle that event.

See Also:
ModEventHandler

Field Summary
static ModEvent GGZMOD_EVENT_CHAT
          A chat message event.
static ModEvent GGZMOD_EVENT_ERROR
          An error has occurred This event occurs when a GGZMod error has occurred.
static ModEvent GGZMOD_EVENT_INFO
          Player information has arrived.
static ModEvent GGZMOD_EVENT_PLAYER
          The player's seat status has changed.
static ModEvent GGZMOD_EVENT_SEAT
          A seat change.
static ModEvent GGZMOD_EVENT_SERVER
          A new server connection has been made This event occurs when a new connection to the game server has been made, either by the core client or by the game client itself.
static ModEvent GGZMOD_EVENT_SPECTATOR_SEAT
          A spectator seat change.
static ModEvent GGZMOD_EVENT_STATE
          Module status changed This event occurs when the game's status changes.
static ModEvent GGZMOD_EVENT_STATS
          A player's stats have been updated.
 
Method Summary
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

GGZMOD_EVENT_STATE

public static final ModEvent GGZMOD_EVENT_STATE
Module status changed This event occurs when the game's status changes. The old state (a ModState) is passed as the event's data.

See Also:
ModState

GGZMOD_EVENT_SERVER

public static final ModEvent GGZMOD_EVENT_SERVER
A new server connection has been made This event occurs when a new connection to the game server has been made, either by the core client or by the game client itself. The fd is passed as the event's data.

See Also:
ModGGZ.connect()

GGZMOD_EVENT_PLAYER

public static final ModEvent GGZMOD_EVENT_PLAYER
The player's seat status has changed. This event occurs when the player's seat status changes; i.e. he changes seats or starts/stops spectating. The event data is a int[2] pair consisting of the old {is_spectator, seat_num}.


GGZMOD_EVENT_SEAT

public static final ModEvent GGZMOD_EVENT_SEAT
A seat change. This event occurs when a seat change occurs. The old seat (a Seat) is passed as the event's data. The seat information will be updated before the event is invoked.


GGZMOD_EVENT_SPECTATOR_SEAT

public static final ModEvent GGZMOD_EVENT_SPECTATOR_SEAT
A spectator seat change. This event occurs when a spectator seat change occurs. The old spectator (a SpectatorSeat) is passed as the event's data. The spectator information will be updated before the event is invoked.


GGZMOD_EVENT_CHAT

public static final ModEvent GGZMOD_EVENT_CHAT
A chat message event. This event occurs when we receive a chat. The chat may have originated in another game client or from the GGZ client; in either case it will be routed to us. The chat information (a GGZChat*) is passed as the event's data. Note that the chat may originate with a player or a spectator, and they may have changed seats or left the table by the time it gets to us.


GGZMOD_EVENT_STATS

public static final ModEvent GGZMOD_EVENT_STATS
A player's stats have been updated.

See Also:
ggzmod_player_get_record, ggzmod_player_get_rating, ggzmod_player_get_ranking, ggzmod_player_get_highscore

GGZMOD_EVENT_INFO

public static final ModEvent GGZMOD_EVENT_INFO
Player information has arrived. Information has been requested about one or more players and it has now arrived. The event data is a GGZPlayerInfo* structure or NULL if info about all players was requested.


GGZMOD_EVENT_ERROR

public static final ModEvent GGZMOD_EVENT_ERROR
An error has occurred This event occurs when a GGZMod error has occurred. An error message (a String) will be passed as the event's data. GGZMod may attempt to recover from the error, but it is not guaranteed that the GGZ connection will continue to work after an error has happened.