This commit is contained in:
SandPoot
2023-01-23 20:44:28 -03:00
parent e292452aae
commit 54641ce201
103 changed files with 730 additions and 232 deletions

View File

@@ -7,3 +7,31 @@
#define EVENT_READY 1 #define EVENT_READY 1
#define EVENT_CANCELLED 2 #define EVENT_CANCELLED 2
#define EVENT_INTERRUPTED 3 #define EVENT_INTERRUPTED 3
///Events that mess with or create artificial intelligences, such as vending machines and the AI itself
#define EVENT_CATEGORY_AI "AI issues"
///Events that spawn anomalies, which might be the source of anomaly cores
#define EVENT_CATEGORY_ANOMALIES "Anomalies"
///Events pertaining cargo, messages incoming to the station and job slots
#define EVENT_CATEGORY_BUREAUCRATIC "Bureaucratic"
///Events that cause breakages and malfunctions that could be fixed by engineers
#define EVENT_CATEGORY_ENGINEERING "Engineering"
///Events that spawn creatures with simple desires, such as to hunt
#define EVENT_CATEGORY_ENTITIES "Entities"
///Events that should have no harmful effects, and might be useful to the crew
#define EVENT_CATEGORY_FRIENDLY "Friendly"
///Events that affect the body and mind
#define EVENT_CATEGORY_HEALTH "Health"
///Events reserved for special occassions
#define EVENT_CATEGORY_HOLIDAY "Holiday"
///Events with enemy groups with a more complex plan
#define EVENT_CATEGORY_INVASION "Invasion"
///Events that make a mess
#define EVENT_CATEGORY_JANITORIAL "Janitorial"
///Events that summon meteors and other debris, and stationwide waves of harmful space weather
#define EVENT_CATEGORY_SPACE "Space Threats"
///Events summoned by a wizard
#define EVENT_CATEGORY_WIZARD "Wizard"
/// Return from admin setup to stop the event from triggering entirely.
#define ADMIN_CANCEL_EVENT "cancel event"

View File

@@ -9,6 +9,14 @@
* Misc * Misc
*/ */
// Generic listoflist safe add and removal macros:
///If value is a list, wrap it in a list so it can be used with list add/remove operations
#define LIST_VALUE_WRAP_LISTS(value) (islist(value) ? list(value) : value)
///Add an untyped item to a list, taking care to handle list items by wrapping them in a list to remove the footgun
#define UNTYPED_LIST_ADD(list, item) (list += LIST_VALUE_WRAP_LISTS(item))
///Remove an untyped item to a list, taking care to handle list items by wrapping them in a list to remove the footgun
#define UNTYPED_LIST_REMOVE(list, item) (list -= LIST_VALUE_WRAP_LISTS(item))
#define LAZYINITLIST(L) if (!L) { L = list(); } #define LAZYINITLIST(L) if (!L) { L = list(); }
#define UNSETEMPTY(L) if (L && !length(L)) L = null #define UNSETEMPTY(L) if (L && !length(L)) L = null
///Like LAZYCOPY - copies an input list if the list has entries, If it doesn't the assigned list is nulled ///Like LAZYCOPY - copies an input list if the list has entries, If it doesn't the assigned list is nulled

View File

@@ -119,6 +119,6 @@
for(var/path in typesof(/obj/item/coin)) for(var/path in typesof(/obj/item/coin))
var/obj/item/coin/C = new path var/obj/item/coin/C = new path
UNTIL(C.flags_1 & INITIALIZED_1) //we want to make sure the value is calculated and not null. UNTIL(C.flags_1 & INITIALIZED_1) //we want to make sure the value is calculated and not null.
GLOB.coin_values[path] = C.value GLOB.coin_values[path] = C.get_item_credit_value()
qdel(C) qdel(C)

View File

