It is currently Wed Jun 19, 2013 2:06 pm Advanced search

TCP server for ants

Topics about starter packages, visualizer or any other third party tools.
Please submit new language requests in the Language Request Forum.

TCP server for ants

Postby Accoun » Thu Oct 20, 2011 5:18 am

TCP server for ants:
http://213.88.39.97:2080/
it use 2081 port for bot connetions
based on:
https://github.com/berak/ants-tcp
client mast be taken here:
http://213.88.39.97:2080/tcpclient.py
coomand line example for play on it:
Code: Select all
python tcpclient.py 213.88.39.97 2081 "python HoldBot.py" username password 1

client short help:
Code: Select all
    tcpclient.py   host_or_ip  port  botpath  player_nick  password  [num_rounds]
    if running on windows or if the botpath contains spaces,
    you have to wrap it with "", eg.: "java /x/y/MyBot", "e:\\ai\\bots\\mybot.exe"
    player_nick and password may only contain ascii_letters, '_', and numbers

on this server u can run more than one copy of u bot

---------------
other TCP servers:
http://ants.fluxid.pl/ranking
http://ash.webfactional.com/ranking
http://tcpants.com/ranking
Last edited by Accoun on Sat Nov 12, 2011 5:39 pm, edited 4 times in total.
Accoun
Colonel
 
Posts: 82
Joined: Tue Mar 02, 2010 10:11 am

Re: TCP server for ants

Postby Accoun » Thu Oct 20, 2011 5:02 pm

changes in options:
## tcp opts:
'turns':1000,
'loadtime': 9000,
'turntime': 9000,

'viewradius2': 77,
'attackradius2': 5,
'spawnradius2': 1,
'attack': 'focus',
'food': 'symmetric',
'food_rate': (1,8), # total food
'food_turn': (12,30), # per turn
'food_start': (75,175), # per land area
'food_visible': (2,4), # in starting loc
'cutoff_percent': 0.66,
'cutoff_turn': 150,
'kill_points': 2,

## non-ants related tcp opts
'trueskill': 'jskills_', # select trueskill implementation: 'py'(trueskill.py) or 'jskills'(java JSkills_0.9.0.jar)
'multi_games': 'True', # allow users to play multiple games at the same time
# if set to False, players will have to wait until their latest game ended
Accoun
Colonel
 
Posts: 82
Joined: Tue Mar 02, 2010 10:11 am

Re: TCP server for ants

Postby ratvier » Thu Oct 20, 2011 5:18 pm

I have a problem

Code: Select all
$ python tcpclient.py 213.88.39.97 2081 "java -jar mybot-0.jar" username password 1
connected to 213.88.39.97:2081 as ratver
your bot (java -jar mybot-0.jar) failed to start!


The command "java -jar mybot-0.jar" is right, it works for play_one_game.sh script.

What's wrong?
ratvier
Cadet
 
Posts: 7
Joined: Thu Oct 20, 2011 1:40 pm

Re: TCP server for ants

Postby Accoun » Thu Oct 20, 2011 6:33 pm

ratvier wrote:I have a problem

The command "java -jar mybot-0.jar" is right, it works for play_one_game.sh script.

What's wrong?

i don know, check paths
Accoun
Colonel
 
Posts: 82
Joined: Tue Mar 02, 2010 10:11 am

Re: TCP server for ants

Postby amstan » Fri Oct 21, 2011 5:48 am

Set this to sticky.
Alexandru M. Stan
Contest Organizer
User avatar
amstan
Contest Organizer
 
Posts: 692
Joined: Sun Jan 31, 2010 4:02 am
Location: Stoney Creek, Ontario

Re: TCP server for ants

Postby ratvier » Fri Oct 21, 2011 6:19 am

Accoun wrote:i don know, check paths

Paths is ok.

I found very strange workaround... Maybe this will help someone.

Code: Select all
python tcpclient.py 213.88.39.97 2081 "./bot.sh" username password 1


contents of bot.sh
Code: Select all
#!/bin/sh
java -jar mybot-0.jar
ratvier
Cadet
 
Posts: 7
Joined: Thu Oct 20, 2011 1:40 pm

Re: TCP server for ants

Postby olex.s » Fri Oct 21, 2011 12:48 pm

Something needs to be done about matchmaking on the server... first 8 games (at the time of writing this) I've only ever played one opponent, and rose to #1 ranking with that: http://213.88.39.97:2080/player/olexs
olex.s
Captain
 
Posts: 26
Joined: Tue Sep 14, 2010 6:51 pm

Re: TCP server for ants

Postby george » Fri Oct 21, 2011 1:56 pm

hi Accoun, thanks for this - tcp server is main thing for creating good bots :)

i guess when more people run on it, the games will have better matching?
george
Lieutenant
 
Posts: 16
Joined: Mon Mar 08, 2010 4:19 pm

Re: TCP server for ants

Postby Accoun » Fri Oct 21, 2011 2:17 pm

george wrote:hi Accoun, thanks for this - tcp server is main thing for creating good bots :)

i guess when more people run on it, the games will have better matching?

read source of it, i dont well know python
Accoun
Colonel
 
Posts: 82
Joined: Tue Mar 02, 2010 10:11 am

Re: TCP server for ants

Postby george » Fri Oct 21, 2011 4:58 pm

george wrote:read source of it, i dont well know python


well, it does do games with 3 or more players, as long as there are enough bots signed in.

from the code, it doesnt seem to do rank matching. i guess someone could change code when/if they feel they really need it ...
george
Lieutenant
 
Posts: 16
Joined: Mon Mar 08, 2010 4:19 pm

Next

Return to Starter Packages & Tools

Who is online

Users browsing this forum: No registered users and 1 guest

cron