Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

Im writing a game, and want to use artificial intelligence for the computer opponent. Whats the best way to go about that?

0
Posted

Im writing a game, and want to use artificial intelligence for the computer opponent. Whats the best way to go about that?

0

A#: Start simple. Make the computer opponent do something. You can always build on the success of the bits that work, and clear out the bits that don’t. Evolutionary programming… There are many different approaches : A#a: Fixed Responses You can easily write a computer opponent which behaves in a set fashion. A ‘Finite State Machine’ would be an example of this. For instance, the Space Invaders aliens move in a fixed pattern and drop bombs at random. The PacMan ghosts always moved toward your guy, subject to the constraints of the walls. These examples are very dated, but this should ensure that the examples are those which almost everyone will have seen, and which used the most basic computer opponent methods. The computer opponent either takes no notice of the player’s activities (eg, Space Invaders) or treats them in a simplistic manner (eg, PacMan). This makes for easier programming, with “memory” and “reasoning” taking almost no part in planning the computer’s actions. The probl

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.

Experts123