K4stic Posted February 19, 2013 Share Posted February 19, 2013 I need help to make this work to then player join on team Client Side: function checkbum( ) local thisTeam = getPlayerTeam(getLocalPlayer()) if thisTeam ~= false then if thisTeam == getTeamFromName(Bumsteam) then setElementData ( getLocalPlayer(), "Bumsstatus", "yes" ) local trashspots = getElementsByType ( "trash_spot" ) for trashKey,theTrash in ipairs(trashspots) do local Tx, Ty, Tz = getElementPosition( theTrash ) local trashBlip = createBlipAttachedTo ( theTrash, 39, 1, 0, 0, 0, 0, 0, 100) setElementParent ( trashBlip, theTrash ) end myRCs = { } local recyclecenters = getElementsByType ( "recycle_center" ) for rcKey,theRC in ipairs(recyclecenters) do local Tx, Ty, Tz = getElementPosition( theRC ) theRBlip = exports.customblips:createCustomBlip ( Tx, Ty, 20, 20, "img/recy1.png" ) end else setElementData ( getLocalPlayer(), "Bumsstatus", "no" ) local trashblips = getElementsByType ( "blip" ) for trashKey,theTrashBlip in ipairs(trashspots) do if (getElementData( theTrashBlip, "purpose" ) == "trash") then destroyElement(theTrashBlip) end end destroyElement(theRBlip) end end end addEventHandler("onClientPlayerJoin", root, checkbum) addEventHandler("onClientResourceStart", root, checkbum) Link to comment
iPrestege Posted February 19, 2013 Share Posted February 19, 2013 you mean you want to do it for : Bumsteam team? Link to comment
K4stic Posted February 19, 2013 Author Share Posted February 19, 2013 it test if you are in bums team then it create blips (is checker) so i need to on player charge team to start this checker 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