Create
Return to post

Comparing difference between and

View raw
  • settings
  • {
  • main
  • {
  • Description: "The classic Hide & Seek game has returned as a new and improved workshop gamemode! A new additional level of customization is offered to hosts through Workshop Settings; make everyone small, change the time for each phase, or even how the game plays with different game styles\n[Created by CaptCaptain#11421] [For the latest code, visit: https://workshop.codes/hide-and-seek-ult]"
  • }
  • lobby
  • {
  • Match Voice Chat: Enabled
  • Max Spectators: 12
  • Map Rotation: After A Game
  • Return To Lobby: Never
  • Team Balancing: After A Game
  • Max Team 1 Players: 9
  • Max Team 2 Players: 3
  • }
  • modes
  • {
  • Skirmish
  • {
  • disabled maps
  • {
  • Workshop Island
  • Workshop Island Night
  • Workshop Chamber
  • Workshop Green Screen
  • Workshop Expanse
  • Workshop Expanse Night
  • }
  • }
  • Team Deathmatch
  • {
  • enabled maps
  • {
  • Castillo
  • Château Guillard
  • Kanezaka
  • Ecopoint: Antarctica
  • Ecopoint: Antarctica Winter
  • Necropolis
  • Petra
  • Black Forest
  • Black Forest Winter
  • }
  • }
  • Capture The Flag
  • {
  • enabled maps
  • {
  • Ayutthaya
  • Busan Downtown Lunar New Year
  • Busan Sanctuary Lunar New Year
  • }
  • }
  • General
  • {
  • Hero Limit: Off
  • Respawn As Random Hero: Off
  • Spawn Health Packs: Disabled
  • Game Mode Start: Immediately
  • Flag Pickup Time: 5
  • }
  • }
  • heroes
  • {
  • General
  • {
  • Ultimate Ability: Off
  • Ultimate Generation - Combat: 0%
  • Ultimate Generation - Passive: 0%
  • D.Va
  • {
  • Spawn With Ultimate Ready: On
  • }
  • }
  • Team 2
  • {
  • Ability Cooldown Time: 50%
  • }
  • }
  • }
  • variables {
  • global:
  • 0: practiceRangeTranslations
  • 1: CURRENT_VERSION
  • 2: WS_SET_USEOUTLINE
  • 3: WS_SET_HIDETIME_RAW
  • 4: WS_SET_HIDETIME
  • 5: WS_SET_SEEKTIME_RAW
  • 6: WS_SET_SEEKTIME
  • 7: WS_SET_MODE_RAW
  • 8: WS_SET_MODE
  • 9: WS_SET_REQUIRED_RATIO
  • 10: WS_SET_REQUIRED_HIDERS
  • 11: WS_SET_WAITING_MAXTIME_RAW
  • 12: WS_SET_WAITING_MAXTIME
  • 13: WS_SET_SLOWHIDER
  • 14: WS_SET_SEEKER_OUTLINES_RAW
  • 15: WS_SET_SEEKER_OUTLINES
  • 16: WS_SET_SHOW_HIDERS_RAW
  • 17: WS_SET_SHOW_HIDERS
  • 18: WS_SET_END_RAW
  • 19: WS_SET_END
  • 20: WS_SET_3RD_CAM_RAW
  • 21: WS_SET_3RD_CAM
  • 22: WS_SET_SEEKER_ASSIST
  • 23: WS_SET_LAYING_DOWN
  • 24: WS_SET_USE_SLINGSHOT
  • 25: WS_SET_ADV_DVA_MECH_RAW
  • 26: WS_SET_ADV_DVA_MECH
  • 27: WS_SET_ADV_INF_HAMMOND_GRAPPLE
  • 28: WS_SET_ADV_TANKSCALING_RAW
  • 29: WS_SET_ADV_TANKSCALING
  • 30: WS_SET_ADV_WINS_RAW
  • 31: WS_SET_ADV_WINS
  • 32: WS_SET_ADV_SCALE
  • 33: WS_SET_ADV_SEEK_ALLOWH
  • 34: WS_SET_ADV_BASESPEED
  • 35: WS_SET_ADV_DEBUGSTATS_RAW
  • 36: WS_SET_ADV_DEBUGSTATS
  • 37: CurrentGameState
  • 38: CurrentTime
  • 39: CurrentRound
  • 40: HiderTeamScore
  • 41: SeekerTeamScore
  • 42: LastHiderHud
  • 43: playerIndex
  • 44: globalHudIndex
  • 45: Hud_GameInfo
  • 46: Hud_GameTitle
  • 47: Hud_Seeker_Blindness
  • player:
  • 0: ShowHiders
  • 1: JoinedLate
  • 2: playerHudIndex
  • 3: playerIndex
  • 4: Hud_Player
  • 5: BaseMoveSpeed
  • 6: BaseJumpHeight
  • 7: BaseScaling
  • 8: HiderSlowFactor
  • 9: DvaMechPosition
  • 10: DvaHasTeleported
  • 11: LastWalkablePosition
  • 12: ResurrectBlocked
  • 13: CameraState
  • 14: ThirdPersonCameraEnabled
  • 15: LayingDownCameraEnabled
  • 16: SlingshotPosition
  • 17: SlingshotEnabled
  • 18: SlingshotUsed
  • 19: Hud_Slingshot
  • 20: PreviousPosition
  • 21: Hud_Detection
  • 22: Hud_InSpawn
  • 23: Huds_JoinedLate
  • 24: Effects_SombraInvis
  • 25: Hud_SombraTrans
  • 26: Hud_Seeker_Name
  • 27: Hud_Seeker_Assistance
  • 28: Effect_Seeker_Blindness
  • }
  • subroutines {
  • 0: PLAYSOUND_DEBUFF
  • 1: PLAYSOUND_RINGEXPLOSION
  • 2: PLAYSOUND_BUFF
  • 3: StartThirdPersonCamera
  • 4: StartCamera
  • 5: SlingshotCooldown
  • 6: RestrictAbilities
  • }
  • rule ("Initialize global variables") {
  • event {
  • Ongoing - Global;
  • }
  • actions {
  • Set Global Variable(practiceRangeTranslations, Array(Custom String("Practice Range", Null, Null, Null)));
  • Set Global Variable(CURRENT_VERSION, Custom String("2.1.0", Null, Null, Null));
  • Set Global Variable(WS_SET_USEOUTLINE, Workshop Setting Toggle(Custom String("Ruleset", Null, Null, Null), Custom String("Hider Outlines", Null, Null, Null), False, 4));
  • Set Global Variable(WS_SET_HIDETIME_RAW, Workshop Setting Combo(Custom String("Ruleset", Null, Null, Null), Custom String("Time Limit󠀺 Hiding", Null, Null, Null), 1, Array(Custom String("1󠀺30", Null, Null, Null), Custom String("1󠀺00", Null, Null, Null), Custom String("0󠀺45", Null, Null, Null)), 2));
  • Set Global Variable(WS_SET_HIDETIME, Value In Array(Array(90, 60, 45), Global.WS_SET_HIDETIME_RAW));
  • Set Global Variable(WS_SET_SEEKTIME_RAW, Workshop Setting Combo(Custom String("Ruleset", Null, Null, Null), Custom String("Time Limit󠀺 Seeking", Null, Null, Null), 2, Array(Custom String("5󠀺00", Null, Null, Null), Custom String("4󠀺30", Null, Null, Null), Custom String("4󠀺00", Null, Null, Null), Custom String("3󠀺30", Null, Null, Null), Custom String("3󠀺00", Null, Null, Null), Custom String("2󠀺30", Null, Null, Null), Custom String("2󠀺00", Null, Null, Null)), 2));
  • Set Global Variable(WS_SET_SEEKTIME, Value In Array(Array(300, 270, 240, 210, 180, 150, 120), Global.WS_SET_SEEKTIME_RAW));
  • Set Global Variable(WS_SET_MODE_RAW, Workshop Setting Combo(Custom String("Ruleset", Null, Null, Null), Custom String("Style", Null, Null, Null), 0, Array(Custom String("Default", Null, Null, Null), Custom String("Glitch (Noclip)", Null, Null, Null), Custom String("TINY", Null, Null, Null), Custom String("Mercy V. Reinhardt", Null, Null, Null)), 0));
  • Set Global Variable(WS_SET_MODE, Value In Array(Array(0, 4, 5, 3), Global.WS_SET_MODE_RAW));
  • Set Global Variable(WS_SET_REQUIRED_RATIO, Workshop Setting Combo(Custom String("Ruleset", Null, Null, Null), Custom String("Required Seeker to Hider Ratio", Null, Null, Null), 0, Array(Custom String("1󠀺3", Null, Null, Null), Custom String("1󠀺2", Null, Null, Null), Custom String("1󠀺1", Null, Null, Null)), 3));
  • Set Global Variable(WS_SET_REQUIRED_HIDERS, Value In Array(Array(3, 2, 1), Global.WS_SET_REQUIRED_RATIO));
  • Set Global Variable(WS_SET_WAITING_MAXTIME_RAW, Workshop Setting Combo(Custom String("Ruleset", Null, Null, Null), Custom String("Game Mode Start", Null, Null, Null), 1, Array(Custom String("IMMEDIATELY", Null, Null, Null), Custom String("Wait For Players (Timeout)", Null, Null, Null), Custom String("Wait For Players (No Timeout)", Null, Null, Null)), 1));
  • Set Global Variable(WS_SET_WAITING_MAXTIME, Value In Array(Array(0, 5, 9999), Global.WS_SET_WAITING_MAXTIME_RAW));
  • Set Global Variable(WS_SET_SLOWHIDER, Workshop Setting Toggle(Custom String("Ruleset", Null, Null, Null), Custom String("Slow Hider When In Line Of Sight Of Seeker", Null, Null, Null), True, 4));
  • Set Global Variable(WS_SET_SEEKER_OUTLINES_RAW, Workshop Setting Combo(Custom String("Ruleset", Null, Null, Null), Custom String("Seeker Outlines", Null, Null, Null), 0, Array(Custom String("Default", Null, Null, Null), Custom String("Occluded", Null, Null, Null), Custom String("Always", Null, Null, Null)), 4));
  • Set Global Variable(WS_SET_SEEKER_OUTLINES, Value In Array(Array(11, 12, 13), Global.WS_SET_SEEKER_OUTLINES_RAW));
  • Set Global Variable(WS_SET_SHOW_HIDERS_RAW, Workshop Setting Combo(Custom String("Ruleset", Null, Null, Null), Custom String("Show Remaining Hiders When Round Ends", Null, Null, Null), 2, Array(Custom String("Last Hider Only", Null, Null, Null), Custom String("On", Null, Null, Null), Custom String("Off", Null, Null, Null)), 5));
  • Set Global Variable(WS_SET_SHOW_HIDERS, Value In Array(Array(0, 1, 2), Global.WS_SET_SHOW_HIDERS_RAW));
  • Set Global Variable(WS_SET_END_RAW, Workshop Setting Combo(Custom String("Ruleset", Null, Null, Null), Custom String("WHEN MATCH IS COMPLETE (SKIRMISH)", Null, Null, Null), 0, Array(Custom String("SKIP END GAME SCREEN", Null, Null, Null), Custom String("SKIP POTG", Null, Null, Null), Custom String("DO NOTHING", Null, Null, Null)), 7));
  • Set Global Variable(WS_SET_END, Value In Array(Array(25.9, 8, 9999), Global.WS_SET_END_RAW));
  • Set Global Variable(WS_SET_3RD_CAM_RAW, Workshop Setting Combo(Custom String("Accessibility Settings", Null, Null, Null), Custom String("Camera Mode", Null, Null, Null), 0, Array(Custom String("First Person", Null, Null, Null), Custom String("Third Person", Null, Null, Null), Custom String("Toggle", Null, Null, Null)), 6));
  • Set Global Variable(WS_SET_3RD_CAM, Value In Array(Array(7, 6, 8), Global.WS_SET_3RD_CAM_RAW));
  • Set Global Variable(WS_SET_SEEKER_ASSIST, Workshop Setting Toggle(Custom String("Accessibility Settings", Null, Null, Null), Custom String("Seeker Assistance", Null, Null, Null), False, 5));
  • Set Global Variable(WS_SET_LAYING_DOWN, Workshop Setting Toggle(Custom String("Accessibility Settings", Null, Null, Null), Custom String("Allow Hiders to Lay Down", Null, Null, Null), False, 5));
  • Set Global Variable(WS_SET_USE_SLINGSHOT, Workshop Setting Toggle(Custom String("Accessibility Settings", Null, Null, Null), Custom String("Allow Slingshot Tool", Null, Null, Null), False, 5));
  • Set Global Variable(WS_SET_ADV_DVA_MECH_RAW, Workshop Setting Combo(Custom String("Accessibility Settings", Null, Null, Null), Custom String("D.va Player Accessibility", Null, Null, Null), 1, Array(Custom String("Allow De-mech Only", Null, Null, Null), Custom String("Allow Re-mech and De-mech", Null, Null, Null), Custom String("Off", Null, Null, Null)), 2));
  • Set Global Variable(WS_SET_ADV_DVA_MECH, Value In Array(Array(1, 0, 2), Global.WS_SET_ADV_DVA_MECH_RAW));
  • Set Global Variable(WS_SET_ADV_INF_HAMMOND_GRAPPLE, Workshop Setting Toggle(Custom String("Accessibility Settings", Null, Null, Null), Custom String("Wrecking Ball Hider Accessibility󠀺 Infinite Grapple", Null, Null, Null), False, 2));
  • Set Global Variable(WS_SET_ADV_TANKSCALING_RAW, Workshop Setting Combo(Custom String("Accessibility Settings", Null, Null, Null), Custom String("Tank Hider Accessibility", Null, Null, Null), 2, Array(Custom String("Scale Down All Tanks", Null, Null, Null), Custom String("Scale Down Tanks Automatically", Null, Null, Null), Custom String("Off", Null, Null, Null)), 2));
  • Set Global Variable(WS_SET_ADV_TANKSCALING, Value In Array(Array(3, 4, 5), Global.WS_SET_ADV_TANKSCALING_RAW));
  • Set Global Variable(WS_SET_ADV_WINS_RAW, Workshop Setting Combo(Custom String("Advanced Settings", Null, Null, Null), Custom String("FIRST TEAM TO", Null, Null, Null), 0, Array(Custom String("1 win", Null, Null, Null), Custom String("2 wins", Null, Null, Null), Custom String("3 wins", Null, Null, Null)), 0));
  • Set Global Variable(WS_SET_ADV_WINS, Value In Array(Array(1, 2, 3), Global.WS_SET_ADV_WINS_RAW));
  • Set Global Variable(WS_SET_ADV_SCALE, Workshop Setting Real(Custom String("Advanced Settings", Null, Null, Null), Custom String("Player Size Scalar", Null, Null, Null), 1, 0.1, 1, 0));
  • Set Global Variable(WS_SET_ADV_SEEK_ALLOWH, Workshop Setting Toggle(Custom String("Advanced Settings", Null, Null, Null), Custom String("Allow Restricted Seeker Heroes (Moira, Zenyatta, Sombra)", Null, Null, Null), False, 4));
  • Set Global Variable(WS_SET_ADV_BASESPEED, Workshop Setting Real(Custom String("Advanced Settings", Null, Null, Null), Custom String("Player Speed Scalar", Null, Null, Null), 1, 1, 5, 1));
  • Set Global Variable(WS_SET_ADV_DEBUGSTATS_RAW, Workshop Setting Combo(Custom String("Advanced Settings", Null, Null, Null), Custom String("Show Debug Stats", Null, Null, Null), 2, Array(Custom String("HOST ONLY", Null, Null, Null), Custom String("ALL PLAYERS", Null, Null, Null), Custom String("NONE", Null, Null, Null)), 6));
  • Set Global Variable(WS_SET_ADV_DEBUGSTATS, Value In Array(Array(1, 0, 2), Global.WS_SET_ADV_DEBUGSTATS_RAW));
  • Set Global Variable(CurrentGameState, 0);
  • Set Global Variable(CurrentTime, 1800);
  • Set Global Variable(CurrentRound, 0);
  • Set Global Variable(HiderTeamScore, 0);
  • Set Global Variable(SeekerTeamScore, 0);
  • Set Global Variable(globalHudIndex, 0);
  • }
  • }
  • rule ("Initialize player variables") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • actions {
  • Set Player Variable(Event Player, ShowHiders, False);
  • Set Player Variable(Event Player, playerHudIndex, 0);
  • Set Player Variable(Event Player, playerIndex, 0);
  • Set Player Variable(Event Player, BaseMoveSpeed, Multiply(100, Global.WS_SET_ADV_BASESPEED));
  • Set Player Variable(Event Player, BaseJumpHeight, Multiply(100, Global.WS_SET_ADV_BASESPEED));
  • Set Player Variable(Event Player, BaseScaling, Global.WS_SET_ADV_SCALE);
  • Set Player Variable(Event Player, HiderSlowFactor, 2);
  • Set Player Variable(Event Player, CameraState, If-Then-Else(Compare(Global.WS_SET_3RD_CAM, ==, 6), 2, 0));
  • Set Player Variable(Event Player, ThirdPersonCameraEnabled, If-Then-Else(Compare(Global.WS_SET_3RD_CAM, ==, 6), True, False));
  • Set Player Variable(Event Player, LayingDownCameraEnabled, False);
  • Set Player Variable(Event Player, SlingshotEnabled, False);
  • Set Player Variable(Event Player, SlingshotUsed, False);
  • Set Player Variable(Event Player, Hud_Slingshot, Empty Array);
  • }
  • }
  • rule ("____________Shared Rules") {
  • event {
  • Ongoing - Global;
  • }
  • }
  • rule ("Subroutine PLAYSOUND_RINGEXPLOSION") {
  • event {
  • Subroutine;
  • PLAYSOUND_RINGEXPLOSION;
  • }
  • actions {
  • For Global Variable(playerIndex, 0, Number Of Players(All Teams), 1);
  • Play Effect(Value In Array(All Players(All Teams), Global.playerIndex), Ring Explosion Sound, Color(White), Value In Array(All Players(All Teams), Global.playerIndex), 100);
  • End;
  • }
  • }
  • rule ("Subroutine PLAYSOUND_DEBUFF") {
  • event {
  • Subroutine;
  • PLAYSOUND_DEBUFF;
  • }
  • actions {
  • For Global Variable(playerIndex, 0, Number Of Players(All Teams), 1);
  • Play Effect(Value In Array(All Players(All Teams), Global.playerIndex), Debuff Impact Sound, Color(White), Value In Array(All Players(All Teams), Global.playerIndex), 100);
  • End;
  • }
  • }
  • rule ("Subroutine PLAYSOUND_BUFF") {
  • event {
  • Subroutine;
  • PLAYSOUND_BUFF;
  • }
  • actions {
  • For Global Variable(playerIndex, 0, Number Of Players(All Teams), 1);
  • Play Effect(Value In Array(All Players(All Teams), Global.playerIndex), Buff Explosion Sound, Color(White), Value In Array(All Players(All Teams), Global.playerIndex), 100);
  • End;
  • }
  • }
  • rule ("Disable Current Gamemode") {
  • event {
  • Ongoing - Global;
  • }
  • actions {
  • Pause Match Time;
  • Disable Built-In Game Mode Scoring;
  • Disable Built-In Game Mode Announcer;
  • Disable Built-In Game Mode Completion;
  • Disable Built-In Game Mode Scoring;
  • }
  • }
  • rule ("Waiting Phase") {
  • event {
  • Ongoing - Global;
  • }
  • conditions {
  • Global.CurrentGameState == 0;
  • Count Of(Filtered Array(All Players(Team 1), And(Has Spawned(Current Array Element), Not(Is In Spawn Room(Current Array Element))))) > 0;
  • Count Of(Filtered Array(All Players(Team 2), And(Has Spawned(Current Array Element), Not(Is In Spawn Room(Current Array Element))))) > 0;
  • }
  • actions {
  • Log To Inspector(Custom String("Game Phase: Waiting", Null, Null, Null));
  • "Wait until everyone spawns in"
  • Wait Until(Is True For All(All Players(All Teams), Has Spawned(Current Array Element)), Global.WS_SET_WAITING_MAXTIME);
  • "Wait until player count meets the required ratio of seekers to hiders"
  • Wait Until(And(Compare(Count Of(Filtered Array(All Players(Team 1), And(Has Spawned(Current Array Element), Not(Is Dummy Bot(Current Array Element))))), >=, Multiply(Global.WS_SET_REQUIRED_HIDERS, Number Of Living Players(Team 2))), Compare(Count Of(Filtered Array(All Players(Team 2), Has Spawned(Current Array Element))), >, 0)), Global.WS_SET_WAITING_MAXTIME);
  • Set Global Variable(CurrentGameState, 1);
  • }
  • }
  • rule ("Hiding Phase") {
  • event {
  • Ongoing - Global;
  • }
  • conditions {
  • Global.CurrentGameState == 1;
  • }
  • actions {
  • Log To Inspector(Custom String("Game Phase: Hiding", Null, Null, Null));
  • Call Subroutine(PLAYSOUND_RINGEXPLOSION);
  • Respawn(Filtered Array(Remove From Array(All Players(All Teams), Players On Hero(Hero(D.Va), All Teams)), And(Has Spawned(Current Array Element), Not(Is In Spawn Room(Current Array Element)))));
  • Modify Global Variable(CurrentRound, Add, 1);
  • Big Message(If-Then-Else(Compare(Global.WS_SET_ADV_WINS, >, 1), All Players(All Teams), Null), Custom String("Round {0}", Global.CurrentRound, Null, Null));
  • Set Global Variable(CurrentTime, Global.WS_SET_HIDETIME);
  • Chase Global Variable At Rate(CurrentTime, 0, 1, Destination and Rate);
  • Wait Until(Compare(Global.CurrentTime, ==, 0), 9999);
  • Stop Chasing Global Variable(CurrentTime);
  • Set Global Variable(CurrentGameState, 2);
  • }
  • }
  • rule ("Seeking Phase") {
  • event {
  • Ongoing - Global;
  • }
  • conditions {
  • Global.CurrentGameState == 2;
  • }
  • actions {
  • Log To Inspector(Custom String("Game Phase: Seeking", Null, Null, Null));
  • Call Subroutine(PLAYSOUND_RINGEXPLOSION);
  • Set Global Variable(CurrentTime, Global.WS_SET_SEEKTIME);
  • Chase Global Variable At Rate(CurrentTime, 0, 1, Destination and Rate);
  • Wait Until(Or(Compare(Global.CurrentTime, ==, 0), Not(Compare(Count Of(Filtered Array(All Players(Team 1), And(And(And(Has Spawned(Current Array Element), Is Alive(Current Array Element)), Not(Is In Spawn Room(Current Array Element))), Not((Current Array Element).JoinedLate)))), >, 0))), 9999);
  • Stop Chasing Global Variable(CurrentTime);
  • Set Global Variable(CurrentGameState, 3);
  • }
  • }
  • rule ("Results") {
  • event {
  • Ongoing - Global;
  • }
  • conditions {
  • Global.CurrentGameState == 3;
  • }
  • actions {
  • Log To Inspector(Custom String("Game Phase: Results", Null, Null, Null));
  • Call Subroutine(PLAYSOUND_BUFF);
  • "Add score to winning team"
  • If(Compare(Count Of(Filtered Array(All Players(Team 1), And(And(And(Has Spawned(Current Array Element), Is Alive(Current Array Element)), Not(Is In Spawn Room(Current Array Element))), Not((Current Array Element).JoinedLate)))), >, 0));
  • Modify Global Variable(HiderTeamScore, Add, 1);
  • Big Message(If-Then-Else(Compare(Global.WS_SET_ADV_WINS, >, 1), All Players(All Teams), Null), Custom String("Hiders Win!", Null, Null, Null));
  • Else;
  • Modify Global Variable(SeekerTeamScore, Add, 1);
  • Big Message(If-Then-Else(Compare(Global.WS_SET_ADV_WINS, >, 1), All Players(All Teams), Null), Custom String("Seekers Win!", Null, Null, Null));
  • End;
  • "Show hiders if workshop setting is enabled"
  • If(Or(And(Compare(Global.WS_SET_SHOW_HIDERS, ==, 1), Compare(Number Of Living Players(Team 1), >=, 1)), And(Compare(Global.WS_SET_SHOW_HIDERS, ==, 0), Compare(Number Of Living Players(Team 1), ==, 1))));
  • Small Message(All Players(All Teams), Value In Array(Array(Custom String("Revealing the remaining hiders", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))));
  • Set Player Variable(All Players(All Teams), ShowHiders, True);
  • Wait Until(Is True For All(All Players(All Teams), Compare((Current Array Element).ShowHiders, ==, False)), 9999);
  • End;
  • "If team score reaches required wins, then declare victory. Otherwise, start another round"
  • If(Compare(Global.HiderTeamScore, >=, Global.WS_SET_ADV_WINS));
  • Declare Team Victory(Team 1);
  • Set Global Variable(CurrentGameState, 4);
  • Else If(Compare(Global.SeekerTeamScore, >=, Global.WS_SET_ADV_WINS));
  • Declare Team Victory(Team 2);
  • Set Global Variable(CurrentGameState, 4);
  • Else;
  • Set Slow Motion(25);
  • Wait(1, Ignore Condition);
  • Set Global Variable(CurrentGameState, 1);
  • Set Slow Motion(100);
  • }
  • }
  • rule ("Countdown") {
  • event {
  • Ongoing - Global;
  • }
  • conditions {
  • Global.CurrentTime < 10;
  • Global.CurrentTime > 0;
  • }
  • actions {
  • Call Subroutine(PLAYSOUND_DEBUFF);
  • Wait(1, Ignore Condition);
  • Loop If Condition Is True;
  • }
  • }
  • rule ("End Game") {
  • event {
  • Ongoing - Global;
  • }
  • conditions {
  • Global.CurrentGameState == 4;
  • }
  • actions {
  • Log To Inspector(Custom String("Game Phase: End", Null, Null, Null));
  • Wait(Global.WS_SET_END, Ignore Condition);
  • Set Match Time(0);
  • Unpause Match Time;
  • }
  • }
  • rule ("Skip") {
  • event {
  • Ongoing - Global;
  • }
  • conditions {
  • Current Game Mode != Game Mode(Skirmish);
  • }
  • actions {
  • While(Or(Is Assembling Heroes, Is In Setup));
  • Set Match Time(0);
  • Unpause Match Time;
  • Pause Match Time;
  • Wait(1, Ignore Condition);
  • End;
  • }
  • }
  • rule ("Subroutine SlingshotCooldown") {
  • event {
  • Subroutine;
  • SlingshotCooldown;
  • }
  • actions {
  • Set Player Variable(Event Player, SlingshotUsed, True);
  • Wait Until(Is On Ground(Event Player), 9999);
  • Wait(If-Then-Else(Compare(Global.CurrentGameState, ==, 2), 8, 0), Ignore Condition);
  • Set Player Variable(Event Player, SlingshotUsed, False);
  • }
  • }
  • rule ("Subroutine StartCamera") {
  • event {
  • Subroutine;
  • StartCamera;
  • }
  • actions {
  • Start Camera(Event Player, Eye Position(Event Player), Add(Eye Position(Event Player), Facing Direction Of(Event Player)), 60);
  • Wait(0.016, Ignore Condition);
  • }
  • }
  • rule ("Subroutine StartThirdPersonCamera") {
  • event {
  • Subroutine;
  • StartThirdPersonCamera;
  • }
  • actions {
  • Start Camera(Event Player, Update Every Frame(Ray Cast Hit Position(Eye Position(Event Player), Add(Add(Eye Position(Event Player), World Vector Of(Vector(-1, 0, 0), Event Player, Rotation)), Multiply(Facing Direction Of(Event Player), -2.5)), All Players(All Teams), Event Player, False)), Update Every Frame(Ray Cast Hit Position(Eye Position(Event Player), Add(Eye Position(Event Player), Multiply(Facing Direction Of(Event Player), 200)), All Players(All Teams), Event Player, False)), 60);
  • }
  • }
  • rule ("Subroutine RestrictAbilities") {
  • event {
  • Subroutine;
  • RestrictAbilities;
  • }
  • actions {
  • Set Ability 1 Enabled(Event Player, True);
  • Set Ability 2 Enabled(Event Player, True);
  • Set Secondary Fire Enabled(Event Player, True);
  • Skip If(Compare(Global.WS_SET_MODE, ==, 3), 27);
  • If(True);
  • Skip(Value In Array(Array(24, 0, 8), Add(1, Index Of Array Value(Array(Team 1, Team 2), Team Of(Event Player)))));
  • //__label_switch_4_0__:
  • If(True);
  • Skip(Value In Array(Array(4, 0, 2), Add(1, Index Of Array Value(Array(Hero(Mercy), Hero(Hanzo)), Hero Of(Event Player)))));
  • //__label_switch_2_0__:
  • Set Ability 2 Enabled(Event Player, False);
  • Else;
  • //__label_switch_2_1__:
  • Set Ability 1 Enabled(Event Player, False);
  • Else;
  • //__label_switch_2_default__:
  • End;
  • Else;
  • //__label_switch_4_1__:
  • If(True);
  • Skip(Value In Array(Array(12, 0, 2, 4, 6, 8, 10), Add(1, Index Of Array Value(Array(Hero(Orisa), Hero(Hanzo), Hero(Symmetra), Hero(Torbjörn), Hero(Widowmaker), Hero(Junkrat)), Hero Of(Event Player)))));
  • //__label_switch_3_0__:
  • Set Secondary Fire Enabled(Event Player, False);
  • Else;
  • //__label_switch_3_1__:
  • Set Ability 1 Enabled(Event Player, False);
  • Else;
  • //__label_switch_3_2__:
  • Set Ability 1 Enabled(Event Player, False);
  • Else;
  • //__label_switch_3_3__:
  • Set Ability 1 Enabled(Event Player, False);
  • Else;
  • //__label_switch_3_4__:
  • Set Ability 2 Enabled(Event Player, False);
  • Else;
  • //__label_switch_3_5__:
  • Set Ability 2 Enabled(Event Player, False);
  • Else;
  • //__label_switch_3_default__:
  • End;
  • Else;
  • //__label_switch_4_default__:
  • End;
  • //skip_evaluation:
  • }
  • }
  • rule ("Create Player Huds") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • actions {
  • "Destroy player huds"
  • For Player Variable(Event Player, playerHudIndex, 0, Count Of((Event Player).Hud_Player), 1);
  • Destroy HUD Text(Value In Array((Event Player).Hud_Player, (Event Player).playerHudIndex));
  • End;
  • Set Player Variable(Event Player, Hud_Player, Empty Array);
  • Wait Until(Has Spawned(Event Player), 9999);
  • "Creates the Objective Hud"
  • Create HUD Text(Event Player, Custom String("{0} {1}", If-Then-Else(Compare(Team Of(Event Player), ==, Team 1), Ability Icon String(Hero Of(Event Player), Button(Ultimate)), Ability Icon String(Hero Of(Event Player), Button(Primary Fire))), If-Then-Else(Compare(Team Of(Event Player), ==, Team 1), Value In Array(Array(Custom String("Hider", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Value In Array(Array(Custom String("Seeker", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null))))), Null), Custom String("{0}: {1}", Value In Array(Array(Custom String("Phase", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Value In Array(Array(Value In Array(Array(Custom String("Waiting For Players", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Value In Array(Array(Custom String("Hiding", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Value In Array(Array(Custom String("Seeking", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Value In Array(Array(Custom String("Results", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Value In Array(Array(Custom String("End Game", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null))))), Global.CurrentGameState), Null), If-Then-Else(Compare(Global.CurrentTime, >, 60), Custom String("{0}:{1}", Round To Integer(Divide(Modulo(Modulo(Global.CurrentTime, 86400), 3600), 60), Down), Round To Integer(Modulo(Modulo(Modulo(Global.CurrentTime, 86400), 3600), 60), Down), Null), Custom String("{0}", Global.CurrentTime, Null, Null)), Top, 1, If-Then-Else(Compare(Team Of(Event Player), ==, Team 1), Color(Blue), Color(Red)), Color(White), Color(White), Visible To String and Color, Default Visibility);
  • Modify Player Variable(Event Player, Hud_Player, Append To Array, Last Text ID);
  • "Slingshot Instructions"
  • If(Compare(Global.WS_SET_USE_SLINGSHOT, ==, True));
  • Create HUD Text(Event Player, Null, Custom String("[{0}]: {1} / [{2}", Input Binding String(Button(Interact)), Value In Array(Array(Custom String("Toggle Slingshot", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Custom String("{0}]: {1}", Input Binding String(Button(Primary Fire)), Value In Array(Array(Custom String("Confirm", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Null)), Null, Top, 0, Null, Color(White), Null, Visible To and String, Default Visibility);
  • Modify Player Variable(Event Player, Hud_Player, Append To Array, Last Text ID);
  • End;
  • "Camera Hud Instructions"
  • If(Compare(Global.WS_SET_3RD_CAM, ==, 8));
  • Create HUD Text(Event Player, Null, Custom String("[{0}]: {1}", Input Binding String(Button(Reload)), Value In Array(Array(Custom String("Toggle third person camera", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Null), Null, Top, 0, Null, Color(White), Null, Visible To and String, Default Visibility);
  • Modify Player Variable(Event Player, Hud_Player, Append To Array, Last Text ID);
  • End;
  • "Laying down Instructions"
  • If(And(Compare(Global.WS_SET_LAYING_DOWN, ==, True), Compare(Team Of(Event Player), ==, Team 1)));
  • Create HUD Text(Event Player, Null, Custom String("[{0} + {1}]: {2}", Value In Array(Array(Custom String("Emote", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Input Binding String(Button(Crouch)), Custom String("{0} / [{1}]: {2}", Value In Array(Array(Custom String("Lay Down", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Input Binding String(Button(Jump)), Value In Array(Array(Custom String("Stand up", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))))), Null, Top, 0, Null, Color(White), Null, Visible To and String, Default Visibility);
  • Modify Player Variable(Event Player, Hud_Player, Append To Array, Last Text ID);
  • }
  • }
  • rule ("Global Huds") {
  • event {
  • Ongoing - Global;
  • }
  • conditions {
  • Global.CurrentGameState == 1;
  • }
  • actions {
  • Create HUD Text(All Players(All Teams), Null, Value In Array(Array(Custom String("Current Version: {0}\n", Global.CURRENT_VERSION, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Null, Right, 0, Null, Color(White), Null, Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • Create HUD Text(All Players(All Teams), Null, Value In Array(Array(Custom String("https://workshop.codes/hide-and-seek-ult", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Null, Right, 0, Null, Color(White), Null, Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • Create HUD Text(All Players(All Teams), Null, Null, Value In Array(Array(Custom String("{0} Hide & Seek: Ultimate by CaptCaptain#11421", Ability Icon String(Random Value In Array(All Heroes), Button(Ultimate)), Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Right, 0, Null, Null, Color(Sky Blue), Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • Create HUD Text(All Players(All Teams), Value In Array(Array(Custom String("{0} RULESET", Ability Icon String(Hero(Torbjörn), Button(Ability 2)), Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Null, Null, Left, 1, Color(Rose), Null, Null, Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • Create HUD Text(All Players(All Teams), Null, Null, Value In Array(Array(Custom String("STYLE: {0}", Value In Array(Array(Value In Array(Array(Custom String("DEFAULT", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Value In Array(Array(Custom String("GLITCH", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Value In Array(Array(Custom String("TINY", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Value In Array(Array(Custom String("MERCY VS. REINHARDT", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null))))), Global.WS_SET_MODE_RAW), Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Left, 2, Null, Null, Color(White), Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • Create HUD Text(All Players(All Teams), Null, Null, Value In Array(Array(Custom String("MAP: {0} [{1}]", Current Map, Current Game Mode, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Left, 2, Null, Null, Color(White), Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • Create HUD Text(All Players(All Teams), Null, Null, Value In Array(Array(Custom String("FIRST TEAM TO: {0} WIN(S)", Global.WS_SET_ADV_WINS, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Left, 3, Null, Null, Color(White), Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • Create HUD Text(All Players(All Teams), Null, Null, Value In Array(Array(Custom String("TIME LIMIT - SEEKING: {0}:{1}", Round To Integer(Divide(Modulo(Modulo(Global.WS_SET_SEEKTIME, 86400), 3600), 60), Down), Round To Integer(Modulo(Modulo(Modulo(Global.WS_SET_SEEKTIME, 86400), 3600), 60), Down), Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Left, 4, Null, Null, Color(White), Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • Create HUD Text(All Players(All Teams), Null, Null, Value In Array(Array(Custom String("TIME LIMIT - HIDING: {0}:{1}", Round To Integer(Divide(Modulo(Modulo(Global.WS_SET_HIDETIME, 86400), 3600), 60), Down), Round To Integer(Modulo(Modulo(Modulo(Global.WS_SET_HIDETIME, 86400), 3600), 60), Down), Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Left, 4, Null, Null, Color(White), Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • Create HUD Text(All Players(All Teams), Null, Null, Value In Array(Array(Custom String("PLAYER SIZE: {0}x", Global.WS_SET_ADV_SCALE, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Left, 4, Null, Null, Color(White), Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • Create HUD Text(All Players(All Teams), Null, Null, Value In Array(Array(Custom String("PLAYER SPEED: {0}x", Global.WS_SET_ADV_BASESPEED, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Left, 4, Null, Null, Color(White), Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • If(Compare(Global.WS_SET_SEEKER_OUTLINES, !=, 11));
  • Create HUD Text(All Players(All Teams), Null, Null, Value In Array(Array(Custom String("SEEKER OUTLINES: {0}", If-Then-Else(Compare(Global.WS_SET_SEEKER_OUTLINES, ==, 11), Value In Array(Array(Custom String("Default", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), If-Then-Else(Compare(Global.WS_SET_SEEKER_OUTLINES, ==, 12), Value In Array(Array(Custom String("Occluded", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Value In Array(Array(Custom String("Always", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))))), Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Left, 4, Null, Null, Color(White), Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • End;
  • Create HUD Text(All Players(All Teams), Null, Null, Value In Array(Array(Custom String("HIDER OUTLINES: {0}", Global.WS_SET_USEOUTLINE, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Left, 4, Null, Null, Color(White), Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • If(Global.WS_SET_SEEKER_ASSIST);
  • Create HUD Text(All Players(All Teams), Null, Null, Value In Array(Array(Custom String("SEEKER ASSISTANCE: {0}", Global.WS_SET_SEEKER_ASSIST, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Left, 4.1, Null, Null, Color(White), Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • End;
  • If(Compare(Global.WS_SET_ADV_TANKSCALING, !=, 5));
  • Create HUD Text(All Players(All Teams), Null, Null, Value In Array(Array(Custom String("HIDER TANK SCALING: {0}", If-Then-Else(Compare(Global.WS_SET_ADV_TANKSCALING, ==, 4), Value In Array(Array(Custom String("Automatic", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), If-Then-Else(Compare(Global.WS_SET_ADV_TANKSCALING, ==, 3), True, False)), Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Left, 5, Null, Null, Color(White), Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • End;
  • If(Global.WS_SET_USE_SLINGSHOT);
  • Create HUD Text(All Players(All Teams), Null, Null, Value In Array(Array(Custom String("ALLOW SLINGSHOT TOOL: {0}", Global.WS_SET_USE_SLINGSHOT, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Left, 5, Null, Null, Color(White), Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • End;
  • If(Compare(Global.WS_SET_SLOWHIDER, ==, True));
  • Create HUD Text(All Players(All Teams), Null, Null, Value In Array(Array(Custom String("SLOW HIDERS WHEN IN LOS OF SEEKER: {0}", Global.WS_SET_SLOWHIDER, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Left, 5, Null, Null, Color(White), Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • End;
  • If(Global.WS_SET_LAYING_DOWN);
  • Create HUD Text(All Players(All Teams), Null, Null, Value In Array(Array(Custom String("ALLOW HIDERS TO LAY DOWN: {0}", Global.WS_SET_LAYING_DOWN, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Left, 5, Null, Null, Color(White), Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • End;
  • If(Compare(Global.WS_SET_SHOW_HIDERS, !=, 2));
  • Create HUD Text(All Players(All Teams), Null, Null, Value In Array(Array(Custom String("SHOW REMAINING HIDERS AFTER THE ROUND: {0}", If-Then-Else(Compare(Global.WS_SET_SHOW_HIDERS, ==, 0), Value In Array(Array(Custom String("Last Hider Only", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), If-Then-Else(Compare(Global.WS_SET_SHOW_HIDERS, ==, 1), True, False)), Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Left, 5.1, Null, Null, Color(White), Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • End;
  • If(Compare(Global.WS_SET_ADV_INF_HAMMOND_GRAPPLE, ==, True));
  • Create HUD Text(All Players(All Teams), Null, Null, Value In Array(Array(Custom String("WRECKING HIDER INFINITE GRAPPLE: {0}", Global.WS_SET_ADV_INF_HAMMOND_GRAPPLE, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Left, 5, Null, Null, Color(White), Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • End;
  • If(Compare(Global.WS_SET_ADV_SEEK_ALLOWH, ==, True));
  • Create HUD Text(All Players(All Teams), Null, Null, Value In Array(Array(Custom String("RESTRICT SEEKER HERO ROSTER: {0}", Not(Global.WS_SET_ADV_SEEK_ALLOWH), Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Left, 5, Null, Null, Color(White), Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • End;
  • Create HUD Text(All Players(All Teams), Null, Value In Array(Array(Custom String("TO CUSTOMIZE RULESET (HOST ONLY):\nGO TO LOBBY > SETTINGS > WORKSHOP SETTINGS", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Null, Left, 6, Null, Color(Turquoise), Null, Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • Create HUD Text(All Players(All Teams), Null, Value In Array(Array(Custom String("MATCH VOICE CHAT IS ENABLED", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Null, Left, 6, Null, Color(Yellow), Null, Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • Create HUD Text(All Players(All Teams), Null, Value In Array(Array(Custom String("FOR MORE INFORMATION ON RULESET:\nGO TO LOBBY > RIGHT CLICK MAP PICTURE > SCROLL DOWN TO WORKSHOP\n", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Null, Left, 7, Null, Color(Turquoise), Null, Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • If(Compare(Global.WS_SET_ADV_WINS, >, 1));
  • Create HUD Text(All Players(All Teams), Value In Array(Array(Custom String("TEAM SCORE:", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Custom String("", Null, Null, Null), Value In Array(Array(Custom String("HIDERS: {0}\nSEEKERS: {1}", Global.HiderTeamScore, Global.SeekerTeamScore, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Left, 8, Color(Team 1), Color(White), Color(White), Visible To and Sort Order, Default Visibility);
  • Modify Global Variable(Hud_GameInfo, Append To Array, Last Text ID);
  • }
  • }
  • rule ("Remove Global Huds") {
  • event {
  • Ongoing - Global;
  • }
  • conditions {
  • Global.CurrentGameState == 2;
  • }
  • actions {
  • For Global Variable(globalHudIndex, 0, Count Of(Global.Hud_GameInfo), 1);
  • Destroy HUD Text(Value In Array(Global.Hud_GameInfo, Global.globalHudIndex));
  • End;
  • Set Global Variable(Hud_GameInfo, Null);
  • }
  • }
  • rule ("Player Setup") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • actions {
  • Disable Game Mode HUD(Event Player);
  • Disable Built-In Game Mode Respawning(Event Player);
  • Stop Camera(Event Player);
  • Set Move Speed(Event Player, (Event Player).BaseMoveSpeed);
  • Set Jump Vertical Speed(Event Player, (Event Player).BaseJumpHeight);
  • "Glitch Mode"
  • If(Compare(Global.WS_SET_MODE, ==, 4));
  • Disable Movement Collision With Environment(Event Player, False);
  • }
  • }
  • rule ("Player Scaling") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions {
  • Or(Or(Compare((Event Player).BaseScaling, >, 1), Compare((Event Player).BaseScaling, <, 1)), Or(Compare(Global.WS_SET_ADV_TANKSCALING, ==, 4), Compare(Global.WS_SET_ADV_TANKSCALING, ==, 3))) == True;
  • }
  • actions {
  • "Scales the player"
  • Start Scaling Player(Event Player, (Event Player).BaseScaling, True);
  • Start Scaling Barriers(Event Player, (Event Player).BaseScaling, True);
  • Skip If(Not(Or(Compare(Global.WS_SET_ADV_SCALE, >, 1), Compare(Global.WS_SET_ADV_SCALE, <, 1))), 1);
  • Start Modifying Hero Voice Lines(Event Player, Subtract(2, (Event Player).BaseScaling), True);
  • //skip_voice_modification:
  • }
  • }
  • rule ("Reset Ammo") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions {
  • Ammo(Event Player, 0) > 0;
  • Is Firing Primary(Event Player) == False;
  • Is Firing Secondary(Event Player) == False;
  • }
  • actions {
  • "Reset ammo when player has not fired for more than a second"
  • Wait(1, Abort When False);
  • Set Ammo(Event Player, 0, Max Ammo(Event Player, 0));
  • }
  • }
  • rule ("Resurrect") {
  • event {
  • Player Died;
  • All;
  • All;
  • }
  • conditions {
  • Or(Event Was Environment, Compare(Attacker, ==, Victim)) == True;
  • (Event Player).ResurrectBlocked == False;
  • }
  • actions {
  • "If the player dies to the environment or self-destructs."
  • Resurrect(Event Player);
  • Teleport(Event Player, If-Then-Else(Compare((Event Player).LastWalkablePosition, !=, Null), (Event Player).LastWalkablePosition, Nearest Walkable Position(Position Of(Event Player))));
  • Set Status(Event Player, Null, Rooted, 1);
  • If(Compare(Attacker, ==, Victim));
  • Set Status(Event Player, Null, Invincible, 1);
  • End;
  • Small Message(Event Player, Value In Array(Array(Custom String("BE CAREFUL!", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))));
  • }
  • }
  • rule ("Set Last Walkable Position") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions {
  • Is Moving(Event Player) == True;
  • Is On Ground(Event Player) == True;
  • }
  • actions {
  • Set Player Variable(Event Player, LastWalkablePosition, Nearest Walkable Position(Position Of(Event Player)));
  • Wait Until(Is On Ground(Event Player), 9999);
  • }
  • }
  • rule ("Show Remaining Hiders") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions {
  • (Event Player).ShowHiders == True;
  • }
  • actions {
  • If(Compare((Event Player).CameraState, ==, 0));
  • "Smooth camera transition"
  • Start Camera(Event Player, Eye Position(Event Player), Add(Eye Position(Event Player), Facing Direction Of(Event Player)), 5);
  • Wait(0.016, Ignore Condition);
  • End;
  • Set Player Variable(Event Player, CameraState, 3);
  • Disable Hero HUD(Event Player);
  • Start Camera(Event Player, Evaluate Once(Add(Add(Position Of(Event Player), Multiply(Up, 100)), Backward)), Evaluate Once(Position Of(Event Player)), 5);
  • Wait(1, Ignore Condition);
  • For Player Variable(Event Player, playerIndex, 0, Number Of Living Players(Team 1), 1);
  • Start Camera(Event Player, Ray Cast Hit Position(Position Of(Value In Array(All Living Players(Team 1), (Event Player).playerIndex)), Add(Add(Position Of(Value In Array(All Living Players(Team 1), (Event Player).playerIndex)), Multiply(Up, 5)), Vector(0.001, 0, 0)), Null, Value In Array(All Living Players(Team 1), (Event Player).playerIndex), False), Position Of(Value In Array(All Living Players(Team 1), (Event Player).playerIndex)), 10);
  • Wait(2, Ignore Condition);
  • Start Camera(Event Player, Evaluate Once(Add(Add(Position Of(Value In Array(All Living Players(Team 1), (Event Player).playerIndex)), Multiply(Up, 100)), Backward)), Evaluate Once(Position Of(Value In Array(All Living Players(Team 1), (Event Player).playerIndex))), 5);
  • Wait(1, Ignore Condition);
  • End;
  • Enable Hero HUD(Event Player);
  • "Return to previous camera state"
  • If(Compare((Event Player).LayingDownCameraEnabled, ==, True));
  • Set Player Variable(Event Player, CameraState, 1);
  • Else If(Compare((Event Player).ThirdPersonCameraEnabled, ==, True));
  • Set Player Variable(Event Player, CameraState, 2);
  • Else;
  • Set Player Variable(Event Player, CameraState, 0);
  • End;
  • Set Player Variable(Event Player, ShowHiders, False);
  • }
  • }
  • rule ("D.va: Ult") {
  • event {
  • Ongoing - Each Player;
  • All;
  • D.Va;
  • }
  • actions {
  • Set Ultimate Ability Enabled(Event Player, True);
  • Disallow Button(Event Player, Button(Ultimate));
  • }
  • }
  • rule ("D.va: Get Ult In Spawn") {
  • event {
  • Ongoing - Each Player;
  • All;
  • D.Va;
  • }
  • conditions {
  • Is In Spawn Room(Event Player) == True;
  • }
  • actions {
  • Set Ultimate Charge(Event Player, 100);
  • }
  • }
  • rule ("D.va: Enable De-mech") {
  • event {
  • Ongoing - Each Player;
  • All;
  • D.Va;
  • }
  • conditions {
  • Has Spawned(Event Player) == True;
  • Is Button Held(Event Player, Button(Ultimate)) == True;
  • }
  • actions {
  • If(And(Not(Is In Alternate Form(Event Player)), Or(Compare(Global.WS_SET_ADV_DVA_MECH, ==, 1), Compare(Global.WS_SET_ADV_DVA_MECH, ==, 0))));
  • Set Ultimate Charge(Event Player, 0);
  • Kill(Event Player, Null);
  • If(Compare(Global.WS_SET_ADV_DVA_MECH, ==, 0));
  • Wait Until(Is In Alternate Form(Event Player), 9999);
  • Allow Button(Event Player, Button(Ultimate));
  • Set Ultimate Charge(Event Player, 100);
  • End;
  • Else If(And(Is In Alternate Form(Event Player), Compare(Global.WS_SET_ADV_DVA_MECH, ==, 0)));
  • Allow Button(Event Player, Button(Ultimate));
  • Press Button(Event Player, Button(Ultimate));
  • Wait Until(Not(Is In Alternate Form(Event Player)), 9999);
  • Disallow Button(Event Player, Button(Ultimate));
  • }
  • }
  • rule ("Start Third Person Camera") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions {
  • (Event Player).CameraState == 2;
  • }
  • actions {
  • "Smooth transition to third person camera"
  • Call Subroutine(StartCamera);
  • Call Subroutine(StartThirdPersonCamera);
  • }
  • }
  • rule ("Start Laying Down Camera") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions {
  • (Event Player).CameraState == 1;
  • }
  • actions {
  • "Smooth transition to third person camera"
  • Call Subroutine(StartCamera);
  • Start Camera(Event Player, Ray Cast Hit Position(Eye Position(Event Player), Add(Add(Position Of(Event Player), Multiply(Up, 10)), Vector(0.001, 0, 0)), Null, Event Player, False), Position Of(Event Player), 10);
  • }
  • }
  • rule ("Stop Camera") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions {
  • (Event Player).CameraState == 0;
  • }
  • actions {
  • "Smooth transition to first person camera"
  • Start Camera(Event Player, Eye Position(Event Player), Add(Eye Position(Event Player), Facing Direction Of(Event Player)), 60);
  • Wait(0.08, Ignore Condition);
  • Stop Camera(Event Player);
  • }
  • }
  • rule ("Toggle Third Person Camera") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions {
  • Global.WS_SET_3RD_CAM == 8;
  • Or(Compare((Event Player).CameraState, ==, 0), Compare((Event Player).CameraState, ==, 2)) == True;
  • Is Button Held(Event Player, Button(Reload)) == True;
  • Ammo(Event Player, 0) == Max Ammo(Event Player, 0);
  • }
  • actions {
  • Set Player Variable(Event Player, ThirdPersonCameraEnabled, Not((Event Player).ThirdPersonCameraEnabled));
  • Set Player Variable(Event Player, CameraState, If-Then-Else((Event Player).ThirdPersonCameraEnabled, 2, 0));
  • }
  • }
  • rule ("Toggle Slingshot") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions {
  • Global.WS_SET_USE_SLINGSHOT == True;
  • Is Button Held(Event Player, Button(Interact)) == True;
  • }
  • actions {
  • Wait(0.016, Ignore Condition);
  • If(And(And(Global.WS_SET_SLOWHIDER, Is True For Any(All Players(Team 2), Is In Line of Sight(Event Player, Current Array Element, Barriers Do Not Block LOS))), Compare(Team Of(Event Player), ==, Team 1)));
  • Small Message(Event Player, Value In Array(Array(Custom String("CANNOT USE SLINGSHOT WHILE IN LOS OF SEEKERS", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))));
  • Abort;
  • "Using interact with abilities take priority over slingshot toggle"
  • Else If(Is True For Any(Array(And(Compare(Hero Of(Event Player), ==, Hero(Sombra)), Is Using Ability 2(Event Player)), And(Compare(Hero Of(Event Player), ==, Hero(Torbjörn)), Is Using Ability 1(Event Player)), And(Compare(Distance Between(Position Of(Event Player), (Event Player).PreviousPosition), >, 1), Is True For Any(Players On Hero(Hero(Symmetra), Team Of(Event Player)), Is Using Ability 2(Current Array Element)))), Compare(Current Array Element, ==, True)));
  • Abort;
  • End;
  • Set Player Variable(Event Player, SlingshotEnabled, Not((Event Player).SlingshotEnabled));
  • }
  • }
  • rule ("Disable Slingshot") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions {
  • Is Communicating Any Emote(Event Player) == True;
  • }
  • actions {
  • Set Player Variable(Event Player, SlingshotEnabled, False);
  • }
  • }
  • rule ("Create Slingshot Effects") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions {
  • (Event Player).SlingshotEnabled == True;
  • }
  • actions {
  • Play Effect(Event Player, Good Explosion, If-Then-Else((Event Player).SlingshotUsed, Color(Rose), Color(Yellow)), Update Every Frame(Ray Cast Hit Position(Add(Ray Cast Hit Position(Eye Position(Event Player), Add(Eye Position(Event Player), Multiply(Facing Direction Of(Event Player), 15)), Null, Event Player, False), Up), Add(Ray Cast Hit Position(Eye Position(Event Player), Add(Eye Position(Event Player), Multiply(Facing Direction Of(Event Player), 15)), Null, Event Player, False), Multiply(Down, 100)), Null, Event Player, False)), 1);
  • Play Effect(Event Player, Buff Explosion Sound, Color(White), Event Player, 100);
  • "Create slingshot destination effect"
  • Create Effect(Event Player, Light Shaft, If-Then-Else((Event Player).SlingshotUsed, Color(Rose), Color(Yellow)), Update Every Frame(Ray Cast Hit Position(Add(Ray Cast Hit Position(Eye Position(Event Player), Add(Eye Position(Event Player), Multiply(Facing Direction Of(Event Player), 15)), Null, Event Player, False), Up), Add(Ray Cast Hit Position(Eye Position(Event Player), Add(Eye Position(Event Player), Multiply(Facing Direction Of(Event Player), 15)), Null, Event Player, False), Multiply(Down, 100)), Null, Event Player, False)), 0.1, Visible To Position Radius and Color);
  • Modify Player Variable(Event Player, Hud_Slingshot, Append To Array, Last Created Entity);
  • Create Effect(Event Player, Ring, If-Then-Else((Event Player).SlingshotUsed, Color(Rose), Color(Yellow)), Update Every Frame(Ray Cast Hit Position(Add(Ray Cast Hit Position(Eye Position(Event Player), Add(Eye Position(Event Player), Multiply(Facing Direction Of(Event Player), 15)), Null, Event Player, False), Up), Add(Ray Cast Hit Position(Eye Position(Event Player), Add(Eye Position(Event Player), Multiply(Facing Direction Of(Event Player), 15)), Null, Event Player, False), Multiply(Down, 100)), Null, Event Player, False)), 1, Visible To Position Radius and Color);
  • Modify Player Variable(Event Player, Hud_Slingshot, Append To Array, Last Created Entity);
  • "Disallow Primary Fire"
  • Disallow Button(Event Player, Button(Primary Fire));
  • }
  • }
  • rule ("Destroy Slingshot Effects") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions {
  • (Event Player).SlingshotEnabled == False;
  • }
  • actions {
  • Play Effect(Event Player, Good Explosion, If-Then-Else((Event Player).SlingshotUsed, Color(Rose), Color(Yellow)), Update Every Frame(Ray Cast Hit Position(Add(Ray Cast Hit Position(Eye Position(Event Player), Add(Eye Position(Event Player), Multiply(Facing Direction Of(Event Player), 15)), Null, Event Player, False), Up), Add(Ray Cast Hit Position(Eye Position(Event Player), Add(Eye Position(Event Player), Multiply(Facing Direction Of(Event Player), 15)), Null, Event Player, False), Multiply(Down, 100)), Null, Event Player, False)), 1);
  • Play Effect(Event Player, Buff Impact Sound, Color(White), Event Player, 100);
  • For Player Variable(Event Player, playerHudIndex, 0, Count Of((Event Player).Hud_Slingshot), 1);
  • Destroy Effect(Value In Array((Event Player).Hud_Slingshot, (Event Player).playerHudIndex));
  • End;
  • Set Player Variable(Event Player, Hud_Slingshot, Empty Array);
  • "Allow Primary Fire"
  • Allow Button(Event Player, Button(Primary Fire));
  • }
  • }
  • rule ("Confirm Slingshot") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions {
  • (Event Player).SlingshotEnabled == True;
  • Is Button Held(Event Player, Button(Primary Fire)) == True;
  • }
  • actions {
  • Abort If(Has Status(Event Player, Rooted));
  • If((Event Player).SlingshotUsed);
  • Small Message(Event Player, Value In Array(Array(Custom String("SLINGSHOT IS ON COOLDOWN", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))));
  • Abort;
  • Else If(Is In Air(Event Player));
  • Small Message(Event Player, Value In Array(Array(Custom String("SLINGSHOT CANNOT BE USED WHILE IN THE AIR", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))));
  • Abort;
  • End;
  • Play Effect(All Players(Opposite Team Of(Team Of(Event Player))), Buff Explosion Sound, Color(White), Event Player, 30);
  • Play Effect(Event Player, Buff Impact Sound, Color(White), Event Player, 100);
  • "Fling player toward point"
  • Set Player Variable(Event Player, SlingshotPosition, Update Every Frame(Ray Cast Hit Position(Add(Ray Cast Hit Position(Eye Position(Event Player), Add(Eye Position(Event Player), Multiply(Facing Direction Of(Event Player), 15)), Null, Event Player, False), Up), Add(Ray Cast Hit Position(Eye Position(Event Player), Add(Eye Position(Event Player), Multiply(Facing Direction Of(Event Player), 15)), Null, Event Player, False), Multiply(Down, 100)), Null, Event Player, False)));
  • Set Gravity(Event Player, 0);
  • Apply Impulse(Event Player, Direction Towards(Position Of(Event Player), Add((Event Player).SlingshotPosition, Multiply(Up, 2))), Multiply(Distance Between(Position Of(Event Player), (Event Player).SlingshotPosition), 2.5), To World, Cancel Contrary Motion);
  • Wait(0.016, Ignore Condition);
  • Set Gravity(Event Player, 100);
  • Start Rule(SlingshotCooldown, Do Nothing);
  • }
  • }
  • rule ("Symmetra TP Detection: Track Previous Position") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions {
  • Global.WS_SET_USE_SLINGSHOT != False;
  • Has Spawned(Event Player) == True;
  • Is True For Any(Players On Hero(Hero(Symmetra), Team Of(Event Player)), Is Using Ability 2(Current Array Element)) == True;
  • }
  • actions {
  • "This lets us know if they went through a Symmetra teleporter."
  • Set Player Variable(Event Player, PreviousPosition, Position Of(Event Player));
  • Chase Player Variable At Rate(Event Player, PreviousPosition, Position Of(Event Player), 50, Destination and Rate);
  • Log To Inspector(Custom String("Symmetra Teleporter Detection Started for {0}", Event Player, Null, Null));
  • }
  • }
  • rule ("Symmetra TP Detection: Stop Tracking Previous Position") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions {
  • Global.WS_SET_USE_SLINGSHOT != False;
  • Has Spawned(Event Player) == True;
  • Is True For All(Players On Hero(Hero(Symmetra), Team Of(Event Player)), Not(Is Using Ability 2(Current Array Element))) == True;
  • }
  • actions {
  • "We don't need to track the player's last position if no teleporter is up."
  • Stop Chasing Player Variable(Event Player, PreviousPosition);
  • Log To Inspector(Custom String("Symmetra Teleporter Detection Stopped for {0}", Event Player, Null, Null));
  • }
  • }
  • rule ("Show Debug Stats") {
  • event {
  • Ongoing - Global;
  • }
  • conditions {
  • Global.WS_SET_ADV_DEBUGSTATS != 2;
  • }
  • actions {
  • Create HUD Text(If-Then-Else(Compare(Global.WS_SET_ADV_DEBUGSTATS, ==, 1), Host Player, All Players(All Teams)), Null, Null, Custom String("DEBUG STATS", Null, Null, Null), Left, -2, Null, Null, Color(White), Visible To and String, Default Visibility);
  • Create HUD Text(If-Then-Else(Compare(Global.WS_SET_ADV_DEBUGSTATS, ==, 1), Host Player, All Players(All Teams)), Null, Custom String("SERVER LOAD: {0}\nSERVER LOAD AVERAGE: {1}\nSERVER LOAD PEAK: {2}\n", Server Load, Server Load Average, Server Load Peak), Null, Left, -1, Null, Color(White), Null, Visible To and String, Default Visibility);
  • Create HUD Text(If-Then-Else(Compare(Global.WS_SET_ADV_DEBUGSTATS, ==, 1), Host Player, All Players(All Teams)), Null, Custom String("CURRENT TIME: {0}", Global.CurrentTime, Null, Null), Null, Left, -1, Null, Color(White), Null, Visible To and String, Default Visibility);
  • }
  • }
  • rule ("Hider Setup") {
  • event {
  • Ongoing - Each Player;
  • Team 1;
  • All;
  • }
  • actions {
  • "Hider Setup
  • \n Mercy V. Rein"
  • If(True);
  • Skip(Value In Array(Array(7, 0, 5), Add(1, Index Of Array Value(Array(3, 5), Global.WS_SET_MODE))));
  • //__label_switch_5_0__:
  • Set Player Allowed Heroes(Event Player, Hero(Mercy));
  • Set Player Variable(Event Player, HiderSlowFactor, 1.5);
  • Set Move Speed(Event Player, Multiply((Event Player).BaseMoveSpeed, 1.5));
  • Set Jump Vertical Speed(Event Player, Multiply((Event Player).BaseJumpHeight, 1.5));
  • Else;
  • //__label_switch_5_1__:
  • Set Player Variable(Event Player, BaseScaling, Divide(Global.WS_SET_ADV_SCALE, 2));
  • Else;
  • //__label_switch_5_default__:
  • Else;
  • End;
  • "Wait for Player to Spawn"
  • Wait Until(Has Spawned(Event Player), 9999);
  • "Seeker Outlines"
  • If(True);
  • Skip(Value In Array(Array(4, 0, 2), Add(1, Index Of Array Value(Array(13, 12), Global.WS_SET_SEEKER_OUTLINES))));
  • //__label_switch_6_0__:
  • Start Forcing Player Outlines(All Players(Team 2), Event Player, True, Color(Team 2), Always);
  • Else;
  • //__label_switch_6_1__:
  • Start Forcing Player Outlines(All Players(Team 2), Event Player, True, Color(Team 2), Occluded);
  • Else;
  • //__label_switch_6_default__:
  • End;
  • Set Max Health(Event Player, 0);
  • Enable Death Spectate All Players(Event Player);
  • Enable Death Spectate Target HUD(Event Player);
  • Wait Until(Not(Is In Spawn Room(Event Player)), 9999);
  • Start Damage Modification(Event Player, All Players(All Teams), If-Then-Else(Compare(Global.CurrentGameState, ==, 2), 9999999999, 0), Receivers Damagers and Damage Percent);
  • Log To Inspector(Custom String("Hider Setup finished for {0}", Event Player, Null, Null));
  • }
  • }
  • rule ("Hiders Joined Late") {
  • event {
  • Ongoing - Each Player;
  • Team 1;
  • All;
  • }
  • conditions {
  • Global.CurrentGameState == 2;
  • Has Spawned(Event Player) == False;
  • }
  • actions {
  • Set Player Variable(Event Player, JoinedLate, True);
  • }
  • }
  • rule ("Kill Hiders Who Joined Late") {
  • event {
  • Ongoing - Each Player;
  • Team 1;
  • All;
  • }
  • conditions {
  • Global.CurrentGameState == 2;
  • (Event Player).JoinedLate == True;
  • Has Spawned(Event Player) == True;
  • }
  • actions {
  • Disable Hero HUD(Event Player);
  • "Create hud"
  • Create In-World Text(Event Player, Custom String("YOU JOINED LATE!", Null, Null, Null), Update Every Frame(Add(Eye Position(Event Player), Facing Direction Of(Event Player))), 5, Do Not Clip, Visible To and Position, Color(Rose), Visible Never);
  • Modify Player Variable(Event Player, Huds_JoinedLate, Append To Array, Last Text ID);
  • Create In-World Text(Event Player, Custom String("YOU WILL BE PUT INTO SPECTATOR", Null, Null, Null), Update Every Frame(Add(Add(Eye Position(Event Player), Evaluate Once(Vector(0, -0.1, 0))), Facing Direction Of(Event Player))), 2, Do Not Clip, Visible To and Position, Color(Turquoise), Visible Never);
  • Modify Player Variable(Event Player, Huds_JoinedLate, Append To Array, Last Text ID);
  • Create In-World Text(Event Player, Custom String("PLEASE WAIT FOR THE NEXT ROUND", Null, Null, Null), Update Every Frame(Add(Add(Eye Position(Event Player), Evaluate Once(Vector(0, -0.2, 0))), Facing Direction Of(Event Player))), 2, Do Not Clip, Visible To and Position, Color(Turquoise), Visible Never);
  • Modify Player Variable(Event Player, Huds_JoinedLate, Append To Array, Last Text ID);
  • Set Status(Event Player, Null, Rooted, 5);
  • Wait(5, Ignore Condition);
  • "Destroy all hud text"
  • For Player Variable(Event Player, playerHudIndex, 0, Count Of((Event Player).Huds_JoinedLate), 1);
  • Destroy In-World Text(Value In Array((Event Player).Huds_JoinedLate, (Event Player).playerHudIndex));
  • End;
  • Set Player Variable(Event Player, Huds_JoinedLate, Null);
  • "Set JoinedLate to false so the spawn room kill rule can run"
  • Set Player Variable(Event Player, JoinedLate, False);
  • Set Player Variable(Event Player, ResurrectBlocked, True);
  • Enable Hero HUD(Event Player);
  • }
  • }
  • rule ("Hider Tank Scaling") {
  • event {
  • Ongoing - Each Player;
  • Team 1;
  • All;
  • }
  • conditions {
  • Or(Compare(Global.WS_SET_ADV_TANKSCALING, ==, 4), Compare(Global.WS_SET_ADV_TANKSCALING, ==, 3)) == True;
  • Is True For Any(All Tank Heroes, Compare(Current Array Element, ==, Hero Of(Event Player))) == True;
  • Is In Alternate Form(Event Player) == False;
  • }
  • actions {
  • Modify Player Variable(Event Player, BaseScaling, Divide, If-Then-Else(And(Compare(Global.WS_SET_ADV_TANKSCALING, ==, 4), Compare(Hero Of(Event Player), ==, Hero(Wrecking Ball))), 1, If-Then-Else(Or(Compare(Global.WS_SET_ADV_TANKSCALING, ==, 4), Compare(Global.WS_SET_ADV_TANKSCALING, ==, 3)), 1.15, 1)));
  • Wait Until(Or(Not(Is True For Any(All Tank Heroes, Compare(Current Array Element, ==, Hero Of(Event Player)))), Is In Alternate Form(Event Player)), 9999);
  • Modify Player Variable(Event Player, BaseScaling, Multiply, If-Then-Else(And(Compare(Global.WS_SET_ADV_TANKSCALING, ==, 4), Compare(Hero Of(Event Player), ==, Hero(Wrecking Ball))), 1, If-Then-Else(Or(Compare(Global.WS_SET_ADV_TANKSCALING, ==, 4), Compare(Global.WS_SET_ADV_TANKSCALING, ==, 3)), 1.15, 1)));
  • }
  • }
  • rule ("Update Seeker Outline") {
  • event {
  • Player Joined Match;
  • Team 2;
  • All;
  • }
  • actions {
  • If(True);
  • Skip(Value In Array(Array(4, 0, 2), Add(1, Index Of Array Value(Array(13, 12), Global.WS_SET_SEEKER_OUTLINES))));
  • //__label_switch_7_0__:
  • Start Forcing Player Outlines(Event Player, All Players(Team 1), True, Color(Team 2), Always);
  • Else;
  • //__label_switch_7_1__:
  • Start Forcing Player Outlines(Event Player, All Players(Team 1), True, Color(Team 2), Occluded);
  • Else;
  • //__label_switch_7_default__:
  • End;
  • }
  • }
  • rule ("Refresh Ability 1 for Hiders") {
  • event {
  • Ongoing - Each Player;
  • Team 1;
  • All;
  • }
  • conditions {
  • Global.CurrentGameState != 2;
  • Is On Ground(Event Player) == True;
  • Is Using Ability 1(Event Player) == False;
  • }
  • actions {
  • Set Ability Cooldown(Event Player, Button(Ability 1), If-Then-Else(Compare(Ability Cooldown(Event Player, Button(Ability 1)), >, 0), 0.2, 0));
  • Set Ability Charge(Event Player, Button(Ability 1), 3);
  • }
  • }
  • rule ("Refresh Ability 2 for Hiders") {
  • event {
  • Ongoing - Each Player;
  • Team 1;
  • All;
  • }
  • conditions {
  • Global.CurrentGameState != 2;
  • Is On Ground(Event Player) == True;
  • Is Using Ability 2(Event Player) == False;
  • }
  • actions {
  • Set Ability Cooldown(Event Player, Button(Ability 2), If-Then-Else(Compare(Ability Cooldown(Event Player, Button(Ability 2)), >, 0), 0.2, 0));
  • Set Ability Charge(Event Player, Button(Ability 2), 3);
  • }
  • }
  • rule ("Refresh Secondary Fire for Hiders") {
  • event {
  • Ongoing - Each Player;
  • Team 1;
  • All;
  • }
  • conditions {
  • Global.CurrentGameState != 2;
  • Is On Ground(Event Player) == True;
  • Is Firing Secondary(Event Player) == False;
  • }
  • actions {
  • Set Ability Cooldown(Event Player, Button(Secondary Fire), If-Then-Else(Compare(Ability Cooldown(Event Player, Button(Secondary Fire)), >, 0), 0.2, 0));
  • Set Ability Charge(Event Player, Button(Secondary Fire), 3);
  • }
  • }
  • rule ("Refresh Secondary Fire for Wrecking Ball") {
  • event {
  • Ongoing - Each Player;
  • Team 1;
  • Wrecking Ball;
  • }
  • conditions {
  • Global.WS_SET_ADV_INF_HAMMOND_GRAPPLE == True;
  • Is Firing Secondary(Event Player) == False;
  • }
  • actions {
  • Set Ability Cooldown(Event Player, Button(Secondary Fire), If-Then-Else(Compare(Ability Cooldown(Event Player, Button(Secondary Fire)), >, 0), 0.2, 0));
  • Set Ability Charge(Event Player, Button(Secondary Fire), 3);
  • }
  • }
  • rule ("Show Warning to Hider While In Spawn Room") {
  • event {
  • Ongoing - Each Player;
  • Team 1;
  • All;
  • }
  • conditions {
  • Is In Spawn Room(Event Player) == True;
  • Global.CurrentGameState == 1;
  • }
  • actions {
  • Create HUD Text(Event Player, Null, Null, Value In Array(Array(Custom String("{0} YOU WILL BE KILLED IF YOU REMAIN IN SPAWN AFTER HIDING PHASE {0}", Icon String(Warning), Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Top, 2, Null, Null, Color(Rose), Visible To Sort Order String and Color, Default Visibility);
  • Set Player Variable(Event Player, Hud_InSpawn, Last Text ID);
  • Wait Until(Or(Not(Is In Spawn Room(Event Player)), Not(Compare(Global.CurrentGameState, ==, 1))), 9999);
  • Destroy HUD Text((Event Player).Hud_InSpawn);
  • Set Player Variable(Event Player, Hud_InSpawn, Null);
  • }
  • }
  • rule ("Slow Hider") {
  • event {
  • Ongoing - Each Player;
  • Team 1;
  • All;
  • }
  • conditions {
  • Global.WS_SET_SLOWHIDER != False;
  • Global.CurrentGameState == 2;
  • Closest Player To(Event Player, Team 2) != Null;
  • Is True For Any(All Players(Team 2), Is In Line of Sight(Event Player, Current Array Element, Barriers Do Not Block LOS)) == True;
  • }
  • actions {
  • Log To Inspector(Custom String("{0} is in line of sight of {1}", Event Player, Closest Player To(Event Player, Team 2), Null));
  • "Slow hider when in LOS and show Hud indicator"
  • Set Move Speed(Event Player, Divide((Event Player).BaseMoveSpeed, (Event Player).HiderSlowFactor));
  • Set Jump Vertical Speed(Event Player, Divide((Event Player).BaseJumpHeight, (Event Player).HiderSlowFactor));
  • Set Ability 1 Enabled(Event Player, False);
  • Set Ability 2 Enabled(Event Player, False);
  • Set Player Variable(Event Player, SlingshotEnabled, False);
  • Set Secondary Fire Enabled(Event Player, If-Then-Else(Compare(Hero Of(Event Player), ==, Hero(Wrecking Ball)), True, False));
  • Play Effect(Event Player, Explosion Sound, Color(White), Event Player, 250);
  • "Destroy Sombra's Translocator"
  • If(And(Compare(Hero Of(Event Player), ==, Hero(Sombra)), Is Using Ability 2(Event Player)));
  • Press Button(Event Player, Button(Interact));
  • End;
  • "Knock Sombra out of stealth"
  • If(And(Compare(Hero Of(Event Player), ==, Hero(Sombra)), Is Using Ability 1(Event Player)));
  • Cancel Primary Action(Event Player);
  • End;
  • "Prevent Wrecking Ball from losing grapple"
  • If(And(Not(Compare(Hero Of(Event Player), ==, Hero(Wrecking Ball))), Is Moving(Event Player)));
  • Cancel Primary Action(Event Player);
  • End;
  • Create HUD Text(Event Player, Null, Null, Custom String("{0} YOU ARE WITHIN LINE OF SIGHT OF A SEEKER {0}", Icon String(Warning), Null, Null), Top, 2, Null, Null, Color(Rose), Visible To Sort Order String and Color, Default Visibility);
  • Set Player Variable(Event Player, Hud_Detection, Last Text ID);
  • "Wait for hider to be out of LOS"
  • Wait Until(Is True For All(All Players(Team 2), Not(Is In Line of Sight(Event Player, Current Array Element, Barriers Do Not Block LOS))), 9999);
  • "Return hider state to normal"
  • Set Move Speed(Event Player, (Event Player).BaseMoveSpeed);
  • Set Jump Vertical Speed(Event Player, (Event Player).BaseJumpHeight);
  • Set Ability 1 Enabled(Event Player, True);
  • Set Ability 2 Enabled(Event Player, True);
  • Call Subroutine(RestrictAbilities);
  • Destroy HUD Text((Event Player).Hud_Detection);
  • Set Player Variable(Event Player, Hud_Detection, Null);
  • Log To Inspector(Custom String("{0} is no longer in line of sight", Event Player, Null, Null));
  • }
  • }
  • rule ("Hiders Joined Late") {
  • event {
  • Ongoing - Each Player;
  • Team 1;
  • All;
  • }
  • conditions {
  • Global.CurrentGameState == 2;
  • Has Spawned(Event Player) == False;
  • }
  • actions {
  • Set Player Variable(Event Player, JoinedLate, True);
  • }
  • }
  • rule ("Kill Hiders Who Joined Late") {
  • event {
  • Ongoing - Each Player;
  • Team 1;
  • All;
  • }
  • conditions {
  • Global.CurrentGameState == 2;
  • (Event Player).JoinedLate == True;
  • Has Spawned(Event Player) == True;
  • }
  • actions {
  • Disable Hero HUD(Event Player);
  • "Create hud"
  • Create In-World Text(Event Player, Value In Array(Array(Custom String("YOU JOINED LATE!", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Update Every Frame(Add(Eye Position(Event Player), Facing Direction Of(Event Player))), 5, Do Not Clip, Visible To and Position, Color(Rose), Visible Never);
  • Modify Player Variable(Event Player, Huds_JoinedLate, Append To Array, Last Text ID);
  • Create In-World Text(Event Player, Value In Array(Array(Custom String("YOU WILL BE PUT INTO SPECTATOR", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Update Every Frame(Add(Add(Eye Position(Event Player), Evaluate Once(Vector(0, -0.1, 0))), Facing Direction Of(Event Player))), 2, Do Not Clip, Visible To and Position, Color(Turquoise), Visible Never);
  • Modify Player Variable(Event Player, Huds_JoinedLate, Append To Array, Last Text ID);
  • Create In-World Text(Event Player, Value In Array(Array(Custom String("PLEASE WAIT FOR THE NEXT ROUND", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Update Every Frame(Add(Add(Eye Position(Event Player), Evaluate Once(Vector(0, -0.2, 0))), Facing Direction Of(Event Player))), 2, Do Not Clip, Visible To and Position, Color(Turquoise), Visible Never);
  • Modify Player Variable(Event Player, Huds_JoinedLate, Append To Array, Last Text ID);
  • Set Status(Event Player, Null, Rooted, 5);
  • Wait(5, Ignore Condition);
  • "Destroy all hud text"
  • For Player Variable(Event Player, playerHudIndex, 0, Count Of((Event Player).Huds_JoinedLate), 1);
  • Destroy In-World Text(Value In Array((Event Player).Huds_JoinedLate, (Event Player).playerHudIndex));
  • End;
  • Set Player Variable(Event Player, Huds_JoinedLate, Null);
  • "Set JoinedLate to false so the spawn room kill rule can run"
  • Set Player Variable(Event Player, JoinedLate, False);
  • Enable Hero HUD(Event Player);
  • }
  • }
  • rule ("Sombra Invisibility Tracker") {
  • event {
  • Ongoing - Each Player;
  • Team 1;
  • Sombra;
  • }
  • conditions {
  • Has Spawned(Event Player) == True;
  • Is Using Ability 1(Event Player) == True;
  • }
  • actions {
  • "Create effects and hud"
  • Create Effect(All Players(All Teams), Bad Aura, Color(Team 1), Update Every Frame(Add(Position Of(Event Player), Up)), 1, Visible To Position Radius and Color);
  • Modify Player Variable(Event Player, Effects_SombraInvis, Append To Array, Last Created Entity);
  • Create In-World Text(All Players(Team 2), Event Player, Event Player, 1, Clip Against Surfaces, Visible To Position and String, Color(Team 1), Default Visibility);
  • Modify Player Variable(Event Player, Effects_SombraInvis, Append To Array, Last Text ID);
  • Create HUD Text(Event Player, Null, Null, Value In Array(Array(Custom String("{0} YOU ARE VISIBLE TO SEEKERS {0}", Icon String(Warning), Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Top, 2, Null, Null, Color(Rose), Visible To Sort Order String and Color, Default Visibility);
  • Modify Player Variable(Event Player, Effects_SombraInvis, Append To Array, Last Text ID);
  • Wait Until(Not(Is Using Ability 1(Event Player)), 9999);
  • "Destroy all hud text and effects"
  • For Player Variable(Event Player, playerHudIndex, 0, Count Of((Event Player).Effects_SombraInvis), 1);
  • Destroy In-World Text(Value In Array((Event Player).Effects_SombraInvis, (Event Player).playerHudIndex));
  • Destroy HUD Text(Value In Array((Event Player).Effects_SombraInvis, (Event Player).playerHudIndex));
  • Destroy Effect(Value In Array((Event Player).Effects_SombraInvis, (Event Player).playerHudIndex));
  • End;
  • Set Player Variable(Event Player, Effects_SombraInvis, Null);
  • }
  • }
  • rule ("Sombra: Destroy Translocator") {
  • event {
  • Ongoing - Each Player;
  • Team 1;
  • Sombra;
  • }
  • conditions {
  • Has Spawned(Event Player) == True;
  • Is Using Ability 2(Event Player) == True;
  • }
  • actions {
  • Create HUD Text(Event Player, Null, Null, Value In Array(Array(Custom String("{0} YOUR TRANSLOCATOR WILL BE DESTROYED IN {1} SECONDS OR WHEN IT IS OUT OF LOS {0}", Icon String(Warning), Ability Cooldown(Event Player, Button(Ability 2)), Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Top, 2, Null, Null, Color(Rose), Visible To Sort Order String and Color, Default Visibility);
  • Set Player Variable(Event Player, Hud_SombraTrans, Last Text ID);
  • Wait Until(Or(Or(Compare(Ability Cooldown(Event Player, Button(Ability 2)), ==, 0), Not(Is Using Ability 2(Event Player))), Not(Is In Line of Sight(Eye Position(Event Player), Evaluate Once(Ray Cast Hit Position(Eye Position(Event Player), Add(Eye Position(Event Player), Multiply(Facing Direction Of(Event Player), 25)), Null, Event Player, False)), Barriers Do Not Block LOS))), 6);
  • Press Button(Event Player, Button(Interact));
  • "Destroy all hud text and effects"
  • Destroy HUD Text((Event Player).Hud_SombraTrans);
  • Set Player Variable(Event Player, Hud_SombraTrans, Null);
  • }
  • }
  • rule ("Sombra: Clear Effects When Switching Heroes") {
  • event {
  • Ongoing - Each Player;
  • Team 1;
  • All;
  • }
  • conditions {
  • Hero Of(Event Player) != Hero(Sombra);
  • }
  • actions {
  • "Destroy all hud text and effects"
  • For Player Variable(Event Player, playerHudIndex, 0, Count Of((Event Player).Effects_SombraInvis), 1);
  • Destroy In-World Text(Value In Array((Event Player).Effects_SombraInvis, (Event Player).playerHudIndex));
  • Destroy HUD Text(Value In Array((Event Player).Effects_SombraInvis, (Event Player).playerHudIndex));
  • Destroy Effect(Value In Array((Event Player).Effects_SombraInvis, (Event Player).playerHudIndex));
  • End;
  • Set Player Variable(Event Player, Effects_SombraInvis, Null);
  • }
  • }
  • rule ("Hider Laying Down") {
  • event {
  • Ongoing - Each Player;
  • Team 1;
  • All;
  • }
  • conditions {
  • Global.WS_SET_LAYING_DOWN == True;
  • Or(Compare((Event Player).CameraState, ==, 0), Compare((Event Player).CameraState, ==, 2)) == True;
  • Is In Spawn Room(Event Player) == False;
  • Is Communicating Any Emote(Event Player) == True;
  • Is Button Held(Event Player, Button(Crouch)) == True;
  • }
  • actions {
  • Set Player Variable(Event Player, LayingDownCameraEnabled, True);
  • Set Player Variable(Event Player, CameraState, 1);
  • Set Status(Event Player, Null, Knocked Down, 9999);
  • Wait(1, Ignore Condition);
  • Wait Until(And(Compare((Event Player).CameraState, ==, 1), Is True For Any(Array(Button(Jump), Button(Ability 1), Button(Ability 2), Button(Crouch), Button(Interact), Button(Melee), Button(Primary Fire), Button(Secondary Fire), Button(Ultimate)), Is Button Held(Event Player, Current Array Element))), 9999);
  • Clear Status(Event Player, Knocked Down);
  • Set Player Variable(Event Player, LayingDownCameraEnabled, False);
  • "Return to previous camera state"
  • If(Compare((Event Player).ThirdPersonCameraEnabled, ==, True));
  • Set Player Variable(Event Player, CameraState, 2);
  • Call Subroutine(StartThirdPersonCamera);
  • Else;
  • Set Player Variable(Event Player, CameraState, 0);
  • }
  • }
  • rule ("Refresh Resurrect Cooldown") {
  • event {
  • Ongoing - Each Player;
  • Team 1;
  • Mercy;
  • }
  • conditions {
  • Global.WS_SET_MODE == 3;
  • Global.CurrentGameState == 2;
  • Is Using Ability 2(Event Player) == True;
  • }
  • actions {
  • Wait Until(Is Using Ability 2(Event Player), 9999);
  • Set Ability Cooldown(Event Player, Button(Ability 2), 0);
  • }
  • }
  • rule ("Seeker Setup") {
  • event {
  • Ongoing - Each Player;
  • Team 2;
  • All;
  • }
  • actions {
  • "Seeker Setup"
  • Set Player Allowed Heroes(Event Player, If-Then-Else(Global.WS_SET_ADV_SEEK_ALLOWH, All Heroes, Remove From Array(All Heroes, Array(Hero(Moira), Hero(Zenyatta), Hero(Sombra)))));
  • "Mercy V. Rein"
  • If(True);
  • Skip(Value In Array(Array(5, 0), Add(1, Index Of Array Value(Array(3), Global.WS_SET_MODE))));
  • //__label_switch_8_0__:
  • Set Player Allowed Heroes(Event Player, Hero(Reinhardt));
  • Set Move Speed(Event Player, Multiply((Event Player).BaseMoveSpeed, 2));
  • Set Jump Vertical Speed(Event Player, Multiply((Event Player).BaseJumpHeight, 1.75));
  • Set Secondary Fire Enabled(Event Player, False);
  • Else;
  • //__label_switch_8_default__:
  • Else;
  • End;
  • Wait Until(Has Spawned(Event Player), 9999);
  • "Create Seeker Name"
  • If(True);
  • Skip(Value In Array(Array(1, 0), Add(1, Index Of Array Value(Array(11), Global.WS_SET_SEEKER_OUTLINES))));
  • //__label_switch_9_0__:
  • Else;
  • //__label_switch_9_default__:
  • Create In-World Text(All Players(Team 1), Event Player, Event Player, 1, Clip Against Surfaces, Visible To Position and String, Color(Team 2), Default Visibility);
  • Else;
  • End;
  • "Hider Outlines"
  • Start Forcing Player Outlines(All Players(Team 1), Event Player, Global.WS_SET_USEOUTLINE, Color(Team 1), Default);
  • Wait Until(Not(Is In Spawn Room(Event Player)), 9999);
  • Set Status(Event Player, Null, Phased Out, 9999);
  • Log To Inspector(Custom String("Seeker Setup finished for {0}", Event Player, Null, Null));
  • }
  • }
  • rule ("Update Hider Outline") {
  • event {
  • Player Joined Match;
  • Team 1;
  • All;
  • }
  • actions {
  • Start Forcing Player Outlines(Event Player, All Players(Team 2), Global.WS_SET_USEOUTLINE, Color(Team 1), Default);
  • }
  • }
  • rule ("Clear Seeker Name") {
  • event {
  • Player Left Match;
  • Team 2;
  • All;
  • }
  • actions {
  • Destroy In-World Text((Event Player).Hud_Seeker_Name);
  • }
  • }
  • rule ("Seeker Assistance") {
  • event {
  • Ongoing - Each Player;
  • Team 2;
  • All;
  • }
  • conditions {
  • Global.WS_SET_SEEKER_ASSIST == True;
  • Has Spawned(Event Player) == True;
  • Count Of(Filtered Array(Players Within Radius(Event Player, 30, Team 1, Off), Is Alive(Current Array Element))) > 0;
  • }
  • actions {
  • "Create hud text"
  • Create HUD Text(Event Player, Null, Null, Value In Array(Array(Custom String("{0} THERE ARE HIDERS IN THIS AREA {0}", Icon String(Warning), Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Top, 2, Null, Null, Color(Rose), Visible To Sort Order String and Color, Default Visibility);
  • Set Player Variable(Event Player, Hud_Seeker_Assistance, Last Text ID);
  • "Wait until there are no hiders in range"
  • Wait Until(Compare(Count Of(Filtered Array(Players Within Radius(Event Player, 30, Team 1, Off), Is Alive(Current Array Element))), ==, 0), 9999);
  • "Remove hud text"
  • Destroy HUD Text((Event Player).Hud_Seeker_Assistance);
  • Set Player Variable(Event Player, Hud_Seeker_Assistance, Null);
  • }
  • }
  • rule ("____________Skirmish Rules") {
  • event {
  • Ongoing - Global;
  • }
  • }
  • rule ("Title Hud") {
  • event {
  • Ongoing - Global;
  • }
  • conditions {
  • Current Game Mode == Game Mode(Skirmish);
  • }
  • actions {
  • Create In-World Text(All Players(All Teams), Value In Array(Array(Custom String("Hide & Seek", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Add(Objective Position(Objective Index), Vector(0, 4, 0)), 5, Do Not Clip, Visible To and Position, Color(Blue), Visible Never);
  • Modify Global Variable(Hud_GameTitle, Append To Array, Last Text ID);
  • Create In-World Text(All Players(All Teams), Value In Array(Array(Custom String("Ultimate", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Add(Objective Position(Objective Index), Vector(0, 3.5, 0)), 2, Do Not Clip, Visible To and Position, Color(Sky Blue), Visible Never);
  • Modify Global Variable(Hud_GameTitle, Append To Array, Last Text ID);
  • Create In-World Text(All Players(All Teams), Custom String("{0}: {1}", Value In Array(Array(Custom String("Style", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Value In Array(Array(Value In Array(Array(Custom String("DEFAULT", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Value In Array(Array(Custom String("GLITCH", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Value In Array(Array(Custom String("TINY", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Value In Array(Array(Custom String("MERCY VS. REINHARDT", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null))))), Global.WS_SET_MODE_RAW), Null), Add(Objective Position(Objective Index), Vector(0, 3, 0)), 1, Do Not Clip, Visible To Position and String, Color(Rose), Visible Never);
  • Modify Global Variable(Hud_GameTitle, Append To Array, Last Text ID);
  • Create In-World Text(All Players(All Teams), Value In Array(Array(Custom String("Waiting For Players", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Add(Objective Position(Objective Index), Vector(0, 2.25, 0)), 1, Do Not Clip, Visible To and Position, Color(White), Visible Never);
  • Modify Global Variable(Hud_GameTitle, Append To Array, Last Text ID);
  • Create Effect(All Players(All Teams), Ring, Color(Turquoise), Objective Position(Objective Index), 10, Visible To Position and Radius);
  • Modify Global Variable(Hud_GameTitle, Append To Array, Last Created Entity);
  • Wait Until(Compare(Global.CurrentGameState, !=, 0), 9999);
  • For Global Variable(globalHudIndex, 0, Count Of(Global.Hud_GameTitle), 1);
  • Destroy In-World Text(Value In Array(Global.Hud_GameTitle, Global.globalHudIndex));
  • Destroy Effect(Value In Array(Global.Hud_GameTitle, Global.globalHudIndex));
  • End;
  • Set Global Variable(Hud_GameTitle, Null);
  • }
  • }
  • rule ("Player Setup") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions {
  • Or(Compare(Current Game Mode, ==, Game Mode(Skirmish)), Compare(Current Game Mode, ==, Game Mode(Capture The Flag))) == True;
  • }
  • actions {
  • "Teleport to Objective"
  • Wait Until(Has Spawned(Event Player), 9999);
  • Set Player Variable(Event Player, DvaMechPosition, Position Of(Event Player));
  • Call Subroutine(RestrictAbilities);
  • If(Compare(Current Game Mode, ==, Game Mode(Capture The Flag)));
  • Disable Game Mode In-World UI(Event Player);
  • Abort;
  • End;
  • If(Compare(Global.CurrentGameState, ==, 0));
  • Teleport(Event Player, Nearest Walkable Position(Add(Objective Position(Objective Index), Vector(Random Integer(-10, 10), 0, Random Integer(-10, 10)))));
  • Wait(0.016, Ignore Condition);
  • Set Facing(Event Player, Add(Direction Towards(Eye Position(Event Player), Objective Position(Objective Index)), Vector(0, 0.5, 0)), To World);
  • }
  • }
  • rule ("Disable Abilities In Spawn") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions {
  • Or(Compare(Current Game Mode, ==, Game Mode(Skirmish)), Compare(Current Game Mode, ==, Game Mode(Capture The Flag))) == True;
  • Is In Spawn Room(Event Player) == True;
  • }
  • actions {
  • Set Ability 1 Enabled(Event Player, False);
  • Set Ability 2 Enabled(Event Player, False);
  • Set Secondary Fire Enabled(Event Player, False);
  • Cancel Primary Action(Event Player);
  • Wait Until(Not(Is In Spawn Room(Event Player)), 9999);
  • Call Subroutine(RestrictAbilities);
  • }
  • }
  • rule ("Prevent Flag Capture") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions {
  • Current Game Mode == Game Mode(Capture The Flag);
  • Distance Between(Position Of(Event Player), Value In Array(Array(Flag Position(Team 2), Flag Position(Team 1)), Index Of Array Value(Array(Team 1, Team 2), Team Of(Event Player)))) < 3;
  • }
  • actions {
  • Apply Impulse(Event Player, Direction Towards(Value In Array(Array(Flag Position(Team 2), Flag Position(Team 1)), Index Of Array Value(Array(Team 1, Team 2), Team Of(Event Player))), Position Of(Event Player)), 10, To World, Cancel Contrary Motion);
  • Wait(0.016, Ignore Condition);
  • Loop If Condition Is True;
  • }
  • }
  • rule ("D.va: TP to Mech Position (Hider)") {
  • event {
  • Ongoing - Each Player;
  • Team 1;
  • D.Va;
  • }
  • conditions {
  • Or(Compare(Current Game Mode, ==, Game Mode(Skirmish)), Compare(Current Game Mode, ==, Game Mode(Capture The Flag))) == True;
  • Global.CurrentGameState == 1;
  • (Event Player).DvaHasTeleported == False;
  • }
  • actions {
  • Set Player Variable(Event Player, DvaHasTeleported, True);
  • Teleport(Event Player, (Event Player).DvaMechPosition);
  • }
  • }
  • rule ("D.va: TP to Mech Position (Seeker)") {
  • event {
  • Ongoing - Each Player;
  • Team 2;
  • D.Va;
  • }
  • conditions {
  • Or(Compare(Current Game Mode, ==, Game Mode(Skirmish)), Compare(Current Game Mode, ==, Game Mode(Capture The Flag))) == True;
  • Global.CurrentGameState == 1;
  • Is In Spawn Room(Event Player) == False;
  • }
  • actions {
  • Wait(0.25, Abort When False);
  • Teleport(Event Player, (Event Player).DvaMechPosition);
  • }
  • }
  • rule ("Kill Hider in Spawn Room") {
  • event {
  • Ongoing - Each Player;
  • Team 1;
  • All;
  • }
  • conditions {
  • Or(Compare(Current Game Mode, ==, Game Mode(Skirmish)), Compare(Current Game Mode, ==, Game Mode(Capture The Flag))) == True;
  • Global.CurrentGameState == 2;
  • Is In Spawn Room(Event Player) == True;
  • (Event Player).JoinedLate == False;
  • }
  • actions {
  • Set Player Variable(Event Player, ResurrectBlocked, True);
  • Kill(Event Player, Null);
  • Wait(0.016, Ignore Condition);
  • Loop If Condition Is True;
  • }
  • }
  • rule ("Respawn Seeker if they leave Spawn Room") {
  • event {
  • Ongoing - Each Player;
  • Team 2;
  • All;
  • }
  • conditions {
  • Or(Compare(Current Game Mode, ==, Game Mode(Skirmish)), Compare(Current Game Mode, ==, Game Mode(Capture The Flag))) == True;
  • Global.CurrentGameState == 1;
  • Is In Spawn Room(Event Player) == False;
  • }
  • actions {
  • Skip If(Compare(Hero Of(Event Player), ==, Hero(D.Va)), 1);
  • Respawn(Event Player);
  • //skip_respawn:
  • Small Message(Event Player, Value In Array(Array(Custom String("Wait until Seeking Phase to Leave", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))));
  • Log To Inspector(Custom String("{0} left spawn room during hiding phase, respawning", Event Player, Null, Null));
  • }
  • }
  • rule ("Seeker Noclip Barrier") {
  • event {
  • Ongoing - Each Player;
  • Team 2;
  • All;
  • }
  • conditions {
  • Current Game Mode == Game Mode(Skirmish);
  • Global.WS_SET_MODE != 4;
  • Global.CurrentGameState == 2;
  • Is Moving(Event Player) == True;
  • Is On Ground(Event Player) == True;
  • Is In Line of Sight(Eye Position(Event Player), Add(World Vector Of(Throttle Of(Event Player), Event Player, Rotation And Translation), Vector(0, Evaluate Once(Divide(Distance Between(Eye Position(Event Player), Position Of(Event Player)), 2)), 0)), Barriers Do Not Block LOS) == True;
  • }
  • actions {
  • "Disable collision if the player is within line of sight of a point in the direction of throttle."
  • Disable Movement Collision With Environment(Event Player, False);
  • Wait(0.05, Ignore Condition);
  • Loop If Condition Is True;
  • Enable Movement Collision With Environment(Event Player);
  • }
  • }
  • rule ("____________TDM Rules") {
  • event {
  • Ongoing - Global;
  • }
  • }
  • rule ("Player Setup") {
  • event {
  • Ongoing - Each Player;
  • All;
  • All;
  • }
  • conditions {
  • Current Game Mode == Game Mode(Team Deathmatch);
  • }
  • actions {
  • Wait Until(Has Spawned(Event Player), 9999);
  • Call Subroutine(RestrictAbilities);
  • }
  • }
  • rule ("Kill Hider") {
  • event {
  • Player Joined Match;
  • Team 1;
  • All;
  • }
  • conditions {
  • Current Game Mode == Game Mode(Team Deathmatch);
  • Global.CurrentGameState == 2;
  • }
  • actions {
  • Wait Until(Compare((Event Player).JoinedLate, ==, True), 9999);
  • Wait Until(Compare((Event Player).JoinedLate, ==, False), 9999);
  • Kill(Event Player, Null);
  • }
  • }
  • rule ("Lock Seeker in place hud") {
  • event {
  • Ongoing - Global;
  • }
  • conditions {
  • Current Game Mode == Game Mode(Team Deathmatch);
  • Global.CurrentGameState == 1;
  • }
  • actions {
  • Create HUD Text(All Players(Team 2), Null, Null, Value In Array(Array(Custom String("You are currently blind while the hiders hide!", Null, Null, Null)), Max(False, Index Of Array Value(Global.practiceRangeTranslations, Custom String("{0}", Map(Practice Range), Null, Null)))), Top, 2, Null, Null, Color(White), Visible To and String, Default Visibility);
  • Modify Global Variable(Hud_Seeker_Blindness, Append To Array, Last Text ID);
  • Wait Until(Compare(Global.CurrentGameState, ==, 2), 9999);
  • "Destroy all hud text and effects"
  • For Global Variable(globalHudIndex, 0, Count Of(Global.Hud_Seeker_Blindness), 1);
  • Destroy HUD Text(Value In Array(Global.Hud_Seeker_Blindness, Global.globalHudIndex));
  • End;
  • Set Global Variable(Hud_Seeker_Blindness, Null);
  • }
  • }
  • rule ("Lock Seeker in place until seeking phase") {
  • event {
  • Ongoing - Each Player;
  • Team 2;
  • All;
  • }
  • conditions {
  • Current Game Mode == Game Mode(Team Deathmatch);
  • Global.CurrentGameState == 1;
  • Has Spawned(Event Player) == True;
  • }
  • actions {
  • Log To Inspector(Custom String("Locking {0} in place", Event Player, Null, Null));
  • Set Status(Event Player, Null, Rooted, 9999);
  • "Create fog"
  • Create Effect(Event Player, Bad Aura, Color(Black), Update Every Frame(Add(Eye Position(Event Player), Multiply(Facing Direction Of(Event Player), 3))), 1000, Visible To Position and Radius);
  • Modify Player Variable(Event Player, Effect_Seeker_Blindness, Append To Array, Last Created Entity);
  • Create Effect(Event Player, Bad Aura, Color(Black), Update Every Frame(Add(Eye Position(Event Player), Multiply(Facing Direction Of(Event Player), 4))), 1000, Visible To Position and Radius);
  • Modify Player Variable(Event Player, Effect_Seeker_Blindness, Append To Array, Last Created Entity);
  • Create Effect(Event Player, Bad Aura, Color(Black), Update Every Frame(Add(Eye Position(Event Player), Multiply(Facing Direction Of(Event Player), -3))), 1000, Visible To Position and Radius);
  • Modify Player Variable(Event Player, Effect_Seeker_Blindness, Append To Array, Last Created Entity);
  • Wait Until(Compare(Global.CurrentGameState, ==, 2), 9999);
  • "Destroy all hud text and effects"
  • For Player Variable(Event Player, playerHudIndex, 0, Count Of((Event Player).Effect_Seeker_Blindness), 1);
  • Destroy Effect(Value In Array((Event Player).Effect_Seeker_Blindness, (Event Player).playerHudIndex));
  • End;
  • Set Player Variable(Event Player, Effect_Seeker_Blindness, Null);
  • Clear Status(Event Player, Rooted);
  • }
  • }
  • rule ("Prevent Seeker from using hopping emotes") {
  • event {
  • Ongoing - Each Player;
  • Team 2;
  • All;
  • }
  • conditions {
  • Current Game Mode == Game Mode(Team Deathmatch);
  • Global.CurrentGameState == 1;
  • Is Communicating Any Emote(Event Player) == True;
  • }
  • actions {
  • Cancel Primary Action(Event Player);
  • }
  • }
Join the Workshop.codes Discord