CLASS DarkShotguy : ShotgunGuy
{
	override int DamageMobj(
    Actor inflictor, Actor source, int damage,
    Name mod, int flags = 0, double angle = 0)
		{
		if(inflictor is "XtremePlasmaBall")source.A_PlaySound("gore/sizzle",CHAN_AUTO,attenuation:0.8);
		else
		if(inflictor is "XtremeRocket")source.A_PlaySound("gore/snap",CHAN_AUTO,attenuation:0.8);
		else
		if(source is "PlayerPawn")source.A_PlaySound("gore/hitmarker",CHAN_AUTO,attenuation:0.8);

		return super.damagemobj
		(inflictor,source,damage,
		mod,flags,angle);
		}
	
	default
		{
		painchance 120;
		speed 10;
		}
	
	states
	{
	Spawn:
		ZSP1 AB 10 A_Look;
		Loop;
	See:
		ZSP1 AABBCCDD 3 A_Chase;
		Loop;
	Missile:
		ZSP1 E 9 A_FaceTarget;
		ZSP1 F 10 Bright A_SposAttackUseAtkSound;
		ZSP1 E 7;
		Goto See;
	Pain:
		ZSP1 G 2;
		ZSP1 G 2 A_Pain;
		Goto See;
	Death.SSG:
		TNT1 A 0 A_JumpIfCloser(128, "XDeath");
		goto death;
	Death:
		ZSP1 H 5;
		ZSP1 I 5 A_Scream;
		ZSP1 J 5 A_NoBlocking;
		ZSP1 K 5;
		ZSP1 L -1;
		Stop;
	XDeath:
		SPOS M 5;
		TNT1 a 0 a_spawnitemex("gibcontroller");
		SPOS N 5 A_XScream;
		SPOS O 5 A_NoBlocking;
		SPOS PQRST 5;
		SPOS U -1;
		Stop;
	Raise:
		ZSP1 L 5;
		ZSP1 KJIH 5;
		Goto See;
	}
}