MiniGoveya Posted December 8, 2010 Share Posted December 8, 2010 Hey, may you help me with this? I want when i enter in my server, for all the admins his/her car should be color black and green lights, but for others players I want a green car with green lights.. How can i do it? MAY YOU HELP ME? Bie. Link to comment
nowofresh Posted December 8, 2010 Share Posted December 8, 2010 Write function. if(getPlayerTeam" class="kw2">getPlayerTeam(thePlayer) == TEAM_NAME) then [...] This should be work. for example: function test(arguments...) if(getPlayerTeam" class="kw2">getPlayerTeam(thePlayer) == TEAM_NAME) then local reason = {...} if(not [..]) then outputChatBox() outputChatBox() return end Link to comment
Castillo Posted December 8, 2010 Share Posted December 8, 2010 nowofresh, your code doesn't does anything of what he wants O_o, i think you gotta read it again function onEnterSetColor ( thePlayer, seat, jacked ) local accountname = getAccountName(getPlayerAccount(thePlayer)) if isObjectInACLGroup ( "user." .. accountname, aclGetGroup ( "Admin" )) then setVehicleColor(source, 0, 0, 0, 0) setVehicleHeadLightColor(source, 0, 0, 0) else setVehicleColor(source, 16, 16 , 16, 16) setVehicleHeadLightColor(source, 0, 255, 0) end end addEventHandler ( "onVehicleEnter", getRootElement(), onEnterSetColor ) should work, try it (not tested) 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