PauloCascus Posted June 20, 2014 Share Posted June 20, 2014 I want to do grid list of event players They will be added in the list when will hit colShape I'm begginer in the scripting, so do not flame to me Just help me to get more knowledge And don't say me about wiki I've already looked there Client file: addEvent("ColCreate", createCol, false, false ) function createCol () local x, y, z = getElementPosition ( player ) local eventCol = createColCircle ( x, y, 10 ) end end addEventHandler("onClientGUIclick", createEvent, createCol, false ) add Event("ColDelete", deleteCol, false, false ) function deleteCol () local colShape = getElementColShape ( eventCol ) destroyElement ( colShape ) end end addEventHandler(onClientGUIClick", removeEvent, deleteCol, false ) function addPlayerInList ( eventCol, player ) if ( eventCol == getLocalPlayer () ) then for id, playeritem in ipairs(getElementsByType ("player")) do local row = guiGridListAddRow ( eventPlayerGrid ) guiGridListSetItemText (eventPlayerGrid, row, eventPlayerColumn, getPlayerName ( playeritem ), false, false ) end end end addEventHandler("onClientColShapeHit", eventCol, addPlayerInList ) Server file: addEvent("ColCreating", function () if isObjectInACLGroup("user."..getAccountName ( getPlayerAccount(player)), aclGetGroup("GEO")) then triggerClientEvent ( player, "ColCreate", player ) end end Or does not necessarily if panel opens only for members of GEO ? Link to comment
Castillo Posted June 20, 2014 Share Posted June 20, 2014 That whole code makes no sense, is all mixed up. Link to comment
PauloCascus Posted June 21, 2014 Author Share Posted June 21, 2014 That whole code makes no sense, is all mixed up. can you say how to do correctly ? 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