mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2025-12-29 19:52:12 +00:00
* Go fish * Keep forgetting about the map * Forgot about the sprites for the double deck * Cleaned things up * Fix icon conflict * Update cards.dm * Improper tweaks * Update cards.dm * Axing the popup from the toy version entirely, that was a little jank * Meta remap was merged * Huh. \improper was the issue. * Update cards.dm * Few changes and a fix * More changes * Update cards.dm * Update cards.dm * Update cards.dm * Merge branch 'master' into go-fish * Update cards.dm
31 lines
1.3 KiB
Plaintext
31 lines
1.3 KiB
Plaintext
/* this is a playing card deck based off of the Rider-Waite Tarot Deck.
|
|
*/
|
|
|
|
/obj/item/deck/tarot
|
|
name = "deck of tarot cards"
|
|
desc = "For all your occult needs!"
|
|
icon_state = "deck_tarot"
|
|
|
|
/obj/item/deck/tarot/build_deck()
|
|
for(var/tarotname in list("Fool","Magician","High Priestess","Empress","Emperor","Hierophant","Lovers","Chariot","Strength","Hermit","Wheel of Fortune","Justice","Hanged Man","Death","Temperance","Devil","Tower","Star","Moon","Sun","Judgement","World"))
|
|
cards += new /datum/playingcard("[tarotname]", "tarot_major", "card_back_tarot")
|
|
for(var/suit in list("wands","pentacles","cups","swords"))
|
|
for(var/number in list("ace","two","three","four","five","six","seven","eight","nine","ten","page","knight","queen","king"))
|
|
cards += new /datum/playingcard("[number] of [suit]", "tarot_[suit]", "card_back_tarot")
|
|
|
|
/obj/item/deck/tarot/deckshuffle()
|
|
var/mob/living/user = usr
|
|
if(cooldown < world.time - 5 SECONDS)
|
|
var/list/newcards = list()
|
|
while(cards.len)
|
|
var/datum/playingcard/P = pick(cards)
|
|
P.name = replacetext(P.name," reversed","")
|
|
if(prob(50))
|
|
P.name += " reversed"
|
|
newcards += P
|
|
cards -= P
|
|
cards = newcards
|
|
playsound(user, 'sound/items/cardshuffle.ogg', 50, 1)
|
|
user.visible_message("<span class='notice'>[user] shuffles [src].</span>", "<span class='notice'>You shuffle [src].</span>")
|
|
cooldown = world.time
|