I have no experience with Unity, so I will make a few assumptions:
- You tried to make a TrailRenderer, but don't know "how to change trail renderer start width dynamically by script in unity?".
- So far, you have a TrailRenderer, but don't know "how to change trail renderer start width dynamically by script in unity?".
- The TrailRenderer that you have so far is working, but you don't know "how to change trail renderer start width dynamically by script in unity?".
I had to Google "Trail Renderer Unity" to see if that was a Unity thing or a class you'd created. Here are the first two links that Google returns:
Link to the manual page: manual reference
Link to the scripting page: script reference
endWidth
and startWidth
are listed right after the first entry on the script reference page and should allow you to achieve what you want.