ACTOR Godsend
{
 Speed 400
 Projectile
 +THRUACTORS
 +SKYEXPLODE
 +BLOODLESSIMPACT
 +DONTSPLASH
 States
 {
 Spawn:
 TNT1 A 1
 Loop
 Death:
 TNT1 AA 0 A_PlaySound("Violator/Start",5,1.0)
 TNT1 A 0 A_SpawnItemEx("ViolatorAppear1")
 TNT1 A 0 A_SpawnItemEx("ViolatorAppear2")
 TNT1 A 0 A_SpawnItemEx("ViolatorAppear3")
 TNT1 A 0 A_SpawnItemEx("ViolatorAppear4")
 TNT1 A 0 A_SpawnItemEx("ViolatorAppear5")
 TNT1 A 0 A_SpawnItemEx("Violator_LensAppear",0,0,100)
 TNT1 A 50
 TNT1 A 0 A_StopSound(5)
 TNT1 A 0 A_SpawnItemEx("ViolatorOrbiterSpawner",0,0,0,20,0,0,0,SXF_TRANSFERPOINTERS)
 TNT1 A 0 A_SpawnItemEx("ViolatorHit",0,0,0,20,0,0,0,SXF_TRANSFERPOINTERS)
 TNT1 A 0 A_SpawnItemEx("Violator_Lens",0,0,100,20,0,0,0,SXF_TRANSFERPOINTERS)
 TNT1 A 0 A_SpawnItemEx("ViolatorLazor1",0,0,0,20,0,0,0,SXF_TRANSFERPOINTERS)
 TNT1 A 0 A_SpawnItemEx("ViolatorLazor2",0,0,0,20,0,0,0,SXF_TRANSFERPOINTERS)
 TNT1 A 0 A_SpawnItemEx("ViolatorLazor3",0,0,0,20,0,0,0,SXF_TRANSFERPOINTERS)
 TNT1 A 0 A_SpawnItemEx("ViolatorLazor4",0,0,0,20,0,0,0,SXF_TRANSFERPOINTERS)
 TNT1 A 0 A_SpawnItemEx("ViolatorLazor5",0,0,0,20,0,0,0,SXF_TRANSFERPOINTERS)
 TNT1 A 0 A_SpawnItemEx("ViolatorHeat1",0,0,0,20,0,0,0,SXF_TRANSFERPOINTERS)
 TNT1 A 0 A_SpawnItemEx("ViolatorHeat2",0,0,0,20,0,0,0,SXF_TRANSFERPOINTERS)
 TNT1 A 0 A_SpawnItemEx("ViolatorHeat3",0,0,0,20,0,0,0,SXF_TRANSFERPOINTERS)
 TNT1 A 0 A_SpawnItemEx("ViolatorHeat4",0,0,0,20,0,0,0,SXF_TRANSFERPOINTERS)
 TNT1 A 0 A_SpawnItemEx("ViolatorHeat5",0,0,0,20,0,0,0,SXF_TRANSFERPOINTERS)
 Stop
 }
}

Actor Violator_LensAppear
{
	Radius 18
	Height 24
	+NOGRAVITY
	+CLIENTSIDEONLY
	+NOINTERACTION
	+FLOORHUGGER
	+FORCEYBILLBOARD
	Projectile
	RenderStyle Add
	Alpha 0.0
	Scale 0.0
	ReactionTime 49
	States
	{
		Spawn:
			TNT1 A 0
			VIOL I 0 //A_SetScale(ScaleX+0.08,ScaleY+0.08)
			VIOL I 1 Bright A_FadeIn(0.02)
  			TNT1 A 0 A_Countdown
			Loop
		Death:
			VIOL I 0 //A_SetScale(ScaleX+0.08,ScaleY+0.08)
			VIOL I 1 Bright A_FadeIn(0.01)
			Stop
	}
}

ACTOR ViolatorAppear1
{
  Radius 18
  Height 24
  +NOGRAVITY
  +NOINTERACTION
  +CLIENTSIDEONLY
  +CEILINGHUGGER
  +SPAWNCEILING
  +FORCEYBILLBOARD
  Projectile
  Renderstyle Add
  ReactionTime 49
  Alpha 0.0
  XScale 0.0
  YScale 0
  States
  {
  Spawn:
  TNT1 A 0
  PILE E 1 Bright A_FadeIn(0.02)
  TNT1 A 0 //A_SetScale(ScaleX +0.01, ScaleY +0.08)
  TNT1 A 0 A_Countdown
  Loop
  Death:
  TNT1 A 0 //A_SetScale(ScaleX +0.01, ScaleY +0.08)
  PILE E 1 Bright A_FadeIn(0.01)
  Stop
  }
}

ACTOR ViolatorAppear2 : ViolatorAppear1
{
  States
  {
  Spawn:
  PILE D 0
  PILE D 1 Bright A_FadeIn(0.02)
  PILE D 0 //A_SetScale(ScaleX +0.02, ScaleY +0.08)
  PILE D 0 A_Countdown
  Loop
  Death:
  TNT1 A 0 //A_SetScale(ScaleX +0.02, ScaleY +0.08)
  PILE D 1 Bright A_FadeIn(0.01)
  Stop
  }
}

ACTOR ViolatorAppear3 : ViolatorAppear1
{
  States
  {
  Spawn:
  TNT1 A 0
  PILE C 1 Bright A_FadeIn(0.02)
  TNT1 A 0 //A_SetScale(ScaleX +0.03, ScaleY +0.08)
  TNT1 A 0 A_Countdown
  Loop
  Death:
  TNT1 A 0 //A_SetScale(ScaleX +0.03, ScaleY +0.08)
  PILE C 1 Bright A_FadeIn(0.01)
  Stop
  }
}

ACTOR ViolatorAppear4 : ViolatorAppear1
{
  States
  {
  Spawn:
  TNT1 A 0
  PILE B 1 Bright A_FadeIn(0.02)
  TNT1 A 0 //A_SetScale(ScaleX +0.04, ScaleY +0.08)
  TNT1 A 0 A_Countdown
  Loop
  Death:
  TNT1 A 0 //A_SetScale(ScaleX +0.04, ScaleY +0.08)
  PILE B 1 Bright A_FadeIn(0.01)
  Stop
  }
}

ACTOR ViolatorAppear5 : ViolatorAppear1
{
  States
  {
  Spawn:
  TNT1 A 0
  PILE A 1 Bright A_FadeIn(0.02)
  TNT1 A 0 //A_SetScale(ScaleX +0.05, ScaleY +0.08)
  TNT1 A 0 A_Countdown
  Loop
  Death:
  TNT1 A 0 //A_SetScale(ScaleX +0.05, ScaleY +0.08)
  PILE A 1 Bright A_FadeIn(0.01)
  Stop
  }
}

Actor Violator_Lens
{
	Radius 18
	Height 24
	+NOGRAVITY
	+NOINTERACTION
	+FLOORHUGGER
	+FORCEYBILLBOARD
	+CLIENTSIDEONLY
	Projectile
	RenderStyle Add
	Alpha 0.99
	Scale 40.0
	ReactionTime 35
	States
	{
		Spawn:
			TNT1 AA 0 //ACS_NamedExecuteAlways("AssumingControlBecauseBallsAreInnert")
			VIOL IIIII 1 Bright A_FadeOut(0.015)
			VIOL IIIII 1 Bright A_FadeIn(0.015)
  			TNT1 A 0 A_Countdown
			Loop
		Death:
			VIOL I 1 A_FadeOut(0.02)
			VIOL I 0 //A_SetScale(ScaleX-0.07,ScaleY-0.07)
			Loop
	}
}

ACTOR ViolatorLazor1
{
  Radius 18
  Height 24
  +NOGRAVITY
  +NOINTERACTION
  +CLIENTSIDEONLY
  +FLOORHUGGER
  +FORCEYBILLBOARD
  Projectile
  Speed 5
  Renderstyle Add
  ReactionTime 35
  Alpha 0.99
  XScale 0.5
  YScale 4
  States
  {
  Spawn:
  TNT1 AA 0 A_PlaySound("Violator/Loop",5,1.0,1)
  TNT1 A 0 A_PlaySound("Violator/Loop2",6,1.0,1)
  TNT1 A 0 A_PlaySound("Violator/Burn",8,0.7,1)
  PILE EEEEE 1 Bright A_FadeOut(0.0125)
  PILE EEEEE 1 Bright A_FadeIn(0.0125)
  TNT1 A 0 A_Countdown
  Loop
  Death:
  TNT1 A 0 A_PlaySound("Violator/End",5,1.0)
  TNT1 A 0 A_StopSound(6)
  TNT1 A 0 A_StopSound(8)
  Looplet:
  TNT1 A 0 //A_SetScale(ScaleX +0.04, ScaleY -0.06)
  TNT1 A 0 A_FadeOut(0.05)
  PILE E 1 Bright
  Loop
  }
}

ACTOR ViolatorLazor2 : ViolatorLazor1
{
  XScale 1
  States
  {
  Spawn:
  TNT1 AA 0 //ACS_NamedExecuteAlways("AssumingControlBecauseBallsAreInnert")
  PILE DDDDD 1 Bright A_FadeOut(0.0125)
  PILE DDDDD 1 Bright A_FadeIn(0.0125)
  TNT1 A 0 A_Countdown
  Loop
  Death:
  TNT1 A 0 //A_SetScale(ScaleX +0.05, ScaleY -0.8)
  TNT1 A 0 A_FadeOut(0.055)
  PILE D 1 Bright
  Loop
  }
}


ACTOR ViolatorLazor3 : ViolatorLazor1
{
  XScale 1.5
  States
  {
  Spawn:
  TNT1 AA 0 //ACS_NamedExecuteAlways("AssumingControlBecauseBallsAreInnert")
  PILE CCCCC 1 Bright A_FadeOut(0.0125)
  PILE CCCCC 1 Bright A_FadeIn(0.0125)
  TNT1 A 0 A_Countdown
  Loop
  Death:
  TNT1 A 0 //A_SetScale(ScaleX +0.06, ScaleY -0.1)
  TNT1 A 0 A_FadeOut(0.06)
  PILE C 1 Bright
  Loop
  }
}

ACTOR ViolatorLazor4 : ViolatorLazor1
{
  XScale 2
  States
  {
  Spawn:
  TNT1 AA 0 //ACS_NamedExecuteAlways("AssumingControlBecauseBallsAreInnert")
  PILE BBBBB 1 Bright A_FadeOut(0.0125)
  PILE BBBBB 1 Bright A_FadeIn(0.0125)
  TNT1 A 0 A_Countdown
  Loop
  Death:
  TNT1 A 0 //A_SetScale(ScaleX +0.07, ScaleY -0.12)
  TNT1 A 0 A_FadeOut(0.065)
  PILE B 1 Bright
  Loop
  }
}

