Fixes forcing an event being marked as random. (#46800)

This commit is contained in:
AnturK
2019-10-02 18:12:10 +02:00
committed by moo
parent dcc6783dbb
commit 822e109228
2 changed files with 2 additions and 4 deletions

View File

@@ -91,8 +91,7 @@ SUBSYSTEM_DEF(events)
if(. == EVENT_CANT_RUN)//we couldn't run this event for some reason, set its max_occurrences to 0
E.max_occurrences = 0
else if(. == EVENT_READY)
E.random = TRUE
E.runEvent()
E.runEvent(random = TRUE)
//allows a client to trigger an event
//aka Badmin Central

View File

@@ -18,7 +18,6 @@
var/holidayID = "" //string which should be in the SSeventss.holidays list if you wish this event to be holiday-specific
//anything with a (non-null) holidayID which does not match holiday, cannot run.
var/wizardevent = FALSE
var/random = FALSE //If the event has occured randomly, or if it was forced by an admin or in-game occurance
var/alert_observers = TRUE //should we let the ghosts and admins know this event is firing
//should be disabled on events that fire a lot
@@ -84,7 +83,7 @@
log_admin_private("[key_name(usr)] cancelled event [name].")
SSblackbox.record_feedback("tally", "event_admin_cancelled", 1, typepath)
/datum/round_event_control/proc/runEvent()
/datum/round_event_control/proc/runEvent(random = FALSE)
var/datum/round_event/E = new typepath()
E.current_players = get_active_player_count(alive_check = 1, afk_check = 1, human_check = 1)
E.control = src