Change Animation Distance Based

Discussion in 'How Can I...?' started by ababab5, Dec 29, 2016.

  1. ababab5

    ababab5 Boxer

    Joined:
    Nov 21, 2016
    Messages:
    19
    Likes Received:
    4
    Hi,

    I would like to change an enemy animation based on the distance of the player.

    For exemple: A hedgehog. When the player is near : the hedgehog show their spikes.

    Thanks for your help
     
  2. rechris2

    rechris2 Boxer

    Joined:
    Oct 8, 2015
    Messages:
    57
    Likes Received:
    7
    i need also, if we insert animation in default section the enemy start it immediately, how to set when character is near?
     
  3. playsgames6666

    playsgames6666 Miniboss Boxer

    Joined:
    Nov 13, 2015
    Messages:
    1,168
    Likes Received:
    745
    You need to add WAKE to enemy, and set the distance you want it to start.
     
  4. wesam_badr

    wesam_badr Miniboss Boxer

    Joined:
    Oct 10, 2015
    Messages:
    1,065
    Likes Received:
    479
    That it's not possible, unfortunately. That would be a great feature the wake up by a distance it wakes up the object if it has linear or angular velocity but it doesn't wake up the animation itself.
     
  5. Christoph

    Christoph Miniboss Boxer

    Joined:
    Oct 4, 2015
    Messages:
    2,807
    Likes Received:
    2,309
    Make it a spawner then it wakes up the animation as well.
     
  6. ababab5

    ababab5 Boxer

    Joined:
    Nov 21, 2016
    Messages:
    19
    Likes Received:
    4
    Hi,

    thanks.


    Yes good idea but how to spawn just one time?


    Thanks!
     

Share This Page