User Tag List

Results 1 to 2 of 2

Thread: Help with simple platform enemy chasing AI

  1. #1
    Clicker Multimedia Fusion 2

    Join Date
    Apr 2013
    0 Post(s)
    0 Thread(s)

    Help with simple platform enemy chasing AI

    I've looked around at various examples but haven't found something related to the problem I have.

    For a chasing enemy in a platform game, I simply have it so that every 0.05 seconds:

    If X position of enemy is greater than player X position, set Enemy X position as Enemy X position -1.
    (and the opposite for when the enemy is on the other side of the player)

    This works fine, but I don't know what to do when it comes to the enemy being stopped by a wall in the level. Walls in my game are backdrop objects, so I added *enemy is not overlapping a backdrop* to the above events, which does make the enemy stop at the wall, but then they can no longer move the other way as they are permanently stuck 1 pixel into the wall and can no longer move because of the event.

    Any easy solution to this, or should I do a different method entirely for calculating x position of a chasing enemy?

  2. #2
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleUniversal Windows Platform Export ModuleSWF Export ModuleMac Export ModuleInstall Creator Pro
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    Tisnart's Avatar
    Join Date
    Feb 2008
    On, Canada
    2 Post(s)
    0 Thread(s)
    I will eventually be doing this in my blog but have you looked at
    Also there should be lots of examples on the forums here.

Similar Threads

  1. Platform Enemy AI
    By Panchos in forum Multimedia Fusion 2 - Technical Support
    Replies: 1
    Last Post: 5th August 2013, 07:20 PM
  2. Simple enemy chasing player example
    By happygreenfrog in forum File Archive
    Replies: 1
    Last Post: 25th June 2013, 12:31 PM
  3. A Chasing enemy
    By Lillmissthang in forum Multimedia Fusion 2 - Technical Support
    Replies: 17
    Last Post: 1st March 2010, 02:01 PM
  4. Simple platform enemy for Martin_R_Bodger
    By Random in forum File Archive
    Replies: 0
    Last Post: 7th February 2008, 04:43 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts