- Updated Sunday, March 30th 2014 @ 14:22:05
Hi, i have an issue: when i compile my bot, it compile successfully, but then depending on the games, the bot crashes in the middle of the game and i get this:
go place_armies 2000
Maximum number of idle moves returned: skipping move (let bot return 'No moves' instead of nothing)go attack/transfer 2000
Maximum number of idle moves returned: skipping move (let bot return 'No moves' instead of nothing)settings starting_armies 7
I don't know what this means so i don't know how to fix it, my guess is that it is due to a number of illegal move too elevated (like transfer 0 armies). Can someone confirm? Thanks
- Updated Thursday, March 27th 2014 @ 14:54:31
Jackie's Python Starter bot includes the following:
if len(attack_transfers) == 0: return 'No moves'
Basically, I assume this is what you'd need; if you decide not to do anything (at the attack/transfer phase), I suppose it is needed to output this. The error message seems to suggest it.
- Created Thursday, March 27th 2014 @ 18:30:42
Ok so i found the problem, for those who have the same, i just had a bad loop transfering armies from a region to its neighbors if the number of armies on the region was <=3. turns out if the region only has 1 armies, the loop was tring to transfer 0 armies for every neigbhors, wich created 'idle moves"...i forgot the fromRegion.getArmies>1 condition.
- Created Saturday, March 29th 2014 @ 12:02:29
well not really, i still have that problem even tho i don't have fake moves anymore....i really don't understand the problem, anyone is having the same problem?
- Created Sunday, March 30th 2014 @ 14:26:09
this "Maximum number of idle moves returned" issue is really annoying, the bot compile successfully so i don't know what is wrong, and it just crashes randomly in some games, am i really the only one with this problem?
DeveloperCreated Sunday, March 30th 2014 @ 14:51:09
This means either you don't print anything to the server in your place_armies and/or attack/transfer methods (which I assume isn't the case, if this doesn't happen regularly), or the methods take too much time.
You can find this out by using the input you've received in your games on your own computer to check what the problem could be.
I've taken the liberty to find one of your games, and linking the dump here: link.
- Created Sunday, March 30th 2014 @ 20:21:48
ok thanks for the help! i'll try to run the engine on my computer (doesn't seem easy from what i read). i am beginner in coding so that's why i have a lot of question that probably sounds trivals to you guys, i only started to learn programming so that i could do this challenge!
DeveloperUpdated Sunday, March 30th 2014 @ 20:37:13
You don't need to run the actual engine.
Seeing as you're using Java you can try the following:
- Compile your Java code locally
- Run your main class
- Copy and paste the input of the game you want to diagnose.
Everyone started out somewhere, so feel free to keep asking questions. :)
- Updated Monday, March 31st 2014 @ 03:51:48
ok, so i assume i do all this using the Command Prompt? i researched on how to do #1 and #2 and it seemed to work (first time i used the Command Prompt, i was feeling like i was hacking into CIA :D)
i used this command to compile:
javac bot/*.java main/*.java move/*.java
then i ran the main class:
but then what do i do?