i want to have animation of aiming. i wrote my own script for it and its not working properly. every time i hold on the the right mouse button, the animation keep getting played over and over. is there a way to fix that?
here is the script.
var PlayAim = false;
gameObject.animation["Aim"].speed = -6;
Answer by VisionNext
May 18, 2014 at 10:38 AM
make sure that your aiming animation is not set to loop
Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.
The best place to ask and answer questions about development with Unity.
To help users post good questions and use the site effectively we have posted a user guide.
If you are a new user, check out our FAQ for more information.
If you are a moderator, see our Moderator Guidelines page.
We are making improvements to UA, see the list of changes.
For troubleshooting common problems with Unity 5.x Editor (including Win 10).
Answers and Comments
7 People are following this question.
Mouse to control animations
how to make a character lean over or back when looking up or down
FPSInputController and Character Animation
Animations interupting Aim-Script
Mouse Click Animation