[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file /includes/functions.php on line 4586: Cannot modify header information - headers already sent by (output started at /includes/functions.php:3765)
[phpBB Debug] PHP Warning: in file /includes/functions.php on line 4588: Cannot modify header information - headers already sent by (output started at /includes/functions.php:3765)
[phpBB Debug] PHP Warning: in file /includes/functions.php on line 4589: Cannot modify header information - headers already sent by (output started at /includes/functions.php:3765)
[phpBB Debug] PHP Warning: in file /includes/functions.php on line 4590: Cannot modify header information - headers already sent by (output started at /includes/functions.php:3765)
AI Challenge Forums • View topic - Having problems with PlayGame.jar or ShowGame.jar?

It is currently Mon Mar 27, 2017 12:45 am Advanced search

Having problems with PlayGame.jar or ShowGame.jar?

Code won't compile? Found a bug? Post here!

Having problems with PlayGame.jar or ShowGame.jar?

Postby a1k0n » Sun Sep 12, 2010 6:05 am

There are a bunch of bugs in both of the starter packs that have been released so far (and it's kind of hard to tell which one you already have). Most of the known bugs in the engine and visualizer have been fixed, but the updated starter packs haven't been released yet (there are several other pending issues, notably getting everyone's games to run and keeping the site up).

So I have just updated these:
http://a1k0n.net/temp/PlayGame-1.2.jar
http://a1k0n.net/temp/ShowGame-1.2.jar

Bugs fixed by this release:
- Fleets randomly disappear right before capturing a planet
- When fleets from both players land on a neutral simultaneously, the resolution was inconsistent and wrong. This has been corrected according to the rules set forth in some other threads on the msgboard here, and will also be described in detail on the wiki.
- ShowGame.jar takes forever to load games of any reasonable length
- stderr from each bot is swallowed by PlayGame; now it is output to PlayGame's stderr, prefixed with "Player <n>: <stderr line>"
- If the locale was one in which , and . are used differently than they are in the US, PlayGame would fail to parse the maps
- Windows line-endings would break PlayGame
- PlayGame runs much more slowly than it should (several un-optimizations were removed)

Known bugs:
- 0-growth planets show up with 0-size circles, which is very confusing.

Try them, see if they fix your problem.

I believe the plan at this point is to release a set of starter packs at version 1.2, and they will almost certainly contain the above two jars unless any other bugs get fixed before the release.
a1k0n
Colonel
 
Posts: 90
Joined: Fri Feb 12, 2010 3:51 am

Re: Having problems with PlayGame.jar or ShowGame.jar?

Postby tjkoblentz » Sun Sep 12, 2010 6:08 am

Thanks a1k0n! I'll link to this thread from the one I just posted regarding the 0-growth rate graphics bug. It's nice of you to do this.
tjkoblentz
Cadet
 
Posts: 4
Joined: Sun Sep 12, 2010 5:29 am

Re: Having problems with PlayGame.jar or ShowGame.jar?

Postby a1k0n » Sun Sep 12, 2010 6:09 am

There is an bug logged in the issue tracker for that, BTW: http://code.google.com/p/ai-contest/issues/detail?id=71
a1k0n
Colonel
 
Posts: 90
Joined: Fri Feb 12, 2010 3:51 am

Re: Having problems with PlayGame.jar or ShowGame.jar?

Postby tjkoblentz » Sun Sep 12, 2010 6:11 am

Sweet the competition's on Google code (I actually read that somewhere earlier)! Thanks for the link.
tjkoblentz
Cadet
 
Posts: 4
Joined: Sun Sep 12, 2010 5:29 am

Re: Having problems with PlayGame.jar or ShowGame.jar?

Postby temp_dummy » Sun Sep 12, 2010 6:52 am

Anyway, I do have a patch for the viewer that would allow it to play backwards (in theory).
I do not have a working Java environment, but just looking at the code I can see that the forloop does not take into account the direction.

svn/ trunk/ planet_wars/ viz/ ViewerPanel.java

// Makes the game objects
public void run()
{
// <SNIP> find the loop after: tGame.Init();

Replace For with:
int i = 0;
int direction = 1;
if(!forward){
direction = -1;
}

While(i >= 0 and i < turns.length)
{

// <SNIP> Goto end of the loop
i = i + direction;
}
If this compiles, it will play backwards.
---------------------------------------------
NOTE : Just took the latest version and it does run a lot faster !
Makes testing against all maps easier.

Feature request:: Display the move number in the visualizer.
This can help with debugging as I write each gameboard/move to disk and load re-load it for debugging,
If the move number is displayed I know which file to pick. (thank you)
temp_dummy
Colonel
 
Posts: 87
Joined: Sat Sep 11, 2010 6:00 pm

Re: NEW BUG - Can not capture a planet

Postby temp_dummy » Sun Sep 12, 2010 12:18 pm

I found a bug in which the (new version of the ) game engine does not allow me to take over an planet, no matter how many ships I send to it.

The bug is consistently reproducable:
Windows,
C#
map100.txt
Fighting "Rage" (in more ways than one.)

I have included my game trace:
1) Around move 150 you can see that player two has almost complete over the map.
2) In move 166 there are just two planets left, with two ships each.
An entire Armada is coming to get them, but they never will.
3) this continues until move 1001 where Player 2 is rightfully so declared the winner

I hope this has been informative enough?
The big problem is that if we can not trust the engine, how can we trust our bots?
Attachments
FANNY_MOVES.rar
Replication steps
(93.59 KiB) Downloaded 247 times
temp_dummy
Colonel
 
Posts: 87
Joined: Sat Sep 11, 2010 6:00 pm

Re: Having problems with PlayGame.jar or ShowGame.jar?

Postby kukems » Sun Sep 12, 2010 12:19 pm

Hi, I'm using ant to build and run my bot, but I have issue with ShowGame-1.2.jar.

[exec] Exception in thread "Thread-2" java.lang.NumberFormatException: For input string: "Turn 20"
[exec] at java.lang.NumberFormatException.forInputString(NumberFormatException.java:48)
[exec] at java.lang.Integer.parseInt(Integer.java:449)
[exec] at java.lang.Integer.parseInt(Integer.java:499)
[exec] at ViewerPanel.run(ViewerPanel.java:108)
[exec] at java.lang.Thread.run(Thread.java:619)

See gamelog.txt.
kukems
Cadet
 
Posts: 5
Joined: Sat Sep 11, 2010 1:37 pm

Re: Having problems with PlayGame.jar or ShowGame.jar?

Postby temp_dummy » Sun Sep 12, 2010 12:38 pm

temp_dummy
Colonel
 
Posts: 87
Joined: Sat Sep 11, 2010 6:00 pm

Re: Having problems with PlayGame.jar or ShowGame.jar?

Postby Highie » Sun Sep 12, 2010 7:09 pm

Highie
Cadet
 
Posts: 2
Joined: Sun Sep 12, 2010 3:04 pm

Re: Having problems with PlayGame.jar or ShowGame.jar?

Postby Tarski » Mon Sep 13, 2010 10:14 am

Code PlayGame.jar be modified to display errors from bots crashing? E.G. If my bot throws an exception, stderr is swallowed by PlayGame.jar and the bot times out. This makes it difficult to debug. Could the bot's stderr be redirected to stdout by PlayGame.jar?

Cheers
Tarski
Cadet
 
Posts: 4
Joined: Mon Sep 13, 2010 10:10 am

Next

Return to Technical Issues

Who is online

Users browsing this forum: No registered users and 2 guests

cron