Paid vending machines usable by borgs too

This commit is contained in:
Tastyfish
2016-02-17 18:07:23 -05:00
parent 300d85be1c
commit 50d0d0c5e0
2 changed files with 35 additions and 43 deletions
+5 -1
View File
@@ -47,6 +47,10 @@
return "$[num2septext(money)]"
/datum/money_account/proc/charge(var/transaction_amount,var/datum/money_account/dest,var/transaction_purpose, var/terminal_name="", var/terminal_id=0, var/dest_name = "UNKNOWN")
if(suspended)
usr << "<span class='warning'>Unable to access source account: account suspended.</span>"
return 0
if(transaction_amount <= money)
//transfer the money
money -= transaction_amount
@@ -84,5 +88,5 @@
transaction_log.Add(T)
return 1
else
usr << "\icon[src]<span class='warning'>You don't have that much money!</span>"
usr << "<span class='warning'>Insufficient funds in account.</span>"
return 0