Presentation is loading. Please wait.

Presentation is loading. Please wait.

Heuristic Search in Empire-Based Games

Similar presentations


Presentation on theme: "Heuristic Search in Empire-Based Games"— Presentation transcript:

1 Heuristic Search in Empire-Based Games
Nathan Freeburg

2 Introduction Goal Develop a hierarchical heuristic search algorithm to determine moves for a simple strategy game. Why heuristic search? Why hierarchical?

3 Heuristic Search What is it?
Method of choosing branches in a state space which are more likely to lead to an acceptable solution to the problem. Often implemented through minimax search.

4 Search Example A A 2 2 B B C C D D -2 -2 -99 -99 2 2 E E F F G G H H I
J J K K L L M M 4 4 2 2 -2 -2 1 1 -1 -1 -99 -99 5 5 4 4 2 2

5 Reducing the Search Space
A full search for a game with n pieces and m moves per piece, to a depth of d, requires examination of (m^n)^d separate states. A full depth search for each piece, performed one at a time for all pieces, reduces the number of states to be examined to n(m^(d+1)). Remember moves made by other pieces at the current depth.

6 Algorithm Used Choose a piece to focus on.
For all other pieces, perform a depth = 1 lookahead to determine best move at that level. Perform a full depth lookahead for the chosen piece to determine the best move. Repeat for all pieces.

7 Constructing a Hierarchy
Split the decision making process into levels. Determine overall strategy at the highest level. Rule-based approach. Determine the moves necessary to implement that strategy at the next level. Heuristic search.

8 Test Game Loosely based on Empire, via Empire Lite.
Only resources are cities. Advantage goes to attacker. Two win conditions. All opposing units eliminated. All cities occupied by one side.

9 Results Hierarchical heuristic search outperformed non-hierarchical search. Average move time was about 5 seconds for a lookahead depth of 8 on a 400 Mhz processor. Still too high for mainstream applications, but promising.

10 Further Work At a superficial level: further tuning of the heuristics and tightening of the code. Division of units into separate groups, each of which could be given different goals. More robust set of rules for decision making at the top level.

11 Conclusions Hierarchical heuristic search preferable to non-hierarchical, despite increase in complexity. Use in mainstream applications dependent on further increases in processing speed.


Download ppt "Heuristic Search in Empire-Based Games"

Similar presentations


Ads by Google