@@ -93,41 +93,6 @@ SUBSYSTEM_DEF(events)
else if(. == EVENT_READY) else if(. == EVENT_READY)
E.runEvent(random = TRUE) E.runEvent(random = TRUE)
//allows a client to trigger an event
//aka Badmin Central
// > Not in modules/admin
// REEEEEEEEE
// Why the heck is this here! Took me so damn long to find!
/client/proc/forceEvent()
set name = "Trigger Event"
set category = "Admin.Events"
if(!holder ||!check_rights(R_FUN))
return
holder.forceEvent()
/datum/admins/proc/forceEvent()
var/dat = ""
var/normal = ""
var/magic = ""
var/holiday = ""
for(var/datum/round_event_control/E in SSevents.control)
dat = "<BR><A href='?src=[REF(src)];[HrefToken()];forceevent=[REF(E)]'>[E]</A>"
if(E.holidayID)
holiday += dat
else if(E.wizardevent)
magic += dat
else
normal += dat
dat = normal + "<BR>" + magic + "<BR>" + holiday
var/datum/browser/popup = new(usr, "forceevent", "Force Random Event", 300, 750)
popup.set_content(dat)
popup.open()
/* /*
////////////// //////////////
// HOLIDAYS // // HOLIDAYS //

View File

@@ -31,7 +31,6 @@
var/jackpots = 0 var/jackpots = 0
var/paymode = HOLOCHIP //toggles between HOLOCHIP/COIN, defined above var/paymode = HOLOCHIP //toggles between HOLOCHIP/COIN, defined above
var/cointype = /obj/item/coin/iron //default cointype var/cointype = /obj/item/coin/iron //default cointype
var/list/coinvalues = list()
var/list/reels = list(list("", "", "") = 0, list("", "", "") = 0, list("", "", "") = 0, list("", "", "") = 0, list("", "", "") = 0) var/list/reels = list(list("", "", "") = 0, list("", "", "") = 0, list("", "", "") = 0, list("", "", "") = 0, list("", "", "") = 0)
var/list/symbols = list(SEVEN = 1, "<font color='orange'>&</font>" = 2, "<font color='yellow'>@</font>" = 2, "<font color='green'>$</font>" = 2, "<font color='blue'>?</font>" = 2, "<font color='grey'>#</font>" = 2, "<font color='white'>!</font>" = 2, "<font color='fuchsia'>%</font>" = 2) //if people are winning too much, multiply every number in this list by 2 and see if they are still winning too much. var/list/symbols = list(SEVEN = 1, "<font color='orange'>&</font>" = 2, "<font color='yellow'>@</font>" = 2, "<font color='green'>$</font>" = 2, "<font color='blue'>?</font>" = 2, "<font color='grey'>#</font>" = 2, "<font color='white'>!</font>" = 2, "<font color='fuchsia'>%</font>" = 2) //if people are winning too much, multiply every number in this list by 2 and see if they are still winning too much.
@@ -49,11 +48,6 @@
INVOKE_ASYNC(src, .proc/toggle_reel_spin, FALSE) INVOKE_ASYNC(src, .proc/toggle_reel_spin, FALSE)
for(cointype in typesof(/obj/item/coin))
var/obj/item/coin/C = new cointype
coinvalues["[cointype]"] = C.get_item_credit_value()
qdel(C) //Sigh
/obj/machinery/computer/slot_machine/Destroy() /obj/machinery/computer/slot_machine/Destroy()
if(balance) if(balance)
give_payout(balance) give_payout(balance)
@@ -336,7 +330,7 @@
if(throwit && target) if(throwit && target)
H.throw_at(target, 3, 10) H.throw_at(target, 3, 10)
else else
var/value = coinvalues["[cointype]"] var/value = GLOB.coin_values[cointype]
if(value <= 0) if(value <= 0)
CRASH("Coin value of zero, refusing to payout in dispenser") CRASH("Coin value of zero, refusing to payout in dispenser")
while(amount >= value) while(amount >= value)

View File

@@ -0,0 +1,97 @@
///Allows an admin to force an event
/client/proc/forceEvent()
set name = "Trigger Event"
set category = "Admin.Events"
if(!holder || !check_rights(R_FUN))
return
holder.forceEvent()
///Opens up the Force Event Panel
/datum/admins/proc/forceEvent()
if(!check_rights(R_FUN))
return
var/datum/force_event/ui = new(usr)
ui.ui_interact(usr)
/// Force Event Panel
/datum/force_event
/datum/force_event/ui_interact(mob/user, datum/tgui/ui)
ui = SStgui.try_update_ui(user, src, ui)
if(!ui)
ui = new(user, src, "ForceEvent")
ui.open()
/datum/force_event/ui_state(mob/user)
return GLOB.fun_state
/datum/force_event/ui_static_data(mob/user)
var/static/list/category_to_icons
if(!category_to_icons)
category_to_icons = list(
EVENT_CATEGORY_AI = "robot",
EVENT_CATEGORY_ANOMALIES = "cloud-bolt",
EVENT_CATEGORY_BUREAUCRATIC = "print",
EVENT_CATEGORY_ENGINEERING = "wrench",
EVENT_CATEGORY_ENTITIES = "ghost",
EVENT_CATEGORY_FRIENDLY = "face-smile",
EVENT_CATEGORY_HEALTH = "brain",
EVENT_CATEGORY_HOLIDAY = "calendar",
EVENT_CATEGORY_INVASION = "user-group",
EVENT_CATEGORY_JANITORIAL = "bath",
EVENT_CATEGORY_SPACE = "meteor",
EVENT_CATEGORY_WIZARD = "hat-wizard",
)
var/list/data = list()
var/list/categories_seen = list()
var/list/categories = list()
var/list/events = list()
for(var/datum/round_event_control/event_control as anything in SSevents.control)
//add category
if(!categories_seen[event_control.category])
categories_seen[event_control.category] = TRUE
UNTYPED_LIST_ADD(categories, list(
"name" = event_control.category,
"icon" = category_to_icons[event_control.category],
))
//add event, with one value matching up the category
UNTYPED_LIST_ADD(events, list(
"name" = event_control.name,
"description" = event_control.description,
"type" = event_control.type,
"category" = event_control.category,
))
data["categories"] = categories
data["events"] = events
return data
/datum/force_event/ui_act(action, list/params, datum/tgui/ui, datum/ui_state/state)
if(..())
return
if(!check_rights(R_FUN))
return
switch(action)
if("forceevent")
var/announce_event = params["announce"]
var/string_path = params["type"]
if(!string_path)
return
var/event_to_run_type = text2path(string_path)
if(!event_to_run_type)
return
var/datum/round_event_control/event = locate(event_to_run_type) in SSevents.control
if(!event)
return
if(event.admin_setup(usr) == ADMIN_CANCEL_EVENT)
return
var/always_announce_chance = 100
var/no_announce_chance = 0
event.runEvent(announce_chance_override = announce_event ? always_announce_chance : no_announce_chance, admin_forced = TRUE)
message_admins("[key_name_admin(usr)] has triggered an event. ([event.name])")
log_admin("[key_name(usr)] has triggered an event. ([event.name])")

View File

@@ -158,27 +158,6 @@
message_admins("[key_name_admin(usr)] tried to create a revenant. Unfortunately, there were no candidates available.") message_admins("[key_name_admin(usr)] tried to create a revenant. Unfortunately, there were no candidates available.")
log_admin("[key_name(usr)] failed to create a revenant.") log_admin("[key_name(usr)] failed to create a revenant.")
else if(href_list["forceevent"])
if(!check_rights(R_FUN))
return
var/datum/round_event_control/E = locate(href_list["forceevent"]) in SSevents.control
if(E)
E.admin_setup(usr)
var/datum/round_event/event = E.runEvent()
if(event.announceWhen>0)
event.processing = FALSE
var/prompt = alert(usr, "Would you like to alert the crew?", "Alert", "Yes", "No", "Cancel")
switch(prompt)
if("Cancel")
event.kill()
return
if("No")
event.announceWhen = -1
event.processing = TRUE
message_admins("[key_name_admin(usr)] has triggered an event. ([E.name])")
log_admin("[key_name(usr)] has triggered an event. ([E.name])")
return
else if(href_list["dbsearchckey"] || href_list["dbsearchadmin"] || href_list["dbsearchip"] || href_list["dbsearchcid"]) else if(href_list["dbsearchckey"] || href_list["dbsearchadmin"] || href_list["dbsearchip"] || href_list["dbsearchcid"])
var/adminckey = href_list["dbsearchadmin"] var/adminckey = href_list["dbsearchadmin"]
var/playerckey = href_list["dbsearchckey"] var/playerckey = href_list["dbsearchckey"]

View File

@@ -517,10 +517,10 @@ Traitors and the like can also be revived with the previous role mostly intact.
message_admins("Admin [key_name_admin(usr)] has added a new AI law - [input]") message_admins("Admin [key_name_admin(usr)] has added a new AI law - [input]")
var/show_log = alert(src, "Show ion message?", "Message", "Yes", "No") var/show_log = alert(src, "Show ion message?", "Message", "Yes", "No")
var/announce_ion_laws = (show_log == "Yes" ? 1 : -1) var/announce_ion_laws = (show_log == "Yes" ? 100 : 0)
var/datum/round_event/ion_storm/add_law_only/ion = new() var/datum/round_event/ion_storm/add_law_only/ion = new()
ion.announceEvent = announce_ion_laws ion.announce_chance = announce_ion_laws
ion.ionMessage = input ion.ionMessage = input
SSblackbox.record_feedback("tally", "admin_verb", 1, "Add Custom AI Law") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! SSblackbox.record_feedback("tally", "admin_verb", 1, "Add Custom AI Law") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!

View File

@@ -583,13 +583,15 @@
// log_admin("[key_name(holder)] has Un-Fully Immersed everyone.") // log_admin("[key_name(holder)] has Un-Fully Immersed everyone.")
if(E) if(E)
E.processing = FALSE E.processing = FALSE
if(E.announceWhen>0) if(E.announce_when>0)
switch(alert(holder, "Would you like to alert the crew?", "Alert", "Yes", "No", "Cancel")) switch(alert(holder, "Would you like to alert the crew?", "Alert", "Yes", "No", "Cancel"))
if("Yes")
E.announce_chance = 100
if("Cancel") if("Cancel")
E.kill() E.kill()
return return
if("No") if("No")
E.announceWhen = -1 E.announce_chance = 0
E.processing = TRUE E.processing = TRUE
if(holder) if(holder)
log_admin("[key_name(holder)] used secret [action]") log_admin("[key_name(holder)] used secret [action]")

View File

@@ -5,7 +5,8 @@
weight = 7 weight = 7
max_occurrences = 1 max_occurrences = 1
min_players = 5 min_players = 5
category = EVENT_CATEGORY_HEALTH
description = "Spawns a sentient disease, who wants to infect as many people as possible."
/datum/round_event/ghost_role/sentient_disease /datum/round_event/ghost_role/sentient_disease
role_name = "sentient disease" role_name = "sentient disease"

View File

@@ -220,6 +220,8 @@
typepath = /datum/round_event/ghost_role/morph typepath = /datum/round_event/ghost_role/morph
weight = 0 //Admin only weight = 0 //Admin only
max_occurrences = 1 max_occurrences = 1
category = EVENT_CATEGORY_ENTITIES
description = "Spawns a hungry shapeshifting blobby creature."
/datum/round_event/ghost_role/morph /datum/round_event/ghost_role/morph
minimum_required = 1 minimum_required = 1

View File

@@ -6,7 +6,8 @@
weight = 7 weight = 7
max_occurrences = 1 max_occurrences = 1
min_players = 5 min_players = 5
category = EVENT_CATEGORY_ENTITIES
description = "Spawns an angry, soul sucking ghost."
/datum/round_event/ghost_role/revenant /datum/round_event/ghost_role/revenant
var/ignore_mobcheck = FALSE var/ignore_mobcheck = FALSE

View File

@@ -5,6 +5,8 @@
max_occurrences = 1 max_occurrences = 1
earliest_start = 1 HOURS earliest_start = 1 HOURS
min_players = 20 min_players = 20
category = EVENT_CATEGORY_ENTITIES
description = "Spawns a slaughter demon, to hunt by travelling through pools of blood."
/datum/round_event_control/slaughter/canSpawnEvent() /datum/round_event_control/slaughter/canSpawnEvent()
weight = initial(src.weight) weight = initial(src.weight)

View File

@@ -6,7 +6,8 @@
earliest_start = 30 MINUTES earliest_start = 30 MINUTES
min_players = 35 min_players = 35
dynamic_should_hijack = TRUE dynamic_should_hijack = TRUE
category = EVENT_CATEGORY_INVASION
description = "A robotic menace invades the station consuming everything for materials and reproducing."
/datum/round_event/spawn_swarmer /datum/round_event/spawn_swarmer

View File

@@ -3,6 +3,8 @@
//this datum is used by the events controller to dictate how it selects events //this datum is used by the events controller to dictate how it selects events
/datum/round_event_control /datum/round_event_control
var/name //The human-readable name of the event var/name //The human-readable name of the event
var/category //The category of the event
var/description //The description of the event
var/typepath //The typepath of the event datum /datum/round_event var/typepath //The typepath of the event datum /datum/round_event
var/weight = 10 //The weight this event has in the random-selection process. var/weight = 10 //The weight this event has in the random-selection process.
@@ -38,6 +40,7 @@
min_players = CEILING(min_players * CONFIG_GET(number/events_min_players_mul), 1) min_players = CEILING(min_players * CONFIG_GET(number/events_min_players_mul), 1)
/datum/round_event_control/wizard /datum/round_event_control/wizard
category = EVENT_CATEGORY_WIZARD
wizardevent = TRUE wizardevent = TRUE
var/can_be_midround_wizard = TRUE var/can_be_midround_wizard = TRUE
@@ -107,13 +110,22 @@
log_admin_private("[key_name(usr)] cancelled event [name].") log_admin_private("[key_name(usr)] cancelled event [name].")
SSblackbox.record_feedback("tally", "event_admin_cancelled", 1, typepath) SSblackbox.record_feedback("tally", "event_admin_cancelled", 1, typepath)
/datum/round_event_control/proc/runEvent(random = FALSE) /*
Runs the event
* Arguments:
* - random: shows if the event was triggered randomly, or by on purpose by an admin or an item
* - announce_chance_override: if the value is not null, overrides the announcement chance when an admin calls an event
*/
/datum/round_event_control/proc/runEvent(random = FALSE, announce_chance_override = null, admin_forced = FALSE)
var/datum/round_event/E = new typepath() var/datum/round_event/E = new typepath()
E.current_players = get_active_player_count(alive_check = 1, afk_check = 1, human_check = 1) E.current_players = get_active_player_count(alive_check = 1, afk_check = 1, human_check = 1)
E.control = src E.control = src
SSblackbox.record_feedback("tally", "event_ran", 1, "[E]") SSblackbox.record_feedback("tally", "event_ran", 1, "[E]")
occurrences++ occurrences++
if(announce_chance_override != null)
E.announce_chance = announce_chance_override
testing("[time2text(world.time, "hh:mm:ss")] [E.type]") testing("[time2text(world.time, "hh:mm:ss")] [E.type]")
if(random) if(random)
log_game("Random Event triggering: [name] ([typepath])") log_game("Random Event triggering: [name] ([typepath])")
@@ -129,18 +141,29 @@
var/processing = TRUE var/processing = TRUE
var/datum/round_event_control/control var/datum/round_event_control/control
var/startWhen = 0 //When in the lifetime to call start(). /// When in the lifetime to call start().
var/announceWhen = 0 //When in the lifetime to call announce(). Set an event's announceWhen to -1 if announcement should not be shown. /// This is in seconds - so 1 = ~2 seconds in.
var/endWhen = 0 //When in the lifetime the event should end. var/start_when = 0
/// When in the lifetime to call announce(). If you don't want it to announce use announce_chance, below.
/// This is in seconds - so 1 = ~2 seconds in.
var/announce_when = 0
/// Probability of announcing, used in prob(), 0 to 100, default 100. Called in process, and for a second time in the ion storm event.
var/announce_chance = 100
/// When in the lifetime the event should end.
/// This is in seconds - so 1 = ~2 seconds in.
var/end_when = 0
var/activeFor = 0 //How long the event has existed. You don't need to change this. /// How long the event has existed. You don't need to change this.
var/current_players = 0 //Amount of of alive, non-AFK human players on server at the time of event start var/activeFor = 0
/// Amount of of alive, non-AFK human players on server at the time of event start
var/current_players = 0
var/threat = 0 var/threat = 0
var/fakeable = TRUE //Can be faked by fake news event. /// Can be faked by fake news event.
var/fakeable = TRUE
//Called first before processing. //Called first before processing.
//Allows you to setup your event, such as randomly //Allows you to setup your event, such as randomly
//setting the startWhen and or announceWhen variables. //setting the start_when and or announce_when variables.
//Only called once. //Only called once.
//EDIT: if there's anything you want to override within the new() call, it will not be overridden by the time this proc is called. //EDIT: if there's anything you want to override within the new() call, it will not be overridden by the time this proc is called.
//It will only have been overridden by the time we get to announce() start() tick() or end() (anything but setup basically). //It will only have been overridden by the time we get to announce() start() tick() or end() (anything but setup basically).
@@ -148,7 +171,7 @@
/datum/round_event/proc/setup() /datum/round_event/proc/setup()
return return
//Called when the tick is equal to the startWhen variable. //Called when the tick is equal to the start_when variable.
//Allows you to start before announcing or vice versa. //Allows you to start before announcing or vice versa.
//Only called once. //Only called once.
/datum/round_event/proc/start() /datum/round_event/proc/start()
@@ -165,20 +188,20 @@
notify_ghosts("[control.name] has an object of interest: [atom_of_interest]!", source=atom_of_interest, action=NOTIFY_ORBIT, header="Something's Interesting!") notify_ghosts("[control.name] has an object of interest: [atom_of_interest]!", source=atom_of_interest, action=NOTIFY_ORBIT, header="Something's Interesting!")
return return
//Called when the tick is equal to the announceWhen variable. //Called when the tick is equal to the announce_when variable.
//Allows you to announce before starting or vice versa. //Allows you to announce before starting or vice versa.
//Only called once. //Only called once.
/datum/round_event/proc/announce(fake) /datum/round_event/proc/announce(fake)
return return
//Called on or after the tick counter is equal to startWhen. //Called on or after the tick counter is equal to start_when.
//You can include code related to your event or add your own //You can include code related to your event or add your own
//time stamped events. //time stamped events.
//Called more than once. //Called more than once.
/datum/round_event/proc/tick() /datum/round_event/proc/tick()
return return
//Called on or after the tick is equal or more than endWhen //Called on or after the tick is equal or more than end_when
//You can include code related to the event ending. //You can include code related to the event ending.
//Do not place spawn() in here, instead use tick() to check for //Do not place spawn() in here, instead use tick() to check for
//the activeFor variable. //the activeFor variable.
@@ -197,28 +220,28 @@
if(!processing) if(!processing)
return return
if(activeFor == startWhen) if(activeFor == start_when)
processing = FALSE processing = FALSE
start() start()
processing = TRUE processing = TRUE
if(activeFor == announceWhen) if(activeFor == announce_when && prob(announce_chance))
processing = FALSE processing = FALSE
announce(FALSE) announce(FALSE)
processing = TRUE processing = TRUE
if(startWhen < activeFor && activeFor < endWhen) if(start_when < activeFor && activeFor < end_when)
processing = FALSE processing = FALSE
tick() tick()
processing = TRUE processing = TRUE
if(activeFor == endWhen) if(activeFor == end_when)
processing = FALSE processing = FALSE
end() end()
processing = TRUE processing = TRUE
// Everything is done, let's clean up. // Everything is done, let's clean up.
if(activeFor >= endWhen && activeFor >= announceWhen && activeFor >= startWhen) if(activeFor >= end_when && activeFor >= announce_when && activeFor >= start_when)
processing = FALSE processing = FALSE
kill() kill()

View File

@@ -5,6 +5,8 @@
max_occurrences = 1 max_occurrences = 1
min_players = 30 min_players = 30
dynamic_should_hijack = TRUE dynamic_should_hijack = TRUE
category = EVENT_CATEGORY_INVASION
description = "One or more abductor teams spawns, and they plan to experiment on the crew."
/datum/round_event/ghost_role/abductor /datum/round_event/ghost_role/abductor
minimum_required = 2 minimum_required = 2

View File

@@ -5,9 +5,11 @@
min_players = 25 min_players = 25
max_occurrences = 1 max_occurrences = 1
dynamic_should_hijack = TRUE dynamic_should_hijack = TRUE
category = EVENT_CATEGORY_ENTITIES
description = "A xenomorph larva spawns on a random vent."
/datum/round_event/ghost_role/alien_infestation /datum/round_event/ghost_role/alien_infestation
announceWhen = 400 announce_when = 400
minimum_required = 1 minimum_required = 1
role_name = "alien larva" role_name = "alien larva"
@@ -19,7 +21,7 @@
/datum/round_event/ghost_role/alien_infestation/setup() /datum/round_event/ghost_role/alien_infestation/setup()
announceWhen = rand(announceWhen, announceWhen + 50) announce_when = rand(announce_when, announce_when + 50)
if(prob(50)) if(prob(50))
spawncount++ spawncount++

