Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
2 captures
13 Jun 22 - 14 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by Davies · Nov 10, 2009 at 07:00 PM · animationeditor

scripting for Animation Editor animations

Has anyone got a sample script for using an animation created by the Animation Editor? I'm very new to scripting, my previous script that works with imported animations doesn't function with Unity ones and I can't figure out what I'm doing wrong from the docs. A sample script of a simple animation triggered by the FPC would help enormously.

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

3 Replies

· Add your reply
  • Sort: 
avatar image
2
Best Answer

Answer by runevision · Nov 11, 2009 at 12:22 PM

Since AnimationClips are the same no matter if they were created inside Unity or not, the problem is likely somewhere else.

Please make sure that the AnimationClip in question is actually in the Animations list of the Animation component on the GameObject you want to animate.

  • If it is there, you should be able to play the animation through scripting just like the other animations that are in the Animations list in the Animation component. See the scripting reference for more info.

  • If it is not there, you need to find out where you saved the AnimationClip and drag the clip from there (in the Project view) into an empty slot in the Animations list in the Animation component of the GameObject you want to animate.

If you want general advise on how to do animation scripting in Unity, these are the must-see resources:

  • The documentation page about Character Animation.

  • The Character Animation Example Project from the resources section on our website.

Comment
Add comment · Show 2 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Davies · Nov 15, 2009 at 09:03 PM 0
Share

Yes the clip is in the Animations component. I cannot find a single complete script anywhere for triggering an animation and no one seems to be able to give me other than very general information that I already know but doesn't tell me how to put a script together correctly. A few samples of scripts for triggering Unity animations would help me, and the others on the forum with the same problems, figure out what to do. The script reference just gives you isolated bits of information, no examples of a correct complete script that you can study.

avatar image runevision ♦♦ · Nov 16, 2009 at 09:11 AM 0
Share

I added links in my answer to resources with plenty of example scripts of how to trigger animations, and other things, including complete examples.

avatar image
-1

Answer by Davies · Dec 01, 2009 at 02:18 PM

Thanks also for the additional links. I shall look into them.

Cheers

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image
0

Answer by Davies · Nov 28, 2009 at 12:27 AM

It was a problem within the animation itself. Not the script.

Which was weird for me as it's the scripting I have problems with.

Anyway, rebuilt the animation and it all worked fine.

Thanks.

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

No one has followed this question yet.

Related Questions

The name 'Joystick' does not denote a valid type ('not found') 2 Answers

Fireflies... 1 Answer

Animation script with is.grounded help 0 Answers

How do I break apart an object? 2 Answers

Why might an Animation play fine in the Editor but not on an iPad? 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges