- Home /
Head bobbing camera movement (Javascript, home made)
I got the camera bobbing from a non home-made script, and by non ome-made i mean one from the community and not made by others like you reading this thread, i'm looking for a more advanced thing that makes the camera move (Ever played crysis?) in a more realistic fashion and stops bobbing while walking into a wall. the script is about 80 lines long so i wil give you a link to pastebin: http://pastebin.com/zh8Jb8v4
i already made the script non-frame independent so the bobbing is always the same no matter the frames you got and also stop making it bob is you were to be walking and pause the game the head would keep moving up and down. it's been all day for me trying to figure this out with barely any success. thanks to whoever answers this even if it's spam xD (That's how desperate i am).
What are we suppose to name the script because it wont let me add it to that main camera
Answer by inkspot · Jul 16, 2013 at 11:16 PM
The head bobs because your using key input to make it bob and to walk forward, walking into a wall is still using the controls and thus bobbing, maybe making it bob on a certain vector velocity will give you the effect you want.
heh... i have barely any skills in working with vectors xD, perhaps you can help me by modifying my script, thats why i posted this question :)
Np i made a new script from a previously used script that i sound on youtube and modified it to only make the camera bob only and not making you look around since i already just use the premade c# script. :) i will mark you the answer anyway since i used the vector 3 thing. :)
Your answer
Follow this Question
Related Questions
Accessing A Variable Across Script In A Child Object 0 Answers
Can someone help me fix my Javascript for Flickering Light? 6 Answers
Headbobbing 1 Answer
Setting Scroll View Width GUILayout 1 Answer
Webplayer String length fails? 1 Answer