Home World Forum
Stars! AutoHost web forums

Jump to Stars! AutoHost


 
 
Home » Stars! 2.6/7 » The Academy » Player assistant "AI"
Re: Player assistant "AI" Wed, 08 March 2006 13:37 Go to previous messageGo to previous message
Kotk

 
Commander

Messages: 1227
Registered: May 2003
m.a@stars wrote on Wed, 08 March 2006 16:41

Ouch!Sad You didn't have a backup? Neutral

Nay, but then again ... minesweeper was too simple problem even for AI amateur like me. There are 16x30 unknowns that can be "mine"/"no mine". Gradually during playing these turn into knowns, and all known "no mine"s give knowledge about 8 unknowns around them. So profiling did show that most of the time AI was busy "looking" at the board and clicking it, there was no much to think about.
Quote:

But, from what you explain, I gather I'm only lacking the "conditions" to add the edge to the graph, plus perhaps a proper structure for storing such graph.
Conditions i gave already? distance < 50 => cyan edge,otherwise distance < 82 => green edge, otherwise no edge. Wink
Graph is nothing special. Directed edge is pair of integers (source vertex id, destination vertex id) so you need vector of pairs of integers to store all edges. Bidirectional edge is one edge there and one back. If you know all your graph has only bidirectional edges anyway (like on our case) then you may use only one pair for each edge. If you want attributes like colors or weights or distances add same size vector for attributes too. Like i say i used boost template but only for it makes needed storages, iterators and all such crap for me. Actually its real powers were not used.
Quote:

Yeah, I tried that one long ago. Phase 2 turned out to be the hardest. Razz But I think if I used some kind of graph to weed out most faraway "sweet-spots" things would improve significantly. Sherlock

Oh ... I joked about that phase 2 thing and need to calculate 20000 times. Wink I think that pen-scanning scouting is geometry problem rather than graph problem. If you have 2 circles they overlap or they dont. Now ... if you have 3 circles that all overlap with each other then there may be (and may not be) region where all 3 overlap. Now if there was such 3- way region and there is 4th circle that has also such 3-way region with each pairs of above 3 then there also exists 4-way region. And ... so on. At some moment you have list of all possible regions. If there are no 5 way regions then there are also no 6 way regions to consider. Wink
Then you take that BOSS 81 ly circle around your JOAT scout, for what you have to analyse these regions. If nothing overlaps with it you take 162 ly circle and so on. Also to simplify your task and have less various regions to consider ... you can limit with say 20 closest unscouted planets to your scout. Wink

Report message to a moderator

 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Minerals - mining and depletion
Next Topic: Need a quick answer with detonating minefield question
Goto Forum:
  


Current Time: Thu Jul 04 09:19:27 EDT 2024