[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 - Prepocessed maps - cheat?

It is currently Sat Aug 17, 2019 3:43 pm Advanced search

Prepocessed maps - cheat?

Share and discuss ideas for your entries here.

Re: Prepocessed maps - cheat?

Postby tmc » Fri Oct 28, 2011 8:51 am

tmc
Brigadier-General
 
Posts: 101
Joined: Fri Oct 28, 2011 8:42 am

Re: Prepocessed maps - cheat?

Postby chabotj1 » Fri Oct 28, 2011 3:12 pm

Its still not that hard to realize the entire map.

Search about you hill until you find an adjacent enemy hill. You now know that the ball using the manhatten distance centered at each hill is symmetric in some way. take the distance betwen nests and divide the horizontal and vertical distance by two this is the distance from a nest that is a symmetric block. Analyze the seen tiles in the ball centered at your nest and identify a set of points that is unique (the points would be different if you rotated the ball
ie (x,y)-->(-y,x)-->(-x,-y)-->(y,-x)-->(x,y)). Make sure this set of points is different when the the ball is reflected as well
(x,y)-->(-x,y), one reflection will do as rotation and this reflection will give you all others.

Find these points assuming same orientation and reflection as your nest and see if they match the same points for your ball. If not rotate them and check again, rotate and check for all rotations, then check a reflection and then all rotations of the reflection. One set of tranformations will have these points equal to the points in your unrotated ball. You now know a tranformation for any point relative to that nest. Apply it to all tiles that have been seen on your nest (treating your nest as the origin) and then add the coordinates of this new nest to the points. Voila. Every time you transform on a nest you will realize another ant hill and you will know its symmetry relative to the ant hill you just transformed points about. Get transformation relative to your original hill and rinse and repeat on this newly discovered hill (until there are no new hills to transform about).

If you set all these points on the map have some indicator that they are simply the clone of some point about your hill you can generate a basis for the map (all points that aren't set are the basis). In fact make these clones store the coordinate of the point htat they are equivalent to about your hill, also have the original hill store the location of all the cloned hills. This way for unseen squares your ants only have to scout the original and from that original you can immediately realize all the cloned points on the map. If you discover another set of hills in the original unknown points (which is possible) calculate how it is symmetrical to you original nest and just looking at the original points calculate the transformation on them to get the cloned point about the new hill. This cloned point will also be considered an original point, take all of the points that are clones of it and add those points to the list for the original point we just used to transform, set the cloned point abpout htis new hill to a clone of the original point. If this point was unseen then update the status of all the new clones to your original point to the status of the original.

Continue on until every ORIGINAL point on the board is seen, you have now realized the entire map. Just looking at these original points or basis points identify symmetric blocks. You now know every symmetric block on the map and thus know where every food on hte map spawns if you have vision of all the basis points.

Have some variable that defines a radius about your nest that you control. If these unseen food points that you determined through symmetry are within this radius then get an ant to go collect it. Otherwise you will never get there before an enemy ant collects the food. Maybe have some minimum distance from an ant as well so if the ant is outside range of control but close to food get him to pick it up.

PS: There is a slight problem with defining points as clones or originals, I am not sure if it is possible to have a symmetric map and have the distance between nests not have an even vertical and horizontal component. If one is odd then give the extra amount to the your nest (ie if horizontal distance is 7 then give 4 to your nest and 3 to newly seen nest.).

This should handle the problem but I am not positive about that.
chabotj1
Cadet
 
Posts: 7
Joined: Thu Oct 27, 2011 12:26 am

Re: Prepocessed maps - cheat?

Postby Frantic » Mon Oct 31, 2011 2:25 pm

Hi,

I'm glad this issue is alive in the forum, since I believe I saw it happening in this game: . The winner makes beelines to the enemy hills, without even coming close to them beforehand.

It really feels like cheating and I hope to god that I am not tempted to follow that path. But, since the the maps are in the starter packages and since they are available for download, this method is always open.

I would propose to have this strategy forbidden; however, the point may be moot if, as suggested, the maps in the actual competition are different...

Frantic.
Frantic
Major
 
Posts: 34
Joined: Fri Sep 02, 2011 3:11 pm

Re: Prepocessed maps - cheat?

Postby bugnuts » Mon Oct 31, 2011 3:21 pm

I don't think that bot is using map info. It never really paths to a hill until it has seen it with a scout and the pathfinding even then is pretty poor if it does have the map. Here is an example of my bot winning very quickly where you might make the same assumption but I can assure you all I do is add the hill as a priority goal and finding them so quickly is just a function of how I path the initial explorers.
bugnuts
Lieutenant
 
Posts: 11
Joined: Mon Oct 31, 2011 3:02 pm

Re: Prepocessed maps - cheat?

Postby Frantic » Mon Oct 31, 2011 3:37 pm

Okay, I scrutinized the behaviour of the winner in my mentioned game, and I concede that the enemy hills were viewed before the actual attack, sometimes just before the strike happens. So I suppose it is possible that the player just got lucky with the placement of his frontline ants.

So I take back my remark. I still think preprocessed maps are a cheat, but now my previous post is out of context.

Darn, and I try so hard not to be a sore loser.... :roll:

Frantic.
Frantic
Major
 
Posts: 34
Joined: Fri Sep 02, 2011 3:11 pm

Re: Prepocessed maps - cheat?

Postby dimkadimon » Tue Nov 01, 2011 12:05 am

dimkadimon
Major-General
 
Posts: 263
Joined: Wed Oct 06, 2010 11:34 pm
Location: Adelaide, Australia

Re: Prepocessed maps - cheat?

Postby tmc » Tue Nov 01, 2011 6:12 am

It's impossible to detect or ban. And I don't think it's a bad thing: a human player would be able to detect the map symmetry, or, if the map weren't symmetric, make an intelligent guess at the local of the opponents' hills. And this is a contest to write intelligent bots, so they should obvious attempt to do the same thing. The real 'solution' is that everyone do it. If you're concerned about it, you can implement it and then release your code, so that everyone's on a level playing field.
tmc
Brigadier-General
 
Posts: 101
Joined: Fri Oct 28, 2011 8:42 am

Re: Prepocessed maps - cheat?

Postby Frantic » Wed Nov 02, 2011 5:16 pm

Oh well. If you can't beat 'em, join 'em.

I am now furiously rewriting my entry to take full advantage of map symmetry, by a unique development method dubbed 'rabid programming' by a mistyping colleague.

And then I will chuckle in mirth at the complaining newcomers....so be it.

Frantic.
Frantic
Major
 
Posts: 34
Joined: Fri Sep 02, 2011 3:11 pm

Previous

Return to Strategy

Who is online

Users browsing this forum: No registered users and 2 guests

cron