Added Transfer of Several Admin Commands by Zing

This commit is contained in:
Viaron
2014-08-07 23:27:21 -04:00
parent 67e823078e
commit 8ae66375da
6 changed files with 132 additions and 0 deletions
+15
View File
@@ -0,0 +1,15 @@
import sys
def run(core, actor, target, commandString):
commandArgs = commandString.split(' ')
arg1 = commandArgs[0]
if target is None:
target = actor
if target:
playerObject = target.getSlottedObject('ghost')
playerObject.setLotsRemaining(playerObject.getLotsRemaining() + int(arg1))
print(playerObject.getLotsRemaining())
actor.sendSystemMessage('GM: Adjust Lot Count: Completed Successfully for ' + target.getFirstName(), 0)
return
+12
View File
@@ -0,0 +1,12 @@
from services.sui import SUIWindow
from services.sui.SUIWindow import Trigger
from java.util import Vector
import sys
def setup():
return
def run(core, actor, target, commandString):
core.chatService.broadcastGalaxy(commandString)
return
+11
View File
@@ -0,0 +1,11 @@
from services.sui import SUIWindow
from services.sui.SUIWindow import Trigger
from java.util import Vector
import sys
def setup():
return
def run(core, actor, target, commandString):
core.chatService.broadcastPlanet(commandString, actor.getPlanet())
return
+20
View File
@@ -0,0 +1,20 @@
import sys
def run(core, actor, target, commandString):
commandArgs = commandString.split(' ')
arg1 = commandArgs[0]
playerObject = actor.getSlottedObject('ghost')
if actor:
actor.setCashCredits(actor.getCashCredits() + int(arg1))
actor.sendSystemMessage(actor.getFirstName() + ' has removed ' + arg1 + ' credits from Project SWG\'s bank.', 0)
if actor and target:
target.setCashCredits(target.getCashCredits() + int(arg1))
target.sendSystemMessage('You have recieved ' + arg1 + ' credits from ' + actor.getFirstName(), 0)
actor.sendSystemMessage('You have transferred ' + arg1 + ' credits to ' + target.getFirstName(), 0)
return
+33
View File
@@ -0,0 +1,33 @@
import sys
from resources.datatables import Options
def run(core, actor, target, commandString):
commandArgs = commandString.split(' ')
command = commandArgs[0]
if command == 'invisible':
if (actor.isInStealth()):
actor.setInStealth(False)
actor.setRadarVisible(True)
actor.sendSystemMessage('GM Command Successfull: You are no longer Invisible.', 0)
else:
actor.setInStealth(True)
actor.setRadarVisible(False)
actor.sendSystemMessage('GM Command Successfull: You are now Invisible.', 0)
if actor.getOptionsBitmask() == 128:
actor.setOptionsBitmask(Options.NONE)
actor.sendSystemMessage('GM Command Successfull: You are now Invulnerable.', 0)
elif actor.getOptionsBitmask() == 0:
actor.setOptionsBitmask(Options.ATTACKABLE)
print(actor.getOptionsBitmask())
actor.sendSystemMessage('GM Command Successfull: You are no longer Invulnerable.', 0)
return
+41
View File
@@ -0,0 +1,41 @@
import sys
from resources.datatables import GcwRank
from services.gcw import GCWService
def run(core, actor, target, commandString):
commandArgs = commandString.split(' ')
arg1 = commandArgs[0]
if len(commandArgs) > 1:
arg2 = commandArgs[1]
if target is None:
target = actor
if target.getFaction() == 'rebel' or 'imperial' and arg1 == 'up':
playerObject = target.getSlottedObject('ghost')
playerObject.setCurrentRank(int(arg2))
newrank = playerObject.getCurrentRank()
core.scriptService.callScript("scripts/collections/", "gcwrank_" + target.getFaction(), "handleRankUp", core, target, newrank)
actor.sendSystemMessage('GM: Set Rank: Completed Successfully', 0)
if target.getFaction() == 'rebel' or 'imperial' and arg1 == 'down':
playerObject = target.getSlottedObject('ghost')
playerObject.setCurrentRank(int(arg2))
newrank = playerObject.getCurrentRank()
core.scriptService.callScript("scripts/collections/", "gcwrank_" + target.getFaction(), "handleRankDown", target, newrank)
actor.sendSystemMessage('GM: Set Rank: Completed Successfully', 0)
# if target.getFaction() == 'imperial' and arg1 == 'up':
# if arg1 == 'up':
# playerObject = actor.getSlottedObject('ghost')
# playerObject.setCurrentRank(int(arg2))
# newrank = playerObject.getCurrentRank()
# core.scriptService.callScript("scripts/collections/", "gcwrank_" + target.getFaction(), "handleRankUp", core, target, newrank)
# actor.sendSystemMessage('GM: Set Rank: Completed Successfully', 0)
# if target.getFaction() == 'imperial' and arg1 == 'down':
# playerObject = actor.getSlottedObject('ghost')
# playerObject.setCurrentRank(int(arg2))
# newrank = playerObject.getCurrentRank()
# core.scriptService.callScript("scripts/collections/", "gcwrank_" + target.getFaction(), "handleRankDown", target, newrank)
# actor.sendSystemMessage('GM: Set Rank: Completed Successfully', 0)
return