mirror of
https://github.com/vgstation-coders/vgstation13.git
synced 2025-12-10 18:32:03 +00:00
endgames now accept args (#17922)
blood moon force-prompt by admins now asks how many mobs per area you wish to make
This commit is contained in:
@@ -63,10 +63,10 @@
|
||||
/datum/universal_state/proc/OverlayAndAmbientSet()
|
||||
return
|
||||
|
||||
/proc/SetUniversalState(var/newstate, var/on_exit = 1, var/on_enter = 1)
|
||||
/proc/SetUniversalState(var/newstate, var/on_exit = 1, var/on_enter = 1, var/list/given_args)
|
||||
if(on_exit)
|
||||
universe.OnExit()
|
||||
universe = new newstate
|
||||
universe = new newstate(given_args)
|
||||
if(on_enter)
|
||||
universe.OnEnter()
|
||||
|
||||
|
||||
@@ -8,9 +8,14 @@
|
||||
/datum/universal_state/halloween
|
||||
name = "All Hallows Eve"
|
||||
desc = "Double, double toil and Trouble. Fire burn and Cauldron bubble."
|
||||
|
||||
var/mob_amount = 10
|
||||
decay_rate = 0
|
||||
|
||||
/datum/universal_state/halloween/New(var/list/given_args = list())
|
||||
..()
|
||||
if(given_args["mobs"])
|
||||
mob_amount = given_args["mobs"]
|
||||
|
||||
/datum/universal_state/halloween/OnShuttleCall(var/mob/user)
|
||||
return 1
|
||||
|
||||
@@ -52,7 +57,7 @@
|
||||
|
||||
/datum/universal_state/halloween/proc/AreaSet()
|
||||
for(var/area/A in areas)
|
||||
if(!istype(A,/area) || isspace(A))
|
||||
if(!istype(A,/area) || isspace(A) || istype(A,/area/chapel))
|
||||
continue
|
||||
|
||||
// No cheating~
|
||||
@@ -66,6 +71,20 @@
|
||||
A.party = null
|
||||
A.radalert = 0
|
||||
A.updateicon()
|
||||
if(!A.area_turfs.len)
|
||||
continue
|
||||
var/list/available_turfs = A.area_turfs.Copy()
|
||||
var/turf/test_turf = available_turfs[1]
|
||||
if(test_turf.z != STATION_Z)
|
||||
continue
|
||||
for(var/i=1 to mob_amount)
|
||||
if(!available_turfs.len)
|
||||
break
|
||||
var/turf/T = pick(available_turfs)
|
||||
if(T.holy || T.z != STATION_Z || !istype(T, /turf/simulated/floor) || T.has_dense_content())
|
||||
available_turfs.Remove(T)
|
||||
continue
|
||||
new /obj/effect/gravestone/halloween(T)
|
||||
CHECK_TICK
|
||||
|
||||
|
||||
@@ -75,8 +94,6 @@
|
||||
if(istype(T, /turf/space))
|
||||
T.overlays += image(icon = T.icon, icon_state = "hell01")
|
||||
else
|
||||
if(!T.holy && prob(5) && T.z == STATION_Z && istype(T, /turf/simulated/floor))
|
||||
new /obj/effect/gravestone/halloween(T)
|
||||
T.underlays += "hell01"
|
||||
CHECK_TICK
|
||||
|
||||
|
||||
@@ -851,7 +851,7 @@ var/global/floorIsLava = 0
|
||||
<A href='?src=\ref[src];secretsfun=hellonearth'>Summon Nar-Sie</A><BR>
|
||||
<A href='?src=\ref[src];secretsfun=supermattercascade'>Start a Supermatter Cascade</A><BR>
|
||||
<A href='?src=\ref[src];secretsfun=meteorstorm'>Trigger an undending Meteor Storm</A><BR>
|
||||
<A href='?src=\ref[src];secretsfun=halloween'>Awaken the damned for some spooky shenanigans</A><BR>
|
||||
<A href='?src=\ref[src];secretsfun=halloween'>Trigger the blood moon</A><BR>
|
||||
<A href='?src=\ref[src];secretsfun=christmas_vic'>Make the station christmasy</A><BR>
|
||||
"}
|
||||
|
||||
|
||||
@@ -3321,8 +3321,12 @@
|
||||
feedback_add_details("admin_secrets_fun_used","HW")
|
||||
var/choice = input("Are you sure you want to wake up the space indian burial ground?. Misuse of this could result in removal of flags or hilarity.") in list("Get our spook on", "Cancel")
|
||||
if(choice != "Cancel")
|
||||
SetUniversalState(/datum/universal_state/halloween, 1, 1)
|
||||
message_admins("[key_name_admin(usr)] has pressed the halloween fun button. Truly [key_name_admin(usr)] is the spookiest.")
|
||||
var/list/given_args = list()
|
||||
var/number = input("How many mobs do you want per area?", 10) as num
|
||||
if(number)
|
||||
given_args["mobs"] = number
|
||||
SetUniversalState(/datum/universal_state/halloween, 1, 1, given_args)
|
||||
message_admins("[key_name_admin(usr)] has pressed the halloween fun button with [number] amount of mobs per area. Truly [key_name_admin(usr)] is the spookiest.")
|
||||
if("christmas_vic")
|
||||
feedback_inc("admin_secrets_fun_used",1)
|
||||
feedback_add_details("admin_secrets_fun_used","XMS")
|
||||
|
||||
Reference in New Issue
Block a user