Hello everyone. I do turn-based strategy in Flash. I need to deal with the algorithm search ways. Could you help me with this.
Finding the way Algoritm
Page 1 of 14 Replies - 560 Views - Last Post: 23 June 2010 - 06:52 PM
Replies To: Finding the way Algoritm
#2
Re: Finding the way Algoritm
Posted 22 June 2010 - 06:27 AM
You might want to look into implementing a solution based in Graph Theory for this, and you can adapt Dijkstra's algorithm for finding all the paths, including the shortest.
#3 Guest_FlashWizard*
Re: Finding the way Algoritm
Posted 22 June 2010 - 06:50 AM
To be honest - I didn't understand nothing looking at the page in Wikipedia, can you tell me about "Graph Theory" easier?
In fact, in my game (as in all turn-based strategy) cells of this kind:
In fact, in my game (as in all turn-based strategy) cells of this kind:
#4 Guest_FlashWizard*
Re: Finding the way Algoritm
Posted 23 June 2010 - 06:01 AM
Hey people! Somebody help me!
#5
Re: Finding the way Algoritm
Posted 23 June 2010 - 06:52 PM
That picture helps explain a lot. Honestly, it might be easier to just use a 2D array rather than a Graph, especially if you aren't familiar with Graph Theory. It sounds to me like you are trying to determine available spots to move to for a turn, correct me if I'm wrong. Some checks you should consider for this include checking to see if the space is adjacent to the current cell and is empty. If so, then it is a valid spot to move.
Page 1 of 1
|
|

New Topic/Question
Reply
MultiQuote









|