adds ticket redemption

the commits that added prize tickets to here and virgo missed this, i found where it came form (Cit) and copied it over, tested and it works fine
This commit is contained in:
kcin2001
2021-03-14 14:46:14 -07:00
committed by GitHub
parent 0f00c5baa0
commit f57d5f85f2
+15 -1
View File
@@ -1322,4 +1322,18 @@
wintick = 0
gameStatus = "CLAWMACHINE_NEW"
emagged = 1
return 1
return 1
/obj/machinery/computer/arcade/attackby(obj/item/O, mob/user, params)
if(istype(O, /obj/item/stack/arcadeticket))
var/obj/item/stack/arcadeticket/T = O
var/amount = T.get_amount()
if(amount <2)
to_chat(user, "<span class='warning'>You need 2 tickets to claim a prize!</span>")
return
prizevend(user)
T.pay_tickets()
T.update_icon()
O = T
to_chat(user, "<span class='notice'>You turn in 2 tickets to the [src] and claim a prize!</span>")
return