Jump to content
This site uses cookies! Learn More

This site uses cookies!

armedunity.com uses cookies to improve user experience.

By continuing to use this site, you agree to allow us to store cookies on your computer.

  • 0
Sign in to follow this  
fpsarmedunity

Camera Animation at game start

Question

Hi .. i'm having torubles t oset animation of camera ta game start ..i want  to simulate player getup from terrain with an animation simialrt to this

 

Please login or register to see this link.

 

i have the animation  and i create a simple script

Please login or register to see this code.

 

 

but doesnt work.. cna please someone can tell me how to make animation to play automatically on start once.??

 

thanks

Share this post


Link to post
Share on other sites

3 answers to this question

Recommended Posts

  • 1

Make the animation clip the current clip on the animation component and set it to play on awake. You don't need an entirely new script to play an animation on start

Share this post


Link to post
Share on other sites

  • 0

Hello. Maybe your animation is broken. Maybe you forgot something...

However you could simply at start disable player movement, its renderer, and set to null the parent of camera. Then use Vector3.Lerp to move camera in space, using too Quaternion.Lerp for rotation.

When player is totally awaken, set parent again and enable renderer if it's necessary...

Please login or register to see this link.

Please login or register to see this link.

Please login or register to see this link.

I assume that Slerp could give a better animation - something more realistic ++

Share this post


Link to post
Share on other sites
  • 0

Or take a look at this video which shows us how to create animation. Maybe you did something wrong ++

 

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

×
×
  • Create New...