Plate Posted February 16, 2013 Posted February 16, 2013 Hola neceisto una ayuda con este script en el que me ayudo Solidsnake14 y Alex_Steel me dice: Bad Argument @ setPlayerTeam Bad Argument @ getPlayerName [ Expected element at argument 1, got boolean ] attempt to concatentate a boolean valvue client: function deteam (player) local row, col = guiGridListGetSelectedItem ( teamList ) if ( row and col and row ~= -1 and col ~= -1 ) then local team = guiGridListGetItemText ( teamList, row, columnA ) triggerServerEvent ( "onClanPlayerMove", localPlayer, getPlayerFromName ( player ), team ) end end addEventHandler ( "onClientGUIClick", mover, deteam, false ) server: function setTeam(player, teamName) local theTeam = getTeamFromName ( teamName ) if ( theTeam ) then setPlayerTeam ( player , theTeam ) outputChatBox(getPlayerName(source).." agrego a "..getPlayerName(player).." al clan "..getTeamName(theTeam).."", getRootElement(), 0, 255 ,255 ,true) end end addEvent("onClanPlayerMove", true) addEventHandler("onClanPlayerMove",getRootElement(), setTeam)
Castillo Posted February 16, 2013 Posted February 16, 2013 function deteam (player) Estas cometiendo el mismo error que en el tema donde te ayude hoy.
Plate Posted February 16, 2013 Author Posted February 16, 2013 guiGridListGetSelectedItem guiGridListGetItemText eso no?
Plate Posted February 16, 2013 Author Posted February 16, 2013 function deteam (player) local row, col = guiGridListGetSelectedItem ( teamList ) if ( row and col and row ~= -1 and col ~= -1 ) then local row2, col2 = guiGridListGetSelectedItem ( playerList ) if ( row2 and col2 and row2 ~= -1 and col2 ~= -1 ) then local team = guiGridListGetItemText ( teamList, row, columnA ) local player = guiGridListGetItemText ( playerList, row3, column ) triggerServerEvent ( "onClanPlayerMove", localPlayer, getPlayerFromName ( player ), team ) end end addEventHandler ( "onClientGUIClick", mover, deteam, false )
Plate Posted February 16, 2013 Author Posted February 16, 2013 local player = guiGridListGetItemText ( playerList, row2, column )
Recommended Posts