drk Posted January 7, 2012 Posted January 7, 2012 Hey, I want to when a player click on a button and a checkbox saying e.g 'Disable radar' it disable radar only for the local player that clicked on the button. Any way to do this? I know that it's possible but I don't know how to do. If anyone help ty.
FatalTerror Posted January 7, 2012 Posted January 7, 2012 addEventHandler("onClientGUIClick", getRootElement(), function() if(source == TheBouton)then showPlayerHudComponent ("radar", false) outputChatBox("Radar disabled !", source) end end) Like this ?
drk Posted January 7, 2012 Author Posted January 7, 2012 Yes, but it hide the radar only for the player?
drk Posted January 7, 2012 Author Posted January 7, 2012 I don't need to put getLocalPlayer() before "radar" ? Like this: showPlayerHudComponent(getLocalPlayer(), 'radar', false)
FatalTerror Posted January 7, 2012 Posted January 7, 2012 Client argument: bool showPlayerHudComponent ( string component, bool show ) If you add getLocalPlayer(), it will be server side. BUT getLocalPlayer() works only in client side
drk Posted January 7, 2012 Author Posted January 7, 2012 Can u help me in other question? viewtopic.php?f=91&t=38613
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