Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 14 Next capture
2021 2022 2023
2 captures
12 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
2
Question by Macdude2 · Jun 20, 2011 at 06:05 AM · animationappreload

Animation not playing when returning to a previous loaded scene

When I start my app, I have a animation the plays in the menu screen. This animation works great when it is first loaded upon opening the app, however, when I try to load the menu during any level of the game, the animation no longer plays in the menu screen. How can I fix this? Someone asked this question a few months ago and it never got answered. Thanks for any help.

http://answers.unity3d.com/questions/34565/animation-not-playing-when-returning-to-a-previous.html

Comment
Add comment · Show 2
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 Heratitan · Jun 20, 2011 at 08:16 PM 0
Share

Are you using a script to play the animation?

avatar image Macdude2 · Jun 20, 2011 at 10:12 PM 0
Share

I am not, I have just set the animation to loop. I also tried to have script set it off by using

function OnLevelLoad(level:int){ if(level == 0)[ Camera.main.animation.Play(); } }

But this does not work.

3 Replies

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

Answer by GuyTidhar · Jun 20, 2011 at 08:38 AM

Have you tried rewinding the animation?

 animation.Rewind("YourAnimationName");
Comment
Add comment · Show 1 · 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 Macdude2 · Jun 20, 2011 at 08:07 PM 0
Share

I have not and I will try this, but the animation is supposed to loop. I didn't think it would have to be rewinded in order to loop.

avatar image
18
Wiki

Answer by Unity_gamer · Aug 09, 2012 at 03:32 PM

I got the Same problem and i tried the above solution but didn't worked.For me the problem was with the pause section in the game , In this game when we press Pause button the Time.timescale value will change in to '0'.That was creating problem.When i changed the Time .timescale value to '1' in the Main Menu script problem solved. If you are using Time.timescale value to pause the Game just make sure that you are turning it back to 1.!!

Comment
Add comment · Show 11 · 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 saygon · Dec 22, 2012 at 01:59 AM 0
Share

Thanks a lot! I setted Time.timeScale to 1 and all fixes.

You save me a lot of time off debugging.

avatar image ugurrrrr · Feb 27, 2014 at 06:38 PM 0
Share

Yes, that worked for me. Thank you...

avatar image pallav_panda · Feb 01, 2015 at 01:52 PM 0
Share

Thanks Unity_gamer. This solution saved my ass!

avatar image jrobertomar · Aug 24, 2015 at 01:45 PM 1
Share

Thanx! $$anonymous$$inda silly, forgetting about the time scale :D

avatar image CaioMGA_ · Sep 15, 2015 at 12:10 AM 0
Share

Thanks, man!

Show more comments
avatar image
1

Answer by zakirshikhli · Jul 29, 2016 at 06:56 AM

The correct answer to Macdude2's question is Unity_gamer's answer, not GuyTidhar's

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

16 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

play animation doesn't work 2 Answers

How to mix animations : character running and reloading at the same time ? 0 Answers

how to add sound to my reloading animation? 2 Answers

script for animation play 1 Answer

Reload Animation 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