- Home /
How to freeze camera?
hello Im from south KOREA so my english skills are veryyyyy terrible...ㅠㅠ
I watched the http://youtu.be/63LWekHew4c youtube and I want to freezing camera like penumbra or amnesia I mean if I open the door or open the desk my camera is freeze
but now my camera is move I open the door but my camera is move so I want to freeze camera like this video How to can I freeze Camera?! (If i press "Q" camera is freeze and my Dragrigidbody can open the door ) please I usually use JS but C# it is ok :D
P.S I used just Main camera on my Player
Do you mean you want to stop the camera from moving when you open a drawer or door?
When you open something, there is an input. Like if mouseOver and mouseClick then drag open drawer. When you check if the drawer is opening, just stop all movement to the character script. So if opening drawer, don't use movement inputs, else move normally.
That's where I would look at adding it. Good Luck =]
Thank you... I i mean i want to stop the camera from moving when i open a drawer or door.... do u have a this script?! if you have a this script can you give me script?!!
Do not ask for scripts
Sorry, but your question is too broad, and this is not the place to ask for scripts. Unity Answers and its community is here to help you solve any Unity-related problems you have, not give away free code. If you don't know how to write code, I suggest learning Unity's Java Script (its really easy), but if you don't have time, or whatever, then you can try asking your question on the Unity Forums. I hope you can get an answer!
Also, use google. Do tutorials, and learn how to use Unity.
Here are some links I strongly suggest to all new users :
Start at the bottom and work up : http://www.unity3dstudent.com/category/modules/essential-skills/
Start at the bottom and work up : http://www.unity3dstudent.com/category/modules/beginner/
this is the YouTube link for the above as one playlist : http://www.youtube.com/watch?v=-oXYHNSmTxg&list=PL27B696FB515608D2&feature=plcp
That is good to get started. Then start with a small tutorial, this is a simple 2D space shooter : http://www.unityjumpstart.com/ProofOfConcept_1/ : click on the videos part1.mp4 part2,3,4 =]
By then you should be getting the hang of things and starting to have ideas of your own. When you decide what kind of game you want to make, then look at each part you'll need. For example, if you want to make some terrain then walk around it with a character : http://cgcookie.com/unity/2011/12/05/introduction-to-character-controllers/
Here's another on the same 'site but I havn't checked the difficulty : http://cgcookie.com/unity/2012/02/24/game-planning-lunar-lander-01/
Basically then just search for tutorials, there are many out there, either written or on youtube.
the Unity Wiki tutorials : http://wiki.unity3d.com/index.php/Tutorials
A big list of tutorials : http://answers.unity3d.com/questions/12321/how-can-i-start-learning-unity-fast-list-of-tutori.html
Helpful page with information on using Built-In Arrays and Lists (you'll need this later!) : http://www.unifycommunity.com/wiki/index.php?title=Which_$$anonymous$$ind_Of_Array_Or_Collection_Should_I_Use?
The unity wiki link above is very handy with lots of scripts and shaders too (just check out all the links down the left, and the tabs along the top : http://wiki.unity3d.com/index.php/Scripts )
http://forum.unity3d.com/threads/132628-How-to-help-the-Absolute-Beginner
If you know what kind of game you want to make, edit your question and write there what you are thinking of, then there may be a tutorial out there for that!
But just be aware, you will do lots of typing, deleting, typing, bashing head on desk, being really happy when it works and you understand how and why. I hope this helps, Happy Coding =]
Answer by AlucardJay · Nov 12, 2012 at 08:04 AM
As in my first comment, when you press Q also disable the movement part of the script. A simple boolean check would do it. Then when the drawer has finished moving, reset the boolean.
If you post your script to show what you are doing, maybe you can get better help. But we are not here just to write and give away scripts. It is pretty much impossible just to write a generic script with the information you have given anyway.