Adding trails with lua

I’m trying to add trails with lua for my addon, but I’m having trouble with it and would like some help. I need to have the ability to disable the trails too. Can someone help?

To create trails, you can use:


Hiding them is a little more complicated but not difficult, take a look here.

Do you know where I can get the ids for the different bones on your player?

I’d suggest searching the wiki from now on as it’s pretty easy to find this stuff.