JoZeFSvK Posted March 10, 2013 Posted March 10, 2013 Hey how i create when player death can open panel BUT! when is ALIVE CAN´T open panel. function funkcia() guiSetVisible(window1, not guiGetVisible(window1)) showCursor(guiGetVisible(window1)) end bindKey ("F1", "down", funkcia )
Baseplate Posted March 10, 2013 Posted March 10, 2013 function funkcia() if (isPlayerDead(localPlayer)) then guiSetVisible(window1, not guiGetVisible(window1)) showCursor(guiGetVisible(window1)) end bindKey ("F1", "down", funkcia ) or you can use isPedDead but it's server-sided so you'll have to trigger events.
JoZeFSvK Posted March 10, 2013 Author Posted March 10, 2013 hmm thank you but when i died i press f1 and nothing it will them that i am alone on server ?
PaiN^ Posted March 10, 2013 Posted March 10, 2013 @ Samer : You're missing an end function funkcia () if ( isPlayerDead( localPlayer ) ) then guiSetVisible( window1, true ) showCursor( true ) end end bindKey ("F1", "down", funkcia )
JoZeFSvK Posted March 10, 2013 Author Posted March 10, 2013 shit epic now i cant show panel i open but when i again press f1 nothing
Vision Posted March 10, 2013 Posted March 10, 2013 guiSetVisible( window1, true ) Should be guiSetVisible ( window1, not guiGetVisible ( window1 ) )
PaiN^ Posted March 10, 2013 Posted March 10, 2013 You're right, Mine only shows the window, But your's makes it disappear as will ..
X-SHADOW Posted March 10, 2013 Posted March 10, 2013 This function is deprecated. This means that its use is discouraged and that it might not exist in future versions. -------------------------------------------------------------------------------- Please use isPedDead instead.
Baseplate Posted March 10, 2013 Posted March 10, 2013 or you can use isPedDead but it's server-sided so you'll have to trigger events. You can see that right?
X-SHADOW Posted March 10, 2013 Posted March 10, 2013 Are You kiding me ? you say it's ServerSide only you didn't say it wont work if he use isPlayerDead .
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now