version 1.5 | | version 1.6 |
---|
| | |
again.', 'Thank you, please come again.','Thank you for banking the Imperial Way.', \ | | again.', 'Thank you, please come again.','Thank you for banking the Imperial Way.', \ |
'Thank you for your patronage.', 'Thank you, have a nice day.', 'Thank you. "Service" \ | | 'Thank you for your patronage.', 'Thank you, have a nice day.', 'Thank you. "Service" \ |
is our middle name.', 'Thank you. "Service" is our middle name.', 'Thank you for your \ | | is our middle name.', 'Thank you. "Service" is our middle name.', 'Thank you for your \ |
patronage.', 'Thank you, have a nice day.', 'Thank you. Hows about a big slobbery \ kiss?'] | | patronage.', 'Thank you, have a nice day.', 'Thank you. Hows about a big slobbery kiss?'] |
| | |
| | |
| | |
| | |
if len(text)==2: | | if len(text)==2: |
if (CFPython.PayAmount(activator, (int(text[1])*exchange_rate)*fees)): | | if (CFPython.PayAmount(activator, (int(text[1])*exchange_rate)*fees)): |
bank.deposit(activatorname, int(text[1])) | | bank.deposit(activatorname, int(text[1])) |
message = '%d imperials deposited to bank account. %s' \ | | message = '%d recieved, %d imperials deposited to bank account. %s' \ |
%(int(text[1]),random.choice(thanks_message)) | | %((int(text[1])*(exchange_rate/50))*fees,int(text[1]),random.choice(thanks_message)) |
else: | | else: |
message = 'You would need %d gold'%((int(text[1])*(exchange_rate/10))*fees) | | message = 'You would need %d gold'%((int(text[1])*(exchange_rate/10))*fees) |
else: | | else: |
| | |
message = '%d imperials withdrawn from bank account. %s' \ | | message = '%d imperials withdrawn from bank account. %s' \ |
%(int(text[1]),random.choice(thanks_message)) | | %(int(text[1]),random.choice(thanks_message)) |
id = CFPython.CreateObject('imperial', (x, y)) | | id = CFPython.CreateObject('imperial', (x, y)) |
CFPython.SetQuantity(id, int(text[1])) | | CFItemBroker.Item(id).add(int(text[1])) |
else: | | else: |
message = 'Not enough imperials on your account' | | message = 'Not enough imperials on your account' |
else: | | else: |
| | |
if len(text)==2: | | if len(text)==2: |
inv=CFPython.CheckInventory(activator,'imperial') | | inv=CFPython.CheckInventory(activator,'imperial') |
if inv: | | if inv: |
pay = CFItemBroker.ItemBroker(inv).subtract(int(text[1])) | | pay = CFItemBroker.Item(inv).subtract(int(text[1])) |
if pay: | | if pay: |
id = CFPython.CreateObject('platinum coin', (x, y)) | | id = CFPython.CreateObject('platinum coin', (x, y)) |
CFPython.SetQuantity(id, int(text[1])*(exchange_rate/50)) | | CFItemBroker.Item(id).add(int(text[1])*(exchange_rate/50)) |
message = random.choice(thanks_message) | | message = random.choice(thanks_message) |
else: | | else: |
message = 'Sorry, you do not have %d imperials' %int(text[1]) | | message = 'Sorry, you do not have %d imperials' %int(text[1]) |
| | |
| | |
elif text[0] == 'balance': | | elif text[0] == 'balance': |
balance = bank.getbalance(activatorname) | | balance = bank.getbalance(activatorname) |
message = 'Amount in bank: %d Ip'%(balance) | | if balance == 1: |
| | message = 'Amount in bank: 1 imperial note' |
| | elif balance: |
| | message = 'Amount in bank: %d imperial notes'%(balance) |
| | else: |
| | message = 'Sorry, you have no balance.' |
else: | | else: |
message = 'Do you need help?' | | message = 'Do you need help?' |
| | |