How I Can Make Enemy Follow Player ???

Discussion in 'How Can I...?' started by elafia, Apr 30, 2020.

  1. elafia

    elafia Boxer

    Joined:
    Apr 29, 2020
    Messages:
    2
    Likes Received:
    0
    Hey Buildbox community,

    Has anyone figured out how to make enemy follow player, I'm sure this would take some coding, so if anyone has created the node and would like to share it with the community I'm sure it would be appreciated.
     
  2. AFStudios

    AFStudios Boxer

    Joined:
    Jan 11, 2020
    Messages:
    27
    Likes Received:
    10
    Here you go
     

    Attached Files:

  3. b0x3r

    b0x3r Boxer

    Joined:
    Apr 5, 2020
    Messages:
    30
    Likes Received:
    6
    I added your asset to the editor and then ensured the player is named Actor. During runtime, the enemy rotates, and briefly begins to move toward the Actor, however, it stops soon after the distance between them begins to increase.

    I'm adjusting the min/max follow distance variables but they don't seem to get the result I'm looking for...an enemy that follows the Actor persistently.

    I've uploaded the bbdoc here. Could you take a look at how it's setup and comment on the issue?
     
  4. b0x3r

    b0x3r Boxer

    Joined:
    Apr 5, 2020
    Messages:
    30
    Likes Received:
    6
    That link is dead. You can download the bbdoc here.
     
  5. spicedbeangames

    spicedbeangames Miniboss Boxer

    Joined:
    Mar 31, 2016
    Messages:
    1,389
    Likes Received:
    596
    I suggest using a game object you create that adds some speed to your enemy. You will need to play around to get the timing and distance right, together with how many to place, depending on your game levels. Remember, to make a 3d object invisible, just delete the 3d Model node after you've set everything up.

    The collision will still work.
     
  6. elafia

    elafia Boxer

    Joined:
    Apr 29, 2020
    Messages:
    2
    Likes Received:
    0
    doesn't work like the way i want, can anyone make a tutorial to make Enemy Follow Player like this game
     
  7. spicedbeangames

    spicedbeangames Miniboss Boxer

    Joined:
    Mar 31, 2016
    Messages:
    1,389
    Likes Received:
    596
    Try this video
     
  8. b0x3r

    b0x3r Boxer

    Joined:
    Apr 5, 2020
    Messages:
    30
    Likes Received:
    6
    I couldn't make it to the end...the music is unbearable.
     
  9. 5petersonzachary

    5petersonzachary Serious Boxer

    Joined:
    Jan 23, 2016
    Messages:
    569
    Likes Received:
    169
    t
    There is no follow node anymore
     
  10. spicedbeangames

    spicedbeangames Miniboss Boxer

    Joined:
    Mar 31, 2016
    Messages:
    1,389
    Likes Received:
    596
    Oh wow. I didn't know that. Perhaps it's being reworked. @Sean Buildbox might know more on this
     
  11. Sean Buildbox

    Sean Buildbox Serious Boxer

    Joined:
    Sep 24, 2015
    Messages:
    902
    Likes Received:
    1,076
    It is the Trail 3D node now. We did have to do a fix for .createGlobal that Trail 3D used post-3.2.1, but that is now the correct node to use
     
  12. AFStudios

    AFStudios Boxer

    Joined:
    Jan 11, 2020
    Messages:
    27
    Likes Received:
    10
    Im sorry it didn't work out. Im still waiting to make some changes with the newer version
     
  13. Gamestudio39922

    Gamestudio39922 Boxer

    Joined:
    Aug 11, 2020
    Messages:
    11
    Likes Received:
    0

    check my profile, for help, leave me a message

     

Share This Page