Jump to content

Script-Add function to script-can use only Admins,SMods,Mods


ZillaGot

Recommended Posts

Posted (edited)

You might want to find the bindKey function that opens the pannel and replace it with a commandhandler.

addCommandHandler 

,set the third argument to true and set the acl rights for the command. Atleast that's how I'd do it.

Edited by Guest
Posted
   local accName = getAccountName ( getPlayerAccount ( source ) ) 
   if isObjectInACLGroup ("user."..accName, aclGetGroup ( "THEGROUPHERE!!" ) ) then 
function bodies .. 

Posted

Thank you very much for the suggestions, but I'm in scripting a "newbie" and I don't know where you'd like the proposed text had to give it go. In that one file is an awful lot of scripts .lua and don't know where I should not plant, helped by someone in detail please? I myself is clueless. :-/

Posted

Replace the hedit/server/core.lua with this one: http://pastebin.mtasa.com/773420943.

You can change the allowed ACL groups on line 65-67. Add a new or statement after the ones there if you want to add another one. If you want to change the group names in the script, then just switch Admin, Moderator or Super Moderator to whatever you use.

Posted
Replace the hedit/server/core.lua with this one: http://pastebin.mtasa.com/773420943.

You can change the allowed ACL groups on line 65-67. Add a new or statement after the ones there if you want to add another one. If you want to change the group names in the script, then just switch Admin, Moderator or Super Moderator to whatever you use.

Unfortunately, it does not work.. :'-(

I found this: http://code.google.com/p/hedit/source/detail?r=185 - where some instructions that it was can only for Admins (so I rewrote that scripts), but it's doesn't work too - script is "running" but nothing more, nothing will happen, will not start when I clicking that command to open script)...

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...