How To Wake Up In Y-direction?

Discussion in 'How Can I...?' started by fez_94, Nov 30, 2016.

  1. fez_94

    fez_94 Boxer

    Joined:
    Nov 1, 2016
    Messages:
    19
    Likes Received:
    2
    Hello I'm making a top down game that scrolls upwards (y-direction/Game direction is -90) and I wanted to add objects with wake up calls that are distance based. I noticed that the wake-up would only trigger when I pass them, so I presume the wakeup distance is x-based and not like a radius around it? My game is based on the default gameplay type.

    I've attached a pic for explanation: as you can see my hero is at the bottom. the game scrolls upward and there is an object in the middle that I would like it if it would wake up and move away before I reach it. It only moves away when I'm on the same x-axis as the object. How would I go around this? thanks
     

    Attached Files:

  2. jerry

    jerry Avid Boxer

    Joined:
    Sep 25, 2015
    Messages:
    421
    Likes Received:
    232
    The Wakeup distance is around the character. The distance is pixel distance and will wake the enemy/object up when it is within range X and Y. You can also choose to put the enemy/object to sleep once the character is passed as well.

    If you want the object to move away, you can just rotate the object. It's just a matter of playing with the Linear Velocity X, Y values.
     

    Attached Files:

    fez_94 likes this.

Share This Page