|
I have no idea how to make a pause menu. I want to make my game have a cursor lock but have the ability to unlock it by pausing. I use javascripts but C# and the others are fine if needed
(comments are locked)
|
|
copy and paste that code then apply it to the button http://unity3d.com/support/documentation/ScriptReference/Screen-lockCursor.html Apply it to what button? Can you be a little more more specific?
Dec 14 '10 at 07:47 PM
23cool1234
the start game button. so like play game or options or quit game if there is play game on your menu then drag the script to that text box and when you click the button in game it will play your game and lock your cursor and if you hit esc then it will appear again.
Dec 19 '10 at 04:34 AM
Zachary
Thanks for the help
Dec 20 '10 at 07:03 PM
23cool1234
No problem.. (=
Dec 21 '10 at 11:49 AM
Zachary
just let me know if you need any more i help i would be glad to try to help!
Dec 23 '10 at 06:12 AM
Zachary
(comments are locked)
|
|
Well, you can unlock the cursor anytime with Screen.lockCursor = false; As for the menu, I guess taking a look at GUI in the docs might be enough.
(comments are locked)
|
|
You can also just hide the cursor and show it on your pause menu :
(comments are locked)
|

I suggest searching the forums and Unity Answers for 'pause' or 'pause menu' (this comes up frequently - there are even some example scripts floating around).