Coin can be inserted in ID cards now.

This commit is contained in:
Ghommie
2020-04-25 14:22:49 +02:00
parent c93f028a97
commit fecf6cef2f
3 changed files with 8 additions and 3 deletions

View File

@@ -303,7 +303,7 @@
if(!bank_support || !alt_click_can_use_id(user))
return
if(!registered_account)
if(!registered_account && bank_support == ID_FREE_BANK_ACCOUNT)
set_new_account(user)
return
@@ -428,7 +428,7 @@ update_label("John Doe", "Clowny")
popup_input = alert(user, "Choose Action", "Agent ID", "Show", "Forge/Reset", "Change Account ID")
else
popup_input = alert(user, "Choose Action", "Agent ID", "Show", "Forge/Reset")
if(user.incapacitated())
if(!user.canUseTopic(src, BE_CLOSE, FALSE))
return
if(popup_input == "Forge/Reset" && !forged)
var/input_name = stripped_input(user, "What name would you like to put on this card? Leave blank to randomise.", "Agent card name", registered_name ? registered_name : (ishuman(user) ? user.real_name : user.name), MAX_NAME_LEN)

View File

@@ -18,9 +18,11 @@
update_desc()
/obj/item/stack/spacecash/proc/update_desc()
var/total_worth = amount*value
var/total_worth = get_item_credit_value()
desc = "It's worth [total_worth] credit[( total_worth > 1 ) ? "s" : ""]"
/obj/item/stack/spacecash/get_item_credit_value()
return (amount*value)
/obj/item/stack/spacecash/merge(obj/item/stack/S)
. = ..()

View File

@@ -341,6 +341,9 @@ GLOBAL_LIST_INIT(sand_recipes, list(\
var/datum/material/M = i
value += M.value_per_unit * custom_materials[M]
/obj/item/coin/get_item_credit_value()
return value
/obj/item/coin/suicide_act(mob/living/user)
user.visible_message("<span class='suicide'>[user] contemplates suicide with \the [src]!</span>")
if (!attack_self(user))