//==================================================================================

event HudTournamentSetupPanelOpen
{
	Animate HudTournamentSetup	Position	"c-90 -70"	Linear 0.0 0.001
	Animate HudTournamentSetup	Position	"c-90 90"	Spline 0.001 0.2
}

event HudTournamentSetupPanelClose
{
	Animate HudTournamentSetup	Position	"c-90 90"	Linear 0.0 0.001
	Animate HudTournamentSetup	Position	"c-90 -70"	Spline 0.001 0.2
}

//==================================================================================

event RDPositiveScorePulse
{
	Animate Score FgColor	"25 255 25 255"		Linear 0.0 0.0
	Animate Score FgColor	"TanLight"			Linear 0.1 0.2
}

event RDNegativeScorePulse
{
	Animate Score FgColor	"255 75 75 255"		Linear 0.0 0.0
	Animate Score FgColor	"TanLight"			Linear 0.1 0.2
}

//==================================================================================

event HudSnapShotReminderIn
{
	Animate ScreenshotPanel		Position	"c-83 -50"	Linear 0.0 0.001
	Animate ScreenshotPanel		Position	"c-83 25"	Spline 0.001 0.2
}
	// Places the replay reminder in the same place as the snapshot reminder
event HudReplayReminderIn
{
	Animate ReplayReminder		Position	"c-83 -50"	Linear 0.0 0.001
	Animate ReplayReminder		Position	"c-83 25"	Spline 0.001 0.2
}
	// Puts the panel below the snapshot panel
event HudReplayReminderIn2
{
	Animate ReplayReminder		Position	"c-83 -50"	Linear 0.0 0.001
	Animate ReplayReminder		Position	"c-83 65"	Spline 0.001 0.2
}

//==================================================================================

event TeamStatus_PlayerDead
{
	SetVisible	respawntime 		1 0
	SetVisible	respawntimeshadow 	1 0
	SetVisible 	SkullPanel 			1 0
	SetVisible 	SkullPanelRed	  	1 0
	
	Animate		respawntime			FgColor		"220 100 100 255"	Accel 0.0 0.0
	Animate		respawntime			FgColor		"TanLight"			Accel 0.2 0.0

	SetVisible 	SkullPanelRed	  	1 0
	SetVisible 	SkullPanelRed	  	0 0.2
}
event TeamStatus_PlayerAlive
{
	SetVisible	respawntime 		0 0
	SetVisible	respawntimeshadow 	0 0
	SetVisible 	SkullPanel			0 0
	SetVisible 	SkullPanelRed	  	0 0
	
	RunEvent 	HudOverhealBarPulseLoop	0.4
}

event HudOverhealBarPulseLoop
{
	Animate		overhealbar 		Alpha		"100"				Linear 0.0 0.1
	Animate		overhealbar 		Alpha		"255"				Linear 0.1 0.4
	RunEvent 	HudOverhealBarPulseLoop	0.4
}


//==================================================================================

event HudReadyPulse
{
	Animate	TournamentInstructionsLabel 	FgColor		"White"		Spline 0.0 0.8
	Animate	TournamentInstructionsLabel 	FgColor		"RedSolid"		Spline 0.8 1.8
	
	RunEvent HudReadyPulseLoop	1.8
}

event HudReadyPulseLoop
{
	RunEvent HudReadyPulse			0.0
}

event HudReadyPulseEnd
{
	Animate	TournamentInstructionsLabel 	FgColor		"White"		Linear 0.0 0.8

	//StopEvent HudReadyPulse			0.0
	//StopEvent HudReadyPulseLoop		0.0
}

//==================================================================================

	// Spy Disguise
