mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 10:43:20 +00:00
Adds new event: drone drop pod
This commit is contained in:
31
code/modules/events/drone_pod_vr.dm
Normal file
31
code/modules/events/drone_pod_vr.dm
Normal file
@@ -0,0 +1,31 @@
|
||||
/datum/event/drone_pod_drop
|
||||
announceWhen = 1
|
||||
var/turf/land_target = null
|
||||
var/attempt_amount = 10
|
||||
|
||||
/datum/event/drone_pod_drop/setup()
|
||||
startWhen = rand(8,15)
|
||||
if(LAZYLEN(using_map.meteor_strike_areas))
|
||||
var/turf/potential_target = null
|
||||
for(var/i=1, i <= attempt_amount, i++)
|
||||
potential_target = pick(get_area_turfs(pick(using_map.meteor_strike_areas)))
|
||||
if(potential_target.x < 7 || potential_target.x > world.maxx-7 || potential_target.y < 7 || potential_target.y > world.maxy-7)
|
||||
continue
|
||||
else
|
||||
land_target = potential_target
|
||||
break
|
||||
|
||||
if(!land_target)
|
||||
kill()
|
||||
|
||||
/datum/event/meteor_strike/announce()
|
||||
command_announcement.Announce("An unidentified drone pod has been detected landing near the surface facilty. Open and examine at your own risk.", "NanoTrasen Orbital Monitoring")
|
||||
|
||||
/datum/event/drone_pod_drop/start()
|
||||
if(istype(land_target, /turf/simulated/open))
|
||||
while(istype(land_target, /turf/simulated/open))
|
||||
land_target = GetBelow(land_target)
|
||||
if(!land_target)
|
||||
kill()
|
||||
|
||||
new /datum/random_map/droppod/supply(null, land_target.x-2, land_target.y-2, land_target.z, supplied_drops = list(/obj/structure/ghost_pod/manual/lost_drone))
|
||||
@@ -81,6 +81,7 @@
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Spider Infestation", /datum/event/spider_infestation, 30, list(ASSIGNMENT_SECURITY = 30), 1),
|
||||
//Evil grubs that drain station power slightly
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Grub Infestation", /datum/event/grub_infestation, 0, list(ASSIGNMENT_SECURITY = 10, ASSIGNMENT_ENGINEER = 30), 1),
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Drone Pod Drop", /datum/event/drone_pod_drop, 10, list(ASSIGNMENT_SCIENTIST = 40), 1)
|
||||
)
|
||||
add_disabled_events(list(
|
||||
new /datum/event_meta(EVENT_LEVEL_MODERATE, "Appendicitis", /datum/event/spontaneous_appendicitis, 0, list(ASSIGNMENT_MEDICAL = 30), 1),
|
||||
|
||||
Reference in New Issue
Block a user