/////////////////////////////
// LAVA EMBER        ////////
// for UTNT          ////////
// by Tormentor667   ////////
/////////////////////////////

Actor BaseEmber
{
	+MISSILE
	+NOBLOCKMAP
	+NOINTERACTION
	+DONTSPLASH
	-SOLID
	Radius 0
	Height 0
	RenderStyle Add
	Alpha 0.01
	Scale 0.06
	Gravity 0.25
	States
	{
	Spawn:
		EMBR AAAA 1 Bright A_FadeIn(0.25)
		TNT1 A 0 A_Jump(80,8)
		TNT1 A 0 A_Jump(80,6)
		TNT1 A 0 A_Jump(80,4)   
		TNT1 A 0 A_Jump(80,2)   
		EMBR AAAAA 8 Bright
		EMBR AAAAAAAAAAAAAAAAAAAA 1 Bright A_FadeOut(0.06)
		Stop
	}
}

actor EmberSpawner 240
{
//$Category HPack_SpecialEffects
	+NOBLOCKMAP
	+NOGRAVITY
	+NOSECTOR
	+NOINTERACTION
	+NOCLIP
	-SOLID
	+CLIENTSIDEONLY
	states
	{
	Spawn:
	Active:
		TNT1 A 0
		TNT1 A 0 A_JumpIf(Args[1], "Circle")
		TNT1 A 2 A_SpawnItemEx ("BaseEmber", random(-Args[0], Args[0]), random(-Args[0], Args[0]), random(0, 8), (0.1)*Random(1, 3), 0, (0.1)*Random(1, 10), random(0,360), 129, Args[2]) 
		Loop
	Circle:
		TNT1 A 0
		TNT1 A 2 A_SpawnItemEx ("BaseEmber", random(-Args[0], Args[0]), 0, random(0, 8), (0.1)*Random(1, 3), 0, (0.1)*Random(1, 10), Random(0, 360), 129, Args[2]) 
		Loop
	Inactive:
		TNT1 A 1
		Loop
	}     
}