ACTOR ViolatorLazor5 : ViolatorLazor1
{
  XScale 2.5
  States
  {
  Spawn:
  TNT1 AA 0 //ACS_NamedExecuteAlways("AssumingControlBecauseBallsAreInnert")
  PILE AAAAA 1 Bright A_FadeOut(0.0125)
  PILE AAAAA 1 Bright A_FadeIn(0.0125)
  TNT1 A 0 A_Countdown
  Loop
  Death:
  TNT1 A 0 //A_SetScale(ScaleX +0.08, ScaleY -0.14)
  TNT1 A 0 A_FadeOut(0.07)
  PILE A 1 Bright
  Loop
  }
}

ACTOR ViolatorHeat1
{
  Radius 18
  Height 24
  +NOGRAVITY
  +NOINTERACTION
  +CLIENTSIDEONLY
  +FLOORHUGGER
  Projectile
  Speed 5
  ReactionTime 70
  States
  {
  Spawn:
  TNT1 A 0
  Looplololo:
  TNT1 A 5 A_SpawnItemEx("ViolatorHaze1",random(75,-75),random(75,-75),-5,20,0,random(15,5))
  TNT1 A 0 A_Countdown
  Loop
  Death:
  TNT1 A 0
  Stop
  }
}

ACTOR ViolatorHaze1
{
  Radius 5
  Height 5
  +NOGRAVITY
  +CLIENTSIDEONLY
  +FORCEYBILLBOARD
  +FLOORHUGGER
  Projectile
  Speed 5
  Renderstyle Add
  Alpha 0.99
  XScale 0.25
  YScale 4
  States
  {
  Spawn:
  TNT1 A 0
  Looplololo:
  PILE E 1 Bright A_FadeOut(0.05)
  PILE E 0 //A_SetScale(ScaleX-0.0125,ScaleY-0.05)
  Loop
  Death:
  TNT1 A 0
  Stop
  }
}

ACTOR ViolatorHeat2 : ViolatorHeat1
{
  States
  {
  Spawn:
  TNT1 A 0
  Looplololo:
  TNT1 A 5 A_SpawnItemEx("ViolatorHaze2",random(100,-100),random(100,-100),-5,20,0,random(15,5))
  TNT1 A 0 A_Countdown
  Loop
  Death:
  TNT1 A 0
  Stop
  }
}

ACTOR ViolatorHaze2 : ViolatorHaze1
{
  XScale 0.5
  States
  {
  Spawn:
  TNT1 A 0
  PILE D 1 Bright A_FadeOut(0.05)
  PILE D 0 //A_SetScale(ScaleX-0.025,ScaleY-0.05)
  Loop
  }
}

ACTOR ViolatorHeat3 : ViolatorHeat1
{
  States
  {
  Spawn:
  TNT1 A 0
  Looplololo:
  TNT1 A 5 A_SpawnItemEx("ViolatorHaze3",random(125,-125),random(125,-125),-5,20,0,random(15,5))
  TNT1 A 0 A_Countdown
  Loop
  Death:
  TNT1 A 0
  Stop
  }
}

ACTOR ViolatorHaze3 : ViolatorHaze1
{
  XScale 0.75
  States
  {
  Spawn:
  TNT1 A 0
  Looplololo:
  PILE C 1 Bright A_FadeOut(0.05)
  PILE C 0 //A_SetScale(ScaleX-0.05,ScaleY-0.05)
  Loop
  }
}

ACTOR ViolatorHeat4 : ViolatorHeat1
{
  States
  {
  Spawn:
  TNT1 A 0
  Looplololo:
  TNT1 A 5 A_SpawnItemEx("ViolatorHaze4",random(150,-150),random(150,-150),-5,20,0,random(15,5))
  TNT1 A 0 A_Countdown
  Loop
  Death:
  TNT1 A 0
  Stop
  }
}

ACTOR ViolatorHaze4 : ViolatorHaze1
{
  XScale 1
  States
  {
  Spawn:
  TNT1 A 0
  PILE B 1 Bright A_FadeOut(0.05)
  PILE B 0 //A_SetScale(ScaleX-0.05,ScaleY-0.05)
  Loop
  }
}

ACTOR ViolatorHeat5 : ViolatorHeat1
{
  States
  {
  Spawn:
  TNT1 A 0
  Looplololo:
  TNT1 A 5 A_SpawnItemEx("ViolatorHaze5",random(175,-175),random(175,-175),-5,20,0,random(15,5))
  TNT1 A 0 A_Countdown
  Loop
  Death:
  TNT1 A 0
  Stop
  }
}

ACTOR ViolatorHaze5 : ViolatorHaze1
{
  XScale 1.25
  States
  {
  Spawn:
  TNT1 A 0
  PILE A 1 Bright A_FadeOut(0.05)
  PILE A 0 //A_SetScale(ScaleX-0.05,ScaleY-0.05)
  Loop
  }
}

