Players getting kicked or banned in the lobby is supported natively on the server as that runs ejabberd.
But the 0 A.D. application has no support for handling kick/ban events at all:
- The kicked client will leave the muc room, but it won't disconnect.
- It will appear entirely functional, as the player and gamelist is still remaining and the host button is still enabled.
- The kicked client will not receive any (chat nor messagebox) notification that it was kicked.
- The other clients won't notice that the client was kicked (it will show the client left the room).
- The kick reason is not being shown either.
- Moderators using the 0 A.D. application to kick clients can't send a disconnect reason.
The patch fixes all of that. Also contains some cleanup:
- Removes duplicate "color" property from addChatMessage as that is only used for system messages (right? no external files?)
- Adds debug output when leaving the lobby room for unkown reasons.
- Removes gloox 1.0.0 check, since minimum required version is 1.0.9 now (http://trac.wildfiregames.com/wiki/BuildInstructions).
- GetPlayerList always returns an array, even when disconnected.
Looked into replacing all ircSplit occurances with regex, but would just add much more parsing code and three or more regex.