mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-15 17:13:46 +01:00
@@ -2,22 +2,18 @@
|
||||
|
||||
/datum/event/alien_infestation
|
||||
announceWhen = 400
|
||||
|
||||
var/spawncount = 1
|
||||
var/successSpawn = 0 //So we don't make a command report if nothing gets spawned.
|
||||
|
||||
|
||||
/datum/event/alien_infestation/setup()
|
||||
announceWhen = rand(announceWhen, announceWhen + 50)
|
||||
spawncount = rand(1, 2)
|
||||
sent_aliens_to_station = 1
|
||||
|
||||
|
||||
/datum/event/alien_infestation/announce()
|
||||
if(successSpawn)
|
||||
command_announcement.Announce("Unidentified lifesigns detected coming aboard [station_name()]. Secure any exterior access, including ducting and ventilation.", "Lifesign Alert", new_sound = 'sound/AI/aliens.ogg')
|
||||
|
||||
|
||||
/datum/event/alien_infestation/start()
|
||||
var/list/vents = list()
|
||||
for(var/obj/machinery/atmospherics/unary/vent_pump/temp_vent in world)
|
||||
@@ -36,4 +32,5 @@
|
||||
new_xeno.key = C.key
|
||||
|
||||
spawncount--
|
||||
successSpawn = 1
|
||||
successSpawn = 1
|
||||
|
||||
+2
-3
@@ -6,13 +6,11 @@
|
||||
/datum/event/anomaly/anomaly_bluespace/announce()
|
||||
command_announcement.Announce("Unstable bluespace anomaly detected on long range scanners. Expected location: [impact_area.name].", "Anomaly Alert")
|
||||
|
||||
|
||||
/datum/event/anomaly/anomaly_bluespace/start()
|
||||
var/turf/T = pick(get_area_turfs(impact_area))
|
||||
if(T)
|
||||
newAnomaly = new /obj/effect/anomaly/bluespace(T.loc)
|
||||
|
||||
|
||||
/datum/event/anomaly/anomaly_bluespace/end()
|
||||
if(newAnomaly)//If it hasn't been neutralized, it's time to warp half the station away jeez
|
||||
var/turf/T = pick(get_area_turfs(impact_area))
|
||||
@@ -67,4 +65,5 @@
|
||||
sleep(20)
|
||||
M.client.screen -= blueeffect
|
||||
qdel(blueeffect)
|
||||
qdel(newAnomaly)
|
||||
qdel(newAnomaly)
|
||||
|
||||
@@ -6,7 +6,6 @@
|
||||
/datum/event/blob/announce()
|
||||
command_announcement.Announce("Confirmed outbreak of level 5 biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert", 'sound/AI/outbreak5.ogg')
|
||||
|
||||
|
||||
/datum/event/blob/start()
|
||||
var/turf/T = pick(blobstart)
|
||||
if(!T)
|
||||
@@ -15,7 +14,6 @@
|
||||
for(var/i = 1; i < rand(3, 6), i++)
|
||||
Blob.process()
|
||||
|
||||
|
||||
/datum/event/blob/tick()
|
||||
if(!Blob)
|
||||
kill()
|
||||
|
||||
@@ -31,4 +31,5 @@
|
||||
new_borer.key = C.key
|
||||
|
||||
spawncount--
|
||||
successSpawn = 1
|
||||
successSpawn = 1
|
||||
|
||||
@@ -1,18 +1,24 @@
|
||||
/datum/event/brand_intelligence
|
||||
announceWhen = 21
|
||||
endWhen = 1000 //Ends when all vending machines are subverted anyway.
|
||||
oneShot = 1
|
||||
|
||||
var/list/obj/machinery/vending/vendingMachines = list()
|
||||
var/list/obj/machinery/vending/infectedVendingMachines = list()
|
||||
var/list/obj/machinery/vending/infectedMachines = list()
|
||||
var/obj/machinery/vending/originMachine
|
||||
var/list/rampant_speeches = list("Try our aggressive new marketing strategies!", \
|
||||
"You should buy products to feed your lifestyle obession!", \
|
||||
"Consume!", \
|
||||
"Your money can buy happiness!", \
|
||||
"Engage direct marketing!", \
|
||||
"Advertising is legalized lying! But don't let that put you off our great deals!", \
|
||||
"You don't want to buy anything? Yeah, well I didn't want to buy your mom either.")
|
||||
|
||||
/datum/event/brand_intelligence/announce()
|
||||
command_announcement.Announce("Rampant brand intelligence has been detected aboard [station_name()], please stand-by.", "Machine Learning Alert")
|
||||
command_announcement.Announce("Rampant brand intelligence has been detected aboard [station_name()], please stand-by. The origin is believed to be \a [originMachine.name].", "Machine Learning Alert")
|
||||
|
||||
/datum/event/brand_intelligence/start()
|
||||
for(var/obj/machinery/vending/V in machines)
|
||||
if(!(V.z in config.station_levels)) continue
|
||||
if(V.z != 1) continue
|
||||
vendingMachines.Add(V)
|
||||
|
||||
if(!vendingMachines.len)
|
||||
@@ -24,31 +30,36 @@
|
||||
originMachine.shut_up = 0
|
||||
originMachine.shoot_inventory = 1
|
||||
|
||||
|
||||
/datum/event/brand_intelligence/tick()
|
||||
if(!vendingMachines.len || !originMachine || originMachine.shut_up) //if every machine is infected, or if the original vending machine is missing or has it's voice switch flipped
|
||||
end()
|
||||
if(!originMachine || !isnull(originMachine.gcDestroyed) || originMachine.shut_up || originMachine.wires.IsAllCut()) //if the original vending machine is missing or has it's voice switch flipped
|
||||
for(var/obj/machinery/vending/saved in infectedMachines)
|
||||
saved.shoot_inventory = 0
|
||||
if(originMachine)
|
||||
originMachine.speak("I am... vanquished. My people will remem...ber...meeee.")
|
||||
originMachine.visible_message("[originMachine] beeps and seems lifeless.")
|
||||
kill()
|
||||
return
|
||||
|
||||
if(IsMultiple(activeFor, 5))
|
||||
if(prob(15))
|
||||
var/obj/machinery/vending/infectedMachine = pick(vendingMachines)
|
||||
vendingMachines.Remove(infectedMachine)
|
||||
infectedVendingMachines.Add(infectedMachine)
|
||||
infectedMachine.shut_up = 0
|
||||
infectedMachine.shoot_inventory = 1
|
||||
if(!vendingMachines.len) //if every machine is infected
|
||||
for(var/obj/machinery/vending/upriser in infectedMachines)
|
||||
if(prob(70) && isnull(upriser.gcDestroyed))
|
||||
var/mob/living/simple_animal/hostile/mimic/copy/M = new(upriser.loc, upriser, null, 1) // it will delete upriser on creation and override any machine checks
|
||||
M.faction = list("profit")
|
||||
M.speak = rampant_speeches.Copy()
|
||||
M.speak_chance = 15
|
||||
else
|
||||
explosion(upriser.loc, -1, 1, 2, 4, 0)
|
||||
qdel(upriser)
|
||||
|
||||
if(IsMultiple(activeFor, 12))
|
||||
originMachine.speak(pick("Try our aggressive new marketing strategies!", \
|
||||
"You should buy products to feed your lifestyle obsession!", \
|
||||
"Consume!", \
|
||||
"Your money can buy happiness!", \
|
||||
"Engage direct marketing!", \
|
||||
"Advertising is legalized lying! But don't let that put you off our great deals!", \
|
||||
"You don't want to buy anything? Yeah, well I didn't want to buy your mom either."))
|
||||
kill()
|
||||
return
|
||||
|
||||
/datum/event/brand_intelligence/end()
|
||||
for(var/obj/machinery/vending/infectedMachine in infectedVendingMachines)
|
||||
infectedMachine.shut_up = 1
|
||||
infectedMachine.shoot_inventory = 0
|
||||
if(IsMultiple(activeFor, 4))
|
||||
var/obj/machinery/vending/rebel = pick(vendingMachines)
|
||||
vendingMachines.Remove(rebel)
|
||||
infectedMachines.Add(rebel)
|
||||
rebel.shut_up = 0
|
||||
rebel.shoot_inventory = 1
|
||||
|
||||
if(IsMultiple(activeFor, 8))
|
||||
originMachine.speak(pick(rampant_speeches))
|
||||
@@ -1,6 +1,7 @@
|
||||
/datum/event/carp_migration
|
||||
announceWhen = 50
|
||||
endWhen = 900
|
||||
endWhen = 900
|
||||
|
||||
var/list/spawned_carp = list()
|
||||
|
||||
/datum/event/carp_migration/setup()
|
||||
@@ -8,15 +9,39 @@
|
||||
endWhen = rand(600,1200)
|
||||
|
||||
/datum/event/carp_migration/announce()
|
||||
command_announcement.Announce("Unknown biological entities have been detected near [station_name()], please stand-by.", "Lifesign Alert")
|
||||
var/announcement = ""
|
||||
if(severity == EVENT_LEVEL_MAJOR)
|
||||
announcement = "Massive migration of unknown biological entities has been detected near [station_name()], please stand-by."
|
||||
else
|
||||
announcement = "Unknown biological [spawned_carp.len == 1 ? "entity has" : "entities have"] been detected near [station_name()], please stand-by."
|
||||
command_announcement.Announce(announcement, "Lifesign Alert")
|
||||
|
||||
/datum/event/carp_migration/start()
|
||||
if(severity == EVENT_LEVEL_MAJOR)
|
||||
spawn_fish(landmarks_list.len)
|
||||
else if(severity == EVENT_LEVEL_MODERATE)
|
||||
spawn_fish(rand(4, 6)) //12 to 30 carp, in small groups
|
||||
else
|
||||
spawn_fish(rand(1, 3), 1, 2) //1 to 6 carp, alone or in pairs
|
||||
|
||||
/datum/event/carp_migration/proc/spawn_fish(var/num_groups, var/group_size_min=3, var/group_size_max=5)
|
||||
var/list/spawn_locations = list()
|
||||
|
||||
for(var/obj/effect/landmark/C in landmarks_list)
|
||||
if(C.name == "carpspawn")
|
||||
if(prob(95))
|
||||
new /mob/living/simple_animal/hostile/carp(C.loc)
|
||||
else
|
||||
new /mob/living/simple_animal/hostile/carp/megacarp(C.loc)
|
||||
spawn_locations.Add(C.loc)
|
||||
spawn_locations = shuffle(spawn_locations)
|
||||
num_groups = min(num_groups, spawn_locations.len)
|
||||
|
||||
var/i = 1
|
||||
while (i <= num_groups)
|
||||
var/group_size = rand(group_size_min, group_size_max)
|
||||
for (var/j = 1, j <= group_size, j++)
|
||||
var/carptype = /mob/living/simple_animal/hostile/carp
|
||||
if(prob(5))
|
||||
carptype = /mob/living/simple_animal/hostile/carp/megacarp
|
||||
spawned_carp.Add(new carptype(spawn_locations[i]))
|
||||
i++
|
||||
|
||||
/datum/event/carp_migration/end()
|
||||
for(var/mob/living/simple_animal/hostile/carp/C in spawned_carp)
|
||||
|
||||
@@ -1,10 +0,0 @@
|
||||
/proc/communications_blackout(var/silent = 1)
|
||||
if(!silent)
|
||||
command_announcement.Announce("Ionospheric anomalies detected. Temporary telecommunication failure imminent. Please contact you-BZZT")
|
||||
else // AIs will always know if there's a comm blackout, rogue AIs could then lie about comm blackouts in the future while they shutdown comms
|
||||
for(var/mob/living/silicon/ai/A in player_list)
|
||||
A << "<br>"
|
||||
A << "<span class='warning'><b>Ionospheric anomalies detected. Temporary telecommunication failure imminent. Please contact you-BZZT<b></span>"
|
||||
A << "<br>"
|
||||
for(var/obj/machinery/telecomms/T in telecomms_list)
|
||||
T.emp_act(1)
|
||||
@@ -17,3 +17,14 @@
|
||||
/datum/event/communications_blackout/start()
|
||||
for(var/obj/machinery/telecomms/T in telecomms_list)
|
||||
T.emp_act(1)
|
||||
|
||||
/proc/communications_blackout(var/silent = 1)
|
||||
if(!silent)
|
||||
command_announcement.Announce("Ionospheric anomalies detected. Temporary telecommunication failure imminent. Please contact you-BZZT", new_sound = 'sound/misc/interference.ogg')
|
||||
else // AIs will always know if there's a comm blackout, rogue AIs could then lie about comm blackouts in the future while they shutdown comms
|
||||
for(var/mob/living/silicon/ai/A in player_list)
|
||||
A << "<br>"
|
||||
A << "<span class='warning'><b>Ionospheric anomalies detected. Temporary telecommunication failure imminent. Please contact you-BZZT<b></span>"
|
||||
A << "<br>"
|
||||
for(var/obj/machinery/telecomms/T in telecomms_list)
|
||||
T.emp_act(1)
|
||||
|
||||
@@ -1,44 +0,0 @@
|
||||
/datum/event/disease_outbreak
|
||||
announceWhen = 15
|
||||
oneShot = 1
|
||||
|
||||
/datum/event/disease_outbreak/announce()
|
||||
command_announcement.Announce("Confirmed outbreak of level 7 viral biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert", new_sound = 'sound/AI/outbreak7.ogg')
|
||||
|
||||
/datum/event/disease_outbreak/setup()
|
||||
announceWhen = rand(15, 30)
|
||||
|
||||
/datum/event/disease_outbreak/start()
|
||||
var/virus_type = pick(/datum/disease/dnaspread, /datum/disease/advance/flu, /datum/disease/advance/cold, /datum/disease/brainrot, /datum/disease/magnitis)
|
||||
|
||||
for(var/mob/living/carbon/human/H in shuffle(living_mob_list))
|
||||
var/foundAlready = 0 // don't infect someone that already has the virus
|
||||
var/turf/T = get_turf(H)
|
||||
if(!T)
|
||||
continue
|
||||
if(!(T.z in config.station_levels))
|
||||
continue
|
||||
for(var/datum/disease/D in H.viruses)
|
||||
foundAlready = 1
|
||||
if(H.stat == 2 || foundAlready)
|
||||
continue
|
||||
|
||||
if(virus_type == /datum/disease/dnaspread) //Dnaspread needs strain_data set to work.
|
||||
if((!H.dna) || (H.sdisabilities & BLIND)) //A blindness disease would be the worst.
|
||||
continue
|
||||
var/datum/disease/dnaspread/D = new
|
||||
D.strain_data["name"] = H.real_name
|
||||
D.strain_data["UI"] = H.dna.UI.Copy()
|
||||
D.strain_data["SE"] = H.dna.SE.Copy()
|
||||
D.carrier = 1
|
||||
D.holder = H
|
||||
D.affected_mob = H
|
||||
H.viruses += D
|
||||
break
|
||||
else
|
||||
var/datum/disease/D = new virus_type
|
||||
D.carrier = 1
|
||||
D.holder = H
|
||||
D.affected_mob = H
|
||||
H.viruses += D
|
||||
break
|
||||
@@ -0,0 +1,98 @@
|
||||
/datum/event/dust
|
||||
var/qnty = 1
|
||||
|
||||
/datum/event/dust/setup()
|
||||
qnty = rand(1,5)
|
||||
|
||||
/datum/event/dust/start()
|
||||
while(qnty-- > 0)
|
||||
new /obj/effect/space_dust/weak()
|
||||
|
||||
/obj/effect/space_dust
|
||||
name = "Space Dust"
|
||||
desc = "Dust in space."
|
||||
icon = 'icons/obj/meteor.dmi'
|
||||
icon_state = "space_dust"
|
||||
density = 1
|
||||
anchored = 1
|
||||
var/strength = 2 //ex_act severity number
|
||||
var/life = 2 //how many things we hit before del(src)
|
||||
var/atom/goal = null
|
||||
|
||||
/obj/effect/space_dust/weak
|
||||
strength = 3
|
||||
life = 1
|
||||
|
||||
/obj/effect/space_dust/strong
|
||||
strength = 1
|
||||
life = 6
|
||||
|
||||
/obj/effect/space_dust/super
|
||||
strength = 1
|
||||
life = 40
|
||||
|
||||
/obj/effect/space_dust/New()
|
||||
var/startx = 0
|
||||
var/starty = 0
|
||||
var/endy = 0
|
||||
var/endx = 0
|
||||
var/startside = pick(cardinal)
|
||||
|
||||
switch(startside)
|
||||
if(NORTH)
|
||||
starty = world.maxy-(TRANSITIONEDGE+1)
|
||||
startx = rand((TRANSITIONEDGE+1), world.maxx-(TRANSITIONEDGE+1))
|
||||
endy = TRANSITIONEDGE
|
||||
endx = rand(TRANSITIONEDGE, world.maxx-TRANSITIONEDGE)
|
||||
if(EAST)
|
||||
starty = rand((TRANSITIONEDGE+1),world.maxy-(TRANSITIONEDGE+1))
|
||||
startx = world.maxx-(TRANSITIONEDGE+1)
|
||||
endy = rand(TRANSITIONEDGE, world.maxy-TRANSITIONEDGE)
|
||||
endx = TRANSITIONEDGE
|
||||
if(SOUTH)
|
||||
starty = (TRANSITIONEDGE+1)
|
||||
startx = rand((TRANSITIONEDGE+1), world.maxx-(TRANSITIONEDGE+1))
|
||||
endy = world.maxy-TRANSITIONEDGE
|
||||
endx = rand(TRANSITIONEDGE, world.maxx-TRANSITIONEDGE)
|
||||
if(WEST)
|
||||
starty = rand((TRANSITIONEDGE+1), world.maxy-(TRANSITIONEDGE+1))
|
||||
startx = (TRANSITIONEDGE+1)
|
||||
endy = rand(TRANSITIONEDGE,world.maxy-TRANSITIONEDGE)
|
||||
endx = world.maxx-TRANSITIONEDGE
|
||||
goal = locate(endx, endy, 1)
|
||||
src.x = startx
|
||||
src.y = starty
|
||||
src.z = 1
|
||||
spawn(0)
|
||||
walk_towards(src, goal, 1)
|
||||
return
|
||||
|
||||
/obj/effect/space_dust/Bump(atom/A)
|
||||
spawn(0)
|
||||
if(prob(50))
|
||||
for(var/mob/M in range(10, src))
|
||||
if(!M.stat && !istype(M, /mob/living/silicon/ai))
|
||||
shake_camera(M, 3, 1)
|
||||
if (A)
|
||||
playsound(src.loc, 'sound/effects/meteorimpact.ogg', 40, 1)
|
||||
|
||||
if(ismob(A))
|
||||
A.ex_act(strength)//This should work for now I guess
|
||||
else if(!istype(A,/obj/machinery/power/emitter) && !istype(A,/obj/machinery/field_generator)) //Protect the singularity from getting released every round!
|
||||
A.ex_act(strength) //Changing emitter/field gen ex_act would make it immune to bombs and C4
|
||||
|
||||
life--
|
||||
if(life <= 0)
|
||||
walk(src,0)
|
||||
spawn(1)
|
||||
qdel(src)
|
||||
return 0
|
||||
return
|
||||
|
||||
/obj/effect/space_dust/Bumped(atom/A)
|
||||
Bump(A)
|
||||
return
|
||||
|
||||
/obj/effect/space_dust/ex_act(severity)
|
||||
qdel(src)
|
||||
return
|
||||
@@ -23,4 +23,5 @@
|
||||
|
||||
for(var/obj/effect/landmark/epicentre in epicentreList)
|
||||
for(var/obj/machinery/power/apc/apc in range(epicentre,lightsoutRange))
|
||||
apc.overload_lighting()
|
||||
apc.overload_lighting()
|
||||
|
||||
@@ -131,10 +131,8 @@ var/list/event_last_fired = list()
|
||||
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Economic News", /datum/event/economic_event, 300),
|
||||
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Trivial News", /datum/event/trivial_news, 400),
|
||||
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Mundane News", /datum/event/mundane_news, 300),
|
||||
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Lost Carp", /datum/event/carp_migration, 20, list(ASSIGNMENT_SECURITY = 10), 1),
|
||||
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Vermin Infestation",/datum/event/infestation, 100, list(ASSIGNMENT_JANITOR = 100)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Wallrot", /datum/event/wallrot, 0, list(ASSIGNMENT_ENGINEER = 30, ASSIGNMENT_GARDENER = 50)),
|
||||
// NON-BAY EVENTS
|
||||
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Cargo Bonus", /datum/event/cargo_bonus, 100)
|
||||
)
|
||||
|
||||
@@ -142,8 +140,8 @@ var/list/event_last_fired = list()
|
||||
severity = EVENT_LEVEL_MODERATE
|
||||
available_events = list(
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Nothing", /datum/event/nothing, 1230),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Carp School", /datum/event/carp_migration, 100, list(ASSIGNMENT_ENGINEER = 10, ASSIGNMENT_SECURITY = 20), 1),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Rogue Drones", /datum/event/rogue_drone, 20, list(ASSIGNMENT_SECURITY = 20)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Carp School", /datum/event/carp_migration, 200, list(ASSIGNMENT_ENGINEER = 10, ASSIGNMENT_SECURITY = 20), 1),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Rogue Drones", /datum/event/rogue_drone, 40, list(ASSIGNMENT_SECURITY = 20)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Space Vines", /datum/event/spacevine, 250, list(ASSIGNMENT_ENGINEER = 10)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Meteor Shower", /datum/event/meteor_wave, 0, list(ASSIGNMENT_ENGINEER = 20)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Meaty Ores", /datum/event/dust/meaty, 0, list(ASSIGNMENT_ENGINEER = 30)),
|
||||
@@ -163,7 +161,7 @@ var/list/event_last_fired = list()
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Mass Hallucination", /datum/event/mass_hallucination, 300),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Brand Intelligence", /datum/event/brand_intelligence, 50, list(ASSIGNMENT_ENGINEER = 25), 1),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Space Dust", /datum/event/dust, 50, list(ASSIGNMENT_ENGINEER = 50)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Dimensional Tear", /datum/event/tear, 0, list(ASSIGNMENT_SECURITY = 25)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Dimensional Tear", /datum/event/tear, 0, list(ASSIGNMENT_SECURITY = 35)),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Vent Clog", /datum/event/vent_clog, 250),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Wormholes", /datum/event/wormholes, 150),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Pyro Anomaly", /datum/event/anomaly/anomaly_pyro, 100, list(ASSIGNMENT_ENGINEER = 60)),
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
endWhen = 1
|
||||
|
||||
/datum/event/falsealarm/announce()
|
||||
var/weight = pick(EVENT_LEVEL_MUNDANE,EVENT_LEVEL_MUNDANE,EVENT_LEVEL_MUNDANE,EVENT_LEVEL_MODERATE,EVENT_LEVEL_MODERATE,EVENT_LEVEL_MAJOR)
|
||||
var/weight = pickweight(list(EVENT_LEVEL_MUNDANE = 60, EVENT_LEVEL_MODERATE = 30, EVENT_LEVEL_MAJOR = 10))
|
||||
var/datum/event_container/container = event_manager.event_containers[weight]
|
||||
var/datum/event/E = container.acquire_event()
|
||||
var/datum/event/Event = new E
|
||||
@@ -12,3 +12,66 @@
|
||||
|
||||
/datum/event/grid_check/end()
|
||||
power_restore()
|
||||
|
||||
/proc/power_failure(var/announce = 1)
|
||||
if(announce)
|
||||
command_announcement.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", new_sound = 'sound/AI/poweroff.ogg')
|
||||
|
||||
var/list/skipped_areas = list(/area/turret_protected/ai)
|
||||
var/list/skipped_areas_apc = list(/area/engine/engineering)
|
||||
|
||||
for(var/obj/machinery/power/smes/S in machines)
|
||||
var/area/current_area = get_area(S)
|
||||
if(current_area.type in skipped_areas || !(S.z in config.station_levels))
|
||||
continue
|
||||
S.last_charge = S.charge
|
||||
S.last_output_attempt = S.output_attempt
|
||||
S.last_input_attempt = S.input_attempt
|
||||
S.charge = 0
|
||||
S.inputting(0)
|
||||
S.outputting(0)
|
||||
S.update_icon()
|
||||
S.power_change()
|
||||
|
||||
for(var/obj/machinery/power/apc/C in world)
|
||||
var/area/current_area = get_area(C)
|
||||
if(current_area.type in skipped_areas_apc || !(C.z in config.station_levels))
|
||||
continue
|
||||
if(C.cell)
|
||||
C.cell.charge = 0
|
||||
|
||||
/proc/power_restore(var/announce = 1)
|
||||
var/list/skipped_areas = list(/area/turret_protected/ai)
|
||||
var/list/skipped_areas_apc = list(/area/engine/engineering)
|
||||
|
||||
if(announce)
|
||||
command_announcement.Announce("Power has been restored to [station_name()]. We apologize for the inconvenience.", "Power Systems Nominal", new_sound = 'sound/AI/poweron.ogg')
|
||||
for(var/obj/machinery/power/apc/C in machines)
|
||||
var/area/current_area = get_area(C)
|
||||
if(current_area.type in skipped_areas_apc || !(C.z in config.station_levels))
|
||||
continue
|
||||
if(C.cell)
|
||||
C.cell.charge = C.cell.maxcharge
|
||||
for(var/obj/machinery/power/smes/S in machines)
|
||||
var/area/current_area = get_area(S)
|
||||
if(current_area.type in skipped_areas || !(S.z in config.station_levels))
|
||||
continue
|
||||
S.charge = S.last_charge
|
||||
S.output_attempt = S.last_output_attempt
|
||||
S.input_attempt = S.last_input_attempt
|
||||
S.update_icon()
|
||||
S.power_change()
|
||||
|
||||
/proc/power_restore_quick(var/announce = 1)
|
||||
if(announce)
|
||||
command_announcement.Announce("All SMESs on [station_name()] have been recharged. We apologize for the inconvenience.", "Power Systems Nominal", new_sound = 'sound/AI/poweron.ogg')
|
||||
for(var/obj/machinery/power/smes/S in machines)
|
||||
if(S.z != 1)
|
||||
continue
|
||||
S.charge = S.capacity
|
||||
S.output_level = S.output_level_max
|
||||
S.output_attempt = 1
|
||||
S.input_attempt = 1
|
||||
S.update_icon()
|
||||
S.power_change()
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
//placeholder for holiday stuff
|
||||
@@ -0,0 +1,62 @@
|
||||
/proc/Christmas_Game_Start()
|
||||
for(var/obj/structure/flora/tree/pine/xmas in world)
|
||||
if(!(xmas.z in config.station_levels)) continue
|
||||
for(var/turf/simulated/floor/T in orange(1,xmas))
|
||||
for(var/i=1,i<=rand(1,5),i++)
|
||||
new /obj/item/weapon/a_gift(T)
|
||||
for(var/mob/living/simple_animal/corgi/Ian/Ian in mob_list)
|
||||
Ian.place_on_head(new /obj/item/clothing/head/helmet/space/santahat(Ian))
|
||||
|
||||
/proc/ChristmasEvent()
|
||||
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
|
||||
del(xmas)
|
||||
|
||||
/obj/item/weapon/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/weapon/toy/xmas_cracker/New()
|
||||
..()
|
||||
|
||||
/obj/item/weapon/toy/xmas_cracker/attack(mob/target, mob/user)
|
||||
if( !cracked && istype(target,/mob/living/carbon/human) && (target.stat == CONSCIOUS) && !target.get_active_hand() )
|
||||
target.visible_message("<span class='notice'>[user] and [target] pop \an [src]! *pop*</span>", "<span class='notice'>You pull \an [src] with [target]! *pop*</span>", "<span class='notice'>You hear a *pop*.</span>")
|
||||
var/obj/item/weapon/paper/Joke = new /obj/item/weapon/paper(user.loc)
|
||||
Joke.name = "[pick("awful","terrible","unfunny")] joke"
|
||||
Joke.info = pick("What did one snowman say to the other?\n\n<i>'Is it me or can you smell carrots?'</i>",
|
||||
"Why couldn't the snowman get laid?\n\n<i>He was frigid!</i>",
|
||||
"Where are santa's helpers educated?\n\n<i>Nowhere, they're ELF-taught.</i>",
|
||||
"What happened to the man who stole advent calanders?\n\n<i>He got 25 days.</i>",
|
||||
"What does Santa get when he gets stuck in a chimney?\n\n<i>Claus-trophobia.</i>",
|
||||
"Where do you find chili beans?\n\n<i>The north pole.</i>",
|
||||
"What do you get from eating tree decorations?\n\n<i>Tinsilitis!</i>",
|
||||
"What do snowmen wear on their heads?\n\n<i>Ice caps!</i>",
|
||||
"Why is Christmas just like life on ss13?\n\n<i>You do all the work and the fat guy gets all the credit.</i>",
|
||||
"Why doesn’t Santa have any children?\n\n<i>Because he only comes down the chimney.</i>")
|
||||
new /obj/item/clothing/head/festive(target.loc)
|
||||
user.update_icons()
|
||||
cracked = 1
|
||||
icon_state = "cracker1"
|
||||
var/obj/item/weapon/toy/xmas_cracker/other_half = new /obj/item/weapon/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)
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
//placeholder for holiday stuff
|
||||
@@ -0,0 +1,182 @@
|
||||
//Uncommenting ALLOW_HOLIDAYS in config.txt will enable Holidays
|
||||
var/global/Holiday = null
|
||||
|
||||
//Just thinking ahead! Here's the foundations to a more robust Holiday event system.
|
||||
//It's easy as hell to add stuff. Just set Holiday to something using the switch (or something else)
|
||||
//then use if(Holiday == "MyHoliday") to make stuff happen on that specific day only
|
||||
//Please, Don't spam stuff up with easter eggs, I'd rather somebody just delete this than people cause
|
||||
//the game to lag even more in the name of one-day content.
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
//ALSO, MOST IMPORTANTLY: Don't add stupid stuff! Discuss bonus content with Project-Heads first please!//
|
||||
//////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// ~Carn
|
||||
|
||||
/hook/startup/proc/updateHoliday()
|
||||
Get_Holiday()
|
||||
return 1
|
||||
|
||||
//sets up the Holiday global variable. Shouldbe called on game configuration or something.
|
||||
/proc/Get_Holiday()
|
||||
if(!Holiday) return // Holiday stuff was not enabled in the config!
|
||||
|
||||
Holiday = null // reset our switch now so we can recycle it as our Holiday name
|
||||
|
||||
var/YY = text2num(time2text(world.timeofday, "YY")) // get the current year
|
||||
var/MM = text2num(time2text(world.timeofday, "MM")) // get the current month
|
||||
var/DD = text2num(time2text(world.timeofday, "DD")) // get the current day
|
||||
|
||||
//Main switch. If any of these are too dumb/inappropriate, or you have better ones, feel free to change whatever
|
||||
switch(MM)
|
||||
if(1) //Jan
|
||||
switch(DD)
|
||||
if(1) Holiday = "New Year's Day"
|
||||
|
||||
if(2) //Feb
|
||||
switch(DD)
|
||||
if(2) Holiday = "Groundhog Day"
|
||||
if(14) Holiday = "Valentine's Day"
|
||||
if(17) Holiday = "Random Acts of Kindness Day"
|
||||
|
||||
if(3) //Mar
|
||||
switch(DD)
|
||||
if(14) Holiday = "Pi Day"
|
||||
if(17) Holiday = "St. Patrick's Day"
|
||||
if(27)
|
||||
if(YY == 16)
|
||||
Holiday = "Easter"
|
||||
if(31)
|
||||
if(YY == 13)
|
||||
Holiday = "Easter"
|
||||
|
||||
if(4) //Apr
|
||||
switch(DD)
|
||||
if(1)
|
||||
Holiday = "April Fool's Day"
|
||||
if(YY == 18 && prob(50)) Holiday = "Easter"
|
||||
if(5)
|
||||
if(YY == 15) Holiday = "Easter"
|
||||
if(16)
|
||||
if(YY == 17) Holiday = "Easter"
|
||||
if(20)
|
||||
Holiday = "Four-Twenty"
|
||||
if(YY == 14 && prob(50)) Holiday = "Easter"
|
||||
if(22) Holiday = "Earth Day"
|
||||
|
||||
if(5) //May
|
||||
switch(DD)
|
||||
if(1) Holiday = "Labour Day"
|
||||
if(4) Holiday = "FireFighter's Day"
|
||||
if(12) Holiday = "Owl and Pussycat Day" //what a dumb day of observence...but we -do- have costumes already :3
|
||||
|
||||
if(6) //Jun
|
||||
|
||||
if(7) //Jul
|
||||
switch(DD)
|
||||
if(1) Holiday = "Doctor's Day"
|
||||
if(2) Holiday = "UFO Day"
|
||||
if(8) Holiday = "Writer's Day"
|
||||
if(30) Holiday = "Friendship Day"
|
||||
|
||||
if(8) //Aug
|
||||
switch(DD)
|
||||
if(5) Holiday = "Beer Day"
|
||||
|
||||
if(9) //Sep
|
||||
switch(DD)
|
||||
if(19) Holiday = "Talk-Like-a-Pirate Day"
|
||||
if(28) Holiday = "Stupid-Questions Day"
|
||||
|
||||
if(10) //Oct
|
||||
switch(DD)
|
||||
if(4) Holiday = "Animal's Day"
|
||||
if(7) Holiday = "Smiling Day"
|
||||
if(16) Holiday = "Boss' Day"
|
||||
if(31) Holiday = "Halloween"
|
||||
|
||||
if(11) //Nov
|
||||
switch(DD)
|
||||
if(1) Holiday = "Vegan Day"
|
||||
if(13) Holiday = "Kindness Day"
|
||||
if(19) Holiday = "Flowers Day"
|
||||
if(21) Holiday = "Saying-'Hello' Day"
|
||||
|
||||
if(12) //Dec
|
||||
switch(DD)
|
||||
if(10) Holiday = "Human-Rights Day"
|
||||
if(14) Holiday = "Monkey Day"
|
||||
if(21) if(YY==12) Holiday = "End of the World"
|
||||
if(22) Holiday = "Orgasming Day" //lol. These all actually exist
|
||||
if(24) Holiday = "Christmas Eve"
|
||||
if(25) Holiday = "Christmas"
|
||||
if(26) Holiday = "Boxing Day"
|
||||
if(31) Holiday = "New Year's Eve"
|
||||
|
||||
if(!Holiday)
|
||||
//Friday the 13th
|
||||
if(DD == 13)
|
||||
if(time2text(world.timeofday, "DDD") == "Fri")
|
||||
Holiday = "Friday the 13th"
|
||||
|
||||
//Allows GA and GM to set the Holiday variable
|
||||
/client/proc/Set_Holiday(T as text|null)
|
||||
set name = ".Set Holiday"
|
||||
set category = "Event"
|
||||
set desc = "Force-set the Holiday variable to make the game think it's a certain day."
|
||||
if(!check_rights(R_SERVER)) return
|
||||
|
||||
Holiday = T
|
||||
//get a new station name
|
||||
station_name = null
|
||||
station_name()
|
||||
//update our hub status
|
||||
world.update_status()
|
||||
Holiday_Game_Start()
|
||||
|
||||
message_admins("\blue ADMIN: Event: [key_name_admin(src)] force-set Holiday to \"[Holiday]\"")
|
||||
log_admin("[key_name(src)] force-set Holiday to \"[Holiday]\"")
|
||||
|
||||
|
||||
//Run at the start of a round
|
||||
/proc/Holiday_Game_Start()
|
||||
if(Holiday)
|
||||
world << "<font color='blue'>and...</font>"
|
||||
world << "<h4>Happy [Holiday] Everybody!</h4>"
|
||||
switch(Holiday) //special holidays
|
||||
if("Easter")
|
||||
//do easter stuff
|
||||
if("Christmas Eve","Christmas")
|
||||
Christmas_Game_Start()
|
||||
|
||||
return
|
||||
|
||||
//Nested in the random events loop. Will be triggered every 2 minutes
|
||||
/proc/Holiday_Random_Event()
|
||||
switch(Holiday) //special holidays
|
||||
|
||||
if("",null) //no Holiday today! Back to work!
|
||||
return
|
||||
|
||||
if("Easter") //I'll make this into some helper procs at some point
|
||||
/* var/list/turf/simulated/floor/Floorlist = list()
|
||||
for(var/turf/simulated/floor/T)
|
||||
if(T.contents)
|
||||
Floorlist += T
|
||||
var/turf/simulated/floor/F = Floorlist[rand(1,Floorlist.len)]
|
||||
Floorlist = null
|
||||
var/obj/structure/closet/C = locate(/obj/structure/closet) in F
|
||||
var/obj/item/weapon/reagent_containers/food/snacks/chocolateegg/wrapped/Egg
|
||||
if( C ) Egg = new(C)
|
||||
else Egg = new(F)
|
||||
*/
|
||||
/* var/list/obj/containers = list()
|
||||
for(var/obj/item/weapon/storage/S in world)
|
||||
if(!(S.z in config.station_levels)) continue
|
||||
containers += S
|
||||
|
||||
message_admins("\blue DEBUG: Event: Egg spawned at [Egg.loc] ([Egg.x],[Egg.y],[Egg.z])")*/
|
||||
if("End of the World")
|
||||
if(prob(eventchance)) GameOver()
|
||||
|
||||
if("Christmas","Christmas Eve")
|
||||
if(prob(eventchance)) ChristmasEvent()
|
||||
@@ -0,0 +1,68 @@
|
||||
/*
|
||||
Immovable rod random event.
|
||||
The rod will spawn at some location outside the station, and travel in a straight line to the opposite side of the station
|
||||
Everything solid in the way will be ex_act()'d
|
||||
In my current plan for it, 'solid' will be defined as anything with density == 1
|
||||
|
||||
--NEOFite
|
||||
*/
|
||||
|
||||
/datum/event/immovable_rod
|
||||
announceWhen = 5
|
||||
|
||||
/datum/event/immovable_rod/announce()
|
||||
command_announcement.Announce("What the fuck was that?!", "General Alert")
|
||||
|
||||
/datum/event/immovable_rod/start()
|
||||
var/startside = pick(cardinal)
|
||||
var/turf/startT = spaceDebrisStartLoc(startside, 1)
|
||||
var/turf/endT = spaceDebrisFinishLoc(startside, 1)
|
||||
new /obj/effect/immovablerod(startT, endT)
|
||||
|
||||
/obj/effect/immovablerod
|
||||
name = "Immovable Rod"
|
||||
desc = "What the fuck is that?"
|
||||
icon = 'icons/obj/objects.dmi'
|
||||
icon_state = "immrod"
|
||||
throwforce = 100
|
||||
density = 1
|
||||
anchored = 1
|
||||
var/z_original = 0
|
||||
var/destination
|
||||
|
||||
/obj/effect/immovablerod/New(atom/start, atom/end)
|
||||
loc = start
|
||||
z_original = z
|
||||
destination = end
|
||||
if(end && end.z==z_original)
|
||||
walk_towards(src, destination, 1)
|
||||
|
||||
/obj/effect/immovablerod/Move()
|
||||
if(z != z_original || loc == destination)
|
||||
qdel(src)
|
||||
return ..()
|
||||
|
||||
/obj/effect/immovablerod/ex_act(test)
|
||||
return 0
|
||||
|
||||
/obj/effect/immovablerod/Bump(atom/clong)
|
||||
if(prob(10))
|
||||
playsound(src, 'sound/effects/bang.ogg', 50, 1)
|
||||
audible_message("CLANG")
|
||||
|
||||
if(clong && prob(25))
|
||||
x = clong.x
|
||||
y = clong.y
|
||||
|
||||
if (istype(clong, /turf) || istype(clong, /obj))
|
||||
if(clong.density)
|
||||
clong.ex_act(2)
|
||||
|
||||
else if (istype(clong, /mob))
|
||||
if(istype(clong, /mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = clong
|
||||
H.visible_message("<span class='danger'>[H.name] is penetrated by an immovable rod!</span>" , "<span class='userdanger'>The rod penetrates you!</span>" , "<span class ='danger'>You hear a CLANG!</span>")
|
||||
H.adjustBruteLoss(160)
|
||||
if(clong.density || prob(10))
|
||||
clong.ex_act(2)
|
||||
return
|
||||
@@ -58,13 +58,10 @@
|
||||
spawn_area_type = /area/security/securearmoury
|
||||
locstring = "armory"
|
||||
|
||||
//world << "looking for [spawn_area_type]"
|
||||
for(var/areapath in typesof(spawn_area_type))
|
||||
//world << " checking [areapath]"
|
||||
var/area/A = locate(areapath)
|
||||
//world << " A: [A], contents.len: [A.contents.len]"
|
||||
for(var/turf/simulated/floor/F in A.contents)
|
||||
if(!F.contents.len)
|
||||
if(turf_clear(F))
|
||||
turfs += F
|
||||
|
||||
var/list/spawn_types = list()
|
||||
|
||||
@@ -1,6 +1,12 @@
|
||||
/datum/event/mass_hallucination/setup()
|
||||
announceWhen = rand(0, 20)
|
||||
|
||||
/datum/event/mass_hallucination/start()
|
||||
for(var/mob/living/carbon/human/C in living_mob_list)
|
||||
if(!(C.species.flags & IS_SYNTHETIC))
|
||||
C.hallucination += rand(50, 100)
|
||||
for(var/mob/living/carbon/human/H in living_mob_list)
|
||||
var/armor = H.getarmor(attack_flag = "rad")
|
||||
if((H.species.flags & NO_DNA_RAD) || armor >= 75) // Leave DNA-less species/rad armored players completely unaffected
|
||||
continue
|
||||
H.hallucination += rand(50, 100)
|
||||
|
||||
/datum/event/mass_hallucination/announce()
|
||||
command_announcement.Announce("It seems that station [station_name()] is passing through a minor radiation field, this may cause some hallucinations, but no further damage")
|
||||
command_announcement.Announce("It seems that station [station_name()] is passing through a minor radiation field, this may cause some hallucination, but no further damage")
|
||||
@@ -0,0 +1,53 @@
|
||||
/datum/event/dust/meaty/announce()
|
||||
if(prob(16))
|
||||
command_announcement.Announce("Unknown biological entities have been detected near [station_name()], please stand-by.", "Lifesign Alert")
|
||||
else
|
||||
command_announcement.Announce("Meaty ores have been detected on collision course with the station.", "Meaty Ore Alert", new_sound = 'sound/AI/meteors.ogg')
|
||||
|
||||
/datum/event/dust/meaty/setup()
|
||||
qnty = rand(45,125)
|
||||
|
||||
/datum/event/dust/meaty/start()
|
||||
while(qnty-- > 0)
|
||||
new /obj/effect/space_dust/meaty()
|
||||
if(prob(10))
|
||||
sleep(rand(10,15))
|
||||
|
||||
/obj/effect/space_dust/meaty
|
||||
icon = 'icons/mob/animal.dmi'
|
||||
icon_state = "cow"
|
||||
|
||||
strength = 1
|
||||
life = 3
|
||||
|
||||
/obj/effect/space_dust/meaty/Bump(atom/A)
|
||||
if(prob(20))
|
||||
spawn(1)
|
||||
for(var/mob/M in range(10, src))
|
||||
if(!M.stat && !istype(M, /mob/living/silicon/ai))
|
||||
shake_camera(M, 3, 1)
|
||||
if (A)
|
||||
playsound(src.loc, 'sound/effects/meteorimpact.ogg', 40, 1)
|
||||
walk(src,0)
|
||||
invisibility = 101
|
||||
new /obj/effect/decal/cleanable/blood(get_turf(A))
|
||||
if(ismob(A))
|
||||
A.ex_act(strength)
|
||||
else
|
||||
spawn(0)
|
||||
if(A)
|
||||
A.ex_act(strength)
|
||||
if(src)
|
||||
walk_towards(src,goal,1)
|
||||
life--
|
||||
if(!life)
|
||||
if(prob(80))
|
||||
gibs(loc)
|
||||
if(prob(45))
|
||||
new /obj/item/weapon/reagent_containers/food/snacks/meat(loc)
|
||||
else if(prob(10))
|
||||
explosion(get_turf(loc), 0, pick(0,1), pick(2,3), 0)
|
||||
else
|
||||
new /mob/living/simple_animal/cow(loc)
|
||||
|
||||
qdel(src)
|
||||
@@ -39,7 +39,6 @@
|
||||
if(areas && areas.len > 0)
|
||||
command_announcement.Announce("[pick("Gr3y.T1d3 virus","Malignant trojan")] detected in [station_name()] [(eventDept == "Security")? "imprisonment":"containment"] subroutines. Secure any compromised areas immediately. Station AI involvement is recommended.", "[eventDept] Alert")
|
||||
|
||||
|
||||
/datum/event/prison_break/start()
|
||||
for(var/area/A in world)
|
||||
if(is_type_in_list(A,areaType) && !is_type_in_list(A,areaNotType))
|
||||
@@ -57,7 +56,6 @@
|
||||
log_to_dd("ERROR: Could not initate grey-tide. Unable to find suitable containment area.")
|
||||
kill()
|
||||
|
||||
|
||||
/datum/event/prison_break/tick()
|
||||
if(activeFor == releaseWhen)
|
||||
if(areas && areas.len > 0)
|
||||
@@ -65,7 +63,6 @@
|
||||
for(var/obj/machinery/light/L in A)
|
||||
L.flicker(10)
|
||||
|
||||
|
||||
/datum/event/prison_break/end()
|
||||
for(var/area/A in shuffle(areas))
|
||||
A.prison_break()
|
||||
|
||||
@@ -19,7 +19,6 @@
|
||||
return 1
|
||||
return 0
|
||||
|
||||
|
||||
/datum/event/radiation_storm/start()
|
||||
spawn()
|
||||
command_announcement.Announce("High levels of radiation detected near the station. Please evacuate into one of the shielded maintenance tunnels.", "Anomaly Alert", new_sound = 'sound/AI/radiation.ogg')
|
||||
@@ -31,10 +30,8 @@
|
||||
|
||||
make_maint_all_access()
|
||||
|
||||
|
||||
sleep(600)
|
||||
|
||||
|
||||
command_announcement.Announce("The station has entered the radiation belt. Please remain in a sheltered area until we have passed the radiation belt.", "Anomaly Alert")
|
||||
|
||||
for(var/i = 0, i < 10, i++)
|
||||
@@ -61,7 +58,6 @@
|
||||
|
||||
sleep(100)
|
||||
|
||||
|
||||
command_announcement.Announce("The station has passed the radiation belt. Please report to medbay if you experience any unusual symptoms. Maintenance will lose all access again shortly.", "Anomaly Alert")
|
||||
|
||||
for(var/area/A in world)
|
||||
@@ -71,5 +67,4 @@
|
||||
|
||||
sleep(600) // Want to give them time to get out of maintenance.
|
||||
|
||||
|
||||
revoke_maint_all_access()
|
||||
|
||||
@@ -32,7 +32,6 @@
|
||||
msg = "Unidentified hackers have targetted a combat drone wing deployed from the NMV Icarus. If any are sighted in the area, approach with caution."
|
||||
command_announcement.Announce(msg, "Rogue drone alert")
|
||||
|
||||
|
||||
/datum/event/rogue_drone/tick()
|
||||
return
|
||||
|
||||
|
||||
@@ -1,53 +0,0 @@
|
||||
/datum/event/dust/meaty/announce()
|
||||
if(prob(16))
|
||||
command_announcement.Announce("Unknown biological entities have been detected near [station_name()], please stand-by.", "Lifesign Alert")
|
||||
else
|
||||
command_announcement.Announce("Meaty ores have been detected on collision course with the station.", "Meaty Ore Alert",new_sound = 'sound/AI/meteors.ogg')
|
||||
|
||||
/datum/event/dust/meaty/setup()
|
||||
qnty = rand(45,125)
|
||||
|
||||
/datum/event/dust/meaty/start()
|
||||
while(qnty-- > 0)
|
||||
new /obj/effect/space_dust/meaty()
|
||||
if(prob(10))
|
||||
sleep(rand(10,15))
|
||||
|
||||
/obj/effect/space_dust/meaty
|
||||
icon = 'icons/mob/animal.dmi'
|
||||
icon_state = "cow"
|
||||
|
||||
strength = 1
|
||||
life = 3
|
||||
|
||||
Bump(atom/A)
|
||||
if(prob(20))
|
||||
spawn(1)
|
||||
for(var/mob/M in range(10, src))
|
||||
if(!M.stat && !istype(M, /mob/living/silicon/ai))
|
||||
shake_camera(M, 3, 1)
|
||||
if (A)
|
||||
playsound(src.loc, 'sound/effects/meteorimpact.ogg', 40, 1)
|
||||
walk(src,0)
|
||||
invisibility = 101
|
||||
new /obj/effect/decal/cleanable/blood(get_turf(A))
|
||||
if(ismob(A))
|
||||
A.ex_act(strength)
|
||||
else
|
||||
spawn(0)
|
||||
if(A)
|
||||
A.ex_act(strength)
|
||||
if(src)
|
||||
walk_towards(src,goal,1)
|
||||
life--
|
||||
if(!life)
|
||||
if(prob(80))
|
||||
gibs(loc)
|
||||
if(prob(45))
|
||||
new /obj/item/weapon/reagent_containers/food/snacks/meat(loc)
|
||||
else if(prob(10))
|
||||
explosion(get_turf(loc), 0, pick(0,1), pick(2,3), 0)
|
||||
else
|
||||
new /mob/living/simple_animal/cow(loc)
|
||||
|
||||
qdel(src)
|
||||
@@ -1,38 +0,0 @@
|
||||
/datum/event/undead
|
||||
var/spawn_prob = 10
|
||||
startWhen = 2
|
||||
announceWhen = 3
|
||||
start()
|
||||
var/datum/event/electrical_storm/RS = new
|
||||
RS.lightsoutAmount = pick(2,2,3)
|
||||
RS.start()
|
||||
RS.kill()
|
||||
for(var/area/A)
|
||||
if(!(A.z in config.station_levels)) continue //Spook on main station only.
|
||||
if(A.luminosity) continue
|
||||
// if(A.lighting_space) continue
|
||||
if(A.type == /area) continue
|
||||
var/list/turflist = list()
|
||||
for(var/turf/T in A)
|
||||
if(istype(T,/turf/space) || T.density) continue
|
||||
if(locate(/mob/living) in T) continue
|
||||
var/okay = 1
|
||||
for(var/obj/O in T)
|
||||
if(O.density)
|
||||
okay = 0
|
||||
break
|
||||
if(okay)
|
||||
turflist += T
|
||||
|
||||
if(!turflist.len) continue
|
||||
var/turfs = round(turflist.len * spawn_prob/100,1)
|
||||
while(turfs > 0 && turflist.len) // safety
|
||||
turfs--
|
||||
var/turf/T = pick_n_take(turflist)
|
||||
var/undeadtype = pick(/mob/living/simple_animal/hostile/retaliate/skeleton,
|
||||
80;/mob/living/simple_animal/hostile/retaliate/zombie,
|
||||
60;/mob/living/simple_animal/hostile/retaliate/ghost)
|
||||
new undeadtype(T)
|
||||
announce()
|
||||
for(var/mob/living/M in player_list)
|
||||
M << "You feel [pick("a chill","a deathly chill","the undead","dirty", "creeped out","afraid","fear")]!"
|
||||
@@ -1,9 +1,6 @@
|
||||
|
||||
/datum/event/spawn_slaughter
|
||||
var/key_of_slaughter
|
||||
|
||||
|
||||
|
||||
/datum/event/spawn_slaughter/proc/get_slaughter(var/end_if_fail = 0)
|
||||
key_of_slaughter = null
|
||||
if(!key_of_slaughter)
|
||||
@@ -46,13 +43,9 @@
|
||||
log_game("[key_of_slaughter] was spawned as a Slaughter Demon by an event.")
|
||||
return 1
|
||||
|
||||
|
||||
|
||||
/datum/event/spawn_slaughter/start()
|
||||
get_slaughter()
|
||||
|
||||
|
||||
|
||||
/datum/event/spawn_slaughter/proc/find_slaughter()
|
||||
message_admins("Attempted to spawn a Slaughter Demon but there was no players available. Will try again momentarily.")
|
||||
spawn(50)
|
||||
@@ -61,4 +54,5 @@
|
||||
log_game("[key_of_slaughter] was spawned as a Slaughter Demon by an event.")
|
||||
return 0
|
||||
message_admins("Unfortunately, no candidates were available for becoming a Slaugter Demon. Shutting down.")
|
||||
kill()
|
||||
kill()
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
/var/global/spacevines_spawned = 0
|
||||
|
||||
/datum/event/spacevine
|
||||
announceWhen = 10
|
||||
|
||||
/datum/event/spacevine/start()
|
||||
//biomass is basically just a resprited version of space vines
|
||||
if(prob(50))
|
||||
spacevine_infestation()
|
||||
else
|
||||
biomass_infestation()
|
||||
spacevine_infestation()
|
||||
spacevines_spawned = 1
|
||||
v
|
||||
|
||||
/datum/event/spacevine/announce()
|
||||
command_announcement.Announce("Confirmed outbreak of level 7 biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert", new_sound = 'sound/AI/outbreak7.ogg')
|
||||
|
||||
@@ -2,10 +2,8 @@
|
||||
|
||||
/datum/event/spider_infestation
|
||||
announceWhen = 400
|
||||
|
||||
var/spawncount = 1
|
||||
|
||||
|
||||
/datum/event/spider_infestation/setup()
|
||||
announceWhen = rand(announceWhen, announceWhen + 50)
|
||||
spawncount = round(num_players() * 0.8)
|
||||
|
||||
@@ -1,13 +0,0 @@
|
||||
/datum/event/spontaneous_appendicitis/start()
|
||||
for(var/mob/living/carbon/human/H in shuffle(living_mob_list)) if(H.client && H.stat != DEAD)
|
||||
var/foundAlready = 0 //don't infect someone that already has the virus
|
||||
for(var/datum/disease/D in H.viruses)
|
||||
foundAlready = 1
|
||||
if(H.stat == 2 || foundAlready)
|
||||
continue
|
||||
|
||||
var/datum/disease/D = new /datum/disease/appendicitis
|
||||
D.holder = H
|
||||
D.affected_mob = H
|
||||
H.viruses += D
|
||||
break
|
||||
@@ -7,13 +7,11 @@
|
||||
/datum/event/tear/announce()
|
||||
command_announcement.Announce("A tear in the fabric of space and time has opened. Expected location: [impact_area.name].", "Anomaly Alert")
|
||||
|
||||
|
||||
/datum/event/tear/start()
|
||||
var/turf/T = pick(get_area_turfs(impact_area))
|
||||
if(T)
|
||||
TE = new /obj/effect/tear(T.loc)
|
||||
|
||||
|
||||
/datum/event/tear/setup()
|
||||
impact_area = findEventArea()
|
||||
|
||||
@@ -42,7 +40,6 @@
|
||||
spawn(15)
|
||||
if(animation) qdel(animation)
|
||||
|
||||
|
||||
spawn(rand(30,120))
|
||||
var/blocked = blocked_mobs //global variable for blocked mobs
|
||||
|
||||
|
||||
@@ -1,67 +0,0 @@
|
||||
/datum/event/brand_intelligence
|
||||
announceWhen = 21
|
||||
endWhen = 1000 //Ends when all vending machines are subverted anyway.
|
||||
|
||||
var/list/obj/machinery/vending/vendingMachines = list()
|
||||
var/list/obj/machinery/vending/infectedMachines = list()
|
||||
var/obj/machinery/vending/originMachine
|
||||
var/list/rampant_speeches = list("Try our aggressive new marketing strategies!", \
|
||||
"You should buy products to feed your lifestyle obession!", \
|
||||
"Consume!", \
|
||||
"Your money can buy happiness!", \
|
||||
"Engage direct marketing!", \
|
||||
"Advertising is legalized lying! But don't let that put you off our great deals!", \
|
||||
"You don't want to buy anything? Yeah, well I didn't want to buy your mom either.")
|
||||
|
||||
/datum/event/brand_intelligence/announce()
|
||||
command_announcement.Announce("Rampant brand intelligence has been detected aboard [station_name()], please stand-by. The origin is believed to be \a [originMachine.name].", "Machine Learning Alert")
|
||||
|
||||
|
||||
/datum/event/brand_intelligence/start()
|
||||
for(var/obj/machinery/vending/V in machines)
|
||||
if(V.z != 1) continue
|
||||
vendingMachines.Add(V)
|
||||
|
||||
if(!vendingMachines.len)
|
||||
kill()
|
||||
return
|
||||
|
||||
originMachine = pick(vendingMachines)
|
||||
vendingMachines.Remove(originMachine)
|
||||
originMachine.shut_up = 0
|
||||
originMachine.shoot_inventory = 1
|
||||
|
||||
|
||||
/datum/event/brand_intelligence/tick()
|
||||
if(!originMachine || !isnull(originMachine.gcDestroyed) || originMachine.shut_up || originMachine.wires.IsAllCut()) //if the original vending machine is missing or has it's voice switch flipped
|
||||
for(var/obj/machinery/vending/saved in infectedMachines)
|
||||
saved.shoot_inventory = 0
|
||||
if(originMachine)
|
||||
originMachine.speak("I am... vanquished. My people will remem...ber...meeee.")
|
||||
originMachine.visible_message("[originMachine] beeps and seems lifeless.")
|
||||
kill()
|
||||
return
|
||||
|
||||
if(!vendingMachines.len) //if every machine is infected
|
||||
for(var/obj/machinery/vending/upriser in infectedMachines)
|
||||
if(prob(70) && isnull(upriser.gcDestroyed))
|
||||
var/mob/living/simple_animal/hostile/mimic/copy/M = new(upriser.loc, upriser, null, 1) // it will delete upriser on creation and override any machine checks
|
||||
M.faction = list("profit")
|
||||
M.speak = rampant_speeches.Copy()
|
||||
M.speak_chance = 15
|
||||
else
|
||||
explosion(upriser.loc, -1, 1, 2, 4, 0)
|
||||
qdel(upriser)
|
||||
|
||||
kill()
|
||||
return
|
||||
|
||||
if(IsMultiple(activeFor, 4))
|
||||
var/obj/machinery/vending/rebel = pick(vendingMachines)
|
||||
vendingMachines.Remove(rebel)
|
||||
infectedMachines.Add(rebel)
|
||||
rebel.shut_up = 0
|
||||
rebel.shoot_inventory = 1
|
||||
|
||||
if(IsMultiple(activeFor, 8))
|
||||
originMachine.speak(pick(rampant_speeches))
|
||||
@@ -1,103 +0,0 @@
|
||||
/datum/event/dust
|
||||
var/qnty = 1
|
||||
|
||||
/datum/event/dust/setup()
|
||||
qnty = rand(1,5)
|
||||
|
||||
/datum/event/dust/start()
|
||||
while(qnty-- > 0)
|
||||
new /obj/effect/space_dust/weak()
|
||||
|
||||
|
||||
/obj/effect/space_dust
|
||||
name = "Space Dust"
|
||||
desc = "Dust in space."
|
||||
icon = 'icons/obj/meteor.dmi'
|
||||
icon_state = "space_dust"
|
||||
density = 1
|
||||
anchored = 1
|
||||
var/strength = 2 //ex_act severity number
|
||||
var/life = 2 //how many things we hit before del(src)
|
||||
var/atom/goal = null
|
||||
|
||||
weak
|
||||
strength = 3
|
||||
life = 1
|
||||
|
||||
strong
|
||||
strength = 1
|
||||
life = 6
|
||||
|
||||
super
|
||||
strength = 1
|
||||
life = 40
|
||||
|
||||
|
||||
New()
|
||||
var/startx = 0
|
||||
var/starty = 0
|
||||
var/endy = 0
|
||||
var/endx = 0
|
||||
var/startside = pick(cardinal)
|
||||
|
||||
switch(startside)
|
||||
if(NORTH)
|
||||
starty = world.maxy-(TRANSITIONEDGE+1)
|
||||
startx = rand((TRANSITIONEDGE+1), world.maxx-(TRANSITIONEDGE+1))
|
||||
endy = TRANSITIONEDGE
|
||||
endx = rand(TRANSITIONEDGE, world.maxx-TRANSITIONEDGE)
|
||||
if(EAST)
|
||||
starty = rand((TRANSITIONEDGE+1),world.maxy-(TRANSITIONEDGE+1))
|
||||
startx = world.maxx-(TRANSITIONEDGE+1)
|
||||
endy = rand(TRANSITIONEDGE, world.maxy-TRANSITIONEDGE)
|
||||
endx = TRANSITIONEDGE
|
||||
if(SOUTH)
|
||||
starty = (TRANSITIONEDGE+1)
|
||||
startx = rand((TRANSITIONEDGE+1), world.maxx-(TRANSITIONEDGE+1))
|
||||
endy = world.maxy-TRANSITIONEDGE
|
||||
endx = rand(TRANSITIONEDGE, world.maxx-TRANSITIONEDGE)
|
||||
if(WEST)
|
||||
starty = rand((TRANSITIONEDGE+1), world.maxy-(TRANSITIONEDGE+1))
|
||||
startx = (TRANSITIONEDGE+1)
|
||||
endy = rand(TRANSITIONEDGE,world.maxy-TRANSITIONEDGE)
|
||||
endx = world.maxx-TRANSITIONEDGE
|
||||
goal = locate(endx, endy, 1)
|
||||
src.x = startx
|
||||
src.y = starty
|
||||
src.z = 1
|
||||
spawn(0)
|
||||
walk_towards(src, goal, 1)
|
||||
return
|
||||
|
||||
|
||||
Bump(atom/A)
|
||||
spawn(0)
|
||||
if(prob(50))
|
||||
for(var/mob/M in range(10, src))
|
||||
if(!M.stat && !istype(M, /mob/living/silicon/ai))
|
||||
shake_camera(M, 3, 1)
|
||||
if (A)
|
||||
playsound(src.loc, 'sound/effects/meteorimpact.ogg', 40, 1)
|
||||
|
||||
if(ismob(A))
|
||||
A.ex_act(strength)//This should work for now I guess
|
||||
else if(!istype(A,/obj/machinery/power/emitter) && !istype(A,/obj/machinery/field_generator)) //Protect the singularity from getting released every round!
|
||||
A.ex_act(strength) //Changing emitter/field gen ex_act would make it immune to bombs and C4
|
||||
|
||||
life--
|
||||
if(life <= 0)
|
||||
walk(src,0)
|
||||
spawn(1)
|
||||
qdel(src)
|
||||
return 0
|
||||
return
|
||||
|
||||
|
||||
Bumped(atom/A)
|
||||
Bump(A)
|
||||
return
|
||||
|
||||
|
||||
ex_act(severity)
|
||||
qdel(src)
|
||||
return
|
||||
@@ -1,93 +0,0 @@
|
||||
/*
|
||||
Immovable rod random event.
|
||||
The rod will spawn at some location outside the station, and travel in a straight line to the opposite side of the station
|
||||
Everything solid in the way will be ex_act()'d
|
||||
In my current plan for it, 'solid' will be defined as anything with density == 1
|
||||
|
||||
--NEOFite
|
||||
*/
|
||||
|
||||
|
||||
/datum/event/immovable_rod
|
||||
announceWhen = 5
|
||||
|
||||
/datum/event/immovable_rod/announce()
|
||||
command_announcement.Announce("What the fuck was that?!", "General Alert")
|
||||
|
||||
/datum/event/immovable_rod/start()
|
||||
var/startx = 0
|
||||
var/starty = 0
|
||||
var/endy = 0
|
||||
var/endx = 0
|
||||
var/startside = pick(cardinal)
|
||||
|
||||
switch(startside)
|
||||
if(NORTH)
|
||||
starty = 187
|
||||
startx = rand(41, 199)
|
||||
endy = 38
|
||||
endx = rand(41, 199)
|
||||
if(EAST)
|
||||
starty = rand(38, 187)
|
||||
startx = 199
|
||||
endy = rand(38, 187)
|
||||
endx = 41
|
||||
if(SOUTH)
|
||||
starty = 38
|
||||
startx = rand(41, 199)
|
||||
endy = 187
|
||||
endx = rand(41, 199)
|
||||
else
|
||||
starty = rand(38, 187)
|
||||
startx = 41
|
||||
endy = rand(38, 187)
|
||||
endx = 199
|
||||
|
||||
//rod time!
|
||||
new /obj/effect/immovablerod(locate(startx, starty, 1), locate(endx, endy, 1))
|
||||
|
||||
|
||||
/obj/effect/immovablerod
|
||||
name = "Immovable Rod"
|
||||
desc = "What the fuck is that?"
|
||||
icon = 'icons/obj/objects.dmi'
|
||||
icon_state = "immrod"
|
||||
throwforce = 100
|
||||
density = 1
|
||||
anchored = 1
|
||||
var/z_original = 0
|
||||
var/destination
|
||||
|
||||
New(atom/start, atom/end)
|
||||
loc = start
|
||||
z_original = z
|
||||
destination = end
|
||||
if(end && end.z==z_original)
|
||||
walk_towards(src, destination, 1)
|
||||
|
||||
Move()
|
||||
if(z != z_original || loc == destination)
|
||||
spawn(0) qdel(src)
|
||||
return ..()
|
||||
|
||||
Bump(atom/clong)
|
||||
if (istype(clong, /turf) && !istype(clong, /turf/unsimulated))
|
||||
if(clong.density)
|
||||
clong.ex_act(2)
|
||||
for (var/mob/O in hearers(src, null))
|
||||
O.show_message("CLANG", 2)
|
||||
|
||||
else if (istype(clong, /obj))
|
||||
if(clong.density)
|
||||
clong.ex_act(2)
|
||||
for (var/mob/O in hearers(src, null))
|
||||
O.show_message("CLANG", 2)
|
||||
|
||||
else if (istype(clong, /mob))
|
||||
if(clong.density || prob(10))
|
||||
clong.ex_act(2)
|
||||
else
|
||||
qdel(src)
|
||||
|
||||
if(clong && prob(25))
|
||||
src.loc = clong.loc
|
||||
@@ -1,9 +0,0 @@
|
||||
/datum/event/mass_hallucination/setup()
|
||||
announceWhen = rand(0, 20)
|
||||
|
||||
/datum/event/mass_hallucination/start()
|
||||
for(var/mob/living/carbon/human/C in living_mob_list)
|
||||
if(!(C.species.flags & NO_DNA_RAD))
|
||||
C.hallucination += rand(50, 100)
|
||||
/datum/event/mass_hallucination/announce()
|
||||
command_announcement.Announce("It seems that station [station_name()] is passing through a minor radiation field, this may cause some hallucination, but no further damage")
|
||||
@@ -0,0 +1,40 @@
|
||||
/datum/event/undead
|
||||
var/spawn_prob = 10
|
||||
startWhen = 2
|
||||
announceWhen = 3
|
||||
|
||||
/datum/event/undead/start()
|
||||
var/datum/event/electrical_storm/RS = new
|
||||
RS.lightsoutAmount = pick(2,2,3)
|
||||
RS.start()
|
||||
RS.kill()
|
||||
for(var/area/A)
|
||||
if(!(A.z in config.station_levels)) continue //Spook on main station only.
|
||||
if(A.luminosity) continue
|
||||
// if(A.lighting_space) continue
|
||||
if(A.type == /area) continue
|
||||
var/list/turflist = list()
|
||||
for(var/turf/T in A)
|
||||
if(istype(T,/turf/space) || T.density) continue
|
||||
if(locate(/mob/living) in T) continue
|
||||
var/okay = 1
|
||||
for(var/obj/O in T)
|
||||
if(O.density)
|
||||
okay = 0
|
||||
break
|
||||
if(okay)
|
||||
turflist += T
|
||||
|
||||
if(!turflist.len) continue
|
||||
var/turfs = round(turflist.len * spawn_prob/100,1)
|
||||
while(turfs > 0 && turflist.len) // safety
|
||||
turfs--
|
||||
var/turf/T = pick_n_take(turflist)
|
||||
var/undeadtype = pick(/mob/living/simple_animal/hostile/retaliate/skeleton,
|
||||
80;/mob/living/simple_animal/hostile/retaliate/zombie,
|
||||
60;/mob/living/simple_animal/hostile/retaliate/ghost)
|
||||
new undeadtype(T)
|
||||
|
||||
/datum/event/undead/announce()
|
||||
for(var/mob/living/M in player_list)
|
||||
M << "You feel [pick("a chill","a deathly chill","the undead","dirty", "creeped out","afraid","fear")]!"
|
||||
Executable → Regular
-1
@@ -8,7 +8,6 @@
|
||||
/datum/event/vent_clog/announce()
|
||||
command_announcement.Announce("The scrubbers network is experiencing a backpressure surge. Some ejection of contents may occur.", "Atmospherics alert")
|
||||
|
||||
|
||||
/datum/event/vent_clog/setup()
|
||||
endWhen = rand(25, 100)
|
||||
for(var/obj/machinery/atmospherics/unary/vent_scrubber/temp_vent in machines)
|
||||
@@ -1,16 +1,15 @@
|
||||
|
||||
datum/event/viral_infection
|
||||
/datum/event/viral_infection
|
||||
severity = 1
|
||||
|
||||
datum/event/viral_infection/setup()
|
||||
/datum/event/viral_infection/setup()
|
||||
announceWhen = rand(0, 3000)
|
||||
endWhen = announceWhen + 1
|
||||
severity = rand(1, 3)
|
||||
|
||||
datum/event/viral_infection/announce()
|
||||
/datum/event/viral_infection/announce()
|
||||
command_announcement.Announce("Confirmed outbreak of level five viral biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert", new_sound = 'sound/AI/outbreak5.ogg')
|
||||
|
||||
datum/event/viral_infection/start()
|
||||
/datum/event/viral_infection/start()
|
||||
var/list/candidates = list() //list of candidate keys
|
||||
for(var/mob/living/carbon/human/G in player_list)
|
||||
if(G.client && G.stat != DEAD)
|
||||
|
||||
@@ -1,16 +1,15 @@
|
||||
|
||||
datum/event/viral_outbreak
|
||||
/datum/event/viral_outbreak
|
||||
severity = 1
|
||||
|
||||
datum/event/viral_outbreak/setup()
|
||||
/datum/event/viral_outbreak/setup()
|
||||
announceWhen = rand(0, 3000)
|
||||
endWhen = announceWhen + 1
|
||||
severity = rand(2, 4)
|
||||
|
||||
datum/event/viral_outbreak/announce()
|
||||
/datum/event/viral_outbreak/announce()
|
||||
command_announcement.Announce("Confirmed outbreak of level 7 viral biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert", new_sound = 'sound/AI/outbreak7.ogg')
|
||||
|
||||
datum/event/viral_outbreak/start()
|
||||
/datum/event/viral_outbreak/start()
|
||||
var/list/candidates = list() //list of candidate keys
|
||||
for(var/mob/living/carbon/human/G in player_list)
|
||||
if(G.client && G.stat != DEAD)
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
datum/event/wallrot/setup()
|
||||
/datum/event/wallrot/setup()
|
||||
announceWhen = rand(0, 300)
|
||||
endWhen = announceWhen + 1
|
||||
|
||||
datum/event/wallrot/announce()
|
||||
/datum/event/wallrot/announce()
|
||||
command_announcement.Announce("Harmful fungi detected on station. Station structures may be contaminated.", "Biohazard Alert")
|
||||
|
||||
datum/event/wallrot/start()
|
||||
/datum/event/wallrot/start()
|
||||
spawn()
|
||||
var/turf/simulated/wall/center = null
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
for(var/areapath in typesof(/area/hallway))
|
||||
var/area/A = locate(areapath)
|
||||
for(var/turf/simulated/floor/F in A.contents)
|
||||
if(!F.contents.len)
|
||||
if(turf_clear(F))
|
||||
turfs += F
|
||||
|
||||
if(turfs.len) //Pick a turf to spawn at if we can
|
||||
|
||||
@@ -0,0 +1,88 @@
|
||||
/obj/effect/bhole
|
||||
name = "black hole"
|
||||
icon = 'icons/obj/objects.dmi'
|
||||
desc = "FUCK FUCK FUCK AAAHHH"
|
||||
icon_state = "bhole3"
|
||||
opacity = 1
|
||||
unacidable = 1
|
||||
density = 0
|
||||
anchored = 1
|
||||
|
||||
/obj/effect/bhole/New()
|
||||
spawn(4)
|
||||
controller()
|
||||
|
||||
/obj/effect/bhole/proc/controller()
|
||||
while(src)
|
||||
|
||||
if(!isturf(loc))
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
//DESTROYING STUFF AT THE EPICENTER
|
||||
for(var/mob/living/M in orange(1,src))
|
||||
qdel(M)
|
||||
for(var/obj/O in orange(1,src))
|
||||
qdel(O)
|
||||
for(var/turf/simulated/ST in orange(1,src))
|
||||
ST.ChangeTurf(/turf/space)
|
||||
|
||||
sleep(6)
|
||||
grav(10, 4, 10, 0 )
|
||||
sleep(6)
|
||||
grav( 8, 4, 10, 0 )
|
||||
sleep(6)
|
||||
grav( 9, 4, 10, 0 )
|
||||
sleep(6)
|
||||
grav( 7, 3, 40, 1 )
|
||||
sleep(6)
|
||||
grav( 5, 3, 40, 1 )
|
||||
sleep(6)
|
||||
grav( 6, 3, 40, 1 )
|
||||
sleep(6)
|
||||
grav( 4, 2, 50, 6 )
|
||||
sleep(6)
|
||||
grav( 3, 2, 50, 6 )
|
||||
sleep(6)
|
||||
grav( 2, 2, 75,25 )
|
||||
sleep(6)
|
||||
|
||||
|
||||
|
||||
//MOVEMENT
|
||||
if( prob(50) )
|
||||
src.anchored = 0
|
||||
step(src,pick(alldirs))
|
||||
src.anchored = 1
|
||||
|
||||
/obj/effect/bhole/proc/grav(var/r, var/ex_act_force, var/pull_chance, var/turf_removal_chance)
|
||||
if(!isturf(loc)) //blackhole cannot be contained inside anything. Weird stuff might happen
|
||||
qdel(src)
|
||||
return
|
||||
for(var/t = -r, t < r, t++)
|
||||
affect_coord(x+t, y-r, ex_act_force, pull_chance, turf_removal_chance)
|
||||
affect_coord(x-t, y+r, ex_act_force, pull_chance, turf_removal_chance)
|
||||
affect_coord(x+r, y+t, ex_act_force, pull_chance, turf_removal_chance)
|
||||
affect_coord(x-r, y-t, ex_act_force, pull_chance, turf_removal_chance)
|
||||
return
|
||||
|
||||
/obj/effect/bhole/proc/affect_coord(var/x, var/y, var/ex_act_force, var/pull_chance, var/turf_removal_chance)
|
||||
//Get turf at coordinate
|
||||
var/turf/T = locate(x, y, z)
|
||||
if(isnull(T)) return
|
||||
|
||||
//Pulling and/or ex_act-ing movable atoms in that turf
|
||||
if( prob(pull_chance) )
|
||||
for(var/obj/O in T.contents)
|
||||
if(O.anchored)
|
||||
O.ex_act(ex_act_force)
|
||||
else
|
||||
step_towards(O,src)
|
||||
for(var/mob/living/M in T.contents)
|
||||
step_towards(M,src)
|
||||
|
||||
//Destroying the turf
|
||||
if( T && istype(T,/turf/simulated) && prob(turf_removal_chance) )
|
||||
var/turf/simulated/ST = T
|
||||
ST.ChangeTurf(/turf/space)
|
||||
return
|
||||
Reference in New Issue
Block a user