Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 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 yghtim · Jan 26, 2014 at 11:42 AM · animationstops

unity game stops when animation starts problem.

Hey i have a problem i have this script

function Update() { if(Input.GetKeyDown("r")) { // Plays the reload animation - stops all other animations animation.Play("reload", PlayMode.StopAll); } }

But when i ad it to my gun in unit. i start the game and it works good until i press the key i have selected, and when i press it the game kinda goes back to scene mode but the game is still running somehow...

Why is this happening???

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

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by Bunny83 · Jan 26, 2014 at 11:50 AM

Are you sure that the game view has the keyboard focus? Try clicking into the game view when you start the game. Another reason could be a custom editor script which registers the key has hotkey. Maybe you hit a combination of a built-in hotkey. I'm not sure if CTRL+R, SHIFT+R or ALT+R is a built in hot key as well. If it is there's no way to disable the hot key. Either find a different key or you have to create a build to test it.

edit
I just arrived at my PC ^^
I still use Unity 4.0.1 and there is no hotkey with the R key maybe there's a new hotkey in the current version, but i doubt it. However if you press CRTL+1 Unity would switch to the sceneview. CTRL+2 would switch back to the gameview. CTRL+P would toggle playmode and CTRL+SHIFT+P toggles pause. If you need those combinations in your game, you can't test those in the editor.

Heres a list of (most / all?) hotkeys in Unity however, as i said, maybe there's an editor script which reacts to the "R" key.

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 yghtim · Jan 26, 2014 at 09:49 PM 0
Share

no im pressing w for walking forward, and the screen only goes to scene mode when the script is in an object or else nothing happends...

also, it goes to scene mode BUT at the same time not. the camera goes to scene but the game is stil running somehow. feels more like a bug or something. because even if i follow a youtube tutorial the same thing happends...

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

19 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 avatar image avatar image avatar image

Related Questions

Way to have mulitple input? 1 Answer

I try'd so hard, but my animation script doesnt work..? 1 Answer

Which is better: script or animation (which needs to change with scripting)? 1 Answer

Animation play on input, else play idle animation. 2 Answers

stop particles when animation is playing 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