Hi, So I made a basic animation and attached it to a sword. (First Person MMO?) It will make the sword swing. But I am not a scripter!!! How do I start this animation when I press a certain button??? I want to swing the sword by clicking the mouse. Is this a trigger??? Please help!
animation.CrossFade("name of the animation");
This should be simple enough. Make sure you've assigned the animation to the object and assign this code to your sword. It should work.
You should make sure that in the Inspector Window your Sword object should have the name of the animation that you're going to use under the "animation" box. Click on your Sword object, in the Inspector Window there should be a part called "Animation". There's usually a standard one that comes with the model. Add your animation there. Hope this helps.
This could also be useful;