ACTOR ViolatorHit
{
  Radius 18
  Height 24
  +NOGRAVITY
  +NOINTERACTION
  +FLOORHUGGER
  +FORCERADIUSDMG
  +FOILINVUL
  Obituary "%o got a full face of over twenty thousands of thousands celsius degree heat, thanks to %k's fiery inferno."
  DamageType Superweapon
  Projectile
  ReactionTime 350
  States
  {
  Spawn:
  TNT1 AA 0 //ACS_NamedExecuteAlways("AssumingControlBecauseBallsAreInnert")
  TNT1 A 0 A_Explode(9000000,768,0,1)
  TNT1 A 0 A_Quake (9, 1, 0, 2048, none)
  TNT1 A 0 A_Quake (4, 1, 0, 5120, none)
  TNT1 A 0 A_Quake (1, 1, 0, 10240, none)
  TNT1 A 0 A_SpawnItemEx("ViolatorImpact",0,0,0,0,0,0,0,SXF_CLIENTSIDE)
  TNT1 A 0 A_SpawnItemEx("ViolatorImpact1",random(30,-30),random(30,-30),0,0,0,0,0,SXF_CLIENTSIDE)
  TNT1 A 0 A_SpawnItemEx("ViolatorImpact2",random(60,-60),random(60,-60),0,0,0,0,0,SXF_CLIENTSIDE)
  TNT1 A 0 A_SpawnItemEx("ViolatorImpact3",random(90,-90),random(90,-90),0,0,0,0,0,SXF_CLIENTSIDE)
  TNT1 A 0 A_SpawnItemEx("ViolatorImpact4",random(120,-120),random(120,-120),0,0,0,0,0,SXF_CLIENTSIDE)
  TNT1 A 0 A_SpawnItemEx("ViolatorImpact5",random(150,-150),random(150,-150),0,0,0,0,0,SXF_CLIENTSIDE)
  TNT1 A 1 A_Countdown
  Loop
  Death:
  Stop
  }
}

ACTOR ViolatorImpact1
{
  +NOGRAVITY
  +NOINTERACTION
  +FLOORHUGGER
  +CLIENTSIDEONLY
  Renderstyle Add
  Alpha 0.99
  Scale 2
  States
  {
  Spawn:
  TNT1 A 0
  Looplet:
  TNT1 A 0 //A_SetScale(ScaleX +0.06, ScaleY +0.06)
  TNT1 A 0 A_FadeOut(0.05)
  PILI E 1 Bright
  Loop
  }
}

ACTOR ViolatorImpact2 : ViolatorImpact1
{
  Scale 3
  States
  {
  Spawn:
  TNT1 A 1
  Looplet:
  TNT1 A 0 //A_SetScale(ScaleX +0.07, ScaleY +0.07)
  TNT1 A 0 A_FadeOut(0.055)
  PILI D 1 Bright
  Loop
  }
}

ACTOR ViolatorImpact3 : ViolatorImpact1
{
  Scale 4
  States
  {
  Spawn:
  TNT1 A 2
  Looplet:
  TNT1 A 0 //A_SetScale(ScaleX +0.08, ScaleY +0.08)
  TNT1 A 0 A_FadeOut(0.06)
  PILI C 1 Bright
  Loop
  }
}

ACTOR ViolatorImpact4 : ViolatorImpact1
{
  Scale 5
  States
  {
  Spawn:
  TNT1 A 3
  Looplet:
  TNT1 A 0 //A_SetScale(ScaleX +0.09, ScaleY +0.09)
  TNT1 A 0 A_FadeOut(0.065)
  PILI B 1 Bright
  Loop
  }
}

ACTOR ViolatorImpact5 : ViolatorImpact1
{
  Scale 6
  States
  {
  Spawn:
  TNT1 A 3
  Looplet:
  TNT1 A 0 //A_SetScale(ScaleX +0.1, ScaleY +0.1)
  TNT1 A 0 A_FadeOut(0.07)
  PILI A 1 Bright
  Loop
  }
}

ACTOR Violator_Fire
{
	Renderstyle Add
	+NOGRAVITY
	+CLIENTSIDEONLY
	+NOINTERACTION
	Alpha 0.8
	States
	{
	Spawn:
		TNT1 AA 0 A_Jump(255, "SpawnA","SpawnB","SpawnC","SpawnD","SpawnE", "SpawnF", "SpawnG", "SpawnH")
	SpawnA:
		VIOL A 0 A_Jump(255, "FadeIn")
		Goto SpawnA
	SpawnB:
		VIOL B 0 A_Jump(255, "FadeIn")
		Goto SpawnB
	SpawnC:
		VIOL C 0 A_Jump(255, "FadeIn")
		Goto SpawnC
	SpawnD:
		VIOL D 0 A_Jump(255, "FadeIn")
		Goto SpawnD
	SpawnE:
		VIOL E 0 A_Jump(255, "FadeIn")
		Goto SpawnE
	SpawnF:
		VIOL F 0 A_Jump(255, "FadeIn")
		Goto SpawnF
	SpawnG:
		VIOL G 0 A_Jump(255, "FadeIn")
		Goto SpawnG
	SpawnH:
		VIOL H 0 A_Jump(255, "FadeIn")
		Goto SpawnH
	FadeIn:
		"####" "#" 0 Bright //A_SetScale(FRandom(3.0, 3.55))
		Goto Idle
	Idle:
		"####" "#" 3 Bright A_Jump(48, "FadeOut")
		Loop
	FadeOut:
		"####" "#" 1 Bright A_FadeOut(0.025)
		"####" "#" 0 A_ScaleVelocity(FRandom(1.03, 1.06))
		"####" "#" 0 //A_SetScale(ScaleX - FRandom(0.02, 0.06))
		Loop
	}
}

