- Home /
Trail behind standing player
As per the title suggest, I want to draw trail behind player in all condition. At present I can able to draw trail behind player when it was moving using Trail Renderer component.
But I also want to draw trail when player is not moving. If any other way exist to simulate same effect then please suggest this also.
EDIT : Image example that represent my concept. At present my player is moving so that it draws trail behind it. But if player is not moving than also I want to draw trail behind it.
I want some thing similar to Prewarm in Particle System.
Can you explain in details how do you like the effect (post image, ecc)?
I was edited my question with little bit more information. Please read it.
Is not simple, but you can create a trail of "N" gameobjects (quads). when i emit gamobject N, kill gameobect 0.
Otherwise, you can create a dynamic mesh. When you move player, move mesh vertex accordingly
I don't want to create trail of N objects that I can able to understand what you are trying to say. But I like concept of creating mesh. If you point me towards any link then it become useful to me.
Thanks for your suggestions.
Sure.
See example 1 in this page
http://docs.unity3d.com/ScriptReference/$$anonymous$$esh.html
You have to set vertices array (with coordinates), the uv's (accordingly to you needs), triangles (for triangles int indexes see this pages: http://answers.unity3d.com/questions/187637/procedural-meshs-normals-are-reversed.html and http://kobolds-keep.net/?p=33 )
Answer by hexagonius · Feb 11, 2015 at 08:04 PM
You could use a line renderer. Define its vertex count and width, keep track of your trail yourself and update the renderers vertex positions. Done
Line renderer has an internal manager for vertex, the line is automatically billboarded and the line, for some situation, don't appear correct.
For siddharth3322 screenshot, is better do a procedural mesh, you can have more controls for UVS and vertex positions.
Your answer
Follow this Question
Related Questions
How can I create glowing trail effect? 0 Answers
Trail renderer not working 1 Answer
trails and particles 2 Answers
How to make this trail? 1 Answer
How to get Zerg Tentacle-like effect (see example in post)? 1 Answer