mirror of
https://github.com/ProjectSWGCore/NGECore2.git
synced 2026-10-16 06:13:45 -04:00
Changed admin system
This commit is contained in:
@@ -9,10 +9,7 @@ def run(core, actor, target, commandString):
|
||||
arg1 = commandArgs[0]
|
||||
if len(commandArgs) > 1:
|
||||
arg2 = commandArgs[1]
|
||||
|
||||
if actor.getClient() and actor.getClient().isGM() == False:
|
||||
return
|
||||
|
||||
|
||||
if not commandString.startswith('object/tangible') and not commandString.startswith('object/weapon'):
|
||||
return
|
||||
|
||||
|
||||
@@ -36,16 +36,6 @@ def run(core, actor, target, commandString):
|
||||
if len(commandArgs) > 5:
|
||||
arg5 = commandArgs[5]
|
||||
|
||||
if not command:
|
||||
return
|
||||
|
||||
if actor.getClient().isGM() is False:
|
||||
return
|
||||
|
||||
if playerObject.getGodLevel() == 0:
|
||||
actor.addAbility("admin")
|
||||
playerObject.setGodLevel(50)
|
||||
|
||||
if command == 'giveExperience' and arg1:
|
||||
core.playerService.giveExperience(actor, int(arg1))
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@ def createRadial(core, owner, target, radials):
|
||||
if owner.getPlayerObject().getCitizenship() != 3 and core.playerCityService.getPlayerCity(owner) == city:
|
||||
radials.add(RadialOptions(2, 230, 0, '@city/city:revoke_citizenship'))
|
||||
|
||||
if owner.getClient().isGM():
|
||||
if core.adminService.getAccessLevelFromDB(actor.getClient().getAccountId()) is not None:
|
||||
radials.add(RadialOptions(2, 231, 0, 'Add 10 citizens'))
|
||||
radials.add(RadialOptions(2, 232, 0, 'Deduct 10 citizens'))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user