0 votes
1 view
in AI and Deep Learning by (43.2k points)

I'm creating a game that requires the units onscreen to fight each other, based on teams and designated enemies for each team. The player doesn't control any of the tanks or teams.

The issue is that the battle between the units (tanks at the moment) should be interesting enough to the player that they can watch and have fun without doing anything.

I currently have the tanks moving around totally randomly and shooting at each other when in range, but I'm looking for something smarter.

What types of ai and ai algorithms should I look into? All ideas are welcome, I simply want to make every battle interesting.

1 Answer

0 votes
by (92.8k points)

The simplest thing would be to have them drive in a random direction and when there is an enemy tank within range, they start shooting until one of them is destroyed. You can also have them randomly retreat when their health gets too low. You can also try adding group tactics where any tank that is not engaged will join (with some probability so that maybe it will, maybe it won't - just to keep things interesting) it's the nearest neighbor in combat.

If you're looking for algorithms, A* ("A-Star") is a generic path-finding algorithm that could help your tanks move around, but I don't know of any generic algorithms to control the battles.

If you wish to know more about What is Artificial Intelligence then visit this Artificial Intelligence Course.

Welcome to Intellipaat Community. Get your technical queries answered by top developers !


Categories

...