View File

@@ -5,11 +5,13 @@
min_players = 1 min_players = 1
max_occurrences = 0 //This one probably shouldn't occur! It'd work, but it wouldn't be very fun. max_occurrences = 0 //This one probably shouldn't occur! It'd work, but it wouldn't be very fun.
weight = 15 weight = 15
category = EVENT_CATEGORY_ANOMALIES
description = "This anomaly shocks and explodes. This is the base type."
/datum/round_event/anomaly /datum/round_event/anomaly
var/area/impact_area var/area/impact_area
var/obj/effect/anomaly/anomaly_path = /obj/effect/anomaly/flux var/obj/effect/anomaly/anomaly_path = /obj/effect/anomaly/flux
announceWhen = 1 announce_when = 1
/datum/round_event/anomaly/proc/findEventArea() /datum/round_event/anomaly/proc/findEventArea()

View File

@@ -4,10 +4,11 @@
max_occurrences = 1 max_occurrences = 1
weight = 5 weight = 5
description = "This anomaly randomly teleports all items and mobs in a large area."
/datum/round_event/anomaly/anomaly_bluespace /datum/round_event/anomaly/anomaly_bluespace
startWhen = 3 start_when = 3
announceWhen = 10 announce_when = 10
anomaly_path = /obj/effect/anomaly/bluespace anomaly_path = /obj/effect/anomaly/bluespace
/datum/round_event/anomaly/anomaly_bluespace/announce(fake) /datum/round_event/anomaly/anomaly_bluespace/announce(fake)

View File

@@ -4,10 +4,11 @@
max_occurrences = 5 max_occurrences = 5
weight = 20 weight = 20
description = "This anomaly shocks and explodes."
/datum/round_event/anomaly/anomaly_flux /datum/round_event/anomaly/anomaly_flux
startWhen = 10 start_when = 10
announceWhen = 3 announce_when = 3
anomaly_path = /obj/effect/anomaly/flux anomaly_path = /obj/effect/anomaly/flux
/datum/round_event/anomaly/anomaly_flux/announce(fake) /datum/round_event/anomaly/anomaly_flux/announce(fake)

View File

@@ -4,11 +4,11 @@
max_occurrences = 5 max_occurrences = 5
weight = 20 weight = 20
description = "This anomaly throws things around."
/datum/round_event/anomaly/anomaly_grav /datum/round_event/anomaly/anomaly_grav
startWhen = 3 start_when = 3
announceWhen = 20 announce_when = 20
anomaly_path = /obj/effect/anomaly/grav anomaly_path = /obj/effect/anomaly/grav
/datum/round_event/anomaly/anomaly_grav/announce(fake) /datum/round_event/anomaly/anomaly_grav/announce(fake)

View File

@@ -5,10 +5,11 @@
min_players = 5 min_players = 5
max_occurrences = 5 max_occurrences = 5
weight = 20 weight = 20
description = "This anomaly sets things on fire, and creates a pyroclastic slime."
/datum/round_event/anomaly/anomaly_pyro /datum/round_event/anomaly/anomaly_pyro
startWhen = 3 start_when = 3
announceWhen = 10 announce_when = 10
anomaly_path = /obj/effect/anomaly/pyro anomaly_path = /obj/effect/anomaly/pyro
/datum/round_event/anomaly/anomaly_pyro/announce(fake) /datum/round_event/anomaly/anomaly_pyro/announce(fake)

View File

@@ -5,10 +5,11 @@
min_players = 20 min_players = 20
max_occurrences = 2 max_occurrences = 2
weight = 5 weight = 5
description = "This anomaly sucks in and detonates items."
/datum/round_event/anomaly/anomaly_vortex /datum/round_event/anomaly/anomaly_vortex
startWhen = 10 start_when = 10
announceWhen = 3 announce_when = 3
anomaly_path = /obj/effect/anomaly/bhole anomaly_path = /obj/effect/anomaly/bhole
/datum/round_event/anomaly/anomaly_vortex/announce(fake) /datum/round_event/anomaly/anomaly_vortex/announce(fake)

View File

@@ -3,10 +3,12 @@
typepath = /datum/round_event/atmos_flux typepath = /datum/round_event/atmos_flux
max_occurrences = 5 max_occurrences = 5
weight = 10 weight = 10
category = EVENT_CATEGORY_ENGINEERING
description = "Modifies the speed of the SSair randomly, ends after one minute."
/datum/round_event/atmos_flux /datum/round_event/atmos_flux
announceWhen = 1 announce_when = 1
endWhen = 600 end_when = 600
var/original_speed var/original_speed
/datum/round_event/atmos_flux/announce(fake) /datum/round_event/atmos_flux/announce(fake)

View File

@@ -4,6 +4,8 @@
max_occurrences = 1 max_occurrences = 1
weight = 4 weight = 4
earliest_start = 5 MINUTES earliest_start = 5 MINUTES
category = EVENT_CATEGORY_FRIENDLY
description = "A colourful display can be seen through select windows. And the kitchen."
/datum/round_event_control/aurora_caelus/canSpawnEvent(players, gamemode) /datum/round_event_control/aurora_caelus/canSpawnEvent(players, gamemode)
if(!CONFIG_GET(flag/starlight)) if(!CONFIG_GET(flag/starlight))
@@ -11,9 +13,9 @@
return ..() return ..()
/datum/round_event/aurora_caelus /datum/round_event/aurora_caelus
announceWhen = 1 announce_when = 1
startWhen = 9 start_when = 9
endWhen = 50 end_when = 50
var/list/aurora_colors = list("#A2FF80", "#A2FF8B", "#A2FF96", "#A2FFA5", "#A2FFB6", "#A2FFC7", "#A2FFDE", "#A2FFEE") var/list/aurora_colors = list("#A2FF80", "#A2FF8B", "#A2FF96", "#A2FFA5", "#A2FFB6", "#A2FFC7", "#A2FFDE", "#A2FFEE")
var/aurora_progress = 0 //this cycles from 1 to 8, slowly changing colors from gentle green to gentle blue var/aurora_progress = 0 //this cycles from 1 to 8, slowly changing colors from gentle green to gentle blue

View File

@@ -7,9 +7,11 @@
earliest_start = 40 MINUTES earliest_start = 40 MINUTES
min_players = 35 min_players = 35
dynamic_should_hijack = TRUE dynamic_should_hijack = TRUE
category = EVENT_CATEGORY_ENTITIES
description = "Spawns a new blob overmind."
/datum/round_event/ghost_role/blob /datum/round_event/ghost_role/blob
announceWhen = -1 announce_when = -1
role_name = "blob overmind" role_name = "blob overmind"
fakeable = TRUE fakeable = TRUE

View File

@@ -3,6 +3,8 @@
typepath = /datum/round_event/brain_trauma typepath = /datum/round_event/brain_trauma
weight = 25 weight = 25
min_players = 5 min_players = 5
category = EVENT_CATEGORY_HEALTH
description = "A crewmember gains a random trauma."
/datum/round_event_control/brain_trauma/canSpawnEvent(var/players_amt, var/gamemode) /datum/round_event_control/brain_trauma/canSpawnEvent(var/players_amt, var/gamemode)
if(!..()) return FALSE if(!..()) return FALSE

View File

@@ -5,10 +5,12 @@
min_players = 15 min_players = 15
max_occurrences = 1 max_occurrences = 1
category = EVENT_CATEGORY_AI
description = "Vending machines will attack people until the Patient Zero is disabled."
/datum/round_event/brand_intelligence /datum/round_event/brand_intelligence
announceWhen = 21 announce_when = 21
endWhen = 1000 //Ends when all vending machines are subverted anyway. end_when = 1000 //Ends when all vending machines are subverted anyway.
var/list/obj/machinery/vending/vendingMachines = list() var/list/obj/machinery/vending/vendingMachines = list()
var/list/obj/machinery/vending/infectedMachines = list() var/list/obj/machinery/vending/infectedMachines = list()
var/obj/machinery/vending/originMachine var/obj/machinery/vending/originMachine

View File

@@ -3,9 +3,11 @@
typepath = /datum/round_event/bureaucratic_error typepath = /datum/round_event/bureaucratic_error
max_occurrences = 1 max_occurrences = 1
weight = 5 weight = 5
category = EVENT_CATEGORY_BUREAUCRATIC
description = "Randomly opens and closes job slots, along with changing the overflow role."
/datum/round_event/bureaucratic_error /datum/round_event/bureaucratic_error
announceWhen = 1 announce_when = 1
/datum/round_event/bureaucratic_error/announce(fake) /datum/round_event/bureaucratic_error/announce(fake)
priority_announce("A recent bureaucratic error in the Organic Resources Department may result in personnel shortages in some departments and redundant staffing in others.", "Paperwork Mishap Alert") priority_announce("A recent bureaucratic error in the Organic Resources Department may result in personnel shortages in some departments and redundant staffing in others.", "Paperwork Mishap Alert")

View File

@@ -4,6 +4,8 @@
weight = 100 weight = 100
max_occurrences = 20 max_occurrences = 20
alert_observers = FALSE alert_observers = FALSE
category = EVENT_CATEGORY_ENGINEERING
description = "Turns off a random amount of cameras."
/datum/round_event/camera_failure /datum/round_event/camera_failure
fakeable = FALSE fakeable = FALSE

View File

@@ -5,6 +5,8 @@
min_players = 2 min_players = 2
earliest_start = 10 MINUTES earliest_start = 10 MINUTES
max_occurrences = 6 max_occurrences = 6
category = EVENT_CATEGORY_ENTITIES
description = "Summons a school of space carp."
/datum/round_event_control/carp_migration/New() /datum/round_event_control/carp_migration/New()
. = ..() . = ..()
@@ -14,12 +16,12 @@
earliest_start *= 0.5 earliest_start *= 0.5
/datum/round_event/carp_migration /datum/round_event/carp_migration
announceWhen = 3 announce_when = 3
startWhen = 50 start_when = 50
var/hasAnnounced = FALSE var/hasAnnounced = FALSE
/datum/round_event/carp_migration/setup() /datum/round_event/carp_migration/setup()
startWhen = rand(40, 60) start_when = rand(40, 60)
/datum/round_event/carp_migration/announce(fake) /datum/round_event/carp_migration/announce(fake)
if(prob(50)) if(prob(50))

View File

