WezzarD Posted February 8, 2018 Posted February 8, 2018 I was creating a new game mode after I do all GUI I did this script Quote addEventHandler("onClientGUIClick",root, function () if source == ENTER1 then setElementPosition ( source, 1549.88953, -1685, 13 ) end end ) but when I click on "ENTER1" key it didn't respond.
Mahlukat Posted February 8, 2018 Posted February 8, 2018 try this addEventHandler("onClientGUIClick",root, function () if source == ENTER1 then setElementPosition ( localPlayer, 1549.88953, -1685, 13 ) end end )
ÆBKV Posted February 8, 2018 Posted February 8, 2018 (edited) addEventHandler("onClientGUIClick",ENTER1, function() setElementPosition(localPlayer,1549.88953,-1685,13) end ) If you use source on "onClientGUIClick" it does get the gui element not the player so use always localPlayer on client-side scripts to get the player. Edited February 8, 2018 by ÆBKV
URBAN Posted February 8, 2018 Posted February 8, 2018 (edited) Call it on server side if you call in client it wont sync dimension or interior Edited February 8, 2018 by URBAN
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