event HudSpyDisguiseChanged
{
	StopEvent HudSpyDisguiseHide 0.0

	Animate PlayerStatusSpyOutlineImageOverride				Alpha		"255"			Linear 0.0 0.2
	Animate PlayerStatusSpyOutlineImageOverride				Position	"c-267 c-136"	Linear 0.0 0.2
	Animate PlayerStatusSpyOutlineImageOverride				Size		"120 120"		Linear 0.0 0.2
	
	Animate PlayerStatusSpyOutlineImageOverrideMinMode		Alpha		"255"			Linear 0.0 0.2
	Animate PlayerStatusSpyOutlineImageOverrideMinMode		Position	"c-267 c-131"	Linear 0.0 0.2
	Animate PlayerStatusSpyOutlineImageOverrideMinMode		Size		"120 120"		Linear 0.1 0.3

	RunEvent HudSpyDisguiseHide	0.7
}

event HudSpyDisguiseHide
{
	Animate PlayerStatusSpyOutlineImageOverride				Position	"c-237 r69"		Linear 0.0 0.2
	Animate PlayerStatusSpyOutlineImageOverride				Size		"55 55"			Linear 0.0 0.2
	Animate PlayerStatusSpyOutlineImageOverride				Alpha		"0"				Linear 0.0 0.2
	
	Animate PlayerStatusSpyOutlineImageOverrideMinMode		Position	"c-237 r49"		Linear 0.0 0.2
	Animate PlayerStatusSpyOutlineImageOverrideMinMode		Size		"55 55"			Linear 0.0 0.2
	Animate PlayerStatusSpyOutlineImageOverrideMinMode		Alpha		"0"				Linear 0.1 0.3
}

event HudSpyDisguiseFadeIn
{
	RunEvent HudSpyDisguiseChanged	0
}


event HudSpyDisguiseFadeOut
{
	RunEvent HudSpyDisguiseChanged	0
}

//==================================================================================

event CompetitiveGame_LowerChatWindow
{
	//Fix stuck animations
    RunEvent HudHealthDyingPulseStop 0.1
    RunEvent HudHealthBonusPulseStop 0.1
    RunEvent HudLowAmmoPulseStop 0.1
    RunEvent HudMedicChargedStop 0.1
}

event CompetitiveGame_RestoreChatWindow { }
event HudTournament_MoveChatWindow { }

//==================================================================================

event SurveyShowSequence
{
	// Quickly closes survey
	RunEventChild Survey SurveyDelete 0
}

event SurveySubmitSequence { }

event SurveyDelete
{
	FireCommand 0 "delete"
}

event SurveyHideSequence { }

//==================================================================================

event HudMedicCharged
{
	Animate	ChargeMeter 	Alpha		"100"		Linear 0.0 0.1
	Animate	ChargeMeter 	Alpha		"255"		Linear 0.2 0.4

	RunEvent HudMedicChargedLoop 0.6
}

event HudMedicChargedLoop
{
	RunEvent HudMedicCharged 0.0
}

event HudMedicChargedStop
{
	StopEvent HudMedicCharged 0.0
	StopEvent HudMedicChargedLoop 0.0
	
	Animate	ChargeMeter 	Alpha		"255"		Linear 0.0 0.0
}

//==================================================================================

event ActiveTimerBGPulse
{	
	SetVisible ActiveTimerBG 1 0
}

event ActiveTimerHighlight
{
	StopEvent ActiveTimerDim 0.0
	StopEvent ActiveTimerHighlight2 0.0
	RunEvent ActiveTimerHighlight2 0.001
}

event ActiveTimerHighlight2
{
	SetVisible MatchHudActiveTimerBG 1 0.001
	RunEvent ActiveTimerHighlight2 0.001
}

event ActiveTimerDim
{
	StopEvent ActiveTimerHighlight2 0.0
	SetVisible MatchHudActiveTimerBG 0 0.001
	Animate	MatchHudActiveTimerBG 		Alpha	"255"	Linear 0.0 0.0
}
//===========================================

event OvertimeLabelPulseRed
{
	SetVisible OvertimeBG	1	0.0
	
	RunEvent OvertimeLabelPulseRed 0.001
}
event SuddenDeathLabelPulseRed { }

//===========================================

