//kept around for inheritance purposes
ACTOR ExplosionFire
{
	Game Doom
	Radius 1
	Height 1
	Speed 4
	Damage 0 
    +NOBLOCKMAP
    +NOTELEPORT
    +DONTSPLASH
	+MISSILE
	+FORCEXYBILLBOARD
    +CLIENTSIDEONLY
    +NOINTERACTION
	+NOCLIP
    DamageType Flames
	Gravity 0
	Renderstyle Add
	States
	{
    Spawn:
        MISL BCDEFG 2 BRIGHT
        Stop
	}
}

ACTOR SmoothBulletPuff Replaces BulletPuff
{
	Game Doom
	SpawnID 131
	+NOBLOCKMAP
	+NOGRAVITY
	+ALLOWPARTICLES
	+RANDOMIZE
	RenderStyle Translucent
	Alpha 0.7
	VSpeed 1
	Mass 5
	States
	{
	spawn:
		TNT1 A 0 nodelay A_JumpIf(CallACS("PuffStyle")==1, "FancyPuff")
		spuf abcd 2 bright
		spuf efghi 2
		stop
	FancyPuff:
		spuf a 2 bright
		TNT1 A 0 A_spawnitemex ("PuffParticles", 0, 0, 0, random(1,3),random(-1,1),random(0,-2))		
		TNT1 AAA 0 A_spawnitemex ("SmallPuffParticles", 0, 0, 0, random(1,2),random(-3,3),random(-5,3))			
		
		TNT1 AAA 0 A_spawnitemex ("PuffSmoke", 0, 0, 0, random(-1,1),random(-1,1),random(-1,1))
		spuf bcd 2 bright
		stop
	Melee:
		PUFF CD 2
		Stop
	}
}

Actor bulletcasing
{
  scale 0.17
  radius 3
  projectile
  bouncefactor 0.5
  wallbouncefactor 0.4
  bouncecount 5
  bouncesound "casings/bullet/bounce"
  bouncetype Doom
  -NOGRAVITY
  -NOBLOCKMAP
  +NOTELEPORT
  +THRUACTORS
  +DROPOFF
  +FLOORCLIP
  -BOUNCEONACTORS
  states
	{
	Spawn:
		BCAS ABCDEFGH 1
		loop
	Death:
		TNT1 A 0 A_Jump(255, "Death1", "Death2", "Death3", "Death4")
		goto death1
	Death1:
		TNT1 A 0
		TNT1 A 0 A_JumpIf(CallACS("LiquidCheck"),"disappear")
		BCAS I -1 a_playsound ("casings/bullet/die") 
		stop
	Death2:
		TNT1 A 0
		TNT1 A 0 A_JumpIf(CallACS("LiquidCheck"),"disappear")
		BCAS J -1 a_playsound ("casings/bullet/die") 
		stop
	Death3:
		TNT1 A 0
		TNT1 A 0 A_JumpIf(CallACS("LiquidCheck"),"disappear")
		BCAS K -1 a_playsound ("casings/bullet/die") 
		stop
	Death4:
		TNT1 A 0
		TNT1 A 0 A_JumpIf(CallACS("LiquidCheck"),"disappear")
		BCAS L -1 a_playsound ("casings/bullet/die") 
		stop
	disappear:
		tnt1 a 1
		stop
	}
}

Actor shellcasing
{
  projectile
  scale 0.26
  radius 3
  bouncefactor 0.5
  wallbouncefactor 0.4
  bouncecount 5
  bouncesound "casings/shell/bounce"
  bouncetype Doom
  -NOGRAVITY
  -NOBLOCKMAP
 // -BOUNCEONCEILINGS
  +DROPOFF
  +THRUACTORS
  +NOTELEPORT
  +BOUNCEONACTORS
  +FLOORCLIP
  states
	{
	Spawn:
		SCAS ABCDEFGH 2
		loop
	Death:
		TNT1 A 0 A_Jump(255, "Death1", "Death2", "Death3", "Death4", "Death6")
		goto death1
		
	Death1:
		TNT1 A 0
		TNT1 A 0 A_JumpIf(CallACS("LiquidCheck"),"disappear")
		SHDY a -1 a_playsound ("casings/shell/die")
		stop
	Death2:
		TNT1 A 0
		TNT1 A 0 A_JumpIf(CallACS("LiquidCheck"),"disappear")
		SHDY b -1 a_playsound ("casings/shell/die")
		stop
	Death3:
		TNT1 A 0
		TNT1 A 0 A_JumpIf(CallACS("LiquidCheck"),"disappear")
		SHDY c -1 a_playsound ("casings/shell/die")
		stop
	Death4:
		TNT1 A 0
		TNT1 A 0 A_JumpIf(CallACS("LiquidCheck"),"disappear")
		SHDY d -1 a_playsound ("casings/shell/die")
		stop
	Death5:
		TNT1 A 0
		TNT1 A 0 A_JumpIf(CallACS("LiquidCheck"),"disappear")
		SHDY e -1 a_playsound ("casings/shell/die")
		stop
	Death6:
		TNT1 A 0
		TNT1 A 0 A_JumpIf(CallACS("LiquidCheck"),"disappear")
		SHDY f -1 a_playsound ("casings/shell/die")
		stop
	disappear:
		tnt1 a 1
		stop
	}
}


