/datum/round_event_control/treevenge
name = "Treevenge (Christmas)"
holidayID = CHRISTMAS
typepath = /datum/round_event/treevenge
max_occurrences = 1
weight = 20
/datum/round_event/treevenge/start()
for(var/obj/structure/flora/tree/pine/xmas in world)
var/mob/living/simple_animal/hostile/tree/evil_tree = new /mob/living/simple_animal/hostile/tree(xmas.loc)
evil_tree.icon_state = xmas.icon_state
evil_tree.icon_living = evil_tree.icon_state
evil_tree.icon_dead = evil_tree.icon_state
evil_tree.icon_gib = evil_tree.icon_state
qdel(xmas) //b-but I don't want to delete xmas...
//this is an example of a possible round-start event
/datum/round_event_control/presents
name = "Presents under Trees (Christmas)"
holidayID = CHRISTMAS
typepath = /datum/round_event/presents
weight = -1 //forces it to be called, regardless of weight
max_occurrences = 1
earliest_start = 0
/datum/round_event/presents/start()
for(var/obj/structure/flora/tree/pine/xmas in world)
if(!(xmas.z in GLOB.station_z_levels))
continue
for(var/turf/open/floor/T in orange(1,xmas))
for(var/i=1,i<=rand(1,5),i++)
new /obj/item/a_gift(T)
for(var/mob/living/simple_animal/pet/dog/corgi/Ian/Ian in GLOB.mob_living_list)
Ian.place_on_head(new /obj/item/clothing/head/helmet/space/santahat(Ian))
for(var/obj/machinery/computer/security/telescreen/entertainment/Monitor in GLOB.machines)
Monitor.icon_state = "entertainment_xmas"
/datum/round_event/presents/announce(fake)
priority_announce("Ho Ho Ho, Merry Xmas!", "Unknown Transmission")
/obj/item/toy/xmas_cracker
name = "xmas cracker"
icon = 'icons/obj/christmas.dmi'
icon_state = "cracker"
desc = "Directions for use: Requires two people, one to pull each end."
var/cracked = 0
/obj/item/toy/xmas_cracker/attack(mob/target, mob/user)
if( !cracked && ishuman(target) && (target.stat == CONSCIOUS) && !target.get_active_held_item() )
target.visible_message("[user] and [target] pop \an [src]! *pop*", "You pull \an [src] with [target]! *pop*", "You hear a pop.")
var/obj/item/paper/Joke = new /obj/item/paper(user.loc)
Joke.name = "[pick("awful","terrible","unfunny")] joke"
Joke.info = pick("What did one snowman say to the other?\n\n'Is it me or can you smell carrots?'",
"Why couldn't the snowman get laid?\n\nHe was frigid!",
"Where are santa's helpers educated?\n\nNowhere, they're ELF-taught.",
"What happened to the man who stole advent calanders?\n\nHe got 25 days.",
"What does Santa get when he gets stuck in a chimney?\n\nClaus-trophobia.",
"Where do you find chili beans?\n\nThe north pole.",
"What do you get from eating tree decorations?\n\nTinsilitis!",
"What do snowmen wear on their heads?\n\nIce caps!",
"Why is Christmas just like life on ss13?\n\nYou do all the work and the fat guy gets all the credit.",
"Why doesn�t Santa have any children?\n\nBecause he only comes down the chimney.")
new /obj/item/clothing/head/festive(target.loc)
user.update_icons()
cracked = 1
icon_state = "cracker1"
var/obj/item/toy/xmas_cracker/other_half = new /obj/item/toy/xmas_cracker(target)
other_half.cracked = 1
other_half.icon_state = "cracker2"
target.put_in_active_hand(other_half)
playsound(user, 'sound/effects/snap.ogg', 50, 1)
return 1
return ..()
/obj/item/clothing/head/festive
name = "festive paper hat"
icon_state = "xmashat"
desc = "A crappy paper hat that you are REQUIRED to wear."
flags_inv = 0
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 0, rad = 0, fire = 0, acid = 0)
/obj/effect/landmark/xmastree
name = "christmas tree spawner"
var/tree = /obj/structure/flora/tree/pine/xmas
/obj/effect/landmark/xmastree/Initialize(mapload)
..()
if(FESTIVE_SEASON in SSevents.holidays)
new tree(get_turf(src))
return INITIALIZE_HINT_QDEL
/obj/effect/landmark/xmastree/rdrod
name = "festivus pole spawner"
tree = /obj/structure/festivus
/datum/round_event_control/santa
name = "Santa is coming to town! (Christmas)"
holidayID = CHRISTMAS
typepath = /datum/round_event/santa
weight = 150
max_occurrences = 1
earliest_start = 20000
/datum/round_event/santa
var/mob/living/carbon/human/santa //who is our santa?
/datum/round_event/santa/announce(fake)
priority_announce("Santa is coming to town!", "Unknown Transmission")
/datum/round_event/santa/start()
var/list/candidates = pollGhostCandidates("Santa is coming to town! Do you want to be santa?", poll_time=150)
if(LAZYLEN(candidates))
var/mob/dead/observer/Z = pick(candidates)
santa = new /mob/living/carbon/human(pick(GLOB.blobstart))
santa.key = Z.key
qdel(Z)
santa.equipOutfit(/datum/outfit/santa)
santa.update_icons()
var/datum/objective/santa_objective = new()
santa_objective.explanation_text = "Bring joy and presents to the station!"
santa_objective.completed = 1 //lets cut our santas some slack.
santa_objective.owner = santa.mind
santa.mind.objectives += santa_objective
santa.mind.AddSpell(new /obj/effect/proc_holder/spell/aoe_turf/conjure/presents)
var/obj/effect/proc_holder/spell/targeted/area_teleport/teleport/telespell = new(santa)
telespell.clothes_req = 0 //santa robes aren't actually magical.
santa.mind.AddSpell(telespell) //does the station have chimneys? WHO KNOWS!
to_chat(santa, "You are Santa! Your objective is to bring joy to the people on this station. You can conjure more presents using a spell, and there are several presents in your bag.")