event HudTournament_MoveTimerDown
{
	Animate MatchCountdownLabel			Alpha	"0"		Linear 0.0 0.5
	Animate MatchCountdownLabelShadow	Alpha 	"0"		Linear 0.0 0.5

	SetVisible MatchCountdownLabel 0 0.5
	SetVisible MatchCountdownLabelShadow 0 0.5

	Animate MatchCountdownLabel			Alpha	"255"	Linear 1 0.0
	Animate MatchCountdownLabelShadow	Alpha	"255"	Linear 1 0.0

	Animate RoundCountdownLabel			Alpha	"0"		Linear  0.0 0.0
	Animate RoundCountdownLabelShadow	Alpha	"0"		Linear  0.0 0.0

	SetVisible RoundCountdownLabel 1 0
	SetVisible RoundCountdownLabelShadow 1 0
	
	Animate RoundCountdownLabel			Alpha "255" 	Linear 0.5 0.5
	Animate RoundCountdownLabelShadow	Alpha "255" 	Linear 0.5 0.5
}

event HudTournament_AnimateTeams_In { }

event HudTournament_AnimateTeams_Out { }

event HudMatchStatus_ShowMatchStartDoors
{
	Animate RoundCountdownLabel	Alpha 0 Linear 0.0 0.0
	Animate RoundCountdownLabelShadow	Alpha 0 Linear 0.0 0.0

	SetVisible RoundCountdownLabel 1 0
	SetVisible RoundCountdownLabelShadow 1 0
	
	Animate RoundCountdownLabel	Alpha 255 Linear 0.0 0.25
	Animate RoundCountdownLabelShadow	Alpha 255 Linear 0.0 0.25
	
	SetVisible RoundCountdownLabel 0 9.9
	SetVisible RoundCountdownLabelShadow 0 9.9
}

event HudMatchStatus_ShowRankMatch { }

event HudMatchStatus_ShowCountdown
{
	SetVisible RoundCountdownLabel 1 0
	SetVisible RoundCountdownLabelShadow 1 0
	
	SetVisible RoundCountdownLabel 0 9.9
	SetVisible RoundCountdownLabelShadow 0 9.9
}

event HudTournament_DoorsCleanup { }

event PlayDoorSlamParticles { }

event PlayDoorCloseAnim { }

event PlayDoorOpenAnim { }

event HudTournament_ShowTimerCompetitive
{
	SetVisible MatchCountdownLabel 1 0
	SetVisible MatchCountdownLabelShadow 1 0
}

event HudTournament_ShowTimerDefault
{
	SetVisible MatchCountdownLabel 1 0
	SetVisible MatchCountdownLabelShadow 1 0
}

event HudTournament_HideTimer
{
	SetVisible MatchCountdownLabel 0 0
	SetVisible MatchCountdownLabelShadow 0 0
}

event HudTournament_ShowRoundSign { }

event HudTournament_PlaySignAnim { }

event HudMatchStatus_ShowMatchWinDoors { }

event HudMatchStatus_ShowMatchWinDoors_NoOpen { }

event HudMatchSummary_SlideInPanels
{
	SetVisible StatsBgPanel 1 0.5
	
	Animate BlueTeamPanel 	xpos 	0 		Accel  0.5 0.5
	Animate RedTeamPanel 	xpos 	0 		Accel  0.5 0.5
}

//===========================================

event PvPRankLevelUpXPBar { }

event PvPRankLevelUpModel { }

event PvPRankLevelDownXPBar { }

event CompetitiveGame_ShowPvPRankPanel { }

event PvPRankPanelShowXPChange { }

event XPSourceShow_Positive { }

event XPSourceShow_Negative { }

//===========================================

event HasMOTDBlink { }

event HasNotificationsBlink { }

//===========================================

event MapVoted
{
	Animate VotesLabel	ypos	54		Deaccel 0	0.05
	Animate VotesLabel	ypos	58		Deaccel 0.05 0.1
}

event WinningNextMapVote
{
	Animate VotesLabel	FgColor	CreditsGreen Deaccel	0	0.1.5
}

event LosingNextMapVote
{
	Animate VotesLabel	FgColor	TanLight	Deaccel		0	0.1.5
}