
KGS::Listener::Room - handle room-related messages for you.

use base KGS::Listener::Room;
# maybe overwrite new
sub new { ... }
sub event_update_games {
...
}
sub event_roominfo {
...
}

None yet. Please see KGS::Listener and KGS::Listener::Channel.
Automatically listens and handles the following messages for you and calls event methods:
join_room: part_room: upd_games: desc_room: msg_room: upd_game del_game
Uses $room->{channel} and $room->{conn}{name} to join the channel.
See event_join.
Departs from the room. See event_part.
Utter something in the room.
Request a room description. See event_roominfo.
Request a non-incremental update of the game list. Should be called every minute or so.
See event_update_games.
Called when the user successfully joined the room. This can be called late, after messages for this room have already been received.
Called when the user left the room.
Called whenever the game list is updated, either incrementally or on request. The three parameters are arrayrefs with lists of <KGS::Game>s that have been newly added ($add), existed but got parameters (movecount, status etc.) updated ($update) or have been removed $remove.
You do not need to use these arguments, as the list of games is always kept up-to-date in $room->{games}{id}{KGS::Game}, so you can just use this hash instead.
Called whenever the room info gets updated, either on request or server-initiated.
The owner name can be accessed as $room->{owner}, while the descriptive text is stored in $room->{description}.
$self->{owner} = $msg->{owner};
$self->{description} = $msg->{description};