Updated Cloning Terminal so fee is level based

This commit is contained in:
tacef
2014-05-10 20:11:06 +02:00
parent 3d41026e51
commit 41a5bbf03f
+9 -2
View File
@@ -11,11 +11,18 @@ def handleSelection(core, owner, target, option):
if option == 21 and target:
# REALLY Dirty hack until this can be resolved SWG way !!
str = "Will you pay the %DI credits to clone yourself here?"
stra = "Will you pay the %DI credits to clone yourself here?"
level = int(owner.getLevel())
if level <= 10:
cloningFee = 100
elif level >= 11:
cloningFee = (((owner.getLevel() + 17) * owner.getLevel())/2)
elif level == 90:
cloningFee = 5000
suiSvc = core.suiService
suiWindow = suiSvc.createMessageBox(MessageBoxType.MESSAGE_BOX_OK_CANCEL, '@base_player:clone_confirm_title', str.replace ("%DI" , "5000"), owner, target, 15)
suiWindow = suiSvc.createMessageBox(MessageBoxType.MESSAGE_BOX_OK_CANCEL, '@base_player:clone_confirm_title', stra.replace ("%DI" , str(cloningFee)), owner, target, 15)
returnParams = Vector()
returnParams.add('btnOk:Text')
returnParams.add('btnCancel:Text')