Furious^ONE! Posted August 17, 2014 Posted August 17, 2014 Hi, I have problem with this script: function toggleGGun(player) local accName = getAccountName ( getPlayerAccount ( source ) ) if isObjectInACLGroup ("user."..accName, aclGetGroup ( "Admin" ) ) local on = not exports.gravity_gun:isGravityGunEnabled(player) exports.gravity_gun:togglePlayerGravityGun(player,on) outputChatBox("gravity gun "..(on and "on" or "off"),player) end addCommandHandler("ggun",toggleGGun) I want this script is reserved to Admin. I add this code: local accName = getAccountName ( getPlayerAccount ( source ) ) if isObjectInACLGroup ("user."..accName, aclGetGroup ( "Admin" ) ) but its not working please help me..
undefined Posted August 18, 2014 Posted August 18, 2014 This type is server. What is the this type on xml?
Saml1er Posted August 18, 2014 Posted August 18, 2014 function toggleGGun(player) local acc = getPlayerAccount ( player ) if not isGuestAccount ( acc ) then return end local accName = getAccountName ( acc ) if isObjectInACLGroup ("user."..accName, aclGetGroup ( "Admin" ) ) local on = not exports.gravity_gun:isGravityGunEnabled(player) exports.gravity_gun:togglePlayerGravityGun(player,on) outputChatBox("gravity gun "..(on and "on" or "off"),player) end addCommandHandler("ggun",toggleGGun)
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