@@ -1,45 +1,47 @@
/datum/round_event_control/cat_surgeon /datum/round_event_control/cat_surgeon
name = "Cat Surgeon" name = "Cat Surgeon"
typepath = /datum/round_event/cat_surgeon typepath = /datum/round_event/cat_surgeon
max_occurrences = 1 max_occurrences = 1
weight = 5 weight = 5
category = EVENT_CATEGORY_ENTITIES
description = "Spawns a crazy surgeon ready to perverse things with the crew."
/datum/round_event/cat_surgeon/announce(fake) /datum/round_event/cat_surgeon/announce(fake)
priority_announce("One of our... ahem... 'special' cases has escaped. As it happens their last known location before their tracker went dead is your station so keep an eye out for them. On an unrelated note, has anyone seen our cats?", priority_announce("One of our... ahem... 'special' cases has escaped. As it happens their last known location before their tracker went dead is your station so keep an eye out for them. On an unrelated note, has anyone seen our cats?",
sender_override = "Nanotrasen Psych Ward", has_important_message = TRUE) sender_override = "Nanotrasen Psych Ward", has_important_message = TRUE)
/datum/round_event/cat_surgeon/start() /datum/round_event/cat_surgeon/start()
var/list/spawn_locs = list() var/list/spawn_locs = list()
var/list/unsafe_spawn_locs = list() var/list/unsafe_spawn_locs = list()
for(var/X in GLOB.xeno_spawn) for(var/X in GLOB.xeno_spawn)
if(!isfloorturf(X)) if(!isfloorturf(X))
unsafe_spawn_locs += X unsafe_spawn_locs += X
continue continue
var/turf/open/floor/F = X var/turf/open/floor/F = X
var/datum/gas_mixture/A = F.air var/datum/gas_mixture/A = F.air
var/oxy_moles = A.get_moles(GAS_O2) var/oxy_moles = A.get_moles(GAS_O2)
if((oxy_moles < 16 || oxy_moles > 50) || A.get_moles(GAS_PLASMA) || A.get_moles(GAS_CO2) >= 10) if((oxy_moles < 16 || oxy_moles > 50) || A.get_moles(GAS_PLASMA) || A.get_moles(GAS_CO2) >= 10)
unsafe_spawn_locs += F unsafe_spawn_locs += F
continue continue
if((A.return_temperature() <= 270) || (A.return_temperature() >= 360)) if((A.return_temperature() <= 270) || (A.return_temperature() >= 360))
unsafe_spawn_locs += F unsafe_spawn_locs += F
continue continue
var/pressure = A.return_pressure() var/pressure = A.return_pressure()
if((pressure <= 20) || (pressure >= 550)) if((pressure <= 20) || (pressure >= 550))
unsafe_spawn_locs += F unsafe_spawn_locs += F
continue continue
spawn_locs += F spawn_locs += F
if(!spawn_locs.len) if(!spawn_locs.len)
spawn_locs += unsafe_spawn_locs spawn_locs += unsafe_spawn_locs
if(!spawn_locs.len) if(!spawn_locs.len)
message_admins("No valid spawn locations found, aborting...") message_admins("No valid spawn locations found, aborting...")
return MAP_ERROR return MAP_ERROR
var/turf/T = get_turf(pick(spawn_locs)) var/turf/T = get_turf(pick(spawn_locs))
var/mob/living/simple_animal/hostile/cat_butcherer/S = new(T) var/mob/living/simple_animal/hostile/cat_butcherer/S = new(T)
playsound(S, 'sound/misc/catscream.ogg', 75, 1, -1) playsound(S, 'sound/misc/catscream.ogg', 75, 1, -1)
message_admins("A cat surgeon has been spawned at [COORD(T)][ADMIN_JMP(T)]") message_admins("A cat surgeon has been spawned at [COORD(T)][ADMIN_JMP(T)]")
log_game("A cat surgeon has been spawned at [COORD(T)]") log_game("A cat surgeon has been spawned at [COORD(T)]")
return SUCCESSFUL_SPAWN return SUCCESSFUL_SPAWN

View File

