Deathmatch AI

Hey guys, I need help conceptualizing or mapping out an AI system for enemies for an arena based deathmatch mode. They would need to roam around the map until they see an bad guy (either player or computer). Could this be achieved via waypoints. By that, I mean have the enemies randomly move between waypoints set throughout the map and if they come across an enemy, go for it. Any ideas??

Comments

  • SocksSocks London, UK.Member Posts: 12,822
    edited December 2012
    Here's a nice random movement I made just using a couple of equations.

    http://www.mediafire.com/?wwc4ulgfyy82p1f
  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598
    edited December 2012

    That's neat, @Socks! I will make it Awesomatic immediately. :-)

    ""You are in a maze of twisty passages, all alike." - Zork        temp domain http://spidergriffin.wix.com/alphaghostapps

  • poorcollegedevpoorcollegedev Member Posts: 289
    @Socks hey buddy, that"ll be a good start! How would I keep it inside a set boundaries in the arena?
  • DanDaMan123DanDaMan123 Member Posts: 216
    your demo seems pretty cool but the box follows the same path each time...
  • SocksSocks London, UK.Member Posts: 12,822
    your demo seems pretty cool but the box follows the same path each time...
    Well not quite but it does stick to a similar path, you can change the value to make it more random (pseudo-random) if you like.
  • SocksSocks London, UK.Member Posts: 12,822
    @Socks hey buddy, that"ll be a good start! How would I keep it inside a set boundaries in the arena?
    Hold on, let me work that out . . . .
  • SocksSocks London, UK.Member Posts: 12,822
    @Socks hey buddy, that"ll be a good start! How would I keep it inside a set boundaries in the arena?

    Here try something like this:

    http://www.mediafire.com/?ur28tsvrt60l4oa

    You could make the randomness a bit better with some time and effort, but as a general idea I think this could work.
  • SocksSocks London, UK.Member Posts: 12,822
    Here's a very random path - but this is a wrap around one:

    http://www.mediafire.com/?4c2z2jw8bbweh9r
  • RThurmanRThurman Member, Sous Chef, PRO Posts: 2,881
    edited December 2012
    Here is a different kind of AI movement. This is a basic model of chemotaxis -- the way single cell organisms, like e-coli, seek (or avoid) things. The basic idea is that the organism always continues in its current direction until it senses that it is getting further away from the desired object. Then it randomly tumbles and starts off in a new random direction. It is amazing how efficient random-walk chemotasis can be, given the fact that it's umm -- random.

    For background on chemotaxis, see: http://www.mit.edu/~kardar/teaching/projects/chemotaxis(AndreaSchmidt)/index.htm


    Here is the file:
    http://www.mediafire.com/download.php?7jp43yvo3auxq8e
  • SocksSocks London, UK.Member Posts: 12,822
    Here is a different kind of AI movement. This is a basic model of chemotaxis -- the way single cell organisms, like e-coli, seek (or avoid) things. The basic idea is that the organism always continues in its current direction until it senses that it is getting further away from the desired object. Then it randomly tumbles and starts off in a new random direction. It is amazing how efficient random-walk chemotasis can be, given the fact that it's umm -- random.
    COol ! (I might steal that) !! Good article too, very interesting.

    : )

    There is also a scientific underpinning to my 'random' path ( http://www.mediafire.com/?4c2z2jw8bbweh9r ) it is closely modelled on the route I took home last Thursday night after the pub closed.
  • RThurmanRThurman Member, Sous Chef, PRO Posts: 2,881
    edited December 2012
    There is also a scientific underpinning to my 'random' path ( http://www.mediafire.com/?4c2z2jw8bbweh9r ) it is closely modelled on the route I took home last Thursday night after the pub closed.
    @Socks -- glad you are back in the game!

    @poorcollegedev -- are any of these ideas what you are looking for?
  • 3itg3itg Member, PRO Posts: 382
    edited December 2012
    if you need it to be appear more random, make more sets of your path constraints.
    Then use an integer to define which random path to take.
    so when game.randompath = 1
    change destination to waypoint1 X & Y
    when game.randompath = 2
    change destination to waypoint2 X & Y
    then if you want to add another level...
    make your waypoints randomly select coordinates from a table, or have them move, and follow way points themselves...

    any single suggestion or combination of what has been offered here by myself and others should work great!
    Otherwise more details will help us help you :)
Sign In or Register to comment.