[Pogamut-list] Proper bot termination

jakub.gemrot pogamut-forum at diana.ms.mff.cuni.cz
Wed Jun 16 10:18:34 CEST 2010


Re: Proper bot termination

Author: jakub.gemrot

Hi! This is a common problem of UT2004 that sometimes leaves the body hanging up in the environment.

I would suggest you to use also UT2004Server instance (obtainable via UT2004ServerFactory) and after you kill your agents, kick them out using UT2004Server and Kick command.
That is, use server.getAct().act(new Kick(somePlayer.getId())); for every player that is still in the game.

This will take some time to tweak up as there will be some waiting involved (you will wait for the GB2004 to report you that the player has left,
note that UT2004Server has 'players' as observable collection, so you may hook up a listener for that).

Unfortunately - this functionality is not nicely wrapped yet.

Best,
Jimmy

-- 
Reply Link: <http://diana.ms.mff.cuni.cz/main/tiki-view_forum_thread.php?forumId=4&comments_reply_threadId=4&comments_parentId=248&post_reply=1#form>





More information about the Pogamut-list mailing list