TroyBoy Posted February 18, 2012 Share Posted February 18, 2012 i have problem with this command: addCommandHandler ( "jetpack", function ( theplayer ) local playerTeam = getPlayerTeam ( source ) if (not playerTeam) then return end local name = getTeamName ( playerTeam ) if (name == "Owner" or name == "Admin") then local px, py, pz = getElementPosition ( source ) createPickup ( px, py, pz, "3", "370", "30000" ) end end ) when i do this command its dont do nothing and if you can do this command for the only one that do this command can take and see this jetpack and not others ty Link to comment
drk Posted February 18, 2012 Share Posted February 18, 2012 addCommandHandler ( "jetpack", function () local playerTeam = getPlayerTeam ( source ) if not playerTeam then return end local name = getTeamName ( playerTeam ) if name == "Owner" or name == "Admin" then local px, py, pz = getElementPosition ( source ) createPickup ( px, py, pz, "3", "370", "30000" ) end end ) You have to be a team member. If not, function return end. Next time use lua code tags. Link to comment
Kenix Posted February 18, 2012 Share Posted February 18, 2012 Server addCommandHandler ( "jetpack", function ( player ) local playerTeam = getPlayerTeam ( player ) if not playerTeam then return end local name = getTeamName ( playerTeam ) if name == "Owner" or name == "Admin" then local px, py, pz = getElementPosition ( player ) createPickup ( px, py, pz, 3, 370, 30000 ) end end ) 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