It's free to join Gamasutra!|Have a question? Want to know who runs this site? Here you go.|Targeting the game development market with your product or service? Get info on advertising here.||For altering your contact information or changing email subscription preferences.
Registered members can log in here.Back to the home page.

Search articles, jobs, buyers guide, and more.

By Steve Woodcock
Gamasutra
August 20, 1999

This article originally appeared in the August, 1999 issue of:
Game Developer

Letters to the Editor:
Write a letter
View all letters


Features

 

Contents

Introduction

Technologies in the Limelight

Technology on the Wane

Academia and the Game Industry

What's Next?

Sidebar

Listing 1. Sample Baldur's Gate AI script

Influence Maps in a Nutshell

AAAI Spring Symposium

Further Info

Influence Maps in a Nutshell

Influence Maps (IMs) are an interesting AI technique with its roots in the field of thermodynamics, of all things. The technique is known by a variety of other names, such as "attractor-repulsor" and "force fields".

The basic IM algorithm is refreshingly simple for something in the AI field. Imagine an array which corresponds in size to the size of a strategic-level map. For instance, a strategic map of the U.S. might have resolution down to the state level — in that case, the array might consist of an array of five by ten values (one value for each state). Set all values of the array to zero. Adjust the value of each array element upward by one for each friendly unit in that sector of the map, or downward by one for each enemy unit in that sector. Then begin looking at each location of the array and adjusting the value found there by its neighbors. Typically values are increased by one for each adjacent friendly unit and decreased by one for each adjacent enemy unit.

Do this across the entire map and you now have a "picture" of sorts, that your AI can use tell how much control the two players have over the board. The sign of the value indicates which side has some control. Values near zero indicate areas where control is contested — the front. Large values (positive or negative) indicate strong control over an area.

There can be any number of variations on this basic algorithm depending on the needs of the game, of course, but the principle is the same regardless. This technique can be invaluable in providing all kinds of strategic disposition information to an AI, information which is often difficult to characterize otherwise.

— Steven Woodcock


AAAI Spring Symposium


join | contact us | advertise | write | my profile
news | features | companies | jobs | resumes | education | product guide | projects | store



Copyright © 2003 CMP Media LLC

privacy policy
| terms of service