Avagard Posted April 27, 2017 Share Posted April 27, 2017 hello, why this doesn't trigger? the output shows but it doesn't trigger.. help please --------- server: function spawn1 (source) -- skin spawnPlayer (source, 169.7470703125, -58.4306640625 +5, 1.578125 +5, 0, 13, 0, 0) fadeCamera (source, true) setCameraTarget (source, source) setElementData(source,"MTAGOW",false) end addEvent("spawnLobby1",true) addEventHandler("spawnLobby1",root,spawn1) ---------------- client: function clicked () local row, col = guiGridListGetSelectedItem (MTAGO.gridlist[1]) if guiGridListGetSelectedItem (MTAGO.gridlist[1]) then if guiGridListGetItemText (MTAGO.gridlist[1], row, col) == "Lobby 1 0/10 Bakkara Competetive " then outputChatBox ( "Joining...") triggerEvent ( "spawnLobby1", source) end end end addEventHandler("onClientGUIClick", MTAGO.label[7], clicked) Link to comment
Avagard Posted April 27, 2017 Author Share Posted April 27, 2017 1 hour ago, Avagard said: hello, why this doesn't trigger? the output shows but it doesn't trigger.. help please --------- server: function spawn1 (source) -- skin spawnPlayer (source, 169.7470703125, -58.4306640625 +5, 1.578125 +5, 0, 13, 0, 0) fadeCamera (source, true) setCameraTarget (source, source) setElementData(source,"MTAGOW",false) end addEvent("spawnLobby1",true) addEventHandler("spawnLobby1",root,spawn1) ---------------- client: function clicked () local row, col = guiGridListGetSelectedItem (MTAGO.gridlist[1]) if guiGridListGetSelectedItem (MTAGO.gridlist[1]) then if guiGridListGetItemText (MTAGO.gridlist[1], row, col) == "Lobby 1 0/10 Bakkara Competetive " then outputChatBox ( "Joining...") triggerEvent ( "spawnLobby1", source) end end end addEventHandler("onClientGUIClick", MTAGO.label[7], clicked) nvm... stupid thing.. i fixed it Link to comment
Disy Posted April 27, 2017 Share Posted April 27, 2017 The problem was the missing " after 'Lobby 1' in line 16, right? Link to comment
LoPollo Posted April 27, 2017 Share Posted April 27, 2017 (edited) @Disy notice that the string isn't finished: "Lobby 1 0/10 Bakkara Competetive " Edited April 27, 2017 by LoPollo Link to comment
marty000123 Posted April 27, 2017 Share Posted April 27, 2017 if guiGridListGetItemText (MTAGO.gridlist[1], row, col) == "Lobby 1 THEN Link to comment
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