Playmaker Forum

PlayMaker Updates & Downloads => Share New Actions => Topic started by: Ofonna on October 27, 2017, 10:48:56 PM

Title: Hide Mouse cursor
Post by: Ofonna on October 27, 2017, 10:48:56 PM
i don't know of someone else has updated this but the one in the ecosystem doesn't work, so i made one

*edit i just updated this action, you can now press backslash "\" to get out of locked cursor mode at runtime and go back in, making editing your scene while playing easy and comfortable.

*updated
Title: Re: Hide Mouse cursor
Post by: jeanfabre on November 02, 2017, 03:00:51 AM
Hi,

Cool, Thanks for contributing!

odd, I can't find any hidecursor... can you point me to the link online?

also, I would expose the keycode at least so the the use can choose the key that toggles cursor.

 or even better plug it to a fsmbool var which then lets the logic decide of the way to toggle cursor.

anyway, I think you raised a good case, I made two new custom actions to control visibility and lockMode to give you total control over it.

https://twitter.com/JeanAtPlayMaker/status/925980709248012288

Bye,

 Jean
 
Title: Re: Hide Mouse cursor
Post by: Ofonna on November 02, 2017, 04:52:01 AM
hi Jean, this action basically locks and sets the cursor invincible when the fsm bool is true. but the keycode option is a good idea. i'm probably going to be using your actions since their in the ecosystem, however i'll still add the keycode option like you suggested.

im not sure what link you asked for but this is the api
https://docs.unity3d.com/ScriptReference/CursorLockMode.html
Title: Re: Hide Mouse cursor
Post by: obstudio on November 10, 2017, 06:44:31 PM
hi Jean, is there a possibility to lock cursor in place where it was (not on the center), or mybe there is an action to change position of coursor?