diff --git a/code/modules/events/mass_hallucination.dm b/code/modules/events/mass_hallucination.dm index 1186268e31..dc0b07b464 100644 --- a/code/modules/events/mass_hallucination.dm +++ b/code/modules/events/mass_hallucination.dm @@ -4,11 +4,26 @@ weight = 10 max_occurrences = 2 min_players = 1 + var/forced_hallucination + +/datum/round_event_control/mass_hallucination/admin_setup() + if(!check_rights(R_FUN)) + return + + forced_hallucination = input(usr, "Choose the hallucination to apply","Send Hallucination") as null|anything in subtypesof(/datum/hallucination) /datum/round_event/mass_hallucination fakeable = FALSE /datum/round_event/mass_hallucination/start() + var/datum/round_event_control/mass_hallucination/M = control + if(M.forced_hallucination) + for(var/mob/living/carbon/C in GLOB.alive_mob_list) + if (HAS_TRAIT(C,TRAIT_EXEMPT_HEALTH_EVENTS)) + continue + new M.forced_hallucination(C, TRUE) + return + switch(rand(1,4)) if(1) //same sound for everyone var/sound = pick("airlock","airlock_pry","console","explosion","far_explosion","mech","glass","alarm","beepsky","mech","wall_decon","door_hack","tesla") @@ -37,4 +52,4 @@ for(var/mob/living/carbon/C in GLOB.alive_mob_list) if (HAS_TRAIT(C,TRAIT_EXEMPT_HEALTH_EVENTS)) continue - new picked_hallucination(C, TRUE) \ No newline at end of file + new picked_hallucination(C, TRUE)