Actor Violator_Glow
{
	Renderstyle Add
	+NOGRAVITY
	+CLIENTSIDEONLY
	+NOINTERACTION
	Alpha 0.8
	States
	{
		Spawn:
			TNT1 AA 0 A_Jump(255, "SpawnA", "SpawnB")
		SpawnA:
			FWAL M 0 A_Jump(255, "FadeIn")
			Goto SpawnA
		SpawnB:
			FWAL R 0 A_Jump(255, "FadeIn")
			Goto SpawnB
		FadeIn:
			"####" "#" 0 Bright //A_SetScale(FRandom(3.0, 3.6))
			Goto Idle
		Idle:
			"####" "#" 4 Bright A_Jump(64, "FadeOut")
			Loop
		FadeOut:
			"####" "#" 1 Bright A_FadeOut(0.02)
			"####" "#" 0 A_ScaleVelocity(FRandom(0.97, 0.99))
			"####" "#" 0 //A_SetScale(ScaleX + FRandom(0.03, 0.06))
			Loop
	}
}

Actor Violator_Ember
{
	RenderStyle Add
	+NOGRAVITY
	+CLIENTSIDEONLY
	+NOINTERACTION
	Alpha 0.99
	States
	{
		Spawn:
			TNT1 AA 0 A_Jump(255, "SpawnA", "SpawnB", "SpawnC")
		SpawnA:
			VIOL J 0 A_Jump(255, "FadeIn")
			Goto SpawnA
		SpawnB:
			VIOL K 0 A_Jump(255, "FadeIn")
			Goto SpawnB
		SpawnC:
			VIOL L 0 A_Jump(255, "FadeIn")
			Goto SpawnC
		FadeIn:
			"####" "#" 0 Bright //A_SetScale(FRandom(0.5, 0.75))
			Goto Idle
		Idle:
			"####" "#" 4 Bright A_Jump(150, "FadeOut")
			Loop
		FadeOut:
			"####" "#" 1 Bright A_Weave(FRandom(0.9, 1.0), FRandom(0.9, 1.0),
										FRandom(70, 90), FRandom(70, 90))
			"####" "#" 0 //A_JumpIf(ScaleX <= 0.0, "NULL")
			"####" "#" 0 A_ChangeVelocity(VelX * FRandom(0.93, 0.99),
										  VelY * FRandom(0.93, 0.99),
										  VelZ - FRandom(0.1, 0.2),
										  CVF_REPLACE)
			"####" "#" 0 A_FadeOut(FRandom(0.006, 0.003))
			Loop
	}
}

Actor Violator_Smoke
{
	Alpha 0.0
	+NOGRAVITY
	+CLIENTSIDEONLY
	+NOINTERACTION
	RenderStyle Translucent
	States
	{
		Spawn:
			TNT1 A 35
			TNT1 AA 0 A_Jump(255, "SpawnA", "SpawnB", "SpawnC", "SpawnD")
		SpawnA:
			VIOL N 0 A_Jump(255, "FadeIn")
			Goto SpriteA
		SpawnB:
			VIOL O 0 A_Jump(255, "FadeIn")
			Goto SpriteB
		SpawnC:
			VIOL P 0 A_Jump(255, "FadeIn")
			Goto SpriteC
		SpawnD:
			VIOL Q 0 A_Jump(255, "FadeIn")
			Goto SpriteD
		FadeIn:
			"####" "#" 0 //A_SetScale(FRandom(3.4, 3.6))
			Goto RealFadeIn
		RealFadeIn:
			"####" "#" 1 A_FadeIn(FRandom(0.01, 0.02))
			"####" "#" 0 A_JumpIf(Alpha >= 0.2, "Idle")
			Loop
		Idle:
			"####" "#" 4 A_Jump(35, "FadeOut")
			Loop
		FadeOut:
			"####" "#" 1 A_FadeOut(0.02)
			/* "####" "#" 0 A_ChangeVelocity(VelX * FRandom(0.97, 0.99),
										  VelY * FRandom(0.97, 0.99),
										  VelZ + FRandom(0.12, 0.26),
										  CVF_REPLACE) */
			"####" "#" 0 A_ScaleVelocity(0.96)
			"####" "#" 0 //A_SetScale(ScaleX + FRandom(0.015, 0.025))
			Loop
	}
}

ACTOR ViolatorImpact
{
  +NOGRAVITY
  +CLIENTSIDEONLY
  +NOINTERACTION
  +FLOORHUGGER
  States
  {
  Spawn:
  TNT1 A 0
  Looplet:
  TNT1 AAAAAAAA 0 A_SpawnItemEx("Violator_Fire",random(600,-600),random(600,-600),random(500,0),frandom(2.5,2.75),frandom(2.5,2.75),frandom(-1.0,2.75),random(0.0,360.0),32)
  TNT1 AAAAAAAA 0 A_SpawnItemEx("Violator_Glow",random(600,-600),random(600,-600),random(500,0),frandom(2.5,2.75),frandom(2.5,2.75),frandom(-1.0,2.75),random(0.0,360.0),32)
  TNT1 AAAAAA 0 A_SpawnItemEx("Violator_Smoke",random(600,-600),random(600,-600),random(500,0),frandom(2.5,2.75),frandom(2.5,2.75),frandom(-1.0,3.75),random(0.0,360.0),32)
  TNT1 A 0 A_SpawnItemEx("Violator_Ember",random(500,-500),random(500,-500),random(500,0),frandom(7.0,6.0),frandom(7.0,6.0),frandom(2.0,8.0),random(0.0,360.0),164)
  Stop
  }
}