@@ -2,9 +2,11 @@
name = "Communications Blackout" name = "Communications Blackout"
typepath = /datum/round_event/communications_blackout typepath = /datum/round_event/communications_blackout
weight = 30 weight = 30
category = EVENT_CATEGORY_ENGINEERING
description = "Heavily emps all telecommunication machines, blocking all communication for a while."
/datum/round_event/communications_blackout /datum/round_event/communications_blackout
announceWhen = 1 announce_when = 1
/datum/round_event/communications_blackout/announce(fake) /datum/round_event/communications_blackout/announce(fake)
var/alert = pick( "Ionospheric anomalies detected. Temporary telecommunication failure imminent. Please contact you*%fj00)`5vc-BZZT", \ var/alert = pick( "Ionospheric anomalies detected. Temporary telecommunication failure imminent. Please contact you*%fj00)`5vc-BZZT", \

View File

@@ -2,6 +2,8 @@
name = "Create Devil" name = "Create Devil"
typepath = /datum/round_event/ghost_role/devil typepath = /datum/round_event/ghost_role/devil
max_occurrences = 0 max_occurrences = 0
category = EVENT_CATEGORY_ENTITIES
description = "Spawns a devil, looking forward to makings deals with crewmembers to get their souls."
/datum/round_event/ghost_role/devil /datum/round_event/ghost_role/devil
var/success_spawn = 0 var/success_spawn = 0

View File

@@ -4,9 +4,11 @@
max_occurrences = 1 max_occurrences = 1
min_players = 3 min_players = 3
weight = 5 weight = 5
category = EVENT_CATEGORY_HEALTH
description = "A classic or advanced disease will infect some crewmembers."
/datum/round_event/disease_outbreak /datum/round_event/disease_outbreak
announceWhen = 15 announce_when = 15
var/virus_type var/virus_type
@@ -24,7 +26,7 @@
priority_announce("Confirmed outbreak of level 7 viral biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert", "outbreak7") priority_announce("Confirmed outbreak of level 7 viral biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert", "outbreak7")
/datum/round_event/disease_outbreak/setup() /datum/round_event/disease_outbreak/setup()
announceWhen = rand(15, 30) announce_when = rand(15, 30)
/datum/round_event/disease_outbreak/start() /datum/round_event/disease_outbreak/start()

View File

@@ -5,10 +5,12 @@
max_occurrences = 1000 max_occurrences = 1000
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
alert_observers = FALSE alert_observers = FALSE
category = EVENT_CATEGORY_SPACE
description = "A single space dust is hurled at the station."
/datum/round_event/space_dust /datum/round_event/space_dust
startWhen = 1 start_when = 1
endWhen = 2 end_when = 2
fakeable = FALSE fakeable = FALSE
/datum/round_event/space_dust/start() /datum/round_event/space_dust/start()
@@ -21,11 +23,13 @@
max_occurrences = 1 max_occurrences = 1
min_players = 10 min_players = 10
earliest_start = 20 MINUTES earliest_start = 20 MINUTES
category = EVENT_CATEGORY_SPACE
description = "The station is pelted by an extreme amount of sand for several minutes."
/datum/round_event/sandstorm /datum/round_event/sandstorm
startWhen = 1 start_when = 1
endWhen = 150 // ~5 min end_when = 150 // ~5 min
announceWhen = 0 announce_when = 0
fakeable = FALSE fakeable = FALSE
/datum/round_event/sandstorm/announce(fake) /datum/round_event/sandstorm/announce(fake)

View File

@@ -4,12 +4,13 @@
earliest_start = 10 MINUTES earliest_start = 10 MINUTES
min_players = 5 min_players = 5
weight = 40 weight = 40
alert_observers = FALSE category = EVENT_CATEGORY_ENGINEERING
description = "Destroys all lights in a large area."
/datum/round_event/electrical_storm /datum/round_event/electrical_storm
var/lightsoutAmount = 1 var/lightsoutAmount = 1
var/lightsoutRange = 25 var/lightsoutRange = 25
announceWhen = 1 announce_when = 1
/datum/round_event/electrical_storm/announce(fake) /datum/round_event/electrical_storm/announce(fake)
if(prob(50)) if(prob(50))

View File

@@ -2,6 +2,8 @@
name = "Fake Virus" name = "Fake Virus"
typepath = /datum/round_event/fake_virus typepath = /datum/round_event/fake_virus
weight = 20 weight = 20
category = EVENT_CATEGORY_HEALTH
description = "Some crewmembers suffer from temporary hypochondria."
/datum/round_event/fake_virus/start() /datum/round_event/fake_virus/start()
var/list/fake_virus_victims = list() var/list/fake_virus_victims = list()

View File

@@ -4,7 +4,8 @@
weight = 20 weight = 20
max_occurrences = 5 max_occurrences = 5
var/forced_type //Admin abuse var/forced_type //Admin abuse
category = EVENT_CATEGORY_BUREAUCRATIC
description = "Fakes an event announcement."
/datum/round_event_control/falsealarm/admin_setup() /datum/round_event_control/falsealarm/admin_setup()
if(!check_rights(R_FUN)) if(!check_rights(R_FUN))
@@ -17,15 +18,15 @@
if(!initial(event.fakeable)) if(!initial(event.fakeable))
continue continue
possible_types += E possible_types += E
forced_type = input(usr, "Select the scare.","False event") as null|anything in possible_types forced_type = input(usr, "Select the scare.","False event") as null|anything in possible_types
/datum/round_event_control/falsealarm/canSpawnEvent(players_amt, gamemode) /datum/round_event_control/falsealarm/canSpawnEvent(players_amt, gamemode)
return ..() && length(gather_false_events()) return ..() && length(gather_false_events())
/datum/round_event/falsealarm /datum/round_event/falsealarm
announceWhen = 0 announce_when = 0
endWhen = 1 end_when = 1
fakeable = FALSE fakeable = FALSE
/datum/round_event/falsealarm/announce(fake) /datum/round_event/falsealarm/announce(fake)

View File

@@ -4,7 +4,8 @@
max_occurrences = 0 max_occurrences = 0
min_players = 20 min_players = 20
weight = 10 weight = 10
category = EVENT_CATEGORY_ENTITIES
description = "Spawns a floor cluwne, will hunt a random player and most likely gib them, prepare for adminhelps."
/datum/round_event/floor_cluwne/start() /datum/round_event/floor_cluwne/start()
var/list/spawn_locs = list() var/list/spawn_locs = list()

View File

@@ -4,6 +4,8 @@
max_occurrences = 1 max_occurrences = 1
min_players = 20 min_players = 20
earliest_start = 30 MINUTES //deadchat sink, lets not even consider it early on. earliest_start = 30 MINUTES //deadchat sink, lets not even consider it early on.
category = EVENT_CATEGORY_INVASION
description = "Fugitives will hide on the station, followed by hunters."
/datum/round_event/ghost_role/fugitives /datum/round_event/ghost_role/fugitives
minimum_required = 1 minimum_required = 1

View File

@@ -7,6 +7,8 @@
var/minimum_required = 1 var/minimum_required = 1
var/role_name = "debug rat with cancer" // Q U A L I T Y M E M E S var/role_name = "debug rat with cancer" // Q U A L I T Y M E M E S
var/list/spawned_mobs = list() var/list/spawned_mobs = list()
var/status
var/cached_announcement_chance
fakeable = FALSE fakeable = FALSE
/datum/round_event/ghost_role/start() /datum/round_event/ghost_role/start()
@@ -17,7 +19,10 @@
// to prevent us from getting gc'd halfway through // to prevent us from getting gc'd halfway through
processing = FALSE processing = FALSE
var/status = spawn_role() status = spawn_role()
if(isnull(cached_announcement_chance))
cached_announcement_chance = announce_chance //only announce once we've finished the spawning loop.
announce_chance = (status == SUCCESSFUL_SPAWN ? cached_announcement_chance : 0)
if((status == WAITING_FOR_SOMETHING)) if((status == WAITING_FOR_SOMETHING))
if(retry >= MAX_SPAWN_ATTEMPT) if(retry >= MAX_SPAWN_ATTEMPT)
message_admins("[role_name] event has exceeded maximum spawn attempts. Aborting and refunding.") message_admins("[role_name] event has exceeded maximum spawn attempts. Aborting and refunding.")

View File

@@ -3,10 +3,12 @@
typepath = /datum/round_event/grid_check typepath = /datum/round_event/grid_check
weight = 10 weight = 10
max_occurrences = 3 max_occurrences = 3
category = EVENT_CATEGORY_ENGINEERING
description = "Turns off all APCs for a while, or until they are manually rebooted."
/datum/round_event/grid_check /datum/round_event/grid_check
announceWhen = 1 announce_when = 1
startWhen = 1 start_when = 1
/datum/round_event/grid_check/announce(fake) /datum/round_event/grid_check/announce(fake)
priority_announce("Abnormal activity detected in [station_name()]'s powernet. As a precautionary measure, the station's power will be shut off for an indeterminate duration.", "Critical Power Failure", "poweroff") priority_announce("Abnormal activity detected in [station_name()]'s powernet. As a precautionary measure, the station's power will be shut off for an indeterminate duration.", "Critical Power Failure", "poweroff")

View File

@@ -4,6 +4,8 @@
weight = 10 weight = 10
max_occurrences = 2 max_occurrences = 2
min_players = 10 // To avoid shafting lowpop min_players = 10 // To avoid shafting lowpop
category = EVENT_CATEGORY_HEALTH
description = "A random crewmember's heart gives out."
/datum/round_event_control/heart_attack/canSpawnEvent(var/players_amt, var/gamemode) /datum/round_event_control/heart_attack/canSpawnEvent(var/players_amt, var/gamemode)
if(!..()) return FALSE if(!..()) return FALSE

View File

@@ -4,6 +4,8 @@
max_occurrences = 3 max_occurrences = 3
weight = 20 weight = 20
earliest_start = 10 earliest_start = 10
category = EVENT_CATEGORY_BUREAUCRATIC
description = "Creates bounties that are three times original worth."
/datum/round_event/high_priority_bounty/announce(fake) /datum/round_event/high_priority_bounty/announce(fake)
priority_announce("Central Command has issued a high-priority cargo bounty. Details have been sent to all bounty consoles.", "Nanotrasen Bounty Program") priority_announce("Central Command has issued a high-priority cargo bounty. Details have been sent to all bounty consoles.", "Nanotrasen Bounty Program")

View File

@@ -5,6 +5,8 @@
weight = -1 //forces it to be called, regardless of weight weight = -1 //forces it to be called, regardless of weight
max_occurrences = 1 max_occurrences = 1
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
category = EVENT_CATEGORY_HOLIDAY
description = "Gives everyone treats, and turns Ian and Polly into their festive versions."
/datum/round_event/spooky/start() /datum/round_event/spooky/start()
..() ..()

View File

@@ -11,6 +11,8 @@
weight = -1 //forces it to be called, regardless of weight weight = -1 //forces it to be called, regardless of weight
max_occurrences = 1 max_occurrences = 1
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
category = EVENT_CATEGORY_HOLIDAY
description = "Puts people on dates! They must protect each other. Sometimes a vengeful third wheel spawns."
/datum/round_event/valentines/start() /datum/round_event/valentines/start()
..() ..()

View File

@@ -68,6 +68,8 @@
weight = 20 weight = 20
max_occurrences = 1 max_occurrences = 1
earliest_start = 30 MINUTES earliest_start = 30 MINUTES
category = EVENT_CATEGORY_HOLIDAY
description = "Spawns santa, who shall roam the station, handing out gifts."
/datum/round_event/santa /datum/round_event/santa
var/mob/living/carbon/human/santa //who is our santa? var/mob/living/carbon/human/santa //who is our santa?

View File

@@ -13,7 +13,8 @@ In my current plan for it, 'solid' will be defined as anything with density == 1
min_players = 15 min_players = 15
max_occurrences = 5 max_occurrences = 5
var/atom/special_target var/atom/special_target
category = EVENT_CATEGORY_SPACE
description = "The station passes through an immovable rod."
/datum/round_event_control/immovable_rod/admin_setup() /datum/round_event_control/immovable_rod/admin_setup()
if(!check_rights(R_FUN)) if(!check_rights(R_FUN))
@@ -24,7 +25,7 @@ In my current plan for it, 'solid' will be defined as anything with density == 1
special_target = get_turf(usr) special_target = get_turf(usr)
/datum/round_event/immovable_rod /datum/round_event/immovable_rod
announceWhen = 5 announce_when = 5
/datum/round_event/immovable_rod/announce(fake) /datum/round_event/immovable_rod/announce(fake)
priority_announce("What the fuck was that?!", "General Alert", has_important_message = TRUE) priority_announce("What the fuck was that?!", "General Alert", has_important_message = TRUE)

View File

@@ -5,6 +5,8 @@
typepath = /datum/round_event/ion_storm typepath = /datum/round_event/ion_storm
weight = 15 weight = 15
min_players = 2 min_players = 2
category = EVENT_CATEGORY_AI
description = "Gives the AI a new, randomized law."
/datum/round_event/ion_storm /datum/round_event/ion_storm
var/replaceLawsetChance = 25 //chance the AI's lawset is completely replaced with something else per config weights var/replaceLawsetChance = 25 //chance the AI's lawset is completely replaced with something else per config weights
@@ -14,8 +16,8 @@
var/botEmagChance = 10 var/botEmagChance = 10
var/announceEvent = ION_RANDOM // -1 means don't announce, 0 means have it randomly announce, 1 means it is announced var/announceEvent = ION_RANDOM // -1 means don't announce, 0 means have it randomly announce, 1 means it is announced
var/ionMessage = null var/ionMessage = null
var/ionAnnounceChance = 33 announce_when = 1
announceWhen = 1 announce_chance = 33
/datum/round_event/ion_storm/add_law_only // special subtype that adds a law only /datum/round_event/ion_storm/add_law_only // special subtype that adds a law only
replaceLawsetChance = 0 replaceLawsetChance = 0
@@ -25,7 +27,7 @@
botEmagChance = 0 botEmagChance = 0
/datum/round_event/ion_storm/announce(fake) /datum/round_event/ion_storm/announce(fake)
if(announceEvent == ION_ANNOUNCE || (announceEvent == ION_RANDOM && prob(ionAnnounceChance)) || fake) if(announceEvent == ION_ANNOUNCE || (announceEvent == ION_RANDOM && prob(announce_chance)) || fake)
priority_announce("Ion storm detected near the station. Please check all AI-controlled equipment for errors.", "Anomaly Alert", "ionstorm", has_important_message = prob(80)) priority_announce("Ion storm detected near the station. Please check all AI-controlled equipment for errors.", "Anomaly Alert", "ionstorm", has_important_message = prob(80))

View File

@@ -2,6 +2,7 @@
name = "Major Space Dust" name = "Major Space Dust"
typepath = /datum/round_event/meteor_wave/major_dust typepath = /datum/round_event/meteor_wave/major_dust
weight = 8 weight = 8
description = "The station is pelted by sand."
/datum/round_event/meteor_wave/major_dust /datum/round_event/meteor_wave/major_dust
wave_name = "space dust" wave_name = "space dust"

View File

@@ -5,6 +5,8 @@
max_occurrences = 5 max_occurrences = 5
min_players = 1 min_players = 1
var/forced_hallucination var/forced_hallucination
category = EVENT_CATEGORY_HEALTH
description = "Multiple crewmembers start to hallucinate the same thing."
/datum/round_event_control/mass_hallucination/admin_setup() /datum/round_event_control/mass_hallucination/admin_setup()
if(!check_rights(R_FUN)) if(!check_rights(R_FUN))

View File

@@ -3,6 +3,7 @@
typepath = /datum/round_event/meteor_wave/meaty typepath = /datum/round_event/meteor_wave/meaty
weight = 2 weight = 2
max_occurrences = 1 max_occurrences = 1
description = "A meteor wave made of meat."
/datum/round_event/meteor_wave/meaty /datum/round_event/meteor_wave/meaty
wave_name = "meaty" wave_name = "meaty"

View File

@@ -10,22 +10,24 @@
min_players = 15 min_players = 15
max_occurrences = 3 max_occurrences = 3
earliest_start = 25 MINUTES earliest_start = 25 MINUTES
category = EVENT_CATEGORY_SPACE
description = "A regular meteor wave."
/datum/round_event/meteor_wave /datum/round_event/meteor_wave
startWhen = 6 start_when = 6
endWhen = 66 end_when = 66
announceWhen = 1 announce_when = 1
threat = 15 threat = 15
var/list/wave_type var/list/wave_type
var/wave_name = "normal" var/wave_name = "normal"
var/direction var/direction
/datum/round_event/meteor_wave/setup() /datum/round_event/meteor_wave/setup()
announceWhen = 1 announce_when = 1
startWhen = 150 // 5 minutes start_when = 150 // 5 minutes
if(GLOB.singularity_counter) if(GLOB.singularity_counter)
startWhen *= 1 - min(GLOB.singularity_counter * SINGULO_BEACON_DISTURBANCE, SINGULO_BEACON_MAX_DISTURBANCE) start_when *= 1 - min(GLOB.singularity_counter * SINGULO_BEACON_DISTURBANCE, SINGULO_BEACON_MAX_DISTURBANCE)
endWhen = startWhen + 60 end_when = start_when + 60
/datum/round_event/meteor_wave/New() /datum/round_event/meteor_wave/New()
..() ..()
@@ -61,9 +63,9 @@
kill() kill()
/datum/round_event/meteor_wave/announce(fake) /datum/round_event/meteor_wave/announce(fake)
priority_announce(generateMeteorString(startWhen,TRUE,direction), "Meteor Alert", "meteors", has_important_message = TRUE) priority_announce(generateMeteorString(start_when,TRUE,direction), "Meteor Alert", "meteors", has_important_message = TRUE)
/proc/generateMeteorString(startWhen,syndiealert,direction) /proc/generateMeteorString(start_when,syndiealert,direction)
var/directionstring var/directionstring
switch(direction) switch(direction)
if(NORTH) if(NORTH)
@@ -74,7 +76,7 @@
directionstring = " towards starboard" directionstring = " towards starboard"
if(WEST) if(WEST)
directionstring = " towards port" directionstring = " towards port"
return "Meteors have been detected on a collision course with the station[directionstring]. Estimated time until impact: [round((startWhen * SSevents.wait) / 10, 0.1)] seconds.[GLOB.singularity_counter && syndiealert ? " Warning: Anomalous gravity pulse detected, Syndicate technology interference likely." : ""]" return "Meteors have been detected on a collision course with the station[directionstring]. Estimated time until impact: [round((start_when * SSevents.wait) / 10, 0.1)] seconds.[GLOB.singularity_counter && syndiealert ? " Warning: Anomalous gravity pulse detected, Syndicate technology interference likely." : ""]"
/datum/round_event/meteor_wave/tick() /datum/round_event/meteor_wave/tick()
if(ISMULTIPLE(activeFor, 3)) if(ISMULTIPLE(activeFor, 3))
@@ -87,7 +89,7 @@
min_players = 20 min_players = 20
max_occurrences = 3 max_occurrences = 3
earliest_start = 35 MINUTES earliest_start = 35 MINUTES
description = "A meteor wave with higher chance of big meteors."
/datum/round_event/meteor_wave/threatening /datum/round_event/meteor_wave/threatening
wave_name = "threatening" wave_name = "threatening"
@@ -100,6 +102,7 @@
min_players = 25 min_players = 25
max_occurrences = 3 max_occurrences = 3
earliest_start = 45 MINUTES earliest_start = 45 MINUTES
description = "A meteor wave that might summon a tunguska class meteor."
/datum/round_event/meteor_wave/catastrophic /datum/round_event/meteor_wave/catastrophic
wave_name = "catastrophic" wave_name = "catastrophic"

View File

@@ -2,6 +2,8 @@
name = "Mice Migration" name = "Mice Migration"
typepath = /datum/round_event/mice_migration typepath = /datum/round_event/mice_migration
weight = 10 weight = 10
category = EVENT_CATEGORY_ENTITIES
description = "A horde of mice arrives, and perhaps even the Rat King themselves."
/datum/round_event/mice_migration /datum/round_event/mice_migration
var/minimum_mice = 5 var/minimum_mice = 5

View File

@@ -4,6 +4,8 @@
max_occurrences = 1 max_occurrences = 1
min_players = 20 min_players = 20
dynamic_should_hijack = TRUE dynamic_should_hijack = TRUE
category = EVENT_CATEGORY_ENTITIES
description = "Spawns a nightmare, aiming to darken the station."
/datum/round_event/ghost_role/nightmare /datum/round_event/ghost_role/nightmare
minimum_required = 1 minimum_required = 1

View File

@@ -3,6 +3,8 @@
typepath = /datum/round_event/ghost_role/operative typepath = /datum/round_event/ghost_role/operative
weight = 0 //Admin only weight = 0 //Admin only
max_occurrences = 1 max_occurrences = 1
category = EVENT_CATEGORY_INVASION
description = "A single nuclear operative assaults the station."
/datum/round_event/ghost_role/operative /datum/round_event/ghost_role/operative
minimum_required = 1 minimum_required = 1

View File

@@ -6,6 +6,8 @@
min_players = 10 min_players = 10
earliest_start = 30 MINUTES earliest_start = 30 MINUTES
dynamic_should_hijack = TRUE dynamic_should_hijack = TRUE
category = EVENT_CATEGORY_INVASION
description = "The crew will either pay up, or face a pirate assault."
#define PIRATES_ROGUES "Rogues" #define PIRATES_ROGUES "Rogues"
// #define PIRATES_SILVERSCALES "Silverscales" // #define PIRATES_SILVERSCALES "Silverscales"

View File

@@ -4,6 +4,8 @@
weight = 2 weight = 2
min_players = 15 min_players = 15
earliest_start = 30 MINUTES earliest_start = 30 MINUTES
category = EVENT_CATEGORY_ENTITIES
description = "Syndicate troops pour out of portals."
/datum/round_event/portal_storm/syndicate_shocktroop /datum/round_event/portal_storm/syndicate_shocktroop
boss_types = list(/mob/living/simple_animal/hostile/syndicate/melee/space/stormtrooper = 2) boss_types = list(/mob/living/simple_animal/hostile/syndicate/melee/space/stormtrooper = 2)
@@ -15,6 +17,8 @@
typepath = /datum/round_event/portal_storm/portal_storm_narsie typepath = /datum/round_event/portal_storm/portal_storm_narsie
weight = 0 weight = 0
max_occurrences = 0 max_occurrences = 0
category = EVENT_CATEGORY_ENTITIES
description = "Nar'sie constructs pour out of portals."
/datum/round_event/portal_storm/portal_storm_narsie /datum/round_event/portal_storm/portal_storm_narsie
boss_types = list(/mob/living/simple_animal/hostile/construct/builder = 6) boss_types = list(/mob/living/simple_animal/hostile/construct/builder = 6)
@@ -22,9 +26,9 @@
/mob/living/simple_animal/hostile/construct/wraith/hostile = 6) /mob/living/simple_animal/hostile/construct/wraith/hostile = 6)
/datum/round_event/portal_storm /datum/round_event/portal_storm
startWhen = 7 start_when = 7
endWhen = 999 end_when = 999
announceWhen = 1 announce_when = 1
var/list/boss_spawn = list() var/list/boss_spawn = list()
var/list/boss_types = list() //only configure this if you have hostiles var/list/boss_types = list() //only configure this if you have hostiles
@@ -53,7 +57,7 @@
while(number_of_hostiles > hostiles_spawn.len) while(number_of_hostiles > hostiles_spawn.len)
hostiles_spawn += get_random_station_turf() hostiles_spawn += get_random_station_turf()
next_boss_spawn = startWhen + CEILING(2 * number_of_hostiles / number_of_bosses, 1) next_boss_spawn = start_when + CEILING(2 * number_of_hostiles / number_of_bosses, 1)
/datum/round_event/portal_storm/announce(fake) /datum/round_event/portal_storm/announce(fake)
do_announce() do_announce()
@@ -117,7 +121,7 @@
/datum/round_event/portal_storm/proc/time_to_end() /datum/round_event/portal_storm/proc/time_to_end()
if(!hostile_types.len && !boss_types.len) if(!hostile_types.len && !boss_types.len)
endWhen = activeFor end_when = activeFor
if(!number_of_hostiles && number_of_bosses) if(!number_of_hostiles && number_of_bosses)
endWhen = activeFor end_when = activeFor

