mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-23 05:00:55 +01:00
Observers can auto-orbit meteors; space dust event (#19142)
* Observers can auto-orbit meteors; space dust event During a meteor shower, observers can automatically orbit threatening meteors and watch them hit the station. Added Major Space Dust event, which is a meteor shower containing only space dust. Reduced chance of RNG meteor event. Fixes bug where meteors wouldn't move when spawned.
This commit is contained in:
@@ -1,21 +1,15 @@
|
||||
/datum/round_event_control/meteor_wave/dust
|
||||
/datum/round_event_control/space_dust
|
||||
name = "Minor Space Dust"
|
||||
typepath = /datum/round_event/meteor_wave/dust
|
||||
typepath = /datum/round_event/space_dust
|
||||
weight = 200
|
||||
max_occurrences = 1000
|
||||
earliest_start = 0
|
||||
alertadmins = 0
|
||||
|
||||
/datum/round_event/meteor_wave/dust
|
||||
|
||||
/datum/round_event/space_dust
|
||||
startWhen = 1
|
||||
endWhen = 2
|
||||
announceWhen = 0
|
||||
|
||||
/datum/round_event/meteor_wave/dust/announce()
|
||||
return
|
||||
|
||||
/datum/round_event/meteor_wave/dust/start()
|
||||
/datum/round_event/space_dust/start()
|
||||
spawn_meteors(1, meteorsC)
|
||||
|
||||
/datum/round_event/meteor_wave/dust/tick()
|
||||
return
|
||||
|
||||
@@ -38,6 +38,8 @@ In my current plan for it, 'solid' will be defined as anything with density == 1
|
||||
|
||||
/obj/effect/immovablerod/New(atom/start, atom/end)
|
||||
..()
|
||||
if(SSaugury)
|
||||
SSaugury.register_doom(src, 2000)
|
||||
z_original = z
|
||||
destination = end
|
||||
notify_ghosts("\A [src] is inbound!",
|
||||
|
||||
@@ -0,0 +1,19 @@
|
||||
/datum/round_event_control/meteor_wave/major_dust
|
||||
name = "Major Space Dust"
|
||||
typepath = /datum/round_event/meteor_wave/major_dust
|
||||
weight = 30
|
||||
|
||||
/datum/round_event/meteor_wave/major_dust
|
||||
wave_name = "space dust"
|
||||
|
||||
/datum/round_event/meteor_wave/major_dust/announce()
|
||||
var/reason = pick(
|
||||
"The station is passing through a debris cloud, expect minor damage \
|
||||
to external fittings and fixtures.",
|
||||
"Nanotrasen Superweapons Division is testing a new prototype \
|
||||
[pick("field","projection","nova","super-colliding","reactive")] \
|
||||
[pick("cannon","artillery","tank","cruiser","\[REDACTED\]")], \
|
||||
some mild debris is expected.",
|
||||
"A neighbouring station is throwing rocks at you. (Perhaps they've \
|
||||
grown tired of your messages.)")
|
||||
priority_announce(pick(reason), "Collision Alert")
|
||||
@@ -1,12 +1,11 @@
|
||||
/datum/round_event_control/meteor_wave/meaty
|
||||
name = "Meaty Ore Wave"
|
||||
name = "Meteor Wave: Meaty"
|
||||
typepath = /datum/round_event/meteor_wave/meaty
|
||||
weight = 1
|
||||
weight = 2
|
||||
max_occurrences = 1
|
||||
|
||||
/datum/round_event/meteor_wave/meaty
|
||||
wave_name = "meaty"
|
||||
|
||||
/datum/round_event/meteor_wave/meaty/announce()
|
||||
priority_announce("Meaty ores have been detected on collision course with the station.", "Oh crap, get the mop.",'sound/AI/meteors.ogg')
|
||||
|
||||
/datum/round_event/meteor_wave/meaty/tick()
|
||||
if(IsMultiple(activeFor, 3))
|
||||
spawn_meteors(5, meteorsB) //meteor list types defined in gamemode/meteor/meteors.dm
|
||||
@@ -1,5 +1,7 @@
|
||||
// Normal strength
|
||||
|
||||
/datum/round_event_control/meteor_wave
|
||||
name = "Meteor Wave"
|
||||
name = "Meteor Wave: Normal"
|
||||
typepath = /datum/round_event/meteor_wave
|
||||
weight = 5
|
||||
min_players = 5
|
||||
@@ -10,25 +12,57 @@
|
||||
endWhen = 66
|
||||
announceWhen = 1
|
||||
var/list/wave_type
|
||||
var/wave_name = "normal"
|
||||
|
||||
/datum/round_event/meteor_wave/New()
|
||||
..()
|
||||
random_wave_type()
|
||||
if(!wave_type)
|
||||
determine_wave_type()
|
||||
|
||||
/datum/round_event/meteor_wave/proc/random_wave_type()
|
||||
var/picked_wave = pickweight(list("normal" = 50, "threatening" = 40, "catastrophic" = 10))
|
||||
switch(picked_wave)
|
||||
/datum/round_event/meteor_wave/proc/determine_wave_type()
|
||||
if(!wave_name)
|
||||
wave_name = pickweight(list(
|
||||
"normal" = 50,
|
||||
"threatening" = 40,
|
||||
"catastrophic" = 10))
|
||||
switch(wave_name)
|
||||
if("normal")
|
||||
wave_type = meteors_normal
|
||||
if("threatening")
|
||||
wave_type = meteors_threatening
|
||||
if("catastrophic")
|
||||
wave_type = meteors_catastrophic
|
||||
if("meaty")
|
||||
wave_type = meteorsB
|
||||
if("space dust")
|
||||
wave_type = meteorsC
|
||||
else
|
||||
WARNING("Wave name of [wave_name] not recognised.")
|
||||
kill()
|
||||
|
||||
/datum/round_event/meteor_wave/announce()
|
||||
priority_announce("Meteors have been detected on collision course with the station.", "Meteor Alert", 'sound/AI/meteors.ogg')
|
||||
|
||||
|
||||
/datum/round_event/meteor_wave/tick()
|
||||
if(IsMultiple(activeFor, 3))
|
||||
spawn_meteors(5, wave_type) //meteor list types defined in gamemode/meteor/meteors.dm
|
||||
|
||||
/datum/round_event_control/meteor_wave/threatening
|
||||
name = "Meteor Wave: Threatening"
|
||||
typepath = /datum/round_event/meteor_wave/threatening
|
||||
weight = 4
|
||||
min_players = 5
|
||||
max_occurrences = 3
|
||||
|
||||
/datum/round_event/meteor_wave/threatening
|
||||
wave_name = "threatening"
|
||||
|
||||
/datum/round_event_control/meteor_wave/catastrophic
|
||||
name = "Meteor Wave: Catastrophic"
|
||||
typepath = /datum/round_event/meteor_wave/catastrophic
|
||||
weight = 1
|
||||
min_players = 5
|
||||
max_occurrences = 3
|
||||
|
||||
/datum/round_event/meteor_wave/catastrophic
|
||||
wave_name = "catastrophic"
|
||||
|
||||
@@ -487,11 +487,10 @@
|
||||
if(3)
|
||||
return
|
||||
if(2)
|
||||
if (prob(20))
|
||||
if(prob(20))
|
||||
src.gets_dug()
|
||||
if(1)
|
||||
src.gets_dug()
|
||||
return
|
||||
|
||||
/turf/open/floor/plating/asteroid/attackby(obj/item/weapon/W, mob/user, params)
|
||||
//note that this proc does not call ..()
|
||||
|
||||
@@ -57,10 +57,10 @@ var/list/image/ghost_images_simple = list() //this is a list of all ghost images
|
||||
|
||||
/mob/dead/observer/New(mob/body)
|
||||
verbs += /mob/dead/observer/proc/dead_tele
|
||||
|
||||
|
||||
if(global.cross_allowed)
|
||||
verbs += /mob/dead/observer/proc/server_hop
|
||||
|
||||
|
||||
ghostimage = image(src.icon,src,src.icon_state)
|
||||
if(icon_state in ghost_forms_with_directions_list)
|
||||
ghostimage_default = image(src.icon,src,src.icon_state + "_nodir")
|
||||
@@ -563,7 +563,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
set desc= "Jump to the other server"
|
||||
if (alert(src, "Jump to server running at [global.cross_address]?", "Server Hop", "Yes", "No") != "Yes")
|
||||
return 0
|
||||
if (client && global.cross_allowed)
|
||||
if (client && global.cross_allowed)
|
||||
src << "<span class='notice'>Sending you to [global.cross_address].</span>"
|
||||
winset(src, null, "command=.options") //other wise the user never knows if byond is downloading resources
|
||||
client << link(global.cross_address)
|
||||
|
||||
Reference in New Issue
Block a user