[Pogamut-list] Run bot from command line

cazub pogamut-forum at artemis.ms.mff.cuni.cz
Wed Oct 15 10:52:53 CEST 2008


Re: Run bot from command line
Hey guys, ok so i'm away from that remote PC but i will post errors as soon as possible. The URI actually IS being taken from the command line correctly (i had a System.out.println( ) with the URI in it and all worked).

It sounds like Agentlauncher.launch() is setting the gamebots URI correctly but then the URI for the remote parser is never reset, it just stays 127.0.0.1:4000 , So like you say ALWAYS use a local parser. So i may have to figure out how to package that in my jar like you suggested. 

I instantiate game bots on the server PC (i will call it PC1) with netbeans and a .bat file that loads my UT server with gamebots on it. So on pc1 we have netbeans (which starts the parser i assume) , UTServer, some working command line bots. On Pc2 and PC3 (my remote PCs) i only have the command line bots which don't work. 

in my Code i have 2 files, the bot class , and the launcher class with Main() in it. Inside launcher

java.net.URI gameBots = new URI(args[0]);
bot mybot = new bot();
AgentLauncher launcher = new AgentLauncher(mybot, gameBots, true);
launcher.launch();

Which if i remember gave me a Connection Error about a local parser, if i change the AgentLauncher argument to false, i get a Connection Error about the remote parser at 127.0.0.1:4000. But inside the errors it does say 'local parser' and 'remote parser'. I can't figure out how to change that URI for the remote parser before i launch. Is there even a function to do so? there is one in the Agent class itself but i can't even get to that.


----

Reply Link: <https://artemis.ms.mff.cuni.cz/pogamut/tiki-view_forum_thread.php?forumId=6&comments_reply_threadId=296&comments_parentId=207&post_reply=1#form>





More information about the Pogamut-list mailing list