Create
Return to post

Comparing difference between and

View raw
  • settings
  • {
  • main
  • {
  • Description: "> Scoreboard by Caldoran (v8.2) > Interact + Space (Default: F + Space) to toggle scoreboard on/off as a player > Modify FOV + Disable Camera Blending (Default: Z + B) to toggle scoreboard on/off as Spectator (must be Host) > Check Workshop Settings page for easy configuration > Go to the Rule named Text Configuration to edit text displays"
  • Description: "▩▩▩▩▩▩▩▩▩▩▩▩▩▩▩▩▩▩▩▩▩▩ ▩▩▩▩ Scoreboard v8.20 ▩▩▩▩ ▩▩ workshop.codes/scoreboard ▩▩ ▩▩ Configure in Workshop Settings ▩▩ ▩▩Change text in Text Configuration ▩▩ ▩▩▩▩▩▩▩▩▩▩▩▩▩▩▩▩▩▩▩▩▩▩"
  • }
  • lobby
  • {
  • Map Rotation: After A Game
  • Max Spectators: 12
  • Pause Game On Player Disconnect: Yes
  • Return To Lobby: After A Game
  • }
  • modes
  • {
  • Assault
  • Control
  • {
  • Score To Win: 3
  • }
  • Escort
  • Hybrid
  • General
  • {
  • Competitive Rules: On
  • Kill Cam: Off
  • Limit Roles: 2 Of Each Role Per Team
  • }
  • }
  • }
  • variables
  • {
  • global:
  • 0: EnablePlayerToggle
  • 1: DisplayTeamNames
  • 2: DisplayPlayerTogglePrompt
  • 3: DisplayTitleMessage
  • 4: DisplayScoreboardLegend
  • 5: DisplayHeroSwaps
  • 6: DisplayTeamTotals
  • 7: DisplayPlayerNames
  • 8: DisplayOnFire
  • 9: TimeToDisplayNotices
  • 10: hudHideScoreboard
  • 11: redKills
  • 12: redDamage
  • 13: redHealing
  • 14: blueKills
  • 15: blueDamage
  • 16: blueHealing
  • 17: EnableDebugMode
  • 18: welcomePrompt
  • 19: togglePrompt
  • 20: gameIsInSetup
  • 21: gameNoticeArray
  • 22: tLegendTitle
  • 23: tLegendText
  • 24: tPlayerTogglePrompt
  • 25: tGameTitle
  • 26: gameNoticeTimerArray
  • player:
  • 0: playerName
  • 1: eliminations
  • 2: currentHero
  • 3: finalBlows
  • 4: deaths
  • 5: damageDealt
  • 6: damageTaken
  • 7: healingDone
  • 8: healingTaken
  • 9: hudTextNormal
  • 10: hudTextSetup
  • 11: displayScoreboard
  • }
  • rule("Parameter Configuration")
  • {
  • event
  • {
  • Ongoing - Global;
  • }
  • actions
  • {
  • Global.EnablePlayerToggle = Workshop Setting Toggle(Custom String("Player Options"), Custom String(
  • "Allow players to toggle the scoreboard on/off"), True, 0);
  • Global.DisplayScoreboardLegend = Workshop Setting Toggle(Custom String("Text Display Options"), Custom String(
  • "Display Scoreboard Legend"), True, 0);
  • Global.DisplayTitleMessage = Workshop Setting Toggle(Custom String("Text Display Options"), Custom String("Display Title Message"),
  • True, 0);
  • Global.DisplayPlayerTogglePrompt = Workshop Setting Toggle(Custom String("Text Display Options"), Custom String(
  • "Display Player Toggle Prompt"), True, 0);
  • Global.DisplayPlayerNames = Workshop Setting Toggle(Custom String("Scoreboard Display Options"), Custom String(
  • "Display Player Names"), True, 0);
  • Global.DisplayOnFire = Workshop Setting Toggle(Custom String("Scoreboard Display Options"), Custom String(
  • "Display Player on Fire Status"), True, 0);
  • Global.DisplayTeamNames = Workshop Setting Toggle(Custom String("Scoreboard Display Options"), Custom String("Display Team Names"),
  • True, 0);
  • Global.DisplayTeamTotals = Workshop Setting Toggle(Custom String("Scoreboard Display Options"), Custom String(
  • "Display Team Stat Totals"), True, 0);
  • Global.DisplayHeroSwaps = Workshop Setting Toggle(Custom String("Extra Display Options"), Custom String("Display Hero Swaps"),
  • True, 0);
  • Global.TimeToDisplayNotices = Workshop Setting Integer(Custom String("Extra Display Options"), Custom String(
  • "Time to Display Hero Swaps (Seconds)"), 3, 1, 10, 0);
  • Global.EnableDebugMode = Workshop Setting Toggle(Custom String("Debug Options"), Custom String("Enable Debug Mode"), False, 0);
  • Global.gameNoticeArray = Empty Array;
  • Global.gameNoticeTimerArray = Empty Array;
  • If(Global.EnableDebugMode != True);
  • Disable Inspector Recording;
  • End;
  • }
  • }
  • rule("Text Configuration")
  • {
  • event
  • {
  • Ongoing - Global;
  • }
  • actions
  • {
  • Global.tLegendTitle = Custom String("Scoreboard");
  • Global.tLegendText = Custom String("K / A / D / DMG / DMG (T) / HP / HP (T)");
  • Global.tGameTitle = Custom String("Tournament X");
  • Global.tPlayerTogglePrompt = Custom String("Press Interact + Jump to toggle the Scoreboard on and off");
  • }
  • }
  • rule("Player Setup")
  • {
  • event
  • {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • actions
  • {
  • Event Player.currentHero = Null;
  • }
  • }
  • rule("Create Title and Scoreboard Prompt")
  • {
  • event
  • {
  • Ongoing - Global;
  • }
  • conditions
  • {
  • Is In Setup == True;
  • }
  • actions
  • {
  • If(Global.DisplayTitleMessage == True);
  • Create HUD Text(All Players(All Teams), Null, Null, Global.tGameTitle, Top, 1, Color(White), Color(White), Color(Yellow), None,
  • Visible Always);
  • Global.welcomePrompt = Last Text ID;
  • End;
  • If(Global.EnablePlayerToggle == True && Global.DisplayPlayerTogglePrompt == True);
  • Create HUD Text(All Players(All Teams), Null, Null, Global.tPlayerTogglePrompt, Top, 2, Color(White), Color(White), Color(White),
  • None, Visible Never);
  • Global.togglePrompt = Last Text ID;
  • End;
  • Wait(Match Time, Ignore Condition);
  • Destroy HUD Text(Global.welcomePrompt);
  • Destroy HUD Text(Global.togglePrompt);
  • }
  • }
  • rule("Create Scoreboard Legend")
  • {
  • event
  • {
  • Ongoing - Global;
  • }
  • actions
  • {
  • If(Global.DisplayScoreboardLegend == True);
  • Create HUD Text(Filtered Array(All Players(All Teams), Current Array Element.displayScoreboard == True), Null, Global.tLegendTitle,
  • Null, Left, 0, Color(White), Color(Yellow), Color(Yellow), Visible To, Visible Always);
  • Create HUD Text(Filtered Array(All Players(All Teams), Current Array Element.displayScoreboard == True), Null, Global.tLegendText,
  • Null, Left, 0.500, Color(Blue), Color(White), Color(White), Visible To, Visible Always);
  • End;
  • }
  • }
  • rule("Create Team Names and Team Totals")
  • {
  • event
  • {
  • Ongoing - Global;
  • }
  • actions
  • {
  • If(Global.DisplayTeamNames == True);
  • Create HUD Text(Filtered Array(All Players(All Teams), Current Array Element.displayScoreboard == True), Team 1, Null, Null, Left,
  • 1, Color(Blue), Color(White), Color(White), Visible To, Visible Always);
  • Create HUD Text(Filtered Array(All Players(All Teams), Current Array Element.displayScoreboard == True), Team 2, Null, Null, Left,
  • 8, Color(Red), Color(White), Color(White), Visible To, Visible Always);
  • If(Global.DisplayTeamTotals == True);
  • Create HUD Text(Filtered Array(All Players(All Teams), Current Array Element.displayScoreboard == True), Null, Custom String(
  • "Total: {0} / {1} / {2}", Custom String("{0} Kills", Global.blueKills), Custom String("{0} Damage", Round To Integer(
  • Global.blueDamage, To Nearest)), Custom String("{0} Healing", Round To Integer(Global.blueHealing, To Nearest))), Null, Left,
  • 1.500, Color(White), Color(White), Color(White), Visible To and String, Visible Always);
  • Create HUD Text(Filtered Array(All Players(All Teams), Current Array Element.displayScoreboard == True), Null, Custom String(
  • "Total: {0} / {1} / {2}", Custom String("{0} Kills", Global.redKills), Custom String("{0} Damage", Round To Integer(
  • Global.redDamage, To Nearest)), Custom String("{0} Healing", Round To Integer(Global.redHealing, To Nearest))), Null, Left,
  • 8.500, Color(White), Color(White), Color(White), Visible To and String, Visible Always);
  • End;
  • End;
  • }
  • }
  • rule("Create Player Scoreboard")
  • {
  • event
  • {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • actions
  • {
  • If(Global.DisplayPlayerNames == True);
  • Event Player.playerName = Event Player;
  • Else;
  • Event Player.playerName = Empty Array;
  • End;
  • If(Global.EnablePlayerToggle == True);
  • Create HUD Text(Filtered Array(All Players(All Teams),
  • Global.gameIsInSetup == True && Current Array Element.displayScoreboard == True), Custom String(" "),
  • Event Player.playerName, Custom String("{0} / {1} / {2}", Custom String("{0} / {1} / {2}", Event Player.finalBlows,
  • Event Player.eliminations - Event Player.finalBlows, Event Player.deaths), Custom String("{0} / {1}", Round To Integer(
  • Event Player.damageDealt, To Nearest), Round To Integer(Event Player.damageTaken, Up)), Custom String("{0} / {1}",
  • Round To Integer(Event Player.healingDone, To Nearest), Round To Integer(Event Player.healingTaken, To Nearest))), Left,
  • Slot Of(Event Player) + (Team Of(Event Player) == Team 1 ? 2 : 9), Team Of(Event Player) == Team 1 ? Color(Blue) : Color(Red),
  • Color(Yellow), Color(White), Visible To and String, Visible Never);
  • Event Player.hudTextSetup = Last Text ID;
  • End;
  • Create HUD Text(Filtered Array(All Players(All Teams),
  • Global.gameIsInSetup == False && Current Array Element.displayScoreboard == True), Hero Icon String(Hero Of(Event Player)),
  • Event Player.playerName, Custom String("{0} / {1} / {2}", Custom String("{0} / {1} / {2}", Event Player.finalBlows,
  • Event Player.eliminations - Event Player.finalBlows, Event Player.deaths), Custom String("{0} / {1}", Round To Integer(
  • Event Player.damageDealt, To Nearest), Round To Integer(Event Player.damageTaken, Up)), Custom String("{0} / {1}",
  • Round To Integer(Event Player.healingDone, To Nearest), Round To Integer(Event Player.healingTaken, To Nearest))), Left,
  • Slot Of(Event Player) + (Team Of(Event Player) == Team 1 ? 2 : 9), Team Of(Event Player) == Team 1 ? Color(Blue) : Color(Red),
  • Color(Yellow), Color(White), Visible To and String, Visible Always);
  • Event Player.hudTextNormal = Last Text ID;
  • }
  • }
  • rule("Player Toggle Scoreboard")
  • {
  • event
  • {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions
  • {
  • Is Button Held(Event Player, Button(Interact)) == True;
  • Is Button Held(Event Player, Button(Jump)) == True;
  • Global.EnablePlayerToggle == True;
  • }
  • actions
  • {
  • Event Player.displayScoreboard = Event Player.displayScoreboard ? False : True;
  • Small Message(Event Player, Custom String("Scoreboard {0}", Event Player.displayScoreboard ? Custom String("On") : Custom String(
  • "Off")));
  • Play Effect(Event Player, Ring Explosion Sound, Color(White), Event Player, 100);
  • Wait Until(!Is Button Held(Event Player, Button(Interact)), 99999);
  • }
  • }
  • rule("Host Spectator Toggle Scoreboard")
  • {
  • event
  • {
  • Ongoing - Global;
  • }
  • conditions
  • {
  • Team Of(Host Player) == All Teams;
  • Is Button Held(Host Player, Button(Ultimate)) == True;
  • Is Button Held(Host Player, Button(Jump)) == True;
  • }
  • actions
  • {
  • If(Global.hudHideScoreboard == Null);
  • Small Message(All Players(All Teams), Custom String("Host Toggled Scoreboard Off"));
  • Create HUD Text(Host Player, Null, Null, Custom String(
  • " \n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n"),
  • Left, 0, Color(White), Color(White), Color(White), Visible To and String, Visible Always);
  • Global.hudHideScoreboard = Last Text ID;
  • Else;
  • Small Message(All Players(All Teams), Custom String("Host Toggled Scoreboard On"));
  • Destroy HUD Text(Global.hudHideScoreboard);
  • Global.hudHideScoreboard = Null;
  • End;
  • Wait Until(Is Button Held(Host Player, Button(Ultimate)), 99999);
  • }
  • }
  • rule("Auto Toggle Scoreboard (Hide Heroes)")
  • {
  • event
  • {
  • Ongoing - Global;
  • }
  • conditions
  • {
  • Is In Setup == True;
  • Global.EnablePlayerToggle == True;
  • }
  • actions
  • {
  • Global.gameIsInSetup = True;
  • Wait(15 + Match Time, Ignore Condition);
  • Global.gameIsInSetup = False;
  • }
  • }
  • rule("Add Final Blows")
  • {
  • event
  • {
  • Player Dealt Final Blow;
  • All;
  • All;
  • }
  • conditions
  • {
  • Is Game In Progress == True;
  • }
  • actions
  • {
  • Event Player.finalBlows += 1;
  • If(Team Of(Event Player) == Team 1);
  • Global.blueKills += 1;
  • Else;
  • Global.redKills += 1;
  • End;
  • }
  • }
  • rule("Add Eliminations")
  • {
  • event
  • {
  • Player Earned Elimination;
  • All;
  • All;
  • }
  • conditions
  • {
  • Is Game In Progress == True;
  • }
  • actions
  • {
  • Event Player.eliminations += 1;
  • }
  • }
  • rule("Add Deaths")
  • {
  • event
  • {
  • Player Died;
  • All;
  • All;
  • }
  • conditions
  • {
  • Is Game In Progress == True;
  • }
  • actions
  • {
  • Event Player.deaths += 1;
  • }
  • }
  • rule("Add Damage Dealt / Damage Received")
  • {
  • event
  • {
  • Player Dealt Damage;
  • All;
  • All;
  • }
  • conditions
  • {
  • Attacker != Victim;
  • Is Game In Progress == True;
  • }
  • actions
  • {
  • Attacker.damageDealt += Event Damage;
  • Victim.damageTaken += Event Damage;
  • If(Team Of(Event Player) == Team 1);
  • Global.blueDamage += Event Damage;
  • Else;
  • Global.redDamage += Event Damage;
  • End;
  • }
  • }
  • rule("Add Healing Dealt and Healing Received")
  • {
  • event
  • {
  • Player Dealt Healing;
  • All;
  • All;
  • }
  • conditions
  • {
  • Healer != Healee;
  • Is Game In Progress == True;
  • }
  • actions
  • {
  • Healer.healingDone += Event Healing;
  • Healee.healingTaken += Event Healing;
  • If(Team Of(Event Player) == Team 1);
  • Global.blueHealing += Event Healing;
  • Else;
  • Global.redHealing += Event Healing;
  • End;
  • }
  • }
  • rule("On Fire Notice (On)")
  • {
  • event
  • {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions
  • {
  • Is Portrait On Fire(Event Player) == True;
  • Global.DisplayPlayerNames == True;
  • Global.DisplayOnFire == True;
  • }
  • actions
  • {
  • Event Player.playerName = Custom String("{0} {1}", Event Player, Icon String(Fire));
  • }
  • }
  • rule("On Fire Notice (Off)")
  • {
  • event
  • {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions
  • {
  • Is Portrait On Fire(Event Player) == False;
  • Global.DisplayPlayerNames == True;
  • Global.DisplayOnFire == True;
  • }
  • actions
  • {
  • Event Player.playerName = Event Player;
  • }
  • }
  • rule("Create Hero Swap Notice")
  • {
  • event
  • {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions
  • {
  • Global.DisplayHeroSwaps == True;
  • Hero Of(Event Player) != Event Player.currentHero;
  • Array Contains(All Heroes, Hero Of(Event Player)) == True;
  • }
  • actions
  • {
  • If(Event Player.currentHero != Null);
  • If(Team Of(Event Player) == Team 1);
  • Create HUD Text(Null, Null, Null, String("{0} {1}", Event Player, String("{0} {1} {2}", Hero Icon String(Event Player.currentHero),
  • Icon String(Recycle), Hero Icon String(Hero Of(Event Player)))), Top, 10, Color(White), Color(White), Color(Blue), None,
  • Visible Always);
  • Else;
  • Create HUD Text(Null, Null, Null, String("{0} {1}", Event Player, String("{0} {1} {2}", Hero Icon String(Event Player.currentHero),
  • Icon String(Recycle), Hero Icon String(Hero Of(Event Player)))), Top, 10, Color(White), Color(White), Color(Red), None,
  • Visible Always);
  • End;
  • Modify Global Variable(gameNoticeArray, Append To Array, Last Text ID);
  • Modify Global Variable(gameNoticeTimerArray, Append To Array, Round To Integer(Total Time Elapsed, Up)
  • + Global.TimeToDisplayNotices);
  • End;
  • Wait(0.016, Ignore Condition);
  • Event Player.currentHero = Hero Of(Event Player);
  • }
  • }
  • rule("Clear Game Notices")
  • {
  • event
  • {
  • Ongoing - Global;
  • }
  • conditions
  • {
  • Array Contains(Global.gameNoticeTimerArray, Round To Integer(Total Time Elapsed, Up)) == True;
  • }
  • actions
  • {
  • While(Count Of(Filtered Array(Global.gameNoticeTimerArray, Round To Integer(Total Time Elapsed, Up) == Current Array Element))
  • == True);
  • Destroy HUD Text(Global.gameNoticeArray[0]);
  • Modify Global Variable(gameNoticeArray, Remove From Array By Index, 0);
  • Modify Global Variable(gameNoticeTimerArray, Remove From Array By Index, 0);
  • End;
  • }
  • }
  • rule("Debug Messages")
  • {
  • event
  • {
  • Ongoing - Global;
  • }
  • actions
  • {
  • If(Global.EnableDebugMode == True);
  • Create HUD Text(All Players(All Teams), Server Load, Custom String("Server Load"), Null, Left, 999, Color(White), Color(White),
  • Color(White), Visible To and String, Default Visibility);
  • Create HUD Text(All Players(All Teams), Server Load Average, Custom String("Server Load Average"), Null, Left, 999, Color(White),
  • Color(White), Color(White), Visible To and String, Default Visibility);
  • Create HUD Text(All Players(All Teams), Server Load Peak, Custom String("Server Load Peak"), Null, Left, 999, Color(White), Color(
  • White), Color(White), Visible To and String, Default Visibility);
  • End;
  • }
  • }
  • rule("Debug Hero Swap Test")
  • {
  • event
  • {
  • Player Dealt Damage;
  • All;
  • All;
  • }
  • conditions
  • {
  • Global.EnableDebugMode == True;
  • }
  • actions
  • {
  • Start Forcing Player To Be Hero(Attacker, Random Value In Array(All Heroes));
  • }
  • }
Join the Workshop.codes Discord