View File

@@ -3,10 +3,12 @@
typepath = /datum/round_event/grey_tide typepath = /datum/round_event/grey_tide
max_occurrences = 2 max_occurrences = 2
min_players = 5 min_players = 5
category = EVENT_CATEGORY_ENGINEERING
description = "Bolts open all doors in one or more departments."
/datum/round_event/grey_tide /datum/round_event/grey_tide
announceWhen = 50 announce_when = 50
endWhen = 20 end_when = 20
var/list/area/areasToOpen = list() var/list/area/areasToOpen = list()
var/list/potential_areas = list(/area/command, var/list/potential_areas = list(/area/command,
/area/engineering, /area/engineering,
@@ -17,8 +19,8 @@
var/severity = 1 var/severity = 1
/datum/round_event/grey_tide/setup() /datum/round_event/grey_tide/setup()
announceWhen = rand(50, 60) announce_when = rand(50, 60)
endWhen = rand(20, 30) end_when = rand(20, 30)
severity = rand(1,3) severity = rand(1,3)
for(var/i in 1 to severity) for(var/i in 1 to severity)
var/picked_area = pick_n_take(potential_areas) var/picked_area = pick_n_take(potential_areas)

View File

@@ -3,9 +3,11 @@
typepath = /datum/round_event/processor_overload typepath = /datum/round_event/processor_overload
weight = 15 weight = 15
min_players = 20 min_players = 20
category = EVENT_CATEGORY_ENGINEERING
description = "Emps the telecomm processors, scrambling radio speech. Might blow up a few."
/datum/round_event/processor_overload /datum/round_event/processor_overload
announceWhen = 1 announce_when = 1
/datum/round_event/processor_overload/announce(fake) /datum/round_event/processor_overload/announce(fake)
var/alert = pick( "Exospheric bubble inbound. Processor overload is likely. Please contact you*%xp25)`6cq-BZZT", \ var/alert = pick( "Exospheric bubble inbound. Processor overload is likely. Please contact you*%xp25)`6cq-BZZT", \

View File

@@ -2,14 +2,16 @@
name = "Radiation Storm" name = "Radiation Storm"
typepath = /datum/round_event/radiation_storm typepath = /datum/round_event/radiation_storm
max_occurrences = 1 max_occurrences = 1
category = EVENT_CATEGORY_SPACE
description = "Radiation storm affects the station, forcing the crew to escape to maintenance."
/datum/round_event/radiation_storm /datum/round_event/radiation_storm
/datum/round_event/radiation_storm/setup() /datum/round_event/radiation_storm/setup()
startWhen = 3 start_when = 3
endWhen = startWhen + 1 end_when = start_when + 1
announceWhen = 1 announce_when = 1
/datum/round_event/radiation_storm/announce(fake) /datum/round_event/radiation_storm/announce(fake)
priority_announce("High levels of radiation detected near the station. Maintenance is best shielded from radiation.", "Anomaly Alert", "radiation", has_important_message = TRUE) priority_announce("High levels of radiation detected near the station. Maintenance is best shielded from radiation.", "Anomaly Alert", "radiation", has_important_message = TRUE)

View File

@@ -2,7 +2,8 @@
name = "Random Human-level Intelligence" name = "Random Human-level Intelligence"
typepath = /datum/round_event/ghost_role/sentience typepath = /datum/round_event/ghost_role/sentience
weight = 10 weight = 10
category = EVENT_CATEGORY_FRIENDLY
description = "An animal or robot becomes sentient!"
/datum/round_event/ghost_role/sentience /datum/round_event/ghost_role/sentience
minimum_required = 1 minimum_required = 1
@@ -75,6 +76,8 @@
name = "Station-wide Human-level Intelligence" name = "Station-wide Human-level Intelligence"
typepath = /datum/round_event/ghost_role/sentience/all typepath = /datum/round_event/ghost_role/sentience/all
weight = 0 weight = 0
category = EVENT_CATEGORY_FRIENDLY
description = "ALL animals and robots become sentient, provided there is enough ghosts."
/datum/round_event/ghost_role/sentience/all /datum/round_event/ghost_role/sentience/all
one = "all" one = "all"

View File

@@ -3,6 +3,8 @@
typepath = /datum/round_event/shuttle_catastrophe typepath = /datum/round_event/shuttle_catastrophe
weight = 10 weight = 10
max_occurrences = 1 max_occurrences = 1
category = EVENT_CATEGORY_BUREAUCRATIC
description = "Replaces the emergency shuttle with a random one."
/datum/round_event_control/shuttle_catastrophe/canSpawnEvent(players, gamemode) /datum/round_event_control/shuttle_catastrophe/canSpawnEvent(players, gamemode)
if(SSshuttle.emergency.name == "Build your own shuttle kit") if(SSshuttle.emergency.name == "Build your own shuttle kit")

View File

@@ -13,10 +13,12 @@
typepath = /datum/round_event/shuttle_loan typepath = /datum/round_event/shuttle_loan
max_occurrences = 1 max_occurrences = 1
earliest_start = 7 MINUTES earliest_start = 7 MINUTES
category = EVENT_CATEGORY_BUREAUCRATIC
description = "If cargo accepts the offer, fills the shuttle with loot and/or enemies."
/datum/round_event/shuttle_loan /datum/round_event/shuttle_loan
announceWhen = 1 announce_when = 1
endWhen = 500 end_when = 500
var/dispatched = 0 var/dispatched = 0
var/dispatch_type = 0 var/dispatch_type = 0
var/bonus_points = 10000 var/bonus_points = 10000
@@ -72,7 +74,7 @@
var/datum/bank_account/D = SSeconomy.get_dep_account(ACCOUNT_CAR) var/datum/bank_account/D = SSeconomy.get_dep_account(ACCOUNT_CAR)
if(D) if(D)
D.adjust_money(bonus_points) D.adjust_money(bonus_points)
endWhen = activeFor + 1 end_when = activeFor + 1
SSshuttle.supply.mode = SHUTTLE_CALL SSshuttle.supply.mode = SHUTTLE_CALL
SSshuttle.supply.destination = SSshuttle.getDock("supply_home") SSshuttle.supply.destination = SSshuttle.getDock("supply_home")
@@ -101,9 +103,9 @@
/datum/round_event/shuttle_loan/tick() /datum/round_event/shuttle_loan/tick()
if(dispatched) if(dispatched)
if(SSshuttle.supply.mode != SHUTTLE_IDLE) if(SSshuttle.supply.mode != SHUTTLE_IDLE)
endWhen = activeFor end_when = activeFor
else else
endWhen = activeFor + 1 end_when = activeFor + 1
/datum/round_event/shuttle_loan/end() /datum/round_event/shuttle_loan/end()
if(SSshuttle.shuttle_loan && SSshuttle.shuttle_loan.dispatched) if(SSshuttle.shuttle_loan && SSshuttle.shuttle_loan.dispatched)

View File

@@ -5,11 +5,13 @@
max_occurrences = 1 max_occurrences = 1
min_players = 20 min_players = 20
dynamic_should_hijack = TRUE dynamic_should_hijack = TRUE
category = EVENT_CATEGORY_ENTITIES
description = "Spawns a space dragon, which will try to take over the station."
/datum/round_event/ghost_role/space_dragon /datum/round_event/ghost_role/space_dragon
minimum_required = 1 minimum_required = 1
role_name = "Space Dragon" role_name = "Space Dragon"
announceWhen = 10 announce_when = 10
/datum/round_event/ghost_role/space_dragon/announce(fake) /datum/round_event/ghost_role/space_dragon/announce(fake)
priority_announce("A large organic energy flux has been recorded near of [station_name()], please stand-by.", "Lifesign Alert", has_important_message = TRUE) priority_announce("A large organic energy flux has been recorded near of [station_name()], please stand-by.", "Lifesign Alert", has_important_message = TRUE)

View File

@@ -6,6 +6,8 @@
earliest_start = 20 MINUTES earliest_start = 20 MINUTES
min_players = 15 min_players = 15
dynamic_should_hijack = TRUE dynamic_should_hijack = TRUE
category = EVENT_CATEGORY_INVASION
description = "A space ninja infiltrates the station."
/datum/round_event/ghost_role/space_ninja /datum/round_event/ghost_role/space_ninja
minimum_required = 1 minimum_required = 1

View File

@@ -4,6 +4,8 @@
weight = 15 weight = 15
max_occurrences = 3 max_occurrences = 3
min_players = 20 min_players = 20
category = EVENT_CATEGORY_ENTITIES
description = "Kudzu begins to overtake the station. Might spawn man-traps."
/datum/round_event/spacevine /datum/round_event/spacevine
fakeable = FALSE fakeable = FALSE

View File

@@ -4,15 +4,17 @@
weight = 5 weight = 5
max_occurrences = 1 max_occurrences = 1
min_players = 15 min_players = 15
category = EVENT_CATEGORY_ENTITIES
description = "Spawns spider eggs, ready to hatch."
/datum/round_event/spider_infestation /datum/round_event/spider_infestation
announceWhen = 400 announce_when = 400
var/spawncount = 1 var/spawncount = 1
/datum/round_event/spider_infestation/setup() /datum/round_event/spider_infestation/setup()
announceWhen = rand(announceWhen, announceWhen + 50) announce_when = rand(announce_when, announce_when + 50)
spawncount = rand(5, 8) spawncount = rand(5, 8)
/datum/round_event/spider_infestation/announce(fake) /datum/round_event/spider_infestation/announce(fake)

View File

@@ -5,6 +5,8 @@
max_occurrences = 4 max_occurrences = 4
earliest_start = 10 MINUTES earliest_start = 10 MINUTES
min_players = 5 // To make your chance of getting help a bit higher. min_players = 5 // To make your chance of getting help a bit higher.
category = EVENT_CATEGORY_HEALTH
description = "A random crewmember gets appendicitis."
/datum/round_event/spontaneous_appendicitis /datum/round_event/spontaneous_appendicitis
fakeable = FALSE fakeable = FALSE

View File

@@ -5,6 +5,8 @@
weight = 5 weight = 5
max_occurrences = 4 max_occurrences = 4
earliest_start = 10 MINUTES earliest_start = 10 MINUTES
category = EVENT_CATEGORY_BUREAUCRATIC
description = "A pod containing a random supply crate lands on the station."
///Spawns a cargo pod containing a random cargo supply pack on a random area of the station ///Spawns a cargo pod containing a random cargo supply pack on a random area of the station
/datum/round_event/stray_cargo /datum/round_event/stray_cargo
@@ -20,7 +22,7 @@
* Also randomizes the start timer * Also randomizes the start timer
*/ */
/datum/round_event/stray_cargo/setup() /datum/round_event/stray_cargo/setup()
startWhen = rand(20, 40) start_when = rand(20, 40)
impact_area = find_event_area() impact_area = find_event_area()
if(!impact_area) if(!impact_area)
CRASH("No valid areas for cargo pod found.") CRASH("No valid areas for cargo pod found.")
@@ -89,6 +91,7 @@
weight = 0 weight = 0
max_occurrences = 0 max_occurrences = 0
earliest_start = 30 MINUTES earliest_start = 30 MINUTES
description = "A pod containing syndicate gear lands on the station."
/datum/round_event/stray_cargo/syndicate /datum/round_event/stray_cargo/syndicate
possible_pack_types = list(/datum/supply_pack/misc/syndicate) possible_pack_types = list(/datum/supply_pack/misc/syndicate)

View File

@@ -4,6 +4,8 @@
weight = 20 weight = 20
max_occurrences = 5 max_occurrences = 5
earliest_start = 10 MINUTES earliest_start = 10 MINUTES
category = EVENT_CATEGORY_ENGINEERING
description = "Randomly modifies the supermatter's power, giving the engineers a lot of headaches."
/datum/round_event_control/supermatter_surge/canSpawnEvent() /datum/round_event_control/supermatter_surge/canSpawnEvent()
if(GLOB.main_supermatter_engine?.has_been_powered) if(GLOB.main_supermatter_engine?.has_been_powered)

View File

@@ -4,18 +4,20 @@
weight = 5 weight = 5
max_occurrences = 1 max_occurrences = 1
min_players = 2 min_players = 2
category = EVENT_CATEGORY_SPACE
description = "Several modified radstorms hit the station."
/datum/round_event/supernova /datum/round_event/supernova
announceWhen = 40 announce_when = 40
startWhen = 1 start_when = 1
endWhen = 300 end_when = 300
var/power = 1 var/power = 1
var/datum/sun/supernova var/datum/sun/supernova
var/storm_count = 0 var/storm_count = 0
var/announced = FALSE var/announced = FALSE
/datum/round_event/supernova/setup() /datum/round_event/supernova/setup()
announceWhen = rand(4, 60) announce_when = rand(4, 60)
supernova = new supernova = new
SSsun.suns += supernova SSsun.suns += supernova
switch(rand(1,5)) switch(rand(1,5))
@@ -53,10 +55,10 @@
sucker_light.give_home_power() sucker_light.give_home_power()
/datum/round_event/supernova/tick() /datum/round_event/supernova/tick()
var/midpoint = round((endWhen-startWhen)/2) var/midpoint = round((end_when-start_when)/2)
if(activeFor < midpoint) if(activeFor < midpoint)
supernova.power_mod = min(supernova.power_mod*1.2, power) supernova.power_mod = min(supernova.power_mod*1.2, power)
if(activeFor > endWhen-10) if(activeFor > end_when-10)
supernova.power_mod /= 4 supernova.power_mod /= 4
if(prob(round(supernova.power_mod)) && prob(5-storm_count) && !SSweather.get_weather_by_type(/datum/weather/rad_storm)) if(prob(round(supernova.power_mod)) && prob(5-storm_count) && !SSweather.get_weather_by_type(/datum/weather/rad_storm))
SSweather.run_weather(/datum/weather/rad_storm/supernova) SSweather.run_weather(/datum/weather/rad_storm/supernova)

View File

@@ -4,10 +4,12 @@
weight = 8 weight = 8
max_occurrences = 2 max_occurrences = 2
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
category = EVENT_CATEGORY_FRIENDLY
description = "A mysterious figure requests something to the crew and rewards them with something for getting it done."
/datum/round_event/travelling_trader /datum/round_event/travelling_trader
startWhen = 0 start_when = 0
endWhen = 900 //you effectively have 15 minutes to complete the traders request, before they disappear end_when = 900 //you effectively have 15 minutes to complete the traders request, before they disappear
var/mob/living/carbon/human/dummy/travelling_trader/trader var/mob/living/carbon/human/dummy/travelling_trader/trader
var/atom/spawn_location //where the trader appears var/atom/spawn_location //where the trader appears

View File

@@ -4,6 +4,8 @@
weight = 50 weight = 50
max_occurrences = 10 max_occurrences = 10
alert_observers = FALSE alert_observers = FALSE
category = EVENT_CATEGORY_HEALTH
description = "Unties people's shoes, with a chance to knot them as well."
/datum/round_event/untied_shoes /datum/round_event/untied_shoes
fakeable = FALSE fakeable = FALSE

View File

@@ -3,11 +3,13 @@
typepath = /datum/round_event/vent_clog typepath = /datum/round_event/vent_clog
weight = 10 weight = 10
max_occurrences = 3 max_occurrences = 3
category = EVENT_CATEGORY_HEALTH
description = "All the scrubbers onstation spit random chemicals in smoke form."
/datum/round_event/vent_clog /datum/round_event/vent_clog
announceWhen = 1 announce_when = 1
startWhen = 5 start_when = 5
endWhen = 35 end_when = 35
var/interval = 2 var/interval = 2
var/list/vents = list() var/list/vents = list()
var/randomProbability = 0 var/randomProbability = 0
@@ -62,7 +64,7 @@
priority_announce("The scrubbers network is experiencing a backpressure surge. Some ejection of contents may occur.", "Atmospherics alert", has_important_message = TRUE) priority_announce("The scrubbers network is experiencing a backpressure surge. Some ejection of contents may occur.", "Atmospherics alert", has_important_message = TRUE)
/datum/round_event/vent_clog/setup() /datum/round_event/vent_clog/setup()
endWhen = rand(120, 180) end_when = rand(120, 180)
for(var/obj/machinery/atmospherics/components/unary/vent_scrubber/temp_vent in GLOB.machines) for(var/obj/machinery/atmospherics/components/unary/vent_scrubber/temp_vent in GLOB.machines)
var/turf/T = get_turf(temp_vent) var/turf/T = get_turf(temp_vent)
var/area/A = T.loc var/area/A = T.loc
@@ -108,6 +110,7 @@
min_players = 15 min_players = 15
max_occurrences = 1 max_occurrences = 1
earliest_start = 35 MINUTES earliest_start = 35 MINUTES
description = "Extra dangerous chemicals come out of the scrubbers."
/datum/round_event/vent_clog/threatening /datum/round_event/vent_clog/threatening
randomProbability = 10 randomProbability = 10
@@ -120,6 +123,7 @@
min_players = 25 min_players = 25
max_occurrences = 1 max_occurrences = 1
earliest_start = 45 MINUTES earliest_start = 45 MINUTES
description = "EXTREMELY dangerous chemicals come out of the scrubbers."
/datum/round_event/vent_clog/catastrophic /datum/round_event/vent_clog/catastrophic
randomProbability = 30 randomProbability = 30
@@ -129,6 +133,7 @@
name = "Clogged Vents: Beer" name = "Clogged Vents: Beer"
typepath = /datum/round_event/vent_clog/beer typepath = /datum/round_event/vent_clog/beer
max_occurrences = 0 max_occurrences = 0
description = "Spits out beer through the scrubber system."
/datum/round_event/vent_clog/beer /datum/round_event/vent_clog/beer
reagentsAmount = 100 reagentsAmount = 100
@@ -137,6 +142,7 @@
name = "Anti-Plasma Flood" name = "Anti-Plasma Flood"
typepath = /datum/round_event/vent_clog/plasma_decon typepath = /datum/round_event/vent_clog/plasma_decon
max_occurrences = 0 max_occurrences = 0
description = "Freezing smoke comes out of the scrubbers."
/datum/round_event/vent_clog/beer/announce() /datum/round_event/vent_clog/beer/announce()
priority_announce("The scrubbers network is experiencing an unexpected surge of pressurized beer. Some ejection of contents may occur.", "Atmospherics alert") priority_announce("The scrubbers network is experiencing an unexpected surge of pressurized beer. Some ejection of contents may occur.", "Atmospherics alert")

View File

@@ -3,6 +3,8 @@
typepath = /datum/round_event/wisdomcow typepath = /datum/round_event/wisdomcow
max_occurrences = 1 max_occurrences = 1
weight = 10 weight = 10
category = EVENT_CATEGORY_FRIENDLY
description = "A cow appears to tell you wise words."
/datum/round_event/wisdomcow/announce(fake) /datum/round_event/wisdomcow/announce(fake)
priority_announce("A wise cow has been spotted in the area. Be sure to ask for her advice.", "Nanotrasen Cow Ranching Agency") priority_announce("A wise cow has been spotted in the area. Be sure to ask for her advice.", "Nanotrasen Cow Ranching Agency")

View File

@@ -6,6 +6,7 @@
typepath = /datum/round_event/wizard/robelesscasting typepath = /datum/round_event/wizard/robelesscasting
max_occurrences = 1 max_occurrences = 1
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
description = "Wizard no longer needs robes to cast spells."
/datum/round_event/wizard/robelesscasting/start() /datum/round_event/wizard/robelesscasting/start()
@@ -28,6 +29,7 @@
typepath = /datum/round_event/wizard/improvedcasting typepath = /datum/round_event/wizard/improvedcasting
max_occurrences = 4 //because that'd be max level spells max_occurrences = 4 //because that'd be max level spells
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
description = "Levels up the wizard's spells."
/datum/round_event/wizard/improvedcasting/start() /datum/round_event/wizard/improvedcasting/start()
for(var/i in GLOB.mob_living_list) for(var/i in GLOB.mob_living_list)

View File

@@ -3,6 +3,7 @@
weight = 3 weight = 3
typepath = /datum/round_event/wizard/blobies typepath = /datum/round_event/wizard/blobies
max_occurrences = 3 max_occurrences = 3
description = "Spawns a blob spore on every corpse."
/datum/round_event/wizard/blobies/start() /datum/round_event/wizard/blobies/start()

View File

@@ -5,6 +5,7 @@
max_occurrences = 3 max_occurrences = 3
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
can_be_midround_wizard = FALSE can_be_midround_wizard = FALSE
description = "Gives everyone a cursed item."
//Note about adding items to this: Because of how NODROP_1 works if an item spawned to the hands can also be equiped to a slot //Note about adding items to this: Because of how NODROP_1 works if an item spawned to the hands can also be equiped to a slot
//it will be able to be put into that slot from the hand, but then get stuck there. To avoid this make a new subtype of any //it will be able to be put into that slot from the hand, but then get stuck there. To avoid this make a new subtype of any

View File

@@ -5,6 +5,7 @@
max_occurrences = 1 max_occurrences = 1
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
can_be_midround_wizard = FALSE // not removing it completely yet can_be_midround_wizard = FALSE // not removing it completely yet
description = "A department is turned into an independent state."
/datum/round_event/wizard/deprevolt/start() /datum/round_event/wizard/deprevolt/start()

View File

@@ -4,6 +4,7 @@
typepath = /datum/round_event/wizard/embedpocalypse typepath = /datum/round_event/wizard/embedpocalypse
max_occurrences = 1 max_occurrences = 1
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
description = "Everything becomes pointy enough to embed in people when thrown."
/datum/round_event/wizard/embedpocalypse/start() /datum/round_event/wizard/embedpocalypse/start()
for(var/obj/item/I in world) for(var/obj/item/I in world)
@@ -26,6 +27,7 @@
typepath = /datum/round_event/wizard/embedpocalypse/sticky typepath = /datum/round_event/wizard/embedpocalypse/sticky
max_occurrences = 1 max_occurrences = 1
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
description = "Everything becomes sticky enough to be glued to people when thrown."
/datum/round_event_control/wizard/embedpocalypse/sticky/canSpawnEvent(players_amt, gamemode) /datum/round_event_control/wizard/embedpocalypse/sticky/canSpawnEvent(players_amt, gamemode)
if(GLOB.embedpocalypse) if(GLOB.embedpocalypse)

View File

@@ -4,6 +4,7 @@
typepath = /datum/round_event/wizard/fake_explosion typepath = /datum/round_event/wizard/fake_explosion
max_occurrences = 1 max_occurrences = 1
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
description = "The nuclear explosion cutscene begins to play to scare the crew."
/datum/round_event/wizard/fake_explosion/start() /datum/round_event/wizard/fake_explosion/start()
sound_to_playing_players('sound/machines/alarm.ogg') sound_to_playing_players('sound/machines/alarm.ogg')

View File

@@ -4,6 +4,7 @@
typepath = /datum/round_event/wizard/ghost typepath = /datum/round_event/wizard/ghost
max_occurrences = 1 max_occurrences = 1
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
description = "Ghosts become visible."
/datum/round_event/wizard/ghost/start() /datum/round_event/wizard/ghost/start()
var/msg = "<span class='warning'>You suddenly feel extremely obvious...</span>" var/msg = "<span class='warning'>You suddenly feel extremely obvious...</span>"
@@ -18,6 +19,7 @@
typepath = /datum/round_event/wizard/possession typepath = /datum/round_event/wizard/possession
max_occurrences = 5 max_occurrences = 5
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
description = "Ghosts become visible and gain the power of possession."
/datum/round_event/wizard/possession/start() /datum/round_event/wizard/possession/start()
for(var/mob/dead/observer/G in GLOB.player_list) for(var/mob/dead/observer/G in GLOB.player_list)

View File

@@ -4,6 +4,7 @@
typepath = /datum/round_event/wizard/greentext typepath = /datum/round_event/wizard/greentext
max_occurrences = 1 max_occurrences = 1
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
description = "The Green Text appears on the station, tempting people to try and pick it up."
/datum/round_event/wizard/greentext/start() /datum/round_event/wizard/greentext/start()

View File

@@ -4,6 +4,7 @@
typepath = /datum/round_event/wizard/imposter typepath = /datum/round_event/wizard/imposter
max_occurrences = 1 max_occurrences = 1
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
description = "Spawns a doppelganger of the wizard."
/datum/round_event/wizard/imposter/start() /datum/round_event/wizard/imposter/start()
for(var/datum/mind/M in SSticker.mode.wizards) for(var/datum/mind/M in SSticker.mode.wizards)

View File

@@ -4,6 +4,7 @@
typepath = /datum/round_event/wizard/invincible typepath = /datum/round_event/wizard/invincible
max_occurrences = 5 max_occurrences = 5
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
description = "Everyone is invincible for a short time ticks."
/datum/round_event/wizard/invincible/start() /datum/round_event/wizard/invincible/start()

View File

@@ -4,9 +4,10 @@
typepath = /datum/round_event/wizard/lava typepath = /datum/round_event/wizard/lava
max_occurrences = 3 max_occurrences = 3
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
description = "Turns the floor into hot lava."
/datum/round_event/wizard/lava /datum/round_event/wizard/lava
endWhen = 0 end_when = 0
var/started = FALSE var/started = FALSE
/datum/round_event/wizard/lava/start() /datum/round_event/wizard/lava/start()

View File

@@ -3,6 +3,7 @@
weight = 1 weight = 1
typepath = /datum/round_event/wizard/madness typepath = /datum/round_event/wizard/madness
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
description = "Reveals a horrifying truth to everyone, giving them a trauma."
var/forced_secret var/forced_secret

View File

@@ -4,13 +4,14 @@
typepath = /datum/round_event/wizard/magicarp typepath = /datum/round_event/wizard/magicarp
max_occurrences = 1 max_occurrences = 1
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
description = "Summons a school of carps with magic projectiles."
/datum/round_event/wizard/magicarp /datum/round_event/wizard/magicarp
announceWhen = 3 announce_when = 3
startWhen = 50 start_when = 50
/datum/round_event/wizard/magicarp/setup() /datum/round_event/wizard/magicarp/setup()
startWhen = rand(40, 60) start_when = rand(40, 60)
/datum/round_event/wizard/magicarp/announce(fake) /datum/round_event/wizard/magicarp/announce(fake)
priority_announce("Unknown magical entities have been detected near [station_name()], please stand-by.", "Lifesign Alert") priority_announce("Unknown magical entities have been detected near [station_name()], please stand-by.", "Lifesign Alert")

View File

@@ -5,6 +5,7 @@
max_occurrences = 1 //Exponential growth is nothing to sneeze at! max_occurrences = 1 //Exponential growth is nothing to sneeze at!
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
var/mobs_to_dupe = 0 var/mobs_to_dupe = 0
description = "Rapidly multiplies the animals on the station."
/datum/round_event_control/wizard/petsplosion/preRunEvent() /datum/round_event_control/wizard/petsplosion/preRunEvent()
for(var/mob/living/simple_animal/F in GLOB.alive_mob_list) for(var/mob/living/simple_animal/F in GLOB.alive_mob_list)
@@ -16,7 +17,7 @@
..() ..()
/datum/round_event/wizard/petsplosion /datum/round_event/wizard/petsplosion
endWhen = 61 //1 minute (+1 tick for endWhen not to interfere with tick) end_when = 61 //1 minute (+1 tick for end_when not to interfere with tick)
var/countdown = 0 var/countdown = 0
var/mobs_duped = 0 var/mobs_duped = 0

View File

@@ -5,6 +5,7 @@
max_occurrences = 5 max_occurrences = 5
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
can_be_midround_wizard = FALSE can_be_midround_wizard = FALSE
description = "Gives everyone a random race."
/datum/round_event/wizard/race /datum/round_event/wizard/race
var/list/stored_name var/list/stored_name
@@ -16,7 +17,7 @@
stored_name = list() stored_name = list()
stored_species = list() stored_species = list()
stored_dna = list() stored_dna = list()
endWhen = rand(600,1200) //10 to 20 minutes end_when = rand(600,1200) //10 to 20 minutes
..() ..()
/datum/round_event/wizard/race/start() /datum/round_event/wizard/race/start()

View File

@@ -4,6 +4,7 @@
typepath = /datum/round_event/wizard/rpgloot typepath = /datum/round_event/wizard/rpgloot
max_occurrences = 1 max_occurrences = 1
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
description = "Every item in the world will have fantastical names."
/datum/round_event/wizard/rpgloot/start() /datum/round_event/wizard/rpgloot/start()
var/upgrade_scroll_chance = 0 var/upgrade_scroll_chance = 0

View File

@@ -8,6 +8,7 @@
max_occurrences = 5 max_occurrences = 5
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
can_be_midround_wizard = FALSE // not removing it completely yet can_be_midround_wizard = FALSE // not removing it completely yet
description = "Shuffles everyone around on the station."
/datum/round_event/wizard/shuffleloc/start() /datum/round_event/wizard/shuffleloc/start()
var/list/moblocs = list() var/list/moblocs = list()
@@ -45,6 +46,7 @@
max_occurrences = 5 max_occurrences = 5
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
can_be_midround_wizard = FALSE // not removing it completely yet can_be_midround_wizard = FALSE // not removing it completely yet
description = "Shuffles the names of everyone around the station."
/datum/round_event/wizard/shufflenames/start() /datum/round_event/wizard/shufflenames/start()
var/list/mobnames = list() var/list/mobnames = list()
@@ -80,6 +82,7 @@
max_occurrences = 3 max_occurrences = 3
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
can_be_midround_wizard = FALSE // not removing it completely yet can_be_midround_wizard = FALSE // not removing it completely yet
description = "Shuffles the minds of everyone around the station, except for the wizard."
/datum/round_event/wizard/shuffleminds/start() /datum/round_event/wizard/shuffleminds/start()
var/list/mobs = list() var/list/mobs = list()

View File

@@ -5,6 +5,7 @@
max_occurrences = 1 max_occurrences = 1
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
can_be_midround_wizard = FALSE // not removing it completely yet can_be_midround_wizard = FALSE // not removing it completely yet
description = "Summons a gun for everyone. Might turn people into survivalists."
/datum/round_event_control/wizard/summonguns/New() /datum/round_event_control/wizard/summonguns/New()
if(CONFIG_GET(flag/no_summon_guns)) if(CONFIG_GET(flag/no_summon_guns))
@@ -21,6 +22,7 @@
max_occurrences = 1 max_occurrences = 1
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
can_be_midround_wizard = FALSE // not removing it completely yet can_be_midround_wizard = FALSE // not removing it completely yet
description = "Summons a magic item for everyone. Might turn people into survivalists."
/datum/round_event_control/wizard/summonmagic/New() /datum/round_event_control/wizard/summonmagic/New()
if(CONFIG_GET(flag/no_summon_magic)) if(CONFIG_GET(flag/no_summon_magic))

View File

@@ -4,11 +4,12 @@
max_occurrences = 3 max_occurrences = 3
weight = 2 weight = 2
min_players = 2 min_players = 2
category = EVENT_CATEGORY_SPACE
description = "Space time anomalies appear on the station, randomly teleporting people who walk into them."
/datum/round_event/wormholes /datum/round_event/wormholes
announceWhen = 10 announce_when = 10
endWhen = 60 end_when = 60
var/list/pick_turfs = list() var/list/pick_turfs = list()
var/list/wormholes = list() var/list/wormholes = list()
@@ -16,8 +17,8 @@
var/number_of_wormholes = 400 var/number_of_wormholes = 400
/datum/round_event/wormholes/setup() /datum/round_event/wormholes/setup()
announceWhen = rand(0, 20) announce_when = rand(0, 20)
endWhen = rand(40, 80) end_when = rand(40, 80)
/datum/round_event/wormholes/start() /datum/round_event/wormholes/start()
for(var/turf/open/floor/T in world) for(var/turf/open/floor/T in world)

View File

@@ -5,6 +5,8 @@
weight = -1 weight = -1
max_occurrences = 1 max_occurrences = 1
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
category = EVENT_CATEGORY_HOLIDAY
description = "Hides surprise filled easter eggs in maintenance."
/datum/round_event/easter/announce(fake) /datum/round_event/easter/announce(fake)
priority_announce(pick("Hip-hop into Easter!","Find some Bunny's stash!","Today is National 'Hunt a Wabbit' Day.","Be kind, give Chocolate Eggs!")) priority_announce(pick("Hip-hop into Easter!","Find some Bunny's stash!","Today is National 'Hunt a Wabbit' Day.","Be kind, give Chocolate Eggs!"))
@@ -16,6 +18,8 @@
typepath = /datum/round_event/rabbitrelease typepath = /datum/round_event/rabbitrelease
weight = 5 weight = 5
max_occurrences = 10 max_occurrences = 10
category = EVENT_CATEGORY_HOLIDAY
description = "Summons a wave of cute rabbits."
/datum/round_event/rabbitrelease/announce(fake) /datum/round_event/rabbitrelease/announce(fake)
priority_announce("Unidentified furry objects detected coming aboard [station_name()]. Beware of Adorable-ness.", "Fluffy Alert", "aliens") priority_announce("Unidentified furry objects detected coming aboard [station_name()]. Beware of Adorable-ness.", "Fluffy Alert", "aliens")

View File

@@ -15,6 +15,8 @@
weight = -1 //forces it to be called, regardless of weight weight = -1 //forces it to be called, regardless of weight
max_occurrences = 1 max_occurrences = 1
earliest_start = 0 MINUTES earliest_start = 0 MINUTES
category = EVENT_CATEGORY_HOLIDAY
description = "Spawns Jacq, a friendly mob that gives players a couple fun stuff to do."
/datum/round_event/jacqueen/start() /datum/round_event/jacqueen/start()
..() ..()

View File

@@ -5,8 +5,8 @@
max_occurrences = 2 max_occurrences = 2
earliest_start = 20 MINUTES earliest_start = 20 MINUTES
min_players = 5 min_players = 5
category = EVENT_CATEGORY_ENTITIES
description = "Annoying little creatures go around the station causing havoc and hacking everything."
/datum/round_event/gremlin /datum/round_event/gremlin
var/static/list/acceptable_spawns = list("xeno_spawn", "generic event spawn", "blobstart", "Assistant") var/static/list/acceptable_spawns = list("xeno_spawn", "generic event spawn", "blobstart", "Assistant")

View File

@@ -0,0 +1,17 @@
/*!
* Copyright (c) 2020 Aleksej Komarov
* SPDX-License-Identifier: MIT
*/
/**
* tgui state: fun_state
*
* Checks that the user has the fun privilige.
*/
GLOBAL_DATUM_INIT(fun_state, /datum/ui_state/fun_state, new)
/datum/ui_state/fun_state/can_use_topic(src_object, mob/user)
if(check_rights_for(user.client, R_FUN))
return UI_INTERACTIVE
return UI_CLOSE

Some files were not shown because too many files have changed in this diff Show More