Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: AI for an experimental RTS game: simple FSM or subsumption architecture?  (Read 4544 times)

0 Members and 1 Guest are viewing this topic.

magneonx

  • Full Member
  • ***
  • Posts: 141
    • MSN Messenger - magnumneon04@hotmail.com
    • View Profile
Hello! I just wanted to know more about subsumption architecture? Do you know some topics or articles I can read on? I wanted to look for some articles that are only related on video games

Actually, I wanted to use FSM for my experimental game. I don't want go on details here but I may give some couple of things that I want my game actors to do:

My game should have AI Path Finding which I have done,
My game spawns civilian to a particular point, the primary objective of my game is the player has to escort this to my ship safely
My game has enemies and will "harass" the player for bringing this civilians to my spaceship.
My game has a certain time so the AI has to react base on it also

And no, enemies on the game don't have resources, they just spawn randomly on random time intervals.

I don't know if FSM can satisfy this or using advance fsm like subsumption? I hope I get things straight for now. If so I'll be needing articles, books, personal experiences, to guide me in writing up this AI.

If I miss something and fully misunderstood or disrespected AI programming in anyway please let me know.
Thanks for your enlightenment!

Nexus

  • SFML Team
  • Hero Member
  • *****
  • Posts: 6287
  • Thor Developer
    • View Profile
    • Bromeon
For escort patterns, you might want to look into steering behaviors.

In general, I consider AI for Game Developers a very good book that gives an introduction into various AI topics. It covers a wide variety of techniques used to implement AI behaviors.
Zloxx II: action platformer
Thor Library: particle systems, animations, dot products, ...
SFML Game Development:

magneonx

  • Full Member
  • ***
  • Posts: 141
    • MSN Messenger - magnumneon04@hotmail.com
    • View Profile
Hello wow thanks! and I just want to add that I haven't dealt with AI Programming or any of its kind and I can see the book is also well tailored for starters! This is really great reference!
« Last Edit: August 18, 2013, 12:54:57 pm by magneonx »

magneonx

  • Full Member
  • ***
  • Posts: 141
    • MSN Messenger - magnumneon04@hotmail.com
    • View Profile
Hello I also, in game I have controllable units, just like in some RTS games. I have to select some of them and move as a group. I don't want group movement ala Age of Empires or flocking or flowfield but only like Red Alert. I don't have a very big game world nor I have an open terrain. Units are restricted to tiles. My unit only moves from tile to another which doesn't allow diagonal movements and they are locked into axis.

Is this even possible or I am just kidding myself?

Nexus

  • SFML Team
  • Hero Member
  • *****
  • Posts: 6287
  • Thor Developer
    • View Profile
    • Bromeon
Tile-based movement should be rather simple to implement. For pathfinding, you can use algorithms like A*. This is also covered in the book, by the way...
Zloxx II: action platformer
Thor Library: particle systems, animations, dot products, ...
SFML Game Development:

magneonx

  • Full Member
  • ***
  • Posts: 141
    • MSN Messenger - magnumneon04@hotmail.com
    • View Profile
Yeah, I have done the path finding thingy. But I just notice somehow on this video:


This is the exact way on on how I want my units to move from point A to point B( and yes I have dedicated a thread for this one) but I just notice the movement of the unit with steering behavior seems to look natural.

I finally understand that AI Path Finding isn't moving sprite from point a to b. It is just finding the path. As the name suggest. I am so dumb. Moving the sprite from point A to point B is another story. Now I am amaze with steering behavior.

I wanted group movement and I just realize obstacle avoidance is another thing. I just thought A* Path Finding is the package for unit movement. I am just so wrong.

It seems what I have to do now is to implement A* Path Finding, which is great I have done it, the next thing will be, moving the sprite via the generated path from my A* Path FInder using steering behavior, then next applying obstacle avoidance on that AI.

I am correct on this thought? I know this is there on books and on etc etc. But a simple answer will do. I am curious and beginning to understand things.

Ixrec

  • Hero Member
  • *****
  • Posts: 1241
    • View Profile
    • Email
My limited understanding is: Yes, you have a path finding algorithm generate the path, and then move it along that path as a separate operation.  In many games you'd probably have it regenerate the path every so often so it could adapt to what's going on.

magneonx

  • Full Member
  • ***
  • Posts: 141
    • MSN Messenger - magnumneon04@hotmail.com
    • View Profile
but would that be a very expensive operation?

Ixrec

  • Hero Member
  • *****
  • Posts: 1241
    • View Profile
    • Email
That depends entirely on the algorithm and the environment.  If it's a 50x50 maze of squares, pathfinding is trivial.  If you're after humanoid creatures moving through a complex environment in plausile ways, it could get very complicated.  I've heard game devs typically put a bunch of invisible nodes in their levels so the AI can use those for pathfinding.

 

anything