Files
Paradise/code/modules/arcade/arcade_prize.dm
FalseIncarnate 6dfbd8f260 Claw Games!
Adds claw games, the absolute most-infuriating arcade game known to
mankind.
- Uses new fancy HTML5 / Javascript code stuff
- Is buildable!
- Science can produce the board with programming 2
- Requires a matter bin, manipulator, some cables, and a sheet of glass
- Costs money!
- Accepts cash or ID swipes, 15 credits per play token
- Dispenses prizeballs!
- Open them for a random plushie, carp plushie, or action figure!
- Two sets of sprites, thanks to FoS and Stephanov

Notes for the coders / future:
This provides a basic example for introducing new HTML5 / Javascript
arcade games, as well as a base type machine to use for such games.
While this may seem silly, this proves that we are not doom to have to
tolerate only the battle game and Orion Trail forever, and can even make
our own games for the arcade.
2015-12-09 00:37:30 -05:00

24 lines
746 B
Plaintext

/obj/item/toy/prizeball
name = "prize ball"
desc = "A toy is a toy, but a prize ball could be anything! It could even be a toy!"
icon = 'icons/obj/arcade.dmi'
icon_state = "prizeball_1"
var/opening = 0
/obj/item/toy/prizeball/New()
..()
icon_state = pick("prizeball_1","prizeball_2","prizeball_3")
/obj/item/toy/prizeball/attack_self(mob/user as mob)
if(opening)
return
opening = 1
playsound(src.loc, 'sound/items/bubblewrap.ogg', 30, 1, extrarange = -4, falloff = 10)
icon_state = "prizeconfetti"
src.color = pick(random_color_list)
var/prize_inside = pick(/obj/random/carp_plushie, /obj/random/plushie, /obj/random/figure) //will add ticket bundles later
spawn(10)
user.unEquip(src)
new prize_inside(user.loc)
qdel(src)