[Pogamut-list] Controlling Bot
jakub.gemrot
pogamut-forum at diana.ms.mff.cuni.cz
Mon Dec 6 22:13:11 CET 2010
Re: Controlling Bot
Author: jakub.gemrot
Hi!
There is an UT2004Observer class and UT2004ObserverFactory and UT2004ObserverRunner...
Whenever you start UT2004Observer by:
UT2004Observer obs = new UT2004ObserverRunner().startAgent();
You must somehow obtain an ID of the player you want to observe (one you get for instance from Self message of respective bot) and send this command:
getAct().act(new InitializeObserver().setId(idOfBotIWantToObserve);
obs.getAct().act(new ConfigurationObserver().setUpdate(0.2).setAll(true).setSelf(true).setAsync(true).setGame(false).setSee(false).setSpecial(false));
Then you may attach various listeners to obs.getWorldView() as usual.
I also recommand you to read documentation for ConfigurationObserver command.]
Does it help?
Cheers!
Jimmy
--
Reply Link: <http://diana.ms.mff.cuni.cz/main/tiki-view_forum_thread.php?forumId=4&comments_reply_threadId=4&comments_parentId=446&post_reply=1#form>
More information about the Pogamut-list
mailing list