07 March 2013

Exercising those Animation muscles

Here's an update for that FPS program I've been working on. Which is really only to work out simple animations and find the best ways to control the camera. Turns out that if I attach the camera to a blank game object (one that is only a transform) I can set a perminant rotation/placement, and a temporary one as well. For instance: I lean the camera.main to the right slightly when aiming down the iron-sights, this is a one time call that does not update every frame, a perminant change. I added some walking head bob to the camera that rotates the camera left and right, this actually rotates the CameraMount that the camera is attached to, and is a temporary change. And I have code running every frame that Lerps the camera Mount rotation to a relitive 0 ( the mouse position). Camera bob is a simple on/off switch bit of code that rotates the camera in a downward direction either on the left side or right side. I added some forward drop of the camera each step as well, to hopefully give this all a more natural walking feel to it. I also added a touch of bobbing motion to the gun when you step, Which has to adjust down when you zoom. Added some gun kickback when you fire, as well as a slightly random camera-kick that when firing at a more rapid pace causes accuracy to go down. and again, No recorded animations, :)

press 'C' to toggle full auto.

No comments:

Post a Comment