mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-30 16:47:13 +01:00
Updates the Mafia UI (#79856)
## About The Pull Request The player currently on the stand has a yellow color behind their name. Players who have had their roles revealed now has that stated in the player list Votes no longer show up to people who are on trial  Minor edit: It no longer says 'ON STAND', it instead has their name in yellow background  ## Why It's Good For The Game Mafia UI's a little better now. ## Changelog 🆑 qol: Mafia panel no longer shows vote buttons if you're on stand, shows the roles of revealed players, and list out who is on the stand, if any. /🆑 --------- Co-authored-by: Jeremiah <42397676+jlsnow301@users.noreply.github.com>
This commit is contained in:
@@ -29,6 +29,8 @@
|
||||
if(turn)
|
||||
data["turn"] = " - Day [turn]"
|
||||
|
||||
if(phase == MAFIA_PHASE_JUDGEMENT)
|
||||
data["person_voted_up_ref"] = REF(on_trial)
|
||||
if(phase == MAFIA_PHASE_SETUP)
|
||||
data["lobbydata"] = list()
|
||||
for(var/key in GLOB.mafia_signup + GLOB.mafia_bad_signup + GLOB.pda_mafia_signup)
|
||||
@@ -41,8 +43,10 @@
|
||||
data["timeleft"] = next_phase_timer ? timeleft(next_phase_timer) : 0
|
||||
|
||||
var/datum/mafia_role/user_role = get_role_player(user)
|
||||
|
||||
if(user_role)
|
||||
data["user_notes"] = user_role.written_notes
|
||||
data["player_voted_up"] = (user_role == on_trial)
|
||||
var/list/ui_messages = list()
|
||||
for(var/i = user_role.role_messages.len to 1 step -1)
|
||||
ui_messages.Add(list(list(
|
||||
@@ -56,6 +60,9 @@
|
||||
player_info["name"] = role.body.real_name
|
||||
player_info["ref"] = REF(role)
|
||||
player_info["alive"] = role.game_status == MAFIA_ALIVE
|
||||
player_info["role_revealed"] = FALSE
|
||||
if(role.role_flags & ROLE_REVEALED)
|
||||
player_info["role_revealed"] = role.name
|
||||
player_info["possible_actions"] = list()
|
||||
|
||||
if(user_role) //not observer
|
||||
|
||||
Reference in New Issue
Block a user