Return to post
settings
{
main
{
Description: "12 HOOKS 1 HOLE: WHEN PIGS FLY! CREATED BY: Block#12425. VERSION: 1.4.0. CODE: DK0DP. Contains support for KR language and infinite mode in workshop settings."
Description: "12 HOOKS 1 HOLE: WHEN PIGS FLY! CREATED BY: Block#12425. VERSION: 1.4.2. CODE: DK0DP. Contains support for KR language and infinite mode in workshop settings."
Mode Name: "12 Hooks 1 Hole: When Pigs Fly!"
}
lobby
{
Allow Players Who Are In Queue: Yes
Match Voice Chat: Enabled
Return To Lobby: Never
}
modes
{
Deathmatch
{
enabled maps
{
Ilios Well 0
}
}
General
{
Allow Hero Switching: Off
Game Mode Start: Immediately
Hero Limit: Off
Respawn Time Scalar: 0%
Score To Win: 40
Self Initiated Respawn: Off
Spawn Health Packs: Disabled
}
}
heroes
{
General
{
Junkrat
{
Concussion Mine Cooldown Time: 10%
Damage Dealt: 10%
Damage Received: 10%
Healing Received: 10%
Infinite Ultimate Duration: On
Jump Vertical Speed: 200%
Movement Gravity: 130%
Movement Speed: 140%
Primary Fire: Off
Spawn With Ultimate Ready: On
Ultimate Generation - Combat RIP-Tire: 0%
Ultimate Generation - Passive RIP-Tire: 0%
Ultimate Generation RIP-Tire: 10%
}
Roadhog
{
Chain Hook Cooldown Time: 0%
Damage Dealt: 10%
Damage Received: 10%
Healing Dealt: 10%
Healing Received: 10%
Jump Vertical Speed: 200%
Movement Gravity: 130%
Movement Speed: 140%
Primary Fire: Off
Secondary Fire: Off
Take a Breather: Off
Ultimate Generation - Combat Whole Hog: 0%
Ultimate Generation - Passive Whole Hog: 0%
Ultimate Generation Whole Hog: 10%
Whole Hog Knockback Scalar: 0%
}
enabled heroes
{
Roadhog
}
}
}
}
variables
{
global:
0: wellPosition
1: facePosition
2: spawn1Position
3: spawn2Position
4: spawn3Position
5: spawn4Position
6: spawn1Radius
7: spawn2Radius
8: spawn3Radius
9: spawn4Radius
10: stringCreatorVersion
11: stringCreator
12: stringVersion
13: stringTranslation
15: stringProject
17: stringProjectLink
18: stringCode
19: stringInteract
20: stringCrouch
21: stringSafe
22: stringEaster
23: junkratID
24: stringInfinite
25: infiniteMode
26: debugMode
27: stringUlt1
28: stringUlt2
29: ultColor
player:
0: randomSpawnInteger
1: ultForm
}
subroutines
{
0: variableSetup
1: effectSetup
2: hudSetup
3: setFacing
4: junkratSpawn
5: safeSpawn
6: lang_en
7: lang_kr
8: ultRoutine
}
disabled rule("12 Hooks 1 Hole: When Pigs Fly! by Block#12425. Version: 1.4.0")
disabled rule("12 Hooks 1 Hole: When Pigs Fly! by Block#12425. Version: 1.4.2")
{
event
{
Ongoing - Global;
}
}
disabled rule("Link to mode: https://workshop.codes/DK0DP")
{
event
{
Ongoing - Global;
}
}
disabled rule("========================================= Setup =========================================")
{
event
{
Ongoing - Global;
}
}
rule("Block#12425 - Initial Setup")
{
event
{
Ongoing - Global;
}
conditions
{
Is Assembling Heroes == True;
}
actions
{
Set Match Time(10);
Global.stringCreator = Custom String("Block#12425");
Global.stringVersion = Custom String("1.4.0");
Global.stringVersion = Custom String("1.4.2");
Global.stringProjectLink = Custom String("workshop.codes/DK0DP");
Global.stringInfinite = Custom String("");
Global.infiniteMode = Workshop Setting Toggle(Custom String("General"), Custom String("Enable Infinite mode?"), False, 0);
Global.debugMode = Workshop Setting Toggle(Custom String("Debug"), Custom String("Enable Debug mode?"), False, 0);
"This subroutine initializes the variables."
Call Subroutine(variableSetup);
"This subroutine creates all the effects in the game."
Call Subroutine(effectSetup);
"This subroutine creates all the HUD text in the game."
Call Subroutine(hudSetup);
"Turn this off to see the inspector."
Disable Inspector Recording;
If(Custom String("{0}", Hero(Ana)) == Custom String("아나"));
Call Subroutine(lang_kr);
Else;
Call Subroutine(lang_en);
}
}
rule("Block#12425 - Variable Setup Subroutine")
{
event
{
Subroutine;
variableSetup;
}
actions
{
"Well Position is used the for the top-down camera."
Global.wellPosition = Vector(-208.410, 8.159, -16.380);
"These four actions set the position for each spawn point."
Global.spawn1Position = Vector(-192.910, 2.665, -0.990);
Global.spawn2Position = Vector(-225.753, 0.604, -34.020);
Global.spawn3Position = Vector(-222.717, 2.576, 1.581);
Global.spawn4Position = Vector(-190.352, 2.537, -30.310);
"These four actions set the radius of each spawn point."
Global.spawn1Radius = 5;
Global.spawn2Radius = 6;
Global.spawn3Radius = 5;
Global.spawn4Radius = 5;
"This variable is the position that the camera looks at."
Global.facePosition = Vector(X Component Of(Global.wellPosition), Y Component Of(Global.wellPosition) - 5, Z Component Of(
Global.wellPosition));
}
}
rule("Block#12425 - Effect Creation Subroutine")
{
event
{
Subroutine;
effectSetup;
}
actions
{
"These four effects are for the spawn points."
Create Effect(All Players(All Teams), Sphere, Color(Blue), Global.spawn1Position, Global.spawn1Radius,
Visible To Position and Radius);
Create Effect(All Players(All Teams), Sphere, Color(Orange), Global.spawn2Position, Global.spawn2Radius,
Visible To Position and Radius);
Create Effect(All Players(All Teams), Sphere, Color(Green), Global.spawn3Position, Global.spawn3Radius,
Visible To Position and Radius);
Create Effect(All Players(All Teams), Sphere, Color(Red), Global.spawn4Position, Global.spawn4Radius,
Visible To Position and Radius);
"These four in world texts are used for the spawn points when the player is outside of them."
Create In-World Text(Filtered Array(All Players(All Teams), Distance Between(Global.spawn1Position, Position Of(
Current Array Element)) > Global.spawn1Radius), Global.stringSafe, Global.spawn1Position, 1.500, Clip Against Surfaces,
Visible To Position and String, Color(White), Default Visibility);
Create In-World Text(Filtered Array(All Players(All Teams), Distance Between(Global.spawn2Position, Position Of(
Current Array Element)) > Global.spawn2Radius), Global.stringSafe, Global.spawn2Position, 1.500, Clip Against Surfaces,
Visible To Position and String, Color(White), Default Visibility);
Create In-World Text(Filtered Array(All Players(All Teams), Distance Between(Global.spawn3Position, Position Of(
Current Array Element)) > Global.spawn3Radius), Global.stringSafe, Global.spawn3Position, 1.500, Clip Against Surfaces,
Visible To Position and String, Color(White), Default Visibility);
Create In-World Text(Filtered Array(All Players(All Teams), Distance Between(Global.spawn4Position, Position Of(
Current Array Element)) > Global.spawn4Radius), Global.stringSafe, Global.spawn4Position, 1.500, Clip Against Surfaces,
Visible To Position and String, Color(White), Default Visibility);
}
}
rule("Block#12425 - HUD Setup Subroutine")
{
event
{
Subroutine;
hudSetup;
}
actions
{
"These four HUD texts tell the player that they can use INTERACT to teleport between the zones. Each one is for a different spawn zone."
Create HUD Text(Filtered Array(All Players(All Teams), Distance Between(Global.spawn1Position, Position Of(Current Array Element))
<= Global.spawn1Radius), Custom String("{0}: {1}", Input Binding String(Button(Interact)), Global.stringInteract), Null, Null,
Top, 1, Color(Blue), Color(White), Color(White), Visible To and String, Default Visibility);
Create HUD Text(Filtered Array(All Players(All Teams), Distance Between(Global.spawn2Position, Position Of(Current Array Element))
<= Global.spawn2Radius), Custom String("{0}: {1}", Input Binding String(Button(Interact)), Global.stringInteract), Null, Null,
Top, 1, Color(Orange), Color(White), Color(White), Visible To and String, Default Visibility);
Create HUD Text(Filtered Array(All Players(All Teams), Distance Between(Global.spawn3Position, Position Of(Current Array Element))
<= Global.spawn3Radius), Custom String("{0}: {1}", Input Binding String(Button(Interact)), Global.stringInteract), Null, Null,
Top, 1, Color(Green), Color(White), Color(White), Visible To and String, Default Visibility);
Create HUD Text(Filtered Array(All Players(All Teams), Distance Between(Global.spawn4Position, Position Of(Current Array Element))
<= Global.spawn4Radius), Custom String("{0}: {1}", Input Binding String(Button(Interact)), Global.stringInteract), Null, Null,
Top, 1, Color(Red), Color(White), Color(White), Visible To and String, Default Visibility);
"These four actions tell the player to use crouch to enable the top-down camera. Each one is for a different spawn zone."
Create HUD Text(Filtered Array(All Players(All Teams), Distance Between(Global.spawn1Position, Position Of(Current Array Element))
<= Global.spawn1Radius), Custom String("{0}: {1}", Input Binding String(Button(Crouch)), Global.stringCrouch), Null, Null, Top,
2, Color(Blue), Color(White), Color(White), Visible To and String, Default Visibility);
Create HUD Text(Filtered Array(All Players(All Teams), Distance Between(Global.spawn2Position, Position Of(Current Array Element))
<= Global.spawn2Radius), Custom String("{0}: {1}", Input Binding String(Button(Crouch)), Global.stringCrouch), Null, Null, Top,
2, Color(Orange), Color(White), Color(White), Visible To and String, Default Visibility);
Create HUD Text(Filtered Array(All Players(All Teams), Distance Between(Global.spawn3Position, Position Of(Current Array Element))
<= Global.spawn3Radius), Custom String("{0}: {1}", Input Binding String(Button(Crouch)), Global.stringCrouch), Null, Null, Top,
2, Color(Green), Color(White), Color(White), Visible To and String, Default Visibility);
Create HUD Text(Filtered Array(All Players(All Teams), Distance Between(Global.spawn4Position, Position Of(Current Array Element))
<= Global.spawn4Radius), Custom String("{0}: {1}", Input Binding String(Button(Crouch)), Global.stringCrouch), Null, Null, Top,
2, Color(Red), Color(White), Color(White), Visible To and String, Default Visibility);
"These last four HUD texts are for the top right to let the player know what it is, who made it, and links to external web sites."
Create HUD Text(All Players(All Teams), Custom String("12 Hooks 1 Hole: When Pigs Fly!{0}", Global.stringInfinite), Null, Null,
Right, -5, Color(Orange), Color(White), Color(Orange), Visible To and String, Default Visibility);
Create HUD Text(All Players(All Teams), Null, Global.stringCreatorVersion, Null, Right, -4, Color(White), Color(White), Color(
White), Visible To and String, Default Visibility);
Create HUD Text(All Players(All Teams), Null, Global.stringTranslation, Custom String(" "), Right, -3.500, Color(White), Color(
White), Color(White), Visible To and String, Default Visibility);
Create HUD Text(All Players(All Teams), Null, Global.stringProject, Null, Right, -2, Color(White), Color(Green), Color(Green),
Visible To and String, Default Visibility);
Create HUD Text(All Players(All Teams), Null, Global.stringCode, Null, Right, -0.500, Color(Aqua), Color(Aqua), Color(Aqua),
Visible To and String, Default Visibility);
"HUD for Ult"
Create HUD Text(Filtered Array(All Players(All Teams), Is Using Ultimate(Current Array Element) == True && Hero Of(
Current Array Element) == Hero(Roadhog)), Null, Null, Custom String("{0} {1} {2}", Global.stringUlt1, Input Binding String(
Button(Primary Fire)), Global.stringUlt2), Top, 5, Color(White), Color(White), Global.ultColor, Visible To String and Color,
Visible Never);
}
}
rule("Block#12425 - Initial Player Setup")
{
event
{
Player Joined Match;
All;
All;
}
actions
{
"When a player joins, this variable is set so that the player spawns in a random spawn zone."
Event Player.randomSpawnInteger = Random Integer(0, 3);
Start Heal Over Time(Event Player, Event Player, 9999, 0.100);
Wait Until(Has Spawned(Event Player), 99999);
}
}
rule("Block#12425 - Player Death Setup")
{
event
{
Player Died;
All;
All;
}
actions
{
"Just like when a player joins, this is also reset when a player dies."
Event Player.randomSpawnInteger = Random Integer(0, 3);
Set Ultimate Charge(Event Player, 0);
}
}
rule("DEBUG")
{
event
{
Ongoing - Global;
}
conditions
{
Global.debugMode == True;
}
actions
{
Create HUD Text(Host Player, Facing Direction Of(Host Player), Null, Null, Left, 0, Color(White), Color(White), Color(White),
Visible To and String, Default Visibility);
Create HUD Text(Host Player, Server Load, String("Server Load"), Null, Left, 0, Color(White), Color(White), Color(White),
Visible To and String, Default Visibility);
Create HUD Text(Host Player, Server Load Average, String("Server Load Average"), Null, Left, 0, Color(White), Color(White), Color(
White), Visible To and String, Default Visibility);
Create HUD Text(Host Player, Server Load Peak, String("Server Load Peak"), Null, Left, 0, Color(White), Color(White), Color(White),
Visible To and String, Default Visibility);
}
}
rule("DEBUG DUMMY BOT SPAWN")
{
event
{
Ongoing - Each Player;
All;
All;
}
conditions
{
Global.debugMode == True;
Is Button Held(Event Player, Button(Melee)) == True;
}
actions
{
Create Dummy Bot(Hero(Roadhog), All Teams, -1, Event Player, Vector(0, 0, 0));
Event Player.Z = Last Created Entity;
Wait(5, Ignore Condition);
Teleport(Event Player.Z, Vector(-203.670, 1.623, -20.840));
Wait(0.500, Ignore Condition);
}
}
disabled rule("========================================= Languages =========================================")
{
event
{
Ongoing - Global;
}
}
rule("Block#12425 - English (EN)")
{
event
{
Subroutine;
lang_en;
}
actions
{
Global.stringInteract = Custom String("Teleport to another spawn");
Global.stringCrouch = Custom String("Top-Down View of Well");
Global.stringCreatorVersion = Custom String("Created By: {0}. Version: {1}", Global.stringCreator, Global.stringVersion);
Global.stringCode = Custom String("Code: DK0DP");
Global.stringProject = Custom String("Link: {0}", Global.stringProjectLink);
Global.stringTranslation = Custom String(" ");
Global.stringSafe = Custom String("Safe Zone");
Global.stringEaster = Custom String("Easter Egg found!");
Global.stringUlt1 = Custom String(
" \r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\nPress");
Global.stringUlt2 = Custom String("!");
}
}
rule("Block#12425 - 한국어 (KR) Thanks to 홀수돚거#3265 for KR Translation.")
{
event
{
Subroutine;
lang_kr;
}
actions
{
Global.stringInteract = Custom String("다른 스폰 위치로 텔레포트 ");
Global.stringCrouch = Custom String("우물 중심 탑-다운 뷰로 전환 ");
Global.stringCreatorVersion = Custom String("제작: {0}. 버전 {1}", Global.stringCreator, Global.stringVersion);
Global.stringCode = Custom String("코드: DK0DP");
Global.stringProject = Custom String("링크 : {0}", Global.stringProjectLink);
Global.stringTranslation = Custom String("한국어 번역을 도와주신 홀수돚거#3265님께 감사드립니다.");
Global.stringSafe = Custom String("안전 구역");
Global.stringEaster = Custom String("이스터에그를 찾으셨습니다!");
Global.stringUlt1 = Custom String(
" \r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n누르다");
Global.stringUlt2 = Custom String("!");
}
}
disabled rule("========================================= Roadhog Ult =========================================")
{
event
{
Ongoing - Global;
}
}
rule("Block#12425 - Ult Form Enable")
{
event
{
Ongoing - Each Player;
All;
All;
}
conditions
{
Is Using Ultimate(Event Player) == True;
Hero Of(Event Player) == Hero(Roadhog);
}
actions
{
"In 1.2.8, this ult became more merciful by providing an impulse at ult start. This impulse helps the player immediately start going upward."
Apply Impulse(Event Player, Vector(0, 1, 0), 10, To Player, Cancel Contrary Motion);
Play Effect(All Players(All Teams), Ring Explosion, Color(White), Event Player, 100);
Play Effect(All Players(All Teams), Bad Explosion, Color(White), Event Player, 100);
Play Effect(All Players(All Teams), Good Explosion, Color(Orange), Event Player, 1);
Set Facing(Event Player, Vector(X Component Of(Facing Direction Of(Event Player)) * 0.100, -1, Z Component Of(Facing Direction Of(
Event Player)) * 0.100), To World);
}
}
rule("Block#12425 - Roadhog Ult Press")
{
event
{
Ongoing - Each Player;
All;
All;
}
conditions
{
Hero Of(Event Player) == Hero(Roadhog);
Is Using Ultimate(Event Player) == True;
Is Button Held(Event Player, Button(Primary Fire)) == True;
}
actions
{
Call Subroutine(ultRoutine);
"In 1.2.8, this ult became more merciful by providing an impulse at ult start. This impulse helps the player immediately start going upward."
disabled Apply Impulse(Event Player, Vector(0, 1, 0), 5, To Player, Cancel Contrary Motion);
"This causes the player to go faster the longer they use the ult."
disabled Start Accelerating(Event Player, Up, 70, 10, To Player, Direction Rate and Max Speed);
"The player is forced to look downward when using the ult. The actions are simply too buggy for a dynamic camera during the ult."
disabled Start Facing(Event Player, Vector(X Component Of(Facing Direction Of(Event Player)) * 0.010, -1, Z Component Of(
Facing Direction Of(Event Player)) * 0.010), 400, To World, Direction and Turn Rate);
"This wait action basically sets how long the ult will last."
disabled Wait(1.700, Abort When False);
"This quick stun makes no sound effect, but ends the ult."
disabled Set Status(Event Player, Null, Stunned, 0.015);
}
}
rule("Block#12425 - Roadhog Ult UnPress")
{
event
{
Ongoing - Each Player;
All;
All;
}
conditions
{
disabled Is Using Ultimate(Event Player) != True;
(!Is Using Ultimate(Event Player) || !Is Button Held(Event Player, Button(Primary Fire))) == True;
Hero Of(Event Player) == Hero(Roadhog);
}
actions
{
"When the ult ends, the player is restored back to normal."
Stop Accelerating(Event Player);
Stop Facing(Event Player);
}
}
rule("Block#12425 - Roadhog Ult End")
{
event
{
Ongoing - Each Player;
All;
All;
}
conditions
{
Is Using Ultimate(Event Player) == False;
Hero Of(Event Player) == Hero(Roadhog);
}
actions
{
"When the ult ends, the player is restored back to normal."
Stop Accelerating(Event Player);
Stop Facing(Event Player);
}
}
rule("Block#12425 - Roadhog Kill (Ult -> 100%)")
{
event
{
Player Dealt Final Blow;
All;
All;
}
actions
{
"There is no ult charge, but when a player kills another, it is a guaranteed ult charge given to them."
Set Ultimate Charge(Event Player, 100);
}
}
rule("Block#12425 - Ult Routine")
{
event
{
Subroutine;
ultRoutine;
}
actions
{
"In 1.2.8, this ult became more merciful by providing an impulse at ult start. This impulse helps the player immediately start going upward."
disabled Apply Impulse(Event Player, Vector(0, 1, 0), 5, To Player, Cancel Contrary Motion);
"This causes the player to go faster the longer they use the ult."
Start Accelerating(Event Player, Facing Direction Of(Event Player) * -1, 70, 10, To World, Direction Rate and Max Speed);
Event Player.ultForm = Facing Direction Of(Event Player);
"The player is forced to look downward when using the ult. The actions are simply too buggy for a dynamic camera during the ult."
disabled Start Facing(Event Player, Facing Direction Of(Event Player), 400, To World, Direction and Turn Rate);
"This wait action basically sets how long the ult will last."
disabled Wait(1.700, Abort When False);
"This quick stun makes no sound effect, but ends the ult."
disabled Set Status(Event Player, Null, Stunned, 0.015);
}
}
rule("Block#12425 - Ult HUD Color Loop")
{
event
{
Ongoing - Global;
}
actions
{
Global.ultColor = Color(White);
Wait(0.250, Ignore Condition);
Global.ultColor = Color(Red);
Wait(0.250, Ignore Condition);
Loop;
}
}
disabled rule("========================================= Safe Zone =========================================")
{
event
{
Ongoing - Global;
}
}
rule("Block#12425 - Player Spawn")
{
event
{
Ongoing - Each Player;
All;
All;
}
conditions
{
Is Alive(Event Player) == True;
Has Spawned(Event Player) == True;
Is Dummy Bot(Event Player) == False;
}
actions
{
Call Subroutine(safeSpawn);
Start Heal Over Time(Event Player, Event Player, 9999, 1);
}
}
rule("Block#12425 - Safe Zone Setup")
{
event
{
Subroutine;
safeSpawn;
}
actions
{
"This if/else if logic statement tests the randomSpawnInteger to see which location the game should teleport them to."
If(Event Player.randomSpawnInteger == 0);
Teleport(Event Player, Global.spawn1Position);
Else If(Event Player.randomSpawnInteger == 1);
Teleport(Event Player, Global.spawn2Position);
Else If(Event Player.randomSpawnInteger == 2);
Teleport(Event Player, Global.spawn3Position);
Else;
Teleport(Event Player, Global.spawn4Position);
End;
"This subroutine is called to set the player appropriately in the right direction."
Call Subroutine(setFacing);
}
}
rule("Block#12425 - Player In Safe Zone")
{
event
{
Ongoing - Each Player;
All;
All;
}
conditions
{
Is Dummy Bot(Event Player) == False;
"This giant OR test basically is testing if the player is in any of the spawns."
(Distance Between(Global.spawn1Position, Position Of(Event Player)) <= Global.spawn1Radius || Distance Between(
Global.spawn2Position, Position Of(Event Player)) <= Global.spawn2Radius || Distance Between(Global.spawn3Position,
Position Of(Event Player)) <= Global.spawn3Radius || Distance Between(Global.spawn4Position, Position Of(Event Player))
<= Global.spawn4Radius) == True;
}
actions
{
"If so, the player is both invincible, invisible and cannot interact much with the outside world."
Set Status(Event Player, Null, Phased Out, 9999);
Set Invisible(Event Player, Enemies);
Set Ability 1 Enabled(Event Player, False);
}
}
rule("Block#12425 - Player Outside of Safe Zone")
{
event
{
Ongoing - Each Player;
All;
All;
}
conditions
{
(Distance Between(Global.spawn1Position, Position Of(Event Player)) > Global.spawn1Radius && Distance Between(
Global.spawn2Position, Position Of(Event Player)) > Global.spawn2Radius && Distance Between(Global.spawn3Position, Position Of(
Event Player)) > Global.spawn3Radius && Distance Between(Global.spawn4Position, Position Of(Event Player))
> Global.spawn4Radius) == True;
}
actions
{
"If so, the invincibility, invisibily are disabled, player can use hook again, and any camera going is stopped."
Clear Status(Event Player, Phased Out);
Set Invisible(Event Player, None);
Set Ability 1 Enabled(Event Player, True);
Stop Camera(Event Player);
}
}
rule("Block#12425 - Teleport Player to another zone")
{
event
{
Ongoing - Each Player;
All;
All;
}
conditions
{
Is Button Held(Event Player, Button(Interact)) == True;
(Distance Between(Global.spawn1Position, Position Of(Event Player)) <= Global.spawn1Radius || Distance Between(
Global.spawn2Position, Position Of(Event Player)) <= Global.spawn2Radius || Distance Between(Global.spawn3Position,
Position Of(Event Player)) <= Global.spawn3Radius || Distance Between(Global.spawn4Position, Position Of(Event Player))
<= Global.spawn4Radius) == True;
}
actions
{
"This if/else if logic statement will teleport the player to another spawn location depending on which zone they are in."
If(Distance Between(Global.spawn1Position, Position Of(Event Player)) <= Global.spawn1Radius);
Teleport(Event Player, Global.spawn4Position);
Else If(Distance Between(Global.spawn4Position, Position Of(Event Player)) <= Global.spawn4Radius);
Teleport(Event Player, Global.spawn2Position);
Else If(Distance Between(Global.spawn2Position, Position Of(Event Player)) <= Global.spawn2Radius);
Teleport(Event Player, Global.spawn3Position);
Else If(Distance Between(Global.spawn3Position, Position Of(Event Player)) <= Global.spawn3Radius);
Teleport(Event Player, Global.spawn1Position);
End;
"After that, the player is set facing the well."
Call Subroutine(setFacing);
"This wait is here to prevent the player from spamming the teleport action."
Wait(0.500, Ignore Condition);
}
}
rule("Block#12425 - Start Camera")
{
event
{
Ongoing - Each Player;
All;
All;
}
conditions
{
Is Button Held(Event Player, Button(Crouch)) == True;
(Distance Between(Global.spawn1Position, Position Of(Event Player)) <= Global.spawn1Radius || Distance Between(
Global.spawn2Position, Position Of(Event Player)) <= Global.spawn2Radius || Distance Between(Global.spawn3Position,
Position Of(Event Player)) <= Global.spawn3Radius || Distance Between(Global.spawn4Position, Position Of(Event Player))
<= Global.spawn4Radius) == True;
}
actions
{
"If the player crouches while in a zone, a top down camera is started."
Start Camera(Event Player, Vector(-208.319, 20, -16.289), Global.wellPosition, 0);
}
}
rule("Block#12425 - Stop Camera (No Crouch)")
{
event
{
Ongoing - Each Player;
All;
All;
}
conditions
{
Is Button Held(Event Player, Button(Crouch)) == False;
}
actions
{
"If the camera isn't stopped from the player leaving the zone, then the player must have let go the crouch key in order to stop it."
Stop Camera(Event Player);
}
}
rule("Block#12425 - Set Facing Subroutine")
{
event
{
Subroutine;
setFacing;
}
actions
{
"This subroutine sets the player facing towards the well. This wait action gives the player some time to teleport before running the set facing action."
Wait(0.010, Ignore Condition);
Set Facing(Event Player, Direction Towards(Position Of(Event Player), Global.facePosition), To World);
}
}
disabled rule("========================================= INFINITE MODE =========================================")
{
event
{
Ongoing - Global;
}
}
rule("Block#12425 - Infinite - Junkrat Spawn Subroutine")
{
event
{
Subroutine;
junkratSpawn;
}
actions
{
"This creates the Junkrat dummy bot."
Create Dummy Bot(Hero(Junkrat), All Teams, -1, Vector(-227.043, 6.768, -26.992), Vector(0, 0, 0));
"This ID will be referred to later."
Global.junkratID = Last Created Entity;
Wait(1.200, Ignore Condition);
"This teleports him to the bench."
Teleport(Global.junkratID, Vector(-227.043, 6.768, -26.992));
Wait(0.100, Ignore Condition);
"This orients him the right way for him to be sleeping."
Set Facing(Global.junkratID, Direction Towards(Global.junkratID, Vector(-224.089, 10.063, -15.746)), To World);
Set Status(Global.junkratID, Null, Asleep, 9999);
}
}
rule("Block#12425 - Infinite - Junkrat Easter Egg Creation")
{
event
{
Ongoing - Global;
}
conditions
{
Global.infiniteMode == True;
Is Game In Progress == True;
Count Of(Filtered Array(All Players(All Teams), Is Dummy Bot(Current Array Element) == True)) < 1;
Count Of(All Players(All Teams)) < 12;
}
actions
{
Call Subroutine(junkratSpawn);
Loop If Condition Is True;
}
}
rule("Block#12425 - Infinite - Junkrat Easter Egg Activation")
{
event
{
Player Earned Elimination;
All;
All;
}
conditions
{
Global.infiniteMode == True;
Is Game In Progress == True;
Hero Of(Victim) == Hero(Junkrat);
Is Dummy Bot(Victim) == True;
}
actions
{
"If a player kills the Junkrat bot, then the player becomes Junkrat."
Start Forcing Player To Be Hero(Event Player, Hero(Junkrat));
Wait(0.100, Ignore Condition);
Destroy Dummy Bot(All Teams, Slot Of(Global.junkratID));
"This counteracts the score addition that the player recieves from killing him."
Modify Player Score(Event Player, -1);
Small Message(Event Player, Global.stringEaster);
}
}
rule("Block#12425 - Infinite - Player Death Setup Junkrat")
{
event
{
Player Died;
All;
Junkrat;
}
conditions
{
Global.infiniteMode == True;
Is Dummy Bot(Event Player) == False;
}
actions
{
"When the player dies, he is forced back onto Roadhog."
Wait(0.500, Ignore Condition);
Call Subroutine(safeSpawn);
Start Forcing Player To Be Hero(Event Player, Hero(Roadhog));
}
}
rule("Block#12425 - Infinite - Prevent Gamemode Completion")
{
event
{
Ongoing - Global;
}
conditions
{
Global.infiniteMode == True;
Is Assembling Heroes == True;
}
actions
{
Disable Built-In Game Mode Completion;
Disable Built-In Game Mode Announcer;
Disable Built-In Game Mode Music;
}
}
rule("Block#12425 - Infinite - Pause Match Time")
{
event
{
Ongoing - Global;
}
conditions
{
Global.infiniteMode == True;
Is Game In Progress == True;
}
actions
{
Pause Match Time;
Set Match Time(721);
}
}
rule("Block#12425 - Infinite - String Variable Setup")
{
event
{
Ongoing - Global;
}
conditions
{
Global.infiniteMode == True;
}
actions
{
Global.stringInfinite = Custom String(" ∞");
}
}