mirror of
https://github.com/KabKebab/GS13.git
synced 2026-07-10 23:47:16 +01:00
Adds Unum deck
This commit is contained in:
@@ -650,6 +650,7 @@
|
||||
var/cooldown = 0
|
||||
var/obj/machinery/computer/holodeck/holo = null // Holodeck cards should not be infinite
|
||||
var/list/cards = list()
|
||||
var/original_size = 52
|
||||
|
||||
/obj/item/toy/cards/deck/Initialize()
|
||||
. = ..()
|
||||
@@ -699,16 +700,16 @@
|
||||
H.parentdeck = src
|
||||
var/O = src
|
||||
H.apply_card_vars(H,O)
|
||||
src.cards -= choice
|
||||
src.cards.Cut(1,2) //Removes the top card from the list
|
||||
H.pickup(user)
|
||||
user.put_in_hands(H)
|
||||
user.visible_message("[user] draws a card from the deck.", "<span class='notice'>You draw a card from the deck.</span>")
|
||||
update_icon()
|
||||
|
||||
/obj/item/toy/cards/deck/update_icon()
|
||||
if(cards.len > 26)
|
||||
if(cards.len > original_size/2)
|
||||
icon_state = "deck_[deckstyle]_full"
|
||||
else if(cards.len > 10)
|
||||
else if(cards.len > original_size/4)
|
||||
icon_state = "deck_[deckstyle]_half"
|
||||
else if(cards.len > 0)
|
||||
icon_state = "deck_[deckstyle]_low"
|
||||
|
||||
@@ -0,0 +1,22 @@
|
||||
/// A deck of unum cards. Classic.
|
||||
/obj/item/toy/cards/deck/unum
|
||||
name = "\improper UNUM deck"
|
||||
desc = "A deck of unum cards. House rules to argue over not included."
|
||||
icon = 'icons/obj/toy.dmi'
|
||||
icon_state = "deck_unum_full"
|
||||
deckstyle = "unum"
|
||||
original_size = 108
|
||||
|
||||
//Populate the deck.
|
||||
/obj/item/toy/cards/deck/unum/populate_deck()
|
||||
for(var/colour in list("Red","Yellow","Green","Blue"))
|
||||
cards += "[colour] 0" //Uno, i mean, cough cough, Unum decks have only one colour of each 0, weird huh?
|
||||
for(var/k in 0 to 1) //two of each colour of number
|
||||
cards += "[colour] skip"
|
||||
cards += "[colour] reverse"
|
||||
cards += "[colour] draw 2"
|
||||
for(var/i in 1 to 9)
|
||||
cards += "[colour] [i]"
|
||||
for(var/k in 0 to 3) //4 wilds and draw 4s
|
||||
cards += "Wildcard"
|
||||
cards += "Draw 4"
|
||||
@@ -6,7 +6,8 @@
|
||||
products = list(/obj/item/toy/cards/deck = 5,
|
||||
/obj/item/storage/pill_bottle/dice = 10,
|
||||
/obj/item/toy/cards/deck/cas = 3,
|
||||
/obj/item/toy/cards/deck/cas/black = 3)
|
||||
/obj/item/toy/cards/deck/cas/black = 3,
|
||||
/obj/item/toy/cards/deck/unum = 3)
|
||||
contraband = list(/obj/item/dice/fudge = 9)
|
||||
refill_canister = /obj/item/vending_refill/games
|
||||
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 33 KiB After Width: | Height: | Size: 38 KiB |
@@ -1821,6 +1821,7 @@
|
||||
#include "code\modules\food_and_drinks\recipes\tablecraft\recipes_spaghetti.dm"
|
||||
#include "code\modules\food_and_drinks\recipes\tablecraft\recipes_sushi.dm"
|
||||
#include "code\modules\games\cas.dm"
|
||||
#include "code\modules\games\unum.dm"
|
||||
#include "code\modules\goonchat\browserOutput.dm"
|
||||
#include "code\modules\holiday\easter.dm"
|
||||
#include "code\modules\holiday\holidays.dm"
|
||||
|
||||
Reference in New Issue
Block a user