Welcome Guest
[Log In]
[Register]
| The Artificial Intelligence | |
|---|---|
| Tweet Topic Started: Friday 24-02-2012, 06:26 (146 Views) | |
| Legatus | Friday 24-02-2012, 06:26 Post #1 |
|
Administrator
|
Here's a bit of insight into how the artificial intelligence might work. It's a bit brute-force and flawed, but it's a start. 1. Sort the list of controlled units. *More durable units are moved to the top of the list. *Healers are moved to the bottom of the list. 2. Select the first unit on the list and do the following. 3. Scan for unit within attack/healing/buffing range. Add every enemy within range to a list. *Also scan for potential area of effect spots near the enemies and add them to another list. 4. For each unit/AoE spot in the list, simulate the effects of every ability available. 5. Execute the ability with the best results on the best target. *When selecting the spot to attack from, move as far from allies and enemies as possible. If this goes well, emergent flanking behavior might result. If not... the AI ranks just scatter and the units become easy targets. This is something that needs to be tested and pondered. 6. If there are units remaining in the list of controlled units, go back to step 2. 7. Finished. I'm already pondering alternate, more complex solutions, like ones based on squads and formations, but before we get there we'll have this. Edited by Legatus, Friday 24-02-2012, 06:50.
|
![]() |
|
| molater | Saturday 25-02-2012, 02:57 Post #2 |
|
Apples
|
How about we have two IF-THEN statements for healers; one before other units move and one after the other units move. The first would check to see if any unit in their range is below a certain percentage of health (like OHKO range). If they are, then heal them. If not, then they will be passed over until the second IF-THEN statement. The second would do the same check except they would heal the one with the lowest percentage of health. This way, the AI can afford to have a more aggressive style and not just suicide against the player's wall of spears. |
![]() |
|
| Legatus | Saturday 25-02-2012, 07:30 Post #3 |
|
Administrator
|
That is actually a very good idea. I should incorporate something like that somehow. |
![]() |
|
| Legatus | Tuesday 24-04-2012, 00:24 Post #4 |
|
Administrator
|
Had a short chat with molater which was mostly about a topic not directly related to this project, so it did not get posted in the logs, but it did lead him to asking me about the AI in the game. Here is summarized what basically my latest idea for the AI is. The AI is divided into three hierarchical layers:
The AI is not supposed to be a competitive player-killer, but it is supposed to make it look like the enemies act with some sort of coordination rather than blindly charging on. If I manage to develop it to its full potential, the Command AI would possess such tricks such as holding chokepoints, performing tactical withdrawals and pincer strikes. Edited by Legatus, Tuesday 24-04-2012, 00:26.
|
![]() |
|
| 1 user reading this topic (1 Guest and 0 Anonymous) | |
| « Previous Topic · Coding · Next Topic » |
| Track Topic · E-mail Topic |
2:48 PM Jul 11
|
Themed by tiptopolive of IFSZ.
Hosted for free by ZetaBoards · Privacy Policy





2:48 PM Jul 11