mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-07-14 09:35:30 +01:00
[MIRROR] Fixed final objectives appearing as skipped in the traitor panel [MDB IGNORE] (#20778)
* Fixed final objectives appearing as skipped in the traitor panel (#74956) ## About The Pull Request Final objectives appear as skipped due to them setting the 'skipped' variable on themselves to TRUE when failing all other objectives. Also stops admins from unintentionally bugging the final objective by failing/succeeding it whilst it is taken. Closes #74929 ## Why It's Good For The Game Bugfix ## Changelog 🆑 fix: Fixed final objectives appearing as 'Skipped' in the traitor panel. /🆑 Co-authored-by: Watermelon914 <3052169-Watermelon914@ users.noreply.gitlab.com> * Fixed final objectives appearing as skipped in the traitor panel --------- Co-authored-by: Watermelon914 <37270891+Watermelon914@users.noreply.github.com> Co-authored-by: Watermelon914 <3052169-Watermelon914@ users.noreply.gitlab.com>
This commit is contained in:
@@ -106,7 +106,7 @@
|
||||
else
|
||||
string += ", [to_display.telecrystal_reward] TC"
|
||||
string += ", [to_display.progression_reward] PR"
|
||||
if(to_display.objective_state == OBJECTIVE_STATE_ACTIVE)
|
||||
if(to_display.objective_state == OBJECTIVE_STATE_ACTIVE && !istype(to_display, /datum/traitor_objective/ultimate))
|
||||
string += " <a href='?src=[REF(owner)];fail_objective=[REF(to_display)]'>Fail this objective</a>"
|
||||
string += " <a href='?src=[REF(owner)];succeed_objective=[REF(to_display)]'>Succeed this objective</a>"
|
||||
if(to_display.objective_state == OBJECTIVE_STATE_INACTIVE)
|
||||
|
||||
@@ -31,6 +31,8 @@
|
||||
. = ..()
|
||||
handler.maximum_potential_objectives = 0
|
||||
for(var/datum/traitor_objective/objective as anything in handler.potential_objectives)
|
||||
if(objective == src)
|
||||
continue
|
||||
objective.fail_objective()
|
||||
user.playsound_local(get_turf(user), 'sound/traitor/final_objective.ogg', vol = 100, vary = FALSE, channel = CHANNEL_TRAITOR)
|
||||
handler.final_objective = name
|
||||
|
||||
Reference in New Issue
Block a user