Back to home

Echo No Echo FFA Gun Game (PTR)

2H4YA
click to copy
This game is archived.
If you with to unarchive it, click the "restore" button in the options menu.

Category:
Custom game mode

Author:
Jokaes

Rating:
1

Version:
1.0.1

Posted:
9 days ago

Last updated:
9 days ago

Tags:
echo ffa gun game ult ultimate jokaes

Project Links

Share this workshop!

Options

Echo No Echo FFA Gun Game

Switch to Echo or no Echo with every kill and keep your ultimate. You keep your ult % between switches.

Jokaes#2263

settings
{
	main
	{
		Description: "Echo No Echo FFA Gun Game. Switch to Echo or no Echo with every kill and keep your ultimate. You keep your ult % between switches. Created by Jokaes#2263"
	}

	lobby
	{
		Allow Players Who Are In Queue: Yes
		Max Spectators: 12
	}

	modes
	{
		Deathmatch
		{
			enabled maps
			{
				Black Forest
				Castillo
				Château Guillard
				Ecopoint: Antarctica
				Necropolis
			}
		}

		General
		{
			Allow Hero Switching: Off
			Game Mode Start: Immediately
			Respawn As Random Hero: On
			Spawn Health Packs: Enabled
		}
	}
}

variables
{
	player:
		0: heroList
}

subroutines
{
	0: createHeroList
}

rule("Endless")
{
	event
	{
		Ongoing - Global;
	}

	conditions
	{
		Is Game In Progress == True;
	}

	actions
	{
		Disable Built-In Game Mode Completion;
		Disable Built-In Game Mode Music;
		Disable Built-In Game Mode Announcer;
		Pause Match Time;
		Set Match Time(0.001);
	}
}

rule("(Sub) Create Hero List")
{
	event
	{
		Subroutine;
		createHeroList;
	}

	actions
	{
		Set Player Variable(Event Player, heroList, Empty Array);
		Modify Player Variable(Event Player, heroList, Append To Array, Hero(Echo));
		Modify Player Variable(Event Player, heroList, Append To Array, Random Value In Array(Remove From Array(All Heroes, Hero(Echo))));
	}
}

rule("Init player hero list")
{
	event
	{
		Ongoing - Each Player;
		All;
		All;
	}

	actions
	{
		Start Rule(createHeroList, Do Nothing);
	}
}

rule("HUD")
{
	event
	{
		Ongoing - Each Player;
		All;
		All;
	}

	actions
	{
		Create HUD Text(Event Player, Null, Null, Custom String("Echo No Echo FFA Gun Game", Null, Null, Null), Left, -999, White, White,
			White, Visible To and String, Default Visibility);
		Create HUD Text(Event Player, Null, Null, Custom String("You keep your ult % between switches", Null, Null, Null), Left, -998,
			White, White, White, Visible To and String, Default Visibility);
		Create HUD Text(Event Player, Null, Null, Custom String("Created by Jokaes#2263", Null, Null, Null), Left, -997, White, White,
			White, Visible To and String, Default Visibility);
		Create HUD Text(Filtered Array(Event Player, Compare(Hero Of(Event Player), !=, Value In Array(Player Variable(Event Player,
			heroList), 0))), Hero Icon String(Value In Array(Player Variable(Event Player, heroList), 0)), Null, Null, Left, 0, White,
			White, White, Visible To and String, Default Visibility);
		Create HUD Text(Filtered Array(Event Player, Compare(Hero Of(Event Player), !=, Value In Array(Player Variable(Event Player,
			heroList), 1))), Hero Icon String(Value In Array(Player Variable(Event Player, heroList), 1)), Null, Null, Left, 1, White,
			White, White, Visible To and String, Default Visibility);
		Create HUD Text(Filtered Array(Event Player, Compare(Hero Of(Event Player), ==, Value In Array(Player Variable(Event Player,
			heroList), 0))), Hero Icon String(Value In Array(Player Variable(Event Player, heroList), 0)), String("Current Hero", Null,
			Null, Null), Null, Left, 0, Blue, Blue, White, Visible To and String, Default Visibility);
		Create HUD Text(Filtered Array(Event Player, Compare(Hero Of(Event Player), ==, Value In Array(Player Variable(Event Player,
			heroList), 1))), Hero Icon String(Value In Array(Player Variable(Event Player, heroList), 1)), String("Current Hero", Null,
			Null, Null), Null, Left, 1, Blue, Blue, White, Visible To and String, Default Visibility);
	}
}

rule("Skip assembling heroes")
{
	event
	{
		Ongoing - Global;
	}

	conditions
	{
		Is Assembling Heroes == True;
	}

	actions
	{
		Set Match Time(0);
	}
}

rule("Start forcing hero")
{
	event
	{
		Ongoing - Each Player;
		All;
		All;
	}

	conditions
	{
		Is Game In Progress == True;
	}

	actions
	{
		Set Player Variable(Event Player, D, 0);
		Start Forcing Player To Be Hero(Event Player, Value In Array(Player Variable(Event Player, heroList), Player Variable(Event Player,
			D)));
	}
}

rule("Ult keeper")
{
	event
	{
		Player Dealt Final Blow;
		All;
		All;
	}

	actions
	{
		Set Player Variable(Event Player, U, Ultimate Charge Percent(Event Player));
		Wait(1, Ignore Condition);
		Set Ultimate Charge(Event Player, Player Variable(Event Player, U));
	}
}

rule("Next hero")
{
	event
	{
		Player Dealt Final Blow;
		All;
		All;
	}

	actions
	{
		Skip If(Compare(Player Variable(Event Player, D), ==, 2), 1);
		Modify Player Variable(Event Player, D, Add, 1);
		Skip If(Compare(Player Variable(Event Player, D), !=, 2), 2);
		Set Player Variable(Event Player, D, 0);
		Start Rule(createHeroList, Do Nothing);
		Wait(0.125, Ignore Condition);
		Start Forcing Player To Be Hero(Event Player, Value In Array(Player Variable(Event Player, heroList), Player Variable(Event Player,
			D)));
	}
}

rule("Effects and text")
{
	event
	{
		Player Dealt Final Blow;
		All;
		All;
	}

	actions
	{
		Create In-World Text(All Players(All Teams), Hero Icon String(Value In Array(Global Variable(L), Player Variable(Event Player,
			D))), Event Player, 1, Clip Against Surfaces, Visible To Position and String, White, Default Visibility);
		Set Player Variable(Event Player, I, Last Text ID);
		Wait(0.130, Ignore Condition);
		Play Effect(All Players(All Teams), Good Pickup Effect, Purple, Event Player, 1);
		Create Effect(All Players(All Teams), Sparkles, Purple, Event Player, 1, Visible To Position and Radius);
		Set Player Variable(Event Player, F, Last Created Entity);
		Wait(1.500, Ignore Condition);
		Destroy In-World Text(Player Variable(Event Player, I));
		Destroy Effect(Player Variable(Event Player, F));
	}
}

disabled rule("Dummy (TEST)")
{
	event
	{
		Ongoing - Each Player;
		All;
		All;
	}

	conditions
	{
		Is Button Held(Event Player, Interact) == True;
	}

	actions
	{
		Create Dummy Bot(Value In Array(Player Variable(Event Player, heroList), 0), All Teams, -1, Position Of(Event Player), Vector(0, 0,
			0));
	}
}

disabled rule("Created by Jokaes#2263")
{
	event
	{
		Ongoing - Global;
	}
}

Changelog

9 days ago 1.0.0

This revision contains no notes

FJJZE
click to copy