Merge pull request #9966 from VOREStation/upstream-merge-7985

[MIRROR] adds ticket redemption
This commit is contained in:
Novacat
2021-03-18 10:38:21 -04:00
committed by Chompstation Bot
parent 5c285eda7d
commit ffe0908dfe

View File

@@ -1319,4 +1319,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