ACTOR PuffParticles : BulletCasing
{
	+DONTSPLASH
	bouncetype "Doom"
	bouncesound ""
	gravity 0.2
    Speed 6
	Scale 0.6
	Renderstyle Add	
	States
	{
    Spawn:
		tnt1 a 0 a_jump(128,+3)
        PUFX AABCDE random(1,5) BRIGHT
        Stop
		PUFX CDE random(1,3) BRIGHT
		stop
	death:
		tnt1 a 0
		stop
	}
}

ACTOR SmallPuffParticles : PuffParticles
{
	Speed 15
	Scale 0.4
}

ACTOR Flames
{
	states
	{
	spawn:
		FLAM abcabcabcabcabcabcabcabcabc random(4,5) bright a_spawnitemex("smoothsmoke",0,0,random(12,17),0,0,random(1,2))
		stop
	}
}

ACTOR ExplosionParticles : PuffParticles
{
	bouncecount 3
	Translation "160:167=212:223"
	gravity 0.4
	States
	{
	Spawn:
		RSPK abcdefghijkl random(3,5) bright
        Stop
	}
}

ACTOR BlueEXParticles : Puffparticles
{
	Translation "160:167=194:204"
}

ACTOR GreenEXParticles : Puffparticles
{
	Translation "160:167=113:133"
}

ACTOR PuffSmoke: ExplosionFire
{
    Speed 1
	Renderstyle Translucent
	Alpha 0.4
	States
	{
    Spawn:
    SPUF EFGHI random(3,4) A_FadeOut(0.03)
	Stop
	}
}



actor smoothfog : teleportfog replaces teleportfog
{
+NOTELEPORT
states
	{
	spawn:
	TNT1 A 0 nodelay A_JumpIf(CallACS("PuffStyle")==0, "finish")	
	TNT1 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 0 a_spawnparticle(
			/*color*/yellow, 
			/*flags*/ +SPF_FULLBRIGHT +SPF_RELATIVE, 
			/*lifetime*/random(28,40),
			/*size*/random(3,8), 
			/*angle*/ frandom(0,360),
			/*xyz off*/ random(10,15), 0, 0,		
			/*xyz vel*/ random(-3,5), random(-3,5), random(-2,4), 
			/*xyz accel*/ 0, 0, 0,
			/*start alpha*/ 1.0,
			/*fadestep*/ -1)
	TNT1 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 0 a_spawnparticle(
			/*color*/green, 
			/*flags*/ +SPF_FULLBRIGHT +SPF_RELATIVE, 
			/*lifetime*/random(18,35),
			/*size*/random(3,8), 
			/*angle*/ frandom(0,360),
			/*xyz off*/ random(10,15), 0, 0,		
			/*xyz vel*/ random(-3,5), random(-3,5), random(-2,4), 
			/*xyz accel*/ 0, 0, 0,
			/*start alpha*/ 1.0,
			/*fadestep*/ -1)
			
	finish:
		SFOG abcdefghijklmnopqrstrqpo 2 bright	
		stop
	}
}

actor smoothsmoke : rocketsmoketrail replaces rocketsmoketrail
{
+NOTELEPORT
states
	{
	Spawn:
    SMOK ABCDEFGHIJ random(2,3)
    Stop
	}
}

actor smoothRocketTrail : smoothsmoke
{
	alpha 0.4
	states
	{
	spawn:
	spuf bcdefghi random(1,3) bright a_fadeout(0.1)
	stop
	}
}

actor GreenGlimmer : smoothbulletpuff
{
	+NOGRAVITY
	states
	{
	spawn:
		SFOG mnop random(1,2) bright a_spawnitemex("greensparkle",random(-5,5),random(-5,5),random(-3,5))
		SFOG qrstsrqponm random(1,2) bright
		stop
	}
}
	

actor bluesparkle : smoothsmoke
{
alpha 0.6
states
	{
	spawn:
	TNT1 a 0 a_jump(255,"spawn1","spawn2")
	goto spawn1
	
	spawn1:
	bsp1 abcde random(2,3) bright
	stop
	spawn2:
	bsp2 abcde random(2,3) bright
	stop
	}
}

actor greensparkle : bluesparkle
{
	translation "192:207=113:119"
}