Jump to content

x [ Help ] x مشكله


Recommended Posts

addEvent('aAdminEx1',true ) 
addEventHandler( 'aAdminEx1',root,
    function ( player1,editdays,editsbab )
     local player1 = getPlayerFromName(player1)
       if (player1) then
        local T1 = editdays*60000*60*60*24
         local account = getPlayerAccount(player1)
          if account and not isGuestAccount(account) then
           local acc = getAccountName(account) 
            if isObjectInACLGroup ( 'user.'..acc, aclGetGroup ( "AdminEx" ) ) then return end 
             aclGroupAddObject (aclGetGroup( "AdminEx" ), "user."..acc) 

              setTimer ( function (acc)
                if not isObjectInACLGroup ( 'user.'..acc, aclGetGroup ( "AdminEx" ) ) then return end 
                 aclGroupRemoveObject ( aclGetGroup( "AdminEx" ),'user.'..acc )
             end,T1,1,acc)
         end
     end
end
)

وش الغلط بذا الكود ؟

رغمني ما اشوف  غلط فيه لكن شاك فيه غلط ب السطور ذي

         local account = getPlayerAccount(player1)
          if account and not isGuestAccount(account) then
           local acc = getAccountName(account) 

 

Edited by iMr ~ MnHmAr
Link to comment
addEvent('aAdminEx1',true ) 
addEventHandler( 'aAdminEx1',root,
function (player1,editdays,editsbab)
    local player1 = getPlayerFromName(player1)
    if (player1) then
        local editdays = editdays*1000*60000*60*24 
        local account = getAccountPlayer(player1)
      	if account and not isGuestAccount(account) then
          local acc = getAccountName(account) 
          if isObjectInACLGroup ( 'user.'..acc, aclGetGroup ( "AdminEx" ) ) then return end 
          aclGroupAddObject (aclGetGroup("AdminEx"), "user."..acc) 

           setTimer ( function (acc)
              if not isObjectInACLGroup ( 'user.'..acc, aclGetGroup ( "AdminEx" ) ) then return end
              aclGroupRemoveObject ( aclGetGroup( "AdminEx" ),'user.'..acc )
          end,editdays,1,acc)
        end
    end
end
)

ياشباب وش المشكله مايرقي 

Link to comment

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...