Hassam Posted June 1, 2014 Share Posted June 1, 2014 Hello, I'm posting here because I need help, where I put that --Server function getGroupList() local count = {} for ind, data in pairs(groupTable) do if (data[5] == slot) then if (not slot[ind]) then slot[ind] = 0 end slot[ind] = slot[ind] + 1 end for ind2, data2 in pairs(GAC) do if (data2[1] == ind) then if (not count[ind]) then count[ind] = 0 end count[ind] = count[ind] + 1 end end end triggerClientEvent(client, "groupSystem.addGroupList", client, groupTable, count, slot) end addEvent("groupSystem.getGroupList", true) addEventHandler("groupSystem.getGroupList", root, getGroupList) And that: --Client function addGroupList(group, count, slot) gTable = group guiGridListClear(groupListGrid) for ind, data in pairs(group) do local row = guiGridListAddRow(groupListGrid) guiGridListSetItemText(groupListGrid, row, 1, tostring(ind), false, false) guiGridListSetItemText(groupListGrid, row, 2, tostring(data[1]), false, false) guiGridListSetItemText(groupListGrid, row, 3, tostring(count[ind]), false, false) guiGridListSetItemText(groupListGrid, row, 4, tostring(slot[ind]), false, false) c[ind] = count[ind] s[ind] = slot[ind] end end addEvent("groupSystem.addGroupList", true) addEventHandler("groupSystem.addGroupList", root, addGroupList) function searchGroupList() guiGridListClear(groupListGrid) local text = guiGetText(source) if (not text or text == "") then triggerServerEvent("groupSystem.getGroupList", root) return end for ind, data in pairs(gTable) do if (string.find(ind:lower(), text:lower(), 1, true)) then local row = guiGridListAddRow(groupListGrid) guiGridListSetItemText(groupListGrid, row, 1, tostring(ind), false, false) guiGridListSetItemText(groupListGrid, row, 2, tostring(data[1]), false, false) guiGridListSetItemText(groupListGrid, row, 3, tostring(c[ind]), false, false) guiGridListSetItemText(groupListGrid, row, 4, tostring(s[ind]), false, false) end end end On groupsystem from Seb aka Smart, my objective is creating slots, I made that and I can't see the slots. Note: I edited the Database to put slots. 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