ACTOR ViolatorImpacter
{
	Radius 18
	Height 24
	+NOINTERACTION
	+CLIENTSIDEONLY
	+NOGRAVITY
	+FLOORHUGGER
	ReactionTime 350
	Projectile
	Speed 5
	States
	{
	Spawn:
	TNT1 A 0
	TNT1 A 0 ACS_ExecuteAlways(704)
	TNT1 AA 1 A_Countdown
	TNT1 A 0 A_SpawnItemEx("ViolatorImpact",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS)
	TNT1 A 0 A_SpawnItemEx("ViolatorImpact1")
	TNT1 A 0 A_SpawnItemEx("ViolatorImpact2")
	TNT1 A 0 A_SpawnItemEx("ViolatorImpact3")
	TNT1 A 0 A_SpawnItemEx("ViolatorImpact4")
	TNT1 A 0 A_SpawnItemEx("ViolatorImpact5")
	Loop
	Death:
	TNT1 A 0 A_SpawnItemEx("ViolatorImpact",0,0,0,0,0,0,0,SXF_TRANSFERPOINTERS)
	TNT1 A 2 A_FadeOut(0.05)
	Loop
	}
}

ACTOR ViolatorDetonate : Inventory { Inventory.MaxAmount 1 }

ACTOR ViolatorOrbiterSpawner
{
	ReactionTime 350
	var int user_v;
	+NOINTERACTION
	+NOGRAVITY
	States
	{
		Spawn:
			TNT1 AA 0 A_SetUserVar("user_v", 0)
		Eunghinator:
			TNT1 AAAAAAAAAA 1 A_Countdown
			TNT1 A 0 A_SetUserVar("user_v", user_v+1)
			TNT1 A 0 ACS_ExecuteAlways(713, 0, 0) //ITS FUNNY BECAUSE IT'S... well, fuck.
			TNT1 A 0 A_JumpIf(user_v>6, "Trolololo")
			Loop
		Trolololo:
			TNT1 A 1 A_Countdown
			Loop
		Death:
			TNT1 A 0 A_GiveInventory("ViolatorDetonate", 1)
			TNT1 A 1 //to let the orbiters detect the death trigger
			goto Super::Death
	}
}

//.....................................

ACTOR FireCracker
{
	Radius 20
	Height 12
	//+FLOORHUGGER
	+RIPPER
	+BLOODLESSIMPACT
	+THRUACTORS
	+SEEKERMISSILE
	+FOILINVUL
	+DONTBLAST
	+MISSILE
	+STEPMISSILE
	+DROPOFF
	+NOEXPLODEFLOOR
	+THRUACTORS
	+FORCERADIUSDMG
	+DONTSPLASH
	+SKYEXPLODE
	+NOGRAVITY
	+FOILINVUL
	Speed 40
	/*BounceType Grenade
	WallBounceFactor 1
	BounceFactor 1
	BounceCount 5*/
	Obituary "%o was unlucky enough to get consumed by %k's blazing firecracker."
	DamageType Darkness
	States
	{
	Spawn:
	TNT1 A 0
	TNT1 A 0 A_Explode(2000,384,0)
    TNT1 A 0 A_Quake (4, 5, 0, 512, none)
    TNT1 A 0 A_Quake (2, 5, 0, 768, none)
    TNT1 A 0 A_Quake (1, 5, 0, 1024, none)
	TNT1 A 0 A_PlaySound("Violator/FireCracker",5,1.0,1)
	TNT1 A 0 A_PlaySound("Violator/FireCracker2",6,1.0,1)
	TNT1 A 0 A_SpawnItemEx("FireCrack")
	TNT1 A 5 A_SeekerMissile(10,20,SMF_LOOK|SMF_PRECISE,256,20)
	Loop
	Death:
	TNT1 A 0 A_StopSound(5)
	TNT1 A 0 A_PlaySound("Violator/FireCrackerHit",6,1.0)
	TNT1 A 0 A_Explode(6000,512,0)
	TNT1 A 0 A_SpawnItemEx("ViolatorImpact",0,0,0,0,0,0,0,SXF_CLIENTSIDE)
	TNT1 A 0 A_SpawnItemEx("ViolatorImpact1",random(30,-30),random(30,-30),0,0,0,0,0,SXF_CLIENTSIDE)
	TNT1 A 0 A_SpawnItemEx("ViolatorImpact2",random(60,-60),random(60,-60),0,0,0,0,0,SXF_CLIENTSIDE)
	TNT1 A 0 A_SpawnItemEx("ViolatorImpact3",random(90,-90),random(90,-90),0,0,0,0,0,SXF_CLIENTSIDE)
	TNT1 A 0 A_SpawnItemEx("ViolatorImpact4",random(120,-120),random(120,-120),0,0,0,0,0,SXF_CLIENTSIDE)
	TNT1 A 0 A_SpawnItemEx("ViolatorImpact5",random(150,-150),random(150,-150),0,0,0,0,0,SXF_CLIENTSIDE)
	TNT1 A 1 A_Countdown
	Stop
	}
}

ACTOR FireCrack
{
	+NOINTERACTION
	+CLIENTSIDEONLY
	+NOGRAVITY
	States
	{
	Spawn:
	TNT1 A 0
	TNT1 A 0 A_SpawnItemEx("ViolatorBlast1")
	TNT1 A 0 A_SpawnItemEx("ViolatorBlast2")
	TNT1 A 0 A_SpawnItemEx("ViolatorBlast3")
	TNT1 A 0 A_SpawnItemEx("ViolatorBlast4")
	TNT1 A 0 A_SpawnItemEx("ViolatorBlast5")
	TNT1 AA 0 A_SpawnItemEx("ViolatorBlast")
	Stop
	}
}

ACTOR ViolatorBlast1 : ViolatorImpact1 { Scale 0.5 }
ACTOR ViolatorBlast2 : ViolatorImpact2 { Scale 0.75 }
ACTOR ViolatorBlast3 : ViolatorImpact3 { Scale 1 }
ACTOR ViolatorBlast4 : ViolatorImpact4 { Scale 1.25 }
ACTOR ViolatorBlast5 : ViolatorImpact5 { Scale 1.5 }


ACTOR Violblast_Fire
{
	Renderstyle Add
	+NOGRAVITY
	+CLIENTSIDEONLY
	+NOINTERACTION
	Alpha 0.8
	States
	{
	Spawn:
		TNT1 AA 0 A_Jump(255, "SpawnA","SpawnB","SpawnC","SpawnD","SpawnE", "SpawnF", "SpawnG", "SpawnH")
	SpawnA:
		VIOL A 0 A_Jump(255, "FadeIn")
		Goto SpawnA
	SpawnB:
		VIOL B 0 A_Jump(255, "FadeIn")
		Goto SpawnB
	SpawnC:
		VIOL C 0 A_Jump(255, "FadeIn")
		Goto SpawnC
	SpawnD:
		VIOL D 0 A_Jump(255, "FadeIn")
		Goto SpawnD
	SpawnE:
		VIOL E 0 A_Jump(255, "FadeIn")
		Goto SpawnE
	SpawnF:
		VIOL F 0 A_Jump(255, "FadeIn")
		Goto SpawnF
	SpawnG:
		VIOL G 0 A_Jump(255, "FadeIn")
		Goto SpawnG
	SpawnH:
		VIOL H 0 A_Jump(255, "FadeIn")
		Goto SpawnH
	FadeIn:
		"####" "#" 0 Bright //A_SetScale(FRandom(0.8, 1.15))
		Goto Idle
	Idle:
		"####" "#" 3 Bright A_Jump(48, "FadeOut")
		Loop
	FadeOut:
		"####" "#" 1 Bright A_FadeOut(0.025)
		"####" "#" 0 A_ScaleVelocity(FRandom(1.03, 1.06))
		"####" "#" 0 //A_SetScale(ScaleX - FRandom(0.02, 0.06))
		Loop
	}
}

Actor Violblast_Glow
{
	Renderstyle Add
	+NOGRAVITY
	+NOINTERACTION
	+CLIENTSIDEONLY
	Alpha 0.8
	States
	{
		Spawn:
			TNT1 AA 0 A_Jump(255, "SpawnA", "SpawnB")
		SpawnA:
			FWAL M 0 A_Jump(255, "FadeIn")
			Goto SpawnA
		SpawnB:
			FWAL R 0 A_Jump(255, "FadeIn")
			Goto SpawnB
		FadeIn:
			"####" "#" 0 Bright //A_SetScale(FRandom(0.8, 1.2))
			Goto Idle
		Idle:
			"####" "#" 4 Bright A_Jump(64, "FadeOut")
			Loop
		FadeOut:
			"####" "#" 1 Bright A_FadeOut(0.02)
			"####" "#" 0 A_ScaleVelocity(FRandom(0.97, 0.99))
			"####" "#" 0 //A_SetScale(ScaleX + FRandom(0.03, 0.06))
			Loop
	}
}

Actor Violblast_Ember
{
	RenderStyle Add
	+NOGRAVITY
	+CLIENTSIDEONLY
	+NOINTERACTION
	Alpha 0.99
	States
	{
		Spawn:
			TNT1 AA 0 A_Jump(255, "SpawnA", "SpawnB", "SpawnC")
		SpawnA:
			VIOL J 0 A_Jump(255, "FadeIn")
			Goto SpawnA
		SpawnB:
			VIOL K 0 A_Jump(255, "FadeIn")
			Goto SpawnB
		SpawnC:
			VIOL L 0 A_Jump(255, "FadeIn")
			Goto SpawnC
		FadeIn:
			"####" "#" 0 Bright //A_SetScale(FRandom(0.025, 0.05))
			Goto Idle
		Idle:
			"####" "#" 4 Bright A_Jump(150, "FadeOut")
			Loop
		FadeOut:
			"####" "#" 1 Bright A_Weave(FRandom(0.9, 1.0), FRandom(0.9, 1.0),
										FRandom(70, 90), FRandom(70, 90))
			"####" "#" 0 //A_JumpIf(ScaleX <= 0.0, "NULL")
			"####" "#" 0 A_ChangeVelocity(VelX * FRandom(0.93, 0.99),
										  VelY * FRandom(0.93, 0.99),
										  VelZ - FRandom(0.1, 0.2),
										  CVF_REPLACE)
			"####" "#" 0 A_FadeOut(FRandom(0.006, 0.003))
			Loop
	}
}

Actor Violblast_Smoke
{
	Alpha 0.0
	+NOGRAVITY
	+NOINTERACTION
	+CLIENTSIDEONLY
	RenderStyle Translucent
	States
	{
		Spawn:
			TNT1 A 35
			TNT1 AA 0 A_Jump(255, "SpawnA", "SpawnB", "SpawnC", "SpawnD")
		SpawnA:
			VIOL N 0 A_Jump(255, "FadeIn")
			Goto SpriteA
		SpawnB:
			VIOL O 0 A_Jump(255, "FadeIn")
			Goto SpriteB
		SpawnC:
			VIOL P 0 A_Jump(255, "FadeIn")
			Goto SpriteC
		SpawnD:
			VIOL Q 0 A_Jump(255, "FadeIn")
			Goto SpriteD
		FadeIn:
			"####" "#" 0 //A_SetScale(FRandom(1.0, 1.2))
			Goto RealFadeIn
		RealFadeIn:
			"####" "#" 1 A_FadeIn(FRandom(0.01, 0.02))
			"####" "#" 0 A_JumpIf(Alpha >= 0.2, "Idle")
			Loop
		Idle:
			"####" "#" 4 A_Jump(35, "FadeOut")
			Loop
		FadeOut:
			"####" "#" 1 A_FadeOut(0.02)
			/* "####" "#" 0 A_ChangeVelocity(VelX * FRandom(0.97, 0.99),
										  VelY * FRandom(0.97, 0.99),
										  VelZ + FRandom(0.12, 0.26),
										  CVF_REPLACE) */
			"####" "#" 0 A_ScaleVelocity(0.96)
			"####" "#" 0 //A_SetScale(ScaleX + FRandom(0.015, 0.025))
			Loop
	}
}

ACTOR ViolatorBlast
{
  +NOGRAVITY
  +NOINTERACTION
  +CLIENTSIDEONLY
  +FLOORHUGGER
  States
  {
  Spawn:
  TNT1 A 0
  Looplet:
  TNT1 AAAAAAAA 0 A_SpawnItemEx("Violator_Fire",random(100,-100),random(100,-100),random(100,-100),frandom(1.5,1.75),frandom(1.5,1.75),frandom(-1.75,1.75),random(0.0,360.0),32)
  TNT1 AAAAAAAA 0 A_SpawnItemEx("Violator_Glow",random(100,-100),random(100,-100),random(100,-100),frandom(1.5,1.75),frandom(2.5,2.75),frandom(-1.75,1.75),random(0.0,360.0),32)
  TNT1 AAAAAA 0 A_SpawnItemEx("Violator_Smoke",random(100,-100),random(100,-100),random(100,-100),frandom(1.5,1.75),frandom(1.5,1.75),frandom(-2.25,2.25),random(0.0,360.0),32)
  TNT1 A 0 A_SpawnItemEx("Violator_Ember",random(100,-100),random(100,-100),random(100,-100),frandom(3.0,4.0),frandom(3.0,4.0),frandom(3.0,6.0),random(0.0,360.0),164)
  Stop
  }
}

//.....................................

ACTOR ViolatorOrbiter : FastProjectile
{
	Radius 20
	Height 12
	+NOINTERACTION
	+NOGRAVITY
	+NOCLIP
	+FORCERADIUSDMG
	Projectile
	States
	{
	Spawn:
	TNT1 A 0
	TNT1 A 0 A_Explode(3000,256,0)
	TNT1 A 0 A_PlaySound("Violator/FireCracker",5,1.0,1)
	TNT1 A 0 A_PlaySound("Violator/FireCracker2",6,1.0,1)
	TNT1 AA 0 A_SpawnItemEx("Violator_Fire",random(100,-100),random(100,-100),random(75,0),frandom(1.5,1.75),frandom(1.5,1.75),frandom(-1.0,1.75),random(0.0,360.0),32)
	TNT1 AA 0 A_SpawnItemEx("Violator_Glow",random(100,-100),random(100,-100),random(75,0),frandom(1.5,1.75),frandom(2.5,2.75),frandom(-1.0,1.75),random(0.0,360.0),32)
	TNT1 AA 0 A_SpawnItemEx("Violator_Smoke",random(100,-100),random(100,-100),random(75,0),frandom(1.5,1.75),frandom(1.5,1.75),frandom(-1.0,2.25),random(0.0,360.0),32)
	TNT1 A 0 A_SpawnItemEx("Violator_Ember",random(100,-100),random(100,-100),random(75,0),frandom(3.0,4.0),frandom(3.0,4.0),frandom(3.0,6.0),random(0.0,360.0),214)
	TNT1 A 1
	Loop
	Death:
	TNT1 A 0 A_StopSound(5)
	TNT1 A 0 A_StopSound(6)
	TNT1 A 0 A_Explode(10000,256,0)
	TNT1 A 0 A_SpawnItemEx("ViolatorBlast")
	Stop
	}
}
