Search Unity

  1. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice

Help create a trail to follow a gameobject

Discussion in 'Scripting' started by Meliodass, Jul 13, 2015.

  1. Meliodass

    Meliodass

    Joined:
    Feb 8, 2015
    Posts:
    32
    Hi just wanted to know or can you guys can suggest me how can i leave a trail to follow that certain object . Just like here i want my GameObject to leave a trail so that my character can follow it. and i have read some scripts but it just make my gameobject and my character attract to each other.
     

    Attached Files:

  2. JamesLeeNZ

    JamesLeeNZ

    Joined:
    Nov 15, 2011
    Posts:
    5,615
    Code (csharp):
    1. TrailRenderer
     
    calmcarrots likes this.
  3. Meliodass

    Meliodass

    Joined:
    Feb 8, 2015
    Posts:
    32
    yeah ive read about that but how do you apply it?
     
  4. calmcarrots

    calmcarrots

    Joined:
    Mar 7, 2014
    Posts:
    681
    Create a new scene and look up a good tutorial on Trail Renders. That might be overkill because it literally takes 1 min to understand what it does and how to work it. But create a new scene and try to practice a bit on using it. Also, when you say that the trail render makes your AI and player attract to each other, that is a problem on your part and you have a bug. Either post the script here or on the Unity Answers page but if not, we really can't help you much
     
unityunity