ACTOR ShotgunGuy1: ShotgunGuy Replaces ShotgunGuy
{
	Game Doom
	Health 40
	SpawnID 1
	Radius 16
	Height 54
	Height 54
	Mass 300
	Speed 4
	FastSpeed 8
    Scale 0.98
	PainChance 255
	PainChance "Avoid", 50
	PainChance "Head", 255
	PainChance "Kick", 256 PainChance "Slide", 256
	PainChance "Melee", 255 PainChance "HangingHook", 0 PainChance "Stealth", 255
	PainChance "HelperMarineFatality", 255
	PainChance "MonsterKnocked", 255
	PainChance "ExplosiveImpact", 255
	damagefactor "Crush", 5.0 DamageFactor "Fatality", 5.0 damagefactor "FallInLava", 500.0
	PainChance "Taunt", 255
	damagefactor "Avoid", 0.0
	damagefactor "DontCallTheBaron", 0.0 damagefactor "PussyGrab", 50.0
	damagefactor "TeleportRemover", 0.0
	damagefactor "GibRemoving", 0.0
	damagefactor "SSG", 500.0
	PainChance "LowKick", 255
	DropItem "GrenadeAmmo" 15
	DropItem "ShotgunSpawnerDroped"
	damagetype "Melee"
	DamageFactor "Head", 1.3
	damagefactor "Melee", 1.35
	damagefactor "Shotgun", 2.0
	Monster
	+FLOORCLIP
	+SLIDESONWALLS
	+RANDOMIZE
	+MISSILEMORE
	+DOHARMSPECIES
	DeathHeight 4
	BurnHeight 0
	Species "Zombies"
    BloodType "Brutal_Blood", "SawBlood", "SawBlood"
	SeeSound "grunt/sight"
	PainSound "grunt/pain"
	DeathSound "grunt/death"
	ActiveSound "grunt/active"
    damagefactor "Blood", 0.0 damagefactor "BlueBlood", 0.0 damagefactor "GreenBlood", 0.0
	damagefactor "taunt", 0.0
	Obituary "%o got his face splattered on the wall by a Zombie Shotgunner."
	MaxStepHeight 24
	MaxDropOffHeight 32
	Tag "Shotgun Zombie"
	DamageFactor "CauseSplash", 0.0 DamageFactor "CauseObjectsToSplashSlime", 0.0 DamageFactor "CauseObjectsToSplashNukage", 0.0
	DamageFactor "CauseObjectsToSplashBlood", 0.0 DamageFactor "CauseObjectsToSplashLava", 0.0
	States
	{
	
	
	
	Pain.Avoid: 
	  TNT1 A 0
	  TNT1 A 0 A_Jump(255, "AvoidLeft", "AvoidRight")
	  Goto AvoidLeft
	  
	  AvoidLeft:
	    SPOS A 1 A_FaceTarget
	    TNT1 A 0 ThrustThing(angle*256/360+192, 15, 0, 0)
        ZRO4 ABCDEFGH 2 A_FaceTarget
        Goto Missile
	AvoidRight:
	    SPOS A 1 A_FaceTarget
	    TNT1 A 0 ThrustThing(angle*256/360+64, 15, 0, 0)
        ZRO3 ABCDEFGH 2 A_FaceTarget
        Goto Missile
		
	ReplaceSMG:
		TNT1 A 0 A_ChangeFlag("THRUACTORS", 1)
		TNT1 A 0 A_ChangeFlag("COUNTKILL", 0)
		TNT1 A 0 A_SpawnItemEx ("SMGGuy",0,0,0,0,0,0,0,SXF_NOCHECKPOSITION | SXF_TRANSFERAMBUSHFLAG | SXF_TRANSFERPOINTERS ,0, tid)
		Stop
		
	ReplaceVanilla:
		TNT1 A 0 A_ChangeFlag("THRUACTORS", 1)
		TNT1 A 0 A_ChangeFlag("COUNTKILL", 0)
		TNT1 A 0 A_SpawnItemEx ("VanillaShotgunguy",0,0,0,0,0,0,0,SXF_NOCHECKPOSITION | SXF_TRANSFERAMBUSHFLAG ,0)
		Stop
    Spawn:
		SHID A 1
		TNT1 A 0 A_GiveInventory("SKShotgunGuy", 1)
		TNT1 A 0 ACS_NamedExecuteAlways("BDCheckStuff")//Check if new monsters are disabled
		TNT1 A 0 ACS_NamedExecuteAlways("BDCHeckClassicMonsters", 0, 0, 0, 0)//Check if Vanilla Mode is activated
		SHID A 2
		
		  TNT1 A 0 A_GiveInventory("SKShotgunGuy", 1)
		  TNT1 A 0 A_GiveInventory("TypeSergeant", 1)
		  TNT1 A 0 A_TakeInventory("SergeantAmmo", 6)
		  TNT1 A 0 A_GiveInventory("SergeantAmmo", random(0,5))
		  TNT1 A 0 A_JumpIfInventory("nonewenemies", 1, "Stand")
		  TNT1 A 0 A_Jump(32, "ReplaceSMG")
		  SPOS B 1
		  Goto Stand
	Stand:
		TNT1 A 0
		TNT1 A 0 A_CheckSight("Stand2")
		TNT1 AA 0 A_SpawnItem ("HeadshotTarget20", 4, 44,0)
		SHID AB 11 A_Look
		Loop
		
	Stand2:
		SHID AB 11 A_Look
		TNT1 A 0 A_CheckSight("Stand2")
		Goto Stand
  
	FallBack:
	TNT1 A 0 A_CheckSight("Advance")
	TNT1 A 0 A_ChangeFLag("NODROPOFF", 1)
	TNT1 A 0 A_SpawnItem ("HeadshotTarget4", -5, 40,0)
	TNT1 A 0 A_SpawnItem ("LegTarget4", 10)
	SPOS D 2 A_FaceTarget
	SPOS D 2 A_Recoil(2)
	TNT1 A 0 A_jump(64, "Missile")
	TNT1 A 0 A_SpawnItem ("HeadshotTarget4", -5, 40,0)
	TNT1 A 0 A_SpawnItem ("LegTarget4", 10)
	SPOS C 2 A_FaceTarget
	SPOS C 2 A_Recoil(2)
	TNT1 A 0 A_SpawnItem ("HeadshotTarget4", -5, 40,0)
	TNT1 A 0 A_SpawnItem ("LegTarget4", 10)
	SPOS B 2 A_FaceTarget
	SPOS B 2 A_Recoil(2)
	TNT1 A 0 A_SpawnItem ("HeadshotTarget4", -5, 40,0)
	TNT1 A 0 A_SpawnItem ("LegTarget4", 10)
	SPOS A 2 A_FaceTarget
	SPOS A 2 A_Recoil(2)
	TNT1 A 0 A_SpawnItem ("HeadshotTarget4", -5, 40,0)
	TNT1 A 0 A_SpawnItem ("LegTarget4", 10)
	SPOS D 2 A_FaceTarget
	TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
	GOto Missile
	
	
	
	
	SearchForPlayer:
	Idle:
	    TNT1 A 0 A_ClearTarget
	    TNT1 A 0 A_TakeInventory("EnemyMemory", 30)
		TNT1 A 0 A_GiveInventory("SKShotgunGUy", 1)
        TNT1 A 0 A_SpawnItem ("HeadshotTarget10", 5, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SHID A 10 A_Look
        TNT1 A 0 A_SpawnItem ("HeadshotTarget10", 5, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SHID C 10 A_Look
		TNT1 A 0 A_SpawnItem ("HeadshotTarget10", 5, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SHID A 10 A_Look
        TNT1 A 0 A_SpawnItem ("HeadshotTarget10", 5, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SHID D 10 A_Look
		TNT1 A 0 A_SpawnItem ("HeadshotTarget10", 5, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SHID A 10 A_Look
		
		SPOS A 4 A_Look
		TNT1 A 0 A_SpawnItem ("HeadshotTarget4", 5, 40,0)
		TNT1 A 0 A_Wander
		
		SPOS B 4 A_Look
		TNT1 A 0 A_SpawnItem ("HeadshotTarget4", 5, 40,0)
		TNT1 A 0 A_Wander
		
		SPOS C 4 A_Look
		TNT1 A 0 A_SpawnItem ("HeadshotTarget4", 5, 40,0)
		TNT1 A 0 A_Wander
		
		SPOS D 4 A_Look
		TNT1 A 0 A_SpawnItem ("HeadshotTarget4", 5, 40,0)
		TNT1 A 0 A_Wander
		
		
		TNT1 A 0 A_Jump(128, "Idle")
		SPOS A 4 A_Look
		TNT1 A 0 A_SpawnItem ("HeadshotTarget4", 5, 40,0)
		TNT1 A 0 A_Wander
		
		SPOS B 4 A_Look
		TNT1 A 0 A_SpawnItem ("HeadshotTarget4", 5, 40,0)
		TNT1 A 0 A_Wander
		
		SPOS C 4 A_Look
		TNT1 A 0 A_SpawnItem ("HeadshotTarget4", 5, 40,0)
		TNT1 A 0 A_Wander
		
		SPOS D 4 A_Look
		TNT1 A 0 A_SpawnItem ("HeadshotTarget4", 5, 40,0)
		TNT1 A 0 A_Wander
		
		Loop
		
	
	See:
	TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
	TNT1 A 0 A_TakeInventory("SKZombieman", 1)
	TNT1 A 0 A_TakeInventory("EnemyMemory", 15)
	TNT1 A 0 A_CheckSight("SeeNeverSeen")
	Goto SeeContinue
	
	SeeContinue:
	    TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
	    TNT1 A 0 A_JumpIfCloser(200, "FallBack")
		//Advance:
		TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
		TNT1 A 0 A_JumpIfInventory("EnemyMemory", 15, "SearchForPlayer")
		TNT1 A 0 A_GiveInventory("EnemyMemory", 1)
        //TNT1 A 0 A_SpawnItemEx("FootSep", 0, 0, 20, 0, 0)
		TNT1 A 0 A_TakeInventory("SKShotgunGuy", 1)
		
		
		TNT1 A 0 A_SpawnItem("HeadshotTarget6", 10, 44,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SPOS AAA 2 A_Chase
		
		TNT1 A 0 A_SpawnItem("HeadshotTarget6", 10, 44,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SPOS BBB 2 A_Chase
		
		TNT1 A 0 A_SpawnItem("HeadshotTarget6", 10, 44,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SPOS CCC 2 A_Chase
		
		TNT1 A 0 A_SpawnItem("HeadshotTarget6", 10, 44,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SPOS DDD 2 A_Chase
		
		
		TNT1 A 0 A_JumpIfInTargetInventory("IsInvisible", 1, "Idle")
		Loop
		
	SeeNeverSeen:
		TNT1 A 0 A_JumpIfCloser(200, "FallBack")
		Advance:
		TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
        //TNT1 A 0 A_SpawnItemEx("FootSep", 0, 0, 10, 0, 0)
		
		
		TNT1 A 0 A_SpawnItem("HeadshotTarget6", 10, 44,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SPOS AAA 2 A_Chase
		TNT1 A 0 A_SpawnItem("HeadshotTarget6", 10, 44,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SPOS BBB 2 A_Chase
		TNT1 A 0 A_SpawnItem("HeadshotTarget6", 10, 44,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SPOS CCC 2 A_Chase
		TNT1 A 0 A_SpawnItem("HeadshotTarget6", 10, 44,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SPOS DDD 2 A_Chase
		Loop		
		
	Missile:
	    TNT1 A 0 A_Stop
		TNT1 A 0 A_TakeInventory("EnemyMemory", 10)
		TNT1 A 0 A_SpawnItem("HeadshotTarget10", 0, 40,0)
		TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
		TNT1 A 0 A_TakeInventory("SKShotgunGuy", 1)
		
		//TNT1 A 0 A_TakeInventory("CantFire", 1)
		//TNT1 A 0 A_CustomMissile("MonsterTargetCheck", 34, 0, 0, 0) 
		//TNT1 A 0 A_CustomMissile("MonsterTargetCheckFaster", 34, 0, 0, 0) 
		SPOS D 3 A_FaceTarget
		//TNT1 A 0 A_JumpIfInventory("CantFire",1, "Advance")
		
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		TNT1 A 0 A_GiveInventory("SergeantAmmo", 1)
		
		SPOS D 3 A_FaceTarget
		TNT1 A 0 A_SpawnItem("HeadshotTarget10", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SPOS E 10 A_FaceTarget
		TNT1 A 0 A_SpawnItem("HeadshotTarget4", 0, 40,0)
		SPOS E 4 A_FaceTarget
		TNT1 A 0 A_SpawnItem("HeadshotTarget4", 0, 40,0)
		SPOS E 4 A_FaceTarget
		TNT1 A 0 A_SpawnItem("HeadshotTarget4", 0, 40,0)
		SPOS E 4 A_FaceTarget
		TNT1 A 0 A_SpawnItem("HeadshotTarget10", 0, 40,0)
        
		//TNT1 A 0 A_SetPitch(random (-8, 8) + pitch)
        TNT1 AAAAA 0 A_CustomMissile("ShotgunguyTracer", 36, 0, random(-7, 7), 1, random(-4, 4))
		TNT1 A 0 A_CustomMissile("DistantFireSoundShotgun", 32, 0, 0, 1, 0)
		TNT1 AAAAAAAA 0 A_CustomMissile("ShotgunParticles", 36, 0, random(-9, 9), 6, random(-9, 9))
		TNT1 A 0 A_PlaySound("weapons/sg")
		SPOS F 5 BRIGHT //A_CustomBulletAttack(8, 8, 10, 3, "HitPuff")
		TNT1 A 0 A_Recoil(1)
		SPSR C 6
		TNT1 A 0 A_SpawnItem("HeadshotTarget10", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SPOS E 7 A_FaceTarget
		TNT1 A 0 A_SpawnItem("HeadshotTarget10", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SPSR A 7
        TNT1 A 0 A_PlaySound("weapons/sgpump")
		TNT1 A 0 A_SpawnItem("HeadshotTarget10", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SPSR B 7 A_SpawnItem ("ShotCaseSpawn", 0, 30,0)
		TNT1 A 0 A_SpawnItem("HeadshotTarget10", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SPSR A 7
        TNT1 A 0 A_JumpIfInventory("SergeantAmmo", 6, "Reload")
		TNT1 A 0 A_JumpIfInTargetInventory("IsInvisible", 1, "SearchForPlayer")
		Goto SeeContinue

  Reload:
        TNT1 A 0
		TNT1 A 0 A_SpawnItem ("HeadshotTarget20", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTarget20", 10)
        SPSR A 15
		TNT1 A 0 A_SpawnItem ("HeadshotTarget20", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("HeadshotTarget20", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTarget20", 10)
        ID12 EFG 5
        TNT1 A 0 A_PlaySound("insertshell")
		TNT1 A 0 A_TakeInventory("SergeantAmmo", 1)
		TNT1 A 0 A_SpawnItem ("HeadshotTarget20", 0, 40,0)
        ID12 EFG 5
        TNT1 A 0 A_PlaySound("insertshell")
		TNT1 A 0 A_TakeInventory("SergeantAmmo", 1)
		TNT1 A 0 A_SpawnItem ("HeadshotTarget20", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTarget20", 10)
        ID12 EFG 5
        TNT1 A 0 A_PlaySound("insertshell")
		TNT1 A 0 A_TakeInventory("SergeantAmmo", 1)
		TNT1 A 0 A_SpawnItem ("HeadshotTarget20", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTarget20", 10)
        ID12 EFG 5
        TNT1 A 0 A_PlaySound("insertshell")
		TNT1 A 0 A_TakeInventory("SergeantAmmo", 1)
		TNT1 A 0 A_SpawnItem ("HeadshotTarget20", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTarget20", 10)
		ID12 EFG 5
        TNT1 A 0 A_PlaySound("insertshell")
		TNT1 A 0 A_TakeInventory("SergeantAmmo", 1)
		TNT1 A 0 A_SpawnItem ("HeadshotTarget20", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTarget20", 10)
		ID12 EFG 5
        TNT1 A 0 A_PlaySound("insertshell")
		TNT1 A 0 A_TakeInventory("SergeantAmmo", 1)
		TNT1 A 0 A_SpawnItem ("HeadshotTarget20", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTarget20", 10)
		SPSR A 10
        TNT1 A 0 A_PlaySound("weapons/sgpump")
		TNT1 A 0 A_SpawnItem("HeadshotTarget10", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTarget20", 10)
		SPSR B 10
		TNT1 A 0 A_SpawnItem("HeadshotTarget10", 0, 40,0)
		SPSR A 10
		TNT1 A 0 A_SpawnItem("HeadshotTarget10", 0, 40,0)
        Goto SeeContinue
		

	Pain.Cut:
	Pain.Saw:
		TNT1 A 0
		TNT1 A 0 A_Stop
	Pain:
        TNT1 A 0 A_JumpIfInventory ("IsDown", 1, 9)
		TNT1 A 0 A_TakeInventory("SKShotgunGuy", 1)
		TNT1 A 0 A_SpawnItem("HeadshotTarget4", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SPOS G 3
		TNT1 A 0 A_SpawnItem("HeadshotTarget4", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SPOS G 3 A_Pain
		TNT1 A 0 A_Jump(196, "Missile")
		Goto SeeContinue
        TNT1 AAAAA 0
        TNT1 A 0 A_Pain
        ID11 H 6
        Goto GetUp
		
	Pain.Head:
	Pain.Shrapnel:	
		TNT1 A 0 A_TakeInventory("SKShotgunguy", 1)
		TNT1 A 0 A_SpawnItem ("HeadshotTarget4", 0, 40,0)
		POSH K 5 A_Pain
		TNT1 A 0 A_FaceTarget
		TNT1 A 0 A_SpawnItem ("HeadshotTarget20", 4, 35,0)
		POSH L 20
		TNT1 A 0 A_SpawnItem ("HeadshotTarget20", 4, 35,0)
		POSH L 20
		Goto SeeContinue	
		
	Pain.Melee:
	    TNT1 A 0
		TNT1 A 0 A_JumpIfInventory ("SKShotgunGuy", 1, "GotoStealthKill")
        TNT1 A 0 A_JumpIfInventory ("IsDown", 1, 6)
		TNT1 A 0 A_SpawnItem("HeadshotTarget4", 0, 40,0)
		SPOS G 4
		TNT1 A 0 A_SpawnItem("HeadshotTarget4", 0, 40,0)
		SPOS G 4 A_Pain
		Goto SeeContinue
        TNT1 AAAAA 0
        TNT1 A 0 A_Pain
        ID11 H 8
		ID11 S 35
        TNT1 A 0 A_TakeInventory("IsDown", 1)
		ID11 T 10
        Goto SeeContinue

	Pain.Stealth:
		TNT1 A 0
		TNT1 A 0 A_Pain
		TNT1 A 0 A_JumpIfInventory ("SKShotgunguy", 1, "GotoStealthKill")
        TNT1 A 0 A_JumpIfInventory ("IsDown", 1, "GroundExecution")
		Goto See
		
	GroundExecution:
		TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_GiveToTarget("ExecuteDownedShotgunguy", 1)
		TNT1 A 0 A_GiveToTarget("GoSpecial", 1)
		TNT1 A 0 A_Die("Vanish")
		Stop
		
	Death.Vanish:
		TNT1 A 0
		TNT1 A 0 A_NoBlocking
		Stop

	Pain.ExplosiveImpact:
	Pain.ExtremePunches:
	Pain.Explosive:
	TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
	TNT1 A 0 A_ChangeFlag("NOBLOCKMONST", 1)
	         TNT1 A 0
	         TNT1 A 0 A_Pain
		 TNT1 A 0 A_JumpIfInventory ("IsDown", 1, "Pain")
		 		    TNT1 A 0 A_TakeInventory("SKShotgunGuy", 1)
         TNT1 A 0 A_GiveInventory("IsDown", 1)
        TNT1 A 0 ThrustThingZ(0,40,0,1)
         SPO4 UUVWXY 4
		Goto FallingAfterImpact


	


	Pain.LowKick:
		TNT1 A 0
		TNT1 A 0 A_JumpIfInventory("IsDown", 1, "Death.LowKick")
		Goto Pain
		
	Death.LowKick:
		TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_GiveToTarget("GoFatality", 1)
        TNT1 A 0 A_GiveToTarget("IsCurbstompingSergeant", 1)
        Stop
		
		
		 
	Pain.Slide:
         TNT1 A 0
		 TNT1 A 0 A_ChangeFlag("NOBLOCKMONST", 1)
		 TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
		  TNT1 A 0 A_ChangeFlag("GHOST", 1)
		 TNT1 A 0 A_ChangeFlag("THRUGHOST", 1)	
		 TNT1 A 0 A_JumpIfInventory ("IsDown", 1, "Pain")
         ID11 G 1 A_Pain
		 TNT1 A 0 A_GiveInventory("IsDown", 1)
		 TNT1 A 0 A_TakeInventory("SKShotgunGuy", 1)
        TNT1 A 0 ThrustThingZ(0,30,0,1)
		TNT1 A 0 A_ChangeFlag("NOPAIN", 1)
		//ID11 E 1 A_Chase ("","")
		SPO4 U 1 A_facetarget
        SPO4 U 3 
		TNT1 A 0 A_Recoil(-5)
        SPO4 UVWXY 3
		TNT1 A 0 A_ChangeFlag("NOPAIN", 0)
		TNT1 A 0 A_ChangeFlag("GHOST", 0)
		TNT1 A 0 A_ChangeFlag("THRUGHOST", 0)	
		Goto FallingAfterImpact
		
		FallingAfterImpact:
		ID11 H 1 A_GiveInventory ("FallingHeight", 1)
		ID11 H 1 A_CheckFloor ("GetUp")
		NULL A 0 A_JumpIf (momz == 0, "GetUp")
		Loop	 
		
	Pain.Taunt:
		TNT1 A 0
		TNT1 A 0 HealThing(1)
		TNT1 A 0 A_JumpIfInventory("Enraged", 1, "Missile")
		POSR B 0 A_Pain
		TNT1 A 0 A_ChangeFlag("FASTER", 1)
		TNT1 A 0 A_ChangeFlag("MISSILEMORE", 1)
		TNT1 A 0 A_ChangeFlag("MISSILEEVENMORE", 1)
		TNT1 A 0 A_PlaySound("grunt/sight")
		SPO4 B 1 A_FaceTarget
		SPO4 B 10
		TNT1 A 0 A_GiveInventory("Enraged", 1)
		TNT1 A 0 A_PlaySound("grunt/sight", 1)
		Goto Missile
		
    Pain.Kick:
	Pain.Stomp:
	Pain.HeavyImpact:
         TNT1 A 0
		 TNT1 A 0 A_ChangeFlag("NOBLOCKMONST", 1)
		 TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
		 TNT1 A 0 A_JumpIfInventory ("IsDown", 1, "Pain")
         ID11 G 1 A_Pain
		 TNT1 A 0 A_GiveInventory("IsDown", 1)
		 TNT1 A 0 A_TakeInventory("SKShotgunGuy", 1)
        TNT1 A 0 ThrustThingZ(0,30,0,1)
		TNT1 A 0 A_ChangeFlag("NOPAIN", 1)
		//ID11 E 1 A_Chase ("","")
		SPO4 U 1 A_facetarget
        SPO4 U 3 ThrustThing(angle*256/360+128, 10, 0, 0)
        SPO4 UVWXY 3
		TNT1 A 0 A_ChangeFlag("NOPAIN", 0)
		Goto FallingAfterImpact
		
	FallingAfterImpact:
		ID11 H 1 A_GiveInventory ("FallingHeight", 1)
		ID11 H 1 A_CheckFloor ("GetUp")
		NULL A 0 A_JumpIf (momz == 0, "GetUp")
		Loop
		
	GetUp:
		TNT1 A 0
		TNT1 A 0 A_GiveInventory("IsDown", 1)
		MARN A 0 A_SpawnItem("bdbodythud")
		TNT1 A 0 A_ChangeFlag("FORCEXYBILLBOARD", 1)
		TNT1 A 0 A_ChangeFlag("NOPAIN", 0)
		TNT1 A 0 A_ChangeFLag("GHOST", 1)
		TNT1 A 0 A_JumpIfInventory ("FallingHeight", 5, "FallingDie")
		ID11 S 1
		ID11 SSSSSSSSS 5 A_JumpIf(momz < 0, "FallingAfterImpact")
		TNT1 A 0 A_TakeInventory("FallingHeight", 100)
        
		ID11 T 10
		TNT1 A 0 A_ChangeFlag("FORCEXYBILLBOARD", 0)
		TNT1 A 0 A_TakeInventory("IsDown", 1)
		TNT1 A 0 A_ChangeFlag("GHOST", 0)
        Goto SeeContinue
		 
	FallingDie:
		TNT1 A 0
		TNT1 A 0 A_Stop
		TNT1 A 0 A_CustomMissile("BodyCrash1", 10)
		Goto Getup+9
		
	Death.Fall:
		TNT1 A 0
		TNT1 A 0 A_Scream
		TNT1 A 0 A_NoBLocking
		TNT1 A 0 A_Stop
		TNT1 AAAA 0 A_CustomMissile ("XDeath1", 32, 0, random (0, 360), 2, random (50, 130))
		ID11 EF 2
		TNT1 A 0 A_SpawnItem ("GrowingBloodPool")
		TNT1 A 0 A_SpawnItem("DeadShotgunguy")
		ID11 F 2
		MARN AAA 0 A_SpawnItem("bdbodythud")
		TNT1 A -1
		Stop
	
	
    Pain.KillMe:
        TNT1 A 0
        Goto Missile
    Death.KillMe:
    Death.Taunt:
	    TNT1 A 0 A_ChangeFlag("SOLID", 0)
        TNT1 A 0 A_SpawnItem("ShotgunGuy")
        Stop
		
Death.MonsterShotgunBullet:
Death.Shotgun:
		SPOS J 1 A_FaceTarget
		
		TNT1 A 0 A_SpawnItem("MuchBlood", 0, 40)
		TNT1 A 0 A_CustomMissile ("SuperWallRedBlood", 42, 0, random (170, 190), 2, random (0, 20))
        TNT1 A 0 A_Jump(42, "Death.Shotgunontheface")
		TNT1 A 0 A_JumpIfCloser(100, "Death.bLAST")
		TNT1 A 0 A_JumpIfCloser(320, "Death.Shotgunontheface")
		Goto Death
		
	Death.Shotgunontheface:	
	Death.HeavyImpact:
	    TNT1 A 0
		TNT1 A 0 A_ChangeFlag("SLIDESONWALLS", 0)
		TNT1 A 0 A_Jump(24, "Death.ARm")
		TNT1 A 0 A_Jump(128, "DeathShotgunFly")
		TNT1 A 0 A_ChangeFlag("NOBLOCKMONST", 1)
		TNT1 A 0 A_Jump(96, "Death.Blast")
		TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_Jump(128, "DeathShotgunontheface2")
		TNT1 A 0 A_Stop
		TNT1 A 0 A_Pain
		SPOS H 1 A_FaceTarget
		TNT1 A 0 A_Recoil(13)
		TNT1 A 0 ThrustThingZ(0,20,0,1)
		TNT1 A 0 A_Scream
		TNT1 AA 0 A_CustomMissile ("XDeath1", 35, 0, random (0, 360), 2, random (0, 160))
        SPO4 ABCD 4
		SPO4 EFGHIJ 4 A_JumpIf((MomY == 0), "DSFStop")
		Goto DSFStop+1
		
	DSFStop:
		TNT1 A 0 A_SpawnItem("Ploft3")
		TNT1 A 0 A_Stop
		TNT1 A 0 A_SpawnItem ("GrowingBloodPool")
		TNT1 A 0 A_CustomMissile ("SuperWallRedBlood", 2, 0, random (170, 190), 2, random (0, 0))
		TNT1 A 0 A_SpawnItem("DeadShotgunguySPO4J")
		TNT1 A -1
		Stop
	
	DeathShotgunontheface2:	
		TNT1 A 0 A_ChangeFlag("NOBLOCKMONST", 1)
		TNT1 A 0 A_Stop
		TNT1 A 0 A_Pain
		SPOS H 1 A_FaceTarget
		TNT1 A 0 A_Scream
		TNT1 A 0 A_Recoil(13)
		TNT1 A 0 ThrustThingZ(0,20,0,1)
		TNT1 AA 0 A_CustomMissile ("XDeath1", 35, 0, random (0, 360), 2, random (0, 160))
        SPO4 KLMN 4
		SPO4 OPQRST 4 A_JumpIf((MomY == 0), "DSFStop2")
		Goto DSFStop2+1
		
	DSFStop2:
		TNT1 A 0 A_SpawnItem("Ploft3")
		TNT1 A 0 A_Stop
		TNT1 A 0 A_SpawnItem ("GrowingBloodPool")
		TNT1 A 0 A_CustomMissile ("SuperWallRedBlood", 2, 0, random (170, 190), 2, random (0, 0))
		TNT1 A 0 A_SpawnItem("DeadShotgunguySPO4T")
		TNT1 A -1
		Stop
		
	DeathShotgunFly:
		TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
		TNT1 A 0 A_ChangeFLag("SLIDESONWALLS", 0)
		TNT1 A 0 ThrustThingZ(0,30,0,1)
		TNT1 A 0 A_Scream
		TNT1 A 0 A_NoBlocking
        TNT1 A 0 A_FaceTarget
        TNT1 A 0 A_Recoil (6)
        SPO4 Z 5 A_CustomMissile ("Brutal_LiquidBlood3", 15, 0, random (0, 360), 2, random (0, 40))
		TNT1 A 0 A_JumpIf((MomY == 0), "TakeASit")
		SPO4 Z 5 A_CustomMissile ("Brutal_LiquidBlood3", 15, 0, random (0, 360), 2, random (0, 40))
		TNT1 A 0 A_JumpIf((MomY == 0), "TakeASit")
		SPO4 [ 5 A_CustomMissile ("Brutal_LiquidBlood3", 15, 0, random (0, 360), 2, random (0, 40))
		TNT1 A 0 A_JumpIf((MomY == 0), "TakeASit")
		SPO4 W 5 A_CustomMissile ("Brutal_LiquidBlood3", 15, 0, random (0, 360), 2, random (0, 40))
		SPO4 X 5 A_CustomMissile ("Brutal_LiquidBlood3", 15, 0, random (0, 360), 2, random (0, 40))
		SPO4 Y 5 A_CustomMissile ("Brutal_LiquidBlood3", 15, 0, random (0, 360), 2, random (0, 40))
		TNT1 A 0 A_SpawnItem("GrowingBloodPool")
		TNT1 A 0 A_SpawnItem("DeadShotgunguy1")
		TNT1 A -1
        Stop
	TakeASit:
	    TNT1 AA 0 A_CustomMissile ("SuperWallRedBlood", 6, 0, random (170, 190), 2, random (0, 40))
	    SPO4 U 5
	    TNT1 A 0 A_SpawnItem("GrowingBloodPool")
		TNT1 A 0 A_SpawnItemEx("DeadShotgunguy_Slumped", 10)
		Stop	

    Death.Eat:
	    TNT1 A 0
		TNT1 A 0 A_NoBlocking
	    TNT1 A 0 A_Scream
        TNT1 A 0 A_GiveToTarget("SergeantFatality",1)
        Stop
		
	Death.ShotgunonthefaceArm:	
		TNT1 A 0
		TNT1 A 0 A_Jump(128, "Death.Arm")
	    TNT1 A 0 ThrustThingZ(0,40,0,1)
		TNT1 A 0 A_CustomMissile ("XDeathArm1", 35, 0, random (0, 360), 2, random (0, 160))
        TNT1 A 0 A_CustomMissile ("MuchBlood", 35, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_Scream
		TNT1 A 0 A_NoBlocking
         ID11 OP 15
         TNT1 A 0 A_SpawnItem ("DeadShotgunGuy_NoArm")
		 Stop

	GotoStealthKill:
		TNT1 A 1
		//TNT1 A 0 A_JumpIfInTargetInventory("PowerStrength", 1, "BecomeMeatShield")
		TNT1 A 0 A_Explode(100, 1, 1)
		TNT1 A 1
		Goto SeeContinue
		
		BecomeMeatShield:
		TNT1 A 0 A_NoBlocking
        TNT1 A 0 A_GiveToTarget("HasZManShield", 1)
		TNT1 A 0 A_GiveToTarget("GotMeatShield", 1)
        Stop
		
    Death.Melee:
	
       TNT1 A 0 A_JumpIfInventory ("IsDown", 1, "Death.Down")
	   		TNT1 A 0 A_JumpIfInventory ("SKShotgunGuy", 1, "StealthKill")
         Death.Kick:
		 TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
		 TNT1 A 0 A_Scream
         TNT1 A 0 A_NoBlocking
        TNT1 A 0 ThrustThingZ(0,30,0,1)
        TNT1 A 0 A_FaceTarget
        TNT1 A 0 A_Recoil (8)
         SPO4 UUVWXY 4
         TNT1 A 0 A_SpawnItem("DeadShotgunguy")
		 TNT1 A -1
         Stop

    

	Death:
       TNT1 A 0 A_JumpIfInventory ("IsDown", 1, "Death.Down")
       
        TNT1 A 0 A_Jump(96, "Death.Arm")
	Death.MinorLeg:	
	    TNT1 A 0 A_Jump(48, "Death.Leg")
	Death.Minor:
		TNT1 A 0
		SPOS H 5 A_Scream
		SPOS I 5 
		SPOS J 5 A_NoBlocking
		SPOS K 5
		TNT1 A 0 A_SpawnItem ("GrowingBloodPool")
        TNT1 A 0 A_SpawnItem("DeadShotgunguy")
		TNT1 A -1
		Stop
		
	Death.Down:
	Death.Trample:
        TNT1 A 0 
        TNT1 A 0 A_Scream
		TNT1 A 0 A_NoBlocking
		TNT1 AAA 0 A_CustomMissile ("XDeath1", 2, 0, random (0, 360), 2, random (0, 40))
		ID11 H 12
        TNT1 A 0 A_SpawnItem("DeadShotgunguy")
		TNT1 A -1
		Stop	

     Death.Leg:
	 LegRemove:
		TNT1 A 0 A_CustomMissile ("XDeathSargeLeg1", 35, 0, random (0, 360), 2, random (0, 160))
        SPO3 A 9 A_CustomMissile ("MuchBlood", 10, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_Playsound ("grunt/death")
		SPO3 B 3 
		SPO3 C 3 A_NoBlocking
		TNT1 A 0 A_SpawnItemEx ("SergeantGotHisLegBlowed",0,0,0,0,0,0,0,SXF_NOCHECKPOSITION,0)
        Stop
		
	LeaveCrawling:
	     TNT1 A 0
		 TNT1 A 0 A_SpawnItemEx ("DyingSergeantNoLeg",0,0,0,0,0,0,0,SXF_NOCHECKPOSITION,0)
		 TNT1 A 0
		 Stop

    Death.Arm:
        TNT1 A 0 A_Scream
        TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_CustomMissile ("XDeathArm2", 35, 0, random (0, 360), 2, random (0, 160))
        SPO5 A 9 A_CustomMissile ("XDeath1", 40, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_SpawnItem ("GrowingBloodPool")
		TNT1 A 0 A_SpawnItemEx ("DyingSergeant",0,0,0,0,0,0,0,SXF_NOCHECKPOSITION,0)
        Stop

    HeadExploder:
		TNT1 A 0 A_Jump(72, "Death.HeadExplode")
		Goto Death.HeadMinor

	Death.Head:
		TNT1 A 0
	    TNT1 A 0 A_JumpIfInTargetInventory("HasPlasmaWeapon", 1, "Death.Plasma")
		TNT1 A 0 A_JumpIfInTargetInventory("HasCutingWeapon", 1, "Death.Decaptate")
		TNT1 A 0 A_JumpIfHealthLower(-400, "HeavyHead")
		TNT1 A 0 A_JumpIfHealthLower(-50, "Death.HeadExplode")
		TNT1 A 0 A_JumpIfInTargetInventory("RandomHeadExploder", 1, "HeadExploder")
		TNT1 A 0 A_JumpIfInTargetInventory("HeavyAutomaticWeapon", 1, "Death.MinorHeadLong")
	Death.HeadMinor:
		TNT1 A 0 A_FaceTarget
		TNT1 A 0 A_PlaySound("misc/xdeath4")
		TNT1 A 0 A_Jump(96, "Death.MinorHeadLong")
        TNT1 A 0 A_CustomMissile ("BloodMist", 50, 0, random (0, 360), 2, random (30, 90))
		TNT1 AA 0 A_CustomMissile ("SmallBrainPiece", 50, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("XDeath1", 40, 0, random (100, 130), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("Brains3", 50, 0, random (90, 110), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("Brains5", 50, 0, random (100, 130), 2, random (0, 160))
		TNT1 A 0 A_Scream
		SPOS TTTTUU 2 A_CustomMissile ("Brutal_LiquidBlood", 40, 0, 120, 2, random (0, 60))
		SPOS VVV 2 A_CustomMissile ("Brutal_LiquidBlood2", 30, 0, 120, 2, random (60, 120))
		TNT1 A 0 A_NoBlocking 
		SPOS XXXYYY 2 A_CustomMissile ("Brutal_LiquidBlood2", 20, 0, random (0, 360), 2, random (60, 120))
		TNT1 A 0 A_CustomMissile ("ArterialBloodSPray", 10, 10, -45, 2, random (0, 60))
		TNT1 A 0 A_SpawnItem ("GrowingBloodPool")
		TNT1 A 0 A_SpawnItem("DeadShotgunguySPOSZ")
		TNT1 A -1
		Stop
		
	Death.MinorHeadLong:
		TNT1 A 0
	    TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_Scream
		TNT1 A 0 A_SpawnItemEx("DyingShotgunguyHitInEye",0,0,0,0,0,0,0,SXF_NOCHECKPOSITION,0)
		Stop
		
	DeathMinorHead4:
	    TNT1 A 0
	    TNT1 A 0 A_Pain
		TNT1 A 0 A_FaceTarget
		TNT1 A 0 A_CustomMissile ("Brains4", random (45, 55), random (5, -5), random (170, 190), 2, random (-10, 10))
		TNT1 AA 0 A_CustomMissile ("SmallBrainPieceFast", random (45, 55), random (5, -5), random (170, 190), 2, random (-10, 10))
		TNT1 A 0 A_CustomMissile ("SmallBrainPiece", 50, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("SuperWallRedBlood", 46, 0, random (170, 190), 2, random (0, 40))
		TNT1 A 0 A_CustomMissile ("BloodMist", 50, 0, random (0, 360), 2, random (30, 90))
		13DG J 6
		13DG KL 8
		
		TNT1 A 0 A_Scream
		13DG M 6 A_NoBlocking
		TNT1 A 0 A_CustomMissile ("ArterialBloodSPray", 10, -10, 45, 2, random (0, 60))
		TNT1 A 0 A_SpawnItem ("GrowingBloodPool")
		TNT1 A 0 A_SpawnItem("DeadShotgunguy13DGN")
		TNT1 A -1
		Stop


	Death.headExplode:
        TNT1 A 0
		TNT1 A 0 A_XScream
		TNT1 A 0 A_JumpIfInTargetInventory("HeavyStrikeUpward", 1, "HeavyHead")
		TNT1 A 0 A_SpawnItem("ShotgunguyHeadExplode", 0, 50)
		TNT1 A 0 A_NoBlocking
        SPDH AAAAA 2 A_CustomMissile ("Brutal_LiquidBlood2", 40, 0, random (0, 360), 2, random (60, 120))
		TNT1 A 0 A_FaceTarget
		TNT1 A 0 A_SpawnItemEx("DeadShotgunguyNoHeadContinue",0,0,0,0,0,0,0,SXF_NOCHECKPOSITION,0)
		Stop
		

    HeavyHead:	
		TNT1 A 0 A_ChangeFlag("NOBLOCKMONST", 1)
		TNT1 A 0 A_PlaySound("misc/xdeath4")
		TNT1 A 0 A_FaceTarget
		TNT1 A 0 A_Recoil(10)
		TNT1 A 0 ThrustThingZ(0,35,0,1)
		TNT1 A 0 A_CustomMissile ("MuchBlood2", 40, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("Brains2", 40, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("Brains3", 40, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("Brains5", 40, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("BrainsSergeantHeadPiece", 50, 0, random (0, 360), 2, random (0, 160))
		TNT1 AAA 0 A_CustomMissile ("SmallBrainPieceFast", random (45, 55), random (5, -5), random (170, 190), 2, random (-10, 10))
		TNT1 AAAAA 0 A_CustomMissile ("SmallBrainPiece", 40, 0, random (0, 360), 2, random (0, 160))
		TNT1 AA 0 A_CustomMissile ("SuperWallRedBlood", 46, 0, random (170, 190), 2, random (0, 40))
  	    ZMAD B 0 A_XScream
		
		ZMAD C 0 A_NoBlocking
		SOSL GHIJK 6
		TNT1 A 0 A_CustomMissile ("ArterialBloodSPray", 10, 10, -45, 2, random (0, 60))
		SOSL L -1
		Stop

	Death.decaptate:
        TNT1 AAAAAAA 0 A_CustomMissile ("Blood", 50, 0, random (0, 360), 2, random (0, 160))
        TNT1 A 0 A_PlaySound("misc/xdeath4")
        TNT1 A 0 A_CustomMissile ("XDeathSergeantHeadBeheaded", 50, 0, random (0, 360), 2, random (40, 90))
        TNT1 A 0 A_CustomMissile ("MuchBlood2", 40, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_XScream
		TNT1 A 0 A_NoBlocking
        SPDH AAAAABBBBBBBBBBCCCCC 2 A_CustomMissile ("Brutal_LiquidBlood2", 30, 0, random (0, 360), 2, random (60, 120))
		SPDH DDDDDDEEEEE 2 A_CustomMissile ("Brutal_LiquidBlood2", 10, 0, random (0, 360), 2, random (60, 120))
		SPDH EEEEEEEEEEEE 2 A_CustomMissile ("Brutal_LiquidBlood2", 5, 0, random (0, 360), 2, random (10, 40))
		TNT1 A 0 A_SpawnItem ("GrowingBloodPool")
		TNT1 A 0 A_SpawnItem("DeadShotgunguySPDHE")
		TNT1 A -1
		Stop

        
		
	Death.HKFT:
        TNT1 A 0
        TNT1 A 0 A_Jump(64, "Death.Arm")
        Goto Death.Tear

	 Death.Minigun:
        TNT1 A 0
        TNT1 A 0 A_JumpIfInventory ("IsDown", 1, "Death.Down")
        TNT1 A 0 A_Jump(16, "Death")
		TNT1 A 0 A_Jump(32, "Death.Cut")
		TNT1 A 0 A_Jump(9, "Death.LegMassacre")
		TNT1 A 0 A_Jump(64, "Death")
        Goto Death.Minigun
		
	Death.Saw:
    Death.Tear:
		TNT1 A 0
		TNT1 A 0 A_Jump(32, "Death.ARm")
        TNT1 A 0 A_CustomMissile ("MuchBlood", 1, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_Scream
		TNT1 O 0 A_NoBlocking
	    SP2X AA 8
        TNT1 A 0 A_CustomMissile ("XDeath4", 40, 0, random (0, 360), 2, random (0, 160))
        TNT1 A 0 A_CustomMissile ("RipSergeant", 0, 0, random (0, 360), 2, random (0, 160))
        SP2X BBCD 8
		TNT1 A 0 A_SpawnItem ("GrowingBloodPool")
		TNT1 A 0 A_SpawnItem("DeadShotgunguySP2XE")
		TNT1 A -1
		Stop
		
        Death.Minigun:
        TNT1 A 0
		TNT1 A 0 A_FaceTarget
		TNT1 A 0 A_Scream
		TNT1 O 0 A_NoBlocking
        TNT1 A 0 A_SpawnItem ("BrutalizedSergeant1", 1)
		Stop

        Death.LegMassacre:
        TNT1 A 0
		TNT1 A 0 A_FaceTarget
		TNT1 A 0 A_Scream
		TNT1 O 0 A_NoBlocking
        TNT1 A 0 A_SpawnItem ("BrutalizedSergeantLeg", 1)
		Stop
		
	Death.Blast:
	Death.Railgun:
	    TNT1 A 0
		TNT1 A 0 A_FaceTarget
		TNT1 A 0 A_Jump(12, "Death.Arm")
		TNT1 A 0 A_Jump(128, "Death.Blast2")
		TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_Scream
		TNT1 AAA 0 A_CustomMissile ("Guts", 32, 0, random (150, 210), 2, random (0, 40))
		TNT1 AAA 0 A_CustomMissile ("XDeath1", 32, 0, random (150, 210), 2, random (0, 40))
		TNT1 AAA 0 A_CustomMissile ("Xdeath3", 16, 0, random (170, 190), 2, random (0, 40))
		TNT1 AAAA 0 A_CustomMissile ("Brutal_FlyingBlood", 32, 0, random (170, 190), 2, random (0, 40))
		TNT1 AAAA 0 A_CustomMissile ("Brutal_FlyingBloodFaster", 32, 0, random (170, 190), 2, random (0, 40))
		TNT1 AAAA 0 A_CustomMissile ("Brutal_FlyingBloodMuchFaster", 32, 0, random (170, 190), 2, random (0, 40))
		TNT1 AA 0 A_CustomMissile ("SuperWallRedBlood", 32, 0, random (170, 190), 2, random (0, 40))
		TNT1 AA 0 A_CustomMissile ("BloodMistBig", 40, 0, random (0, 360), 2, random (30, 90))
		TNT1 AAA 0 A_CustomMissile ("BloodMistBig", 40, 0, random (0, 360), 2, random (30, 90))
		ZXZ7 A 6 A_Stop
		TNT1 A 0 A_SpawnItem ("SergeantFallingHoleOnStomach")
		TNT1 A -1
	    Stop
		
	Death.Blast2:
	    TNT1 A 0 A_XScream
		TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_CustomMissile ("XDeathArm1", 42, 0, random (0, 360), 2, random (0, 40))
	    TNT1 AAA 0 A_CustomMissile ("Guts", 32, 0, random (150, 210), 2, random (0, 40))
		TNT1 AAA 0 A_CustomMissile ("XDeath1", 32, 0, random (150, 210), 2, random (0, 40))
		TNT1 AAA 0 A_CustomMissile ("Xdeath3", 16, 0, random (170, 190), 2, random (0, 40))
		TNT1 AA 0 A_CustomMissile ("Xdeath2", 16, 0, random (130, 210), 2, random (0, 40))
		TNT1 AAAA 0 A_CustomMissile ("Brutal_FlyingBlood", 32, 0, random (170, 190), 2, random (0, 40))
		TNT1 AAAA 0 A_CustomMissile ("Brutal_FlyingBloodFaster", 32, 0, random (170, 190), 2, random (0, 40))
		TNT1 AAAA 0 A_CustomMissile ("Brutal_FlyingBloodMuchFaster", 32, 0, random (170, 190), 2, random (0, 40))
		TNT1 AA 0 A_CustomMissile ("SuperWallRedBlood", 32, 0, random (170, 190), 2, random (0, 40))
		TNT1 AAA 0 A_CustomMissile ("BloodMistBig", 40, 0, random (0, 360), 2, random (30, 90))
		TNT1 AAA 0 A_CustomMissile ("BloodMist", 40, 0, random (0, 360), 2, random (40, 90))
		ZXZ6 A 6 A_Stop
		TNT1 A 0 A_SpawnItem("SergeantFallingSplattered")
		TNT1 A -1
	    Stop
		
	Death.SSG:
	Death.Railgun:
		TNT1 A 0
		TNT1 A 0 A_Stop
	    SZD1 E 1 A_Pain
		TNT1 A 0 A_SpawnItem("Muchblood2", 0, 40)
		SZD1 E 1 A_FaceTarget
		
	    TNT1 AAA 0 bright A_CustomMissile ("SuperGoreSpawner", 35, 0, random (170, 190), 2, random (0, 40))
        TNT1 A 0 A_CustomMissile ("XDeath2", 32, 0, random (170, 190), 2, random (0, 40))
		TNT1 A 0 A_CustomMissile ("XDeath3", 32, 0, random (170, 190), 2, random (0, 40))
		TNT1 AAA 0 A_CustomMissile ("Guts", 32, 0, random (150, 210), 2, random (0, 40))
		TNT1 AA 0 A_CustomMissile ("XDeathArm1", 32, 0, random (170, 190), 2, random (0, 40))
		TNT1 A 0 A_CustomMissile ("XDeathSergeantHead", 32, 0, random (170, 190), 2, random (0, 40))
        TNT1 A 0 A_XScream
		TNT1 A 0 A_NoBlocking
        SZD1 EEFFGH 6
		TNT1 A 0 A_SpawnItem ("GrowingBloodPool")
		TNT1 A 0 A_SpawnItem("DeadShotgunguySZD1H")
		TNT1 A -1
        Stop
		
		
	Death.Cut:
		TNT1 A 0
		TNT1 A 0 A_Stop
	    SZD1 E 1 A_Pain
		TNT1 A 0 A_SpawnItem("Muchblood2", 0, 40)
		SZD1 E 1 A_FaceTarget
	    TNT1 A 0 A_CustomMissile ("RipGuts", 32, 0, random (170, 190), 2, random (0, 40))
		TNT1 A 0 A_CustomMissile ("XDeathHalfSergeant2", 32, 0, random (0, 360), 2, random (60, 70))
        TNT1 A 0 A_XScream
		TNT1 A 0 A_NoBlocking
        SZD1 EEFFGH 6
		TNT1 A 0 A_SpawnItem ("GrowingBloodPool")
		TNT1 A 0 A_SpawnItem("DeadShotgunguySZD1H")
		TNT1 A -1
        Stop	
		
		
	

    	Death.GreenFire:
        TNT1 A 0
        TNT1 A 0 A_XScream
        TNT1 A 0 A_NoBlocking
        TNT1 AAAA 0 A_CustomMissile ("Brutal_Blood", 30, 0, random (0, 360), 2, random (0, 160))
		
	    TNT1 A 0 A_CustomMissile ("XDeathBurnedArm", 32, 0, random (0, 360), 2, random (0, 160))
	    TNT1 A 0 A_CustomMissile ("XDeathBurnedLeg", 32, 0, random (0, 360), 2, random (0, 160))
	    TNT1 A 0 A_CustomMissile ("XDeathBurnedSkull", 32, 0, random (0, 360), 2, random (0, 160))
	    TNT1 A 0 A_CustomMissile ("XDeathBurnedMeat", 32, 0, random (0, 360), 2, random (0, 160))
	    TNT1 A 0 A_CustomMissile ("XDeathBurnedMeat2", 32, 0, random (0, 360), 2, random (0, 160))
	    TNT1 A 0 A_CustomMissile ("XDeathBurnedMeat3", 32, 0, random (0, 360), 2, random (0, 160))
		
		EXPL AAAAAAAAAAAAAAAAAAAAAAAA 0 A_CustomMissile ("GreenFlameTrails", 50, 0, random (0, 360), 2, random (0, 360))
		XBRN AAAA 2 BRIGHT A_SpawnItem("GreenFlare",0,43)
        Stop
		
    Death.Plasma: Death.Plasma2:
		TNT1 A 0
		TNT1 A 0 A_Stop
		PBR1 A 6 A_XScream
		TNT1 AAAA 0 A_CustomMissile ("BluePlasmaFireNonStatic", 42, 0, random (0, 360), 2, random (0, 180))
		TNT1 AAA 0 A_CustomMissile ("Blood", 32, 0, random (0, 360), 2, random (0, 180))
		TNT1 AAA 0 A_CustomMissile ("BloodMistSmall", 32, 0, random (0, 360), 2, random (0, 180))
		TNT1 AAA 0 A_CustomMissile ("Brutal_FlyingBlood", 32, 0, random (0, 360), 2, random (0, 180))
		PBR1 B 6 A_NoBlocking
		TNT1 A 0 A_SpawnItemEx ("DetectFloorCraterSmall",0,0,0,0,0,0,0,SXF_NOCHECKPOSITION,0)
		TNT1 A 0 A_SpawnItem("BarrelExplosionSmokeColumn")
		TNT1 A 0 A_SpawnItemEx("TinyBurningPiece", random (-15, 15), random (-15, 15))
		TNT1 AA 0 A_SpawnItemEx("TinyBurningPiece2", random (-35, 35), random (-35, 35))
		TNT1 AA 0 A_SpawnItemEx("TinyBurningPiece3", random (-45, 45), random (-45, 35))
		PBR1 CCDD 3 A_CustomMissile ("BluePlasmaFireNonStatic", 32, 0, random (0, 360), 2, random (0, 180))
		PBR1 EEFF 3 A_CustomMissile ("BluePlasmaFireNonStatic", 24, 0, random (0, 360), 2, random (0, 180))
		PBR1 GG 3 A_CustomMissile ("BluePlasmaFireNonStatic", 22, 0, random (0, 360), 2, random (0, 180))
		PBR1 H -1
		Stop
	
	  Death.ExtremePunches:
		 TNT1 A 0
		 //TNT1 A 0 A_JumpIfInTargetInventory("HeavyStrikeRight", 1, "HeavyPunchRight")
		 //TNT1 A 0 A_JumpIfInTargetInventory("HeavyStrikeLeft", 1, "HeavyPunchLeft") 
		 //TNT1 A 0 A_JumpIfInTargetInventory("HeavyStrikeUpper", 1, "HeavyPunchUpper")
		 TNT1 A 0 A_XScream
		 TNT1 A 0 A_NoBlocking
		 TNT1 A 0 A_FaceTarget
		 TNT1 A 0 A_CustomMissile ("ExtremePunchedShotgunguy", 8, 0, random (175, 185), 2, random (10, 20))
		 Stop
		 
	HeavyPunchRight:
		TNT1 A 0
		TNT1 A 0 A_FaceTarget
		TNT1 A 0 ThrustTHing(angle*256/360+64, 10, 0)
		Goto BlownAwayRight
		
	HeavyPunchLeft:
		TNT1 A 0
		TNT1 A 0 A_FaceTarget
		TNT1 A 0 ThrustTHing(angle*256/360+192, 10, 0)
		Goto BlownAwayLeft
	
	

	Death.SuperPlasma:
        TNT1 A 0
        TNT1 A 0 A_XScream
        TNT1 A 0 A_NoBlocking
		XBRN AA 2 BRIGHT A_SpawnItem("BlueFlare",0,43)
        TNT1 AAAA 0 A_CustomMissile ("Brutal_Blood", 30, 0, random (0, 360), 2, random (0, 160))
		
	    TNT1 A 0 A_CustomMissile ("XDeathBurnedArm", 32, 0, random (0, 360), 2, random (0, 160))
	    TNT1 A 0 A_CustomMissile ("XDeathBurnedLeg", 32, 0, random (0, 360), 2, random (0, 160))
	    TNT1 A 0 A_CustomMissile ("XDeathBurnedSkull", 32, 0, random (0, 360), 2, random (0, 160))
	    TNT1 A 0 A_CustomMissile ("XDeathBurnedMeat", 32, 0, random (0, 360), 2, random (0, 160))
	    TNT1 A 0 A_CustomMissile ("XDeathBurnedMeat2", 32, 0, random (0, 360), 2, random (0, 160))
	    TNT1 A 0 A_CustomMissile ("XDeathBurnedMeat3", 32, 0, random (0, 360), 2, random (0, 160))

		XBRN BB 2 BRIGHT A_SpawnItem("BlueFlare",0,43)
        TNT1 A 0 A_CustomMissile ("Brutal_Blood", 30, 0, random (0, 360), 2, random (0, 160))
		XBRN CC 2 BRIGHT A_SpawnItem("BlueFlare",0,43)
		TNT1 AAAAA 0 A_CustomMissile ("PlasmaParticleX", 48, 0, random (0, 360), 2, random (0, 360))
		TNT1 AAA 0 A_CustomMissile ("BigPlasmaParticleX", 42, 0, random (0, 360), 2, random (0, 360))
        TNT1 A 0
        Stop
	
    Death.Fatality:
		TNT1 A 0
		TNT1 A 0 A_FaceTarget
		TNT1 A 0 A_SpawnItemEx("Shell", 0, 0, 40, 0, 0, 0, 0, 0, 128)
		TNT1 A 0 A_SpawnItemEx("HealthPlusFatalityBonus", 0, 0, 20, random (-1, 1), random (-1, 1), 8)
		TNT1 A 0 A_SpawnItemEx("ArmorShardFatalityBonus", 0, 0, 20, random (-1, 1), random (-1, 1), 8)
		TNT1 A 0 A_Pain
		TNT1 A 0 A_JumpIfIntargetInventory("IsPlayer", 1, 2)
		Goto Death.ExplosiveImpact
		TNT1 A 0
        TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_GiveToTarget("GoFatality", 1)
        TNT1 A 0 A_Jump(255, "Death.Fatality1", "Death.Fatality4", "Death.Fatality2", "Death.Fatality3")
		
	Death.Fatality1:	
        TNT1 A 0 A_GiveToTarget("SergeantFatality", 1)
        Stop
    Death.Fatality2:    
		TNT1 A 0 A_GiveToTarget("SergeantFatality2", 1)
        Stop
	Death.Fatality3:    
		TNT1 A 0 A_GiveToTarget("SergeantFatality3", 1)
        Stop
		
	Death.Fatality4:    
		TNT1 A 0 A_GiveToTarget("SergeantFatality4", 1)
        Stop	
		
	Death.Fatality5:    
		TNT1 A 0 A_GiveToTarget("SergeantFatality5", 1)
        Stop		
		
	Death.PussyGrab:
	    TNT1 A 0
		TNT1 A 0 A_Pain
		TNT1 A 0 A_Chase("","")
		TNT1 A 0 A_Pain
		TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_GiveToTarget("GrabbedAShotgunguy", 1)
        Stop		
		
	Death.HelperMarineFatallity:	
	Death.BHFT:
	Death.RVFT:
		TNT1 A 0
	    TNT1 A 1 A_Pain
		TNT1 A 0 A_Chase("","")
		TNT1 A 0 A_Scream
		TNT1 A 0 A_NoBlocking        
		TNT1 A 0 A_GiveToTarget("SergeantFatality", 1)
		Stop	
		
    Death.fire:
    Death.burn:
	Death.FallInLava:
    Death.flames:
        TNT1 A 0 A_Scream
        TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_SpawnItem("BurningZombieMan", 0, 7)
        //TNT1 A 0 A_SpawnItem("BurningShotgunguy", 0, 10)
      Stop

	XDeath:
		TNT1 A 0 A_XScream
  	    TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_FaceTarget
		TNT1 AAA 0 A_CustomMissile ("XDeath1", 42, 0, random (0, 190), 2, random (10, 60))
		TNT1 AAA 0 A_CustomMissile ("XDeath3", 42, 0, random (0, 190), 2, random (10, 60))
		TNT1 A 0 A_CustomMissile ("XDeath2", 42, 0, random (0, 190), 2, random (10, 60))
		TNT1 A 0 A_CustomMissile ("XDeath4", 42, 0, random (0, 190), 2, random (10, 60))
        TNT1 A 0 A_CustomMissile ("SargeXDeath", 0, 0, random (0, 360), 2, random (0, 160))
        Stop
		
	Death.Desintegrate:
        TNT1 A 0 A_XScream
        TNT1 A 0 A_NoBlocking
        TNT1 A 0 A_SpawnItem("DesintegratedHuman")
		TNT1 A 0 A_Stop
		TGIB ABCDEFGHIJKLMNOPQ 3
		TGIB Q -1
      Stop
	
		
	Death.Stomp:
		TNT1 A 0 A_Scream
		TNT1 A 0 A_NoBlocking
		SPOS IJK 2
	    TNT1 AA 0 A_SpawnItem("MeatDeathSmall")
		TNT1 AAA 0 bright A_CustomMissile ("SuperGoreSpawner", 5, 0, random (0, 360), 2, random (30, 180))
		TNT1 AAAA 0 bright A_CustomMissile ("XDeath1", 5, 0, random (0, 360), 2, random (30, 180))
		TNT1 AA 0 bright A_CustomMissile ("XDeath2b", 55, 0, random (0, 360), 2, random (30, 180))
		TNT1 AA 0 bright A_CustomMissile ("XDeath3b", 55, 0, random (0, 360), 2, random (30, 180))
		TNT1 A 0 A_SpawnItem ("GrowingBloodPool")
		TNT1 A 0 A_SpawnItem ("CrushedRemains")
		TNT1 A 1
		TNT1 A 1 A_XScream
		Stop
		
	Crush:
		TNT1 A 0
		TNT1 AAAA 0 A_SpawnItemEx ("BodyRemovalThing",0,0,0,0,0,0,0,SXF_NOCHECKPOSITION,0)
		TNT1 AAAAA 0 A_CustomMissile ("Brutal_FlyingBloodTrail8", 0, 0, random (0, 360), 2, random (0, 360))
		TNT1 A 1 A_XScream
		Stop	
	
	Death.ExplosiveImpact:
		TNT1 A 0
		TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
		TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_SpawnItemEx("MuchBlood2", 0, 0, 40)
		TNT1 A 0 ThrustThingZ(0,30,0,1)
		TNT1 A 0 A_FaceTarget
		TNT1 A 1
		TNT1 A 0 A_JumpIf(angle < 180, "IsFacingNorth")
		TNT1 A 0 A_JumpIf(velx < 0, "BlownAwayRight")
		TNT1 A 0 A_JumpIf(velx > 0, "BlownAwayLeft")
		Goto XDeath
		IsFacingNorth:
		TNT1 A 0 A_JumpIf(velx > 0, "BlownAwayRight")
		TNT1 A 0 A_JumpIf(velx < 0, "BlownAwayLeft")
		Goto XDeath
		
	BlownAwayLeft:	
		TNT1 A 0
		TNT1 A 0 ThrustThingZ(0,15,0,1)
		TNT1 A 0 A_JumpIfHealthLower(-15, 1)
		Goto LegRemove
		TNT1 A 0 A_Jump(96, "Death.LandMine")
	    TNT1 A 0
		TNT1 A 0 A_CustomMissile ("XDeath2", 32, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_ChangeFlag("NOBLOCKMONST", 1)
	    TNT1 A 0 A_CustomMissile ("Brains2", 50, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("Brains3", 50, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("Brains4", 50, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("Brains5", 50, 0, random (0, 360), 2, random (0, 160))
		TNT1 AAAA 0 A_CustomMissile ("SmallBrainPieceFast", random (45, 55), random (5, -5), random (170, 190), 2, random (-10, 10))
		TNT1 AAAA 0 A_CustomMissile ("SmallBrainPiece", 50, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("XDeathArm1", 35, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("XDeath3", 40, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("XDeathZombieLeg", 32, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 ThrustThingZ(0,10,0,1)
		TNT1 A 0 A_Xscream
	    SXSX GHIJKLM 3
		TNT1 A 0 A_CheckFloor("Land8473")
		SXSX GHIJKLMGHIJKLM 5 A_CheckFloor("Land8473")
		Land8473:
		SXSX N 0
		TNT1 A 0 A_Stop
		TNT1 A 0 A_SpawnItem("GrowingBloodPool")
		TNT1 A 0 A_SpawnItem("DeadSergeantSXSXO")
		TNT1 A -1
		Stop
		
	BlownAwayRight:
		TNT1 A 0
		TNT1 A 0 ThrustThingZ(0,15,0,1)
		TNT1 A 0 A_JumpIfHealthLower(-15, 1)
		Goto Death.Arm
		TNT1 A 0 A_Jump(96, "Death.Hammered")
		TNT1 A 0 A_CustomMissile ("XDeath2", 32, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_ChangeFlag("NOBLOCKMONST", 1)
	    TNT1 A 0 A_CustomMissile ("Brains2", 50, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("Brains3", 50, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("Brains4", 50, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("Brains5", 50, 0, random (0, 360), 2, random (0, 160))
		TNT1 AAAA 0 A_CustomMissile ("SmallBrainPieceFast", random (45, 55), random (5, -5), random (170, 190), 2, random (-10, 10))
		TNT1 AAAA 0 A_CustomMissile ("SmallBrainPiece", 50, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("XDeathArm1", 35, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("XDeath3", 40, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("XDeathZombieLeg", 32, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 ThrustThingZ(0,15,0,1)
		TNT1 A 0 A_XScream
	    SXS2 GHIJKLM 3
		TNT1 A 0 A_CheckFloor("Land8472")
		SXS2 GHIJKLMGHIJKLM 5 A_CheckFloor("Land8472")
		Land8472:
		SXS2 N 0
		TNT1 A 0 A_Stop
		TNT1 A 0 A_SpawnItem("GrowingBloodPool")
		TNT1 A 0 A_SpawnItem("DeadSergeantSXS2O")
		TNT1 A -1
		Stop	
		
	Death.Hammered:
	TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
	TNT1 A 0
	TNT1 A 0 A_CustomMissile ("XDeath1", 32, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("XDeath2", 32, 0, random (0, 360), 2, random (0, 160))
	TNT1 A 0 A_ChangeFlag("NOBLOCKMONST", 1)
	TNT1 A 0
	TNT1 A 0 A_Jump(96,"Death.LandMine")
		TNT1 AAAA 0 A_CustomMissile ("Brains1", 50, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("Brains2", 50, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("Brains3", 50, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("Brains4", 50, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("Brains5", 50, 0, random (0, 360), 2, random (0, 160))
		TNT1 AAAA 0 A_CustomMissile ("SmallBrainPieceFast", random (45, 55), random (5, -5), random (170, 190), 2, random (-10, 10))
		TNT1 AAAA 0 A_CustomMissile ("SmallBrainPiece", 50, 0, random (0, 360), 2, random (0, 160))
		TNT1 AA 0 A_CustomMissile ("SuperWallRedBlood", 46, 0, random (170, 190), 2, random (0, 40))
        TNT1 AAAAAAAAAAA 0 A_CustomMissile ("BrainBlood", 50, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("XDeathArm1", 35, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("XDeath3", 40, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("XDeathSargeLeg2", 32, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 ThrustThingZ(0,30,0,1)
	    ID14 AB 5
		ID14 CDEF 5 A_CheckFloor ("Dead.ExplosiveImpact")
		ID14 FFFFFF 5 A_CheckFloor ("Dead.ExplosiveImpact")
		TNT1 A 0 A_SpawnItem ("VeryFuckedUpBrutalizedSergeantLeg")
		TNT1 A -1
		Stop
		
		Dead.ExplosiveImpact:
		TNT1 A 0 A_SpawnItem ("GrowingBloodPool")
		TNT1 A 0 A_SpawnItem ("VeryFuckedUpBrutalizedSergeantLeg")
		TNT1 A 0 A_SpawnItem ("Ploft")
		TNT1 A 0 A_SpawnItem ("MuchBlood")
		Stop

		
	Death.LandMine:
		TNT1 A 0 A_CustomMissile ("XDeathSargeLeg1", 32, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 ThrustThingZ(0,25,0,1)
		ID16 A 1 A_Scream
	    ID16 A 9
		ID16 BCD 9 A_CheckFloor ("Dead.Landmine")
		ID16 DDDD 9 A_CheckFloor ("Dead.Landmine")
		TNT1 A 0 A_SpawnItem ("DeadShotgunguy_NoLeg", 1)
		Stop		
	
		Dead.Landmine:
		TNT1 A 0 A_SpawnItem ("GrowingBloodPool")
		TNT1 A 0 A_SpawnItem ("DeadShotgunguy_NoLeg", 1)
		TNT1 A 0 A_SpawnItem ("Ploft")
		TNT1 A 0 A_SpawnItem ("MuchBlood")
		Stop
	
	Raise:
		SPOS L 5
		SPOS KJIH 5
		Goto SeeContinue
     
		
	StealthKill:
	TNT1 A 0
	TNT1 A 0 A_JumpIfInTargetInventory("IsPlayer", 1, 1)
	Goto Death
	TNT1 A 0 A_GiveToTarget("GoFatality", 1)
	TNT1 A 0 A_GiveToTarget("GoSpecial", 1)
	TNT1 A 0 A_GiveToTarget("SKShotgunGuy", 1)
	TNT1 A 0 A_Fall
	//TNT1 A 0 A_NoBlocking
	TNT1 A 0 A_Die("Stealthy")
	TNT1 A 1
	
	TNT1 A 1
	Stop
	Death.Stealthy:
	TNT1 A 0
	Stop
	
	Death.Ice:
	Death.Freeze:
	Death.Frost:
	TNT1 A 0 A_ChangeFlag("SHOOTABLE", 0)
	TNT1 A 0 A_ChangeFlag("SOLID", 0)
	TNT1 A 0 A_SpawnItem("FrozenShotgunguy")
	Stop
	
	Death.Massacre:
	Goto Death
	}
}


Actor DeadShotgunGuy1: CurbstompedMarine Replaces DeadShotgunguy
{
    Radius 12
    Height 12
    +SHOOTABLE
    +NOTELEPORT
    +MOVEWITHSECTOR
    +CORPSE
	+FLOORCLIP
	-SOLID
	+THRUACTORS
	damagefactor "Crush", 50.0
    Mass 6000
    Health 300
    damagefactor "Blood", 0.0
    PainChance "Melee", 255
    damagefactor "Trample", 0.0
	damagefactor "ExplosiveImpact", 10.0
States
    {
    Spawn:
        SPOS L -1
        Stop
    Death:
		TNT1 A 0 A_CustomMissile ("XDeathSargeLeg1", 5, 0, random (0, 360), 2, random (0, 160))
		SPOS A 0 A_CustomMissile ("MeatDeathSmall", 5, 0, random (0, 360), 2, random (0, 160))
         TNT1 A 1 A_SpawnItem ("DeadShotgunGuy_NoLeg", 5)
        Stop

    Death.Plasma: Death.Plasma2:
        TNT1 A 0
        TNT1 A 0 A_XScream
        TNT1 A 0 A_NoBlocking
        TNT1 AAA 0 A_CustomMissile ("Brutal_FlyingBlood", 50, 0, random (0, 360), 2, random (0, 160))
	    TNT1 A 0 A_CustomMissile ("XDeathBurnedMeat", 32, 0, random (0, 360), 2, random (0, 160))
	    TNT1 A 0 A_CustomMissile ("XDeathBurnedMeat2", 32, 0, random (0, 360), 2, random (0, 160))
	    TNT1 A 0 A_CustomMissile ("XDeathBurnedMeat3", 32, 0, random (0, 360), 2, random (0, 160))
		EXPL AAA 0 A_CustomMissile ("ExplosionSmoke", 32, 0, random (0, 360), 2, random (0, 360))
        TNT1 A 0
        Stop

    }
}

Actor DeadShotgunGuy_NoArm: DeadShotgunGuy1
{Health 300 States{Spawn:
        SPO5 E -1
        Stop
}}


Actor DeadShotgunGuy_NoLeg: DeadShotgunGuy1 
{Health 300 States{Spawn:
        SPO3 F -1
        Stop
		
	Death:
		TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_CustomMissile ("XDeathSargeLeg1", 5, 0, random (0, 360), 2, random (0, 160))
		SPOS A 0 A_CustomMissile ("MeatDeathSmall", 5, 0, random (0, 360), 2, random (0, 160))
         TNT1 A 1 A_SpawnItem ("DeadShotgunGuy_NoLegBoth", 5)
        Stop	}}
		
Actor DeadShotgunGuy_NoLegBoth: DeadShotgunGuy1 
{Health 300 States{Spawn:
        SPO3 K -1
        Stop
		
	Death:
		TNT1 A 0 A_NoBlocking
		SPOS A 0 A_CustomMissile ("MeatDeathSmall", 5, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("XDeathArm1", 5, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_SpawnItem("RipSergeant")
        Stop	}}		

Actor DeadShotgunGuy_NoBrain: DeadShotgunGuy1
{Health 300 States{Spawn:
        SPOS Z -1
        Stop	Death:
        TNT1 A 0 A_PlaySound("misc/xdeath4")
		TNT1 A 0 A_SpawnItem("ShotgunguyHeadExplode")
        TNT1 A 0 A_SpawnItem ("DeadShotgunguy_NoHead", 1)
		Stop
    }}


Actor DeadShotgunGuy_NoHead: DeadShotgunGuy1
{Health 300 States{Spawn:
        SPDH E -1
        Stop
    
	Death:
		TNT1 A 0 A_NoBlocking
		SPOS A 0 A_CustomMissile ("MeatDeathSmall", 5, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("XDeathArm1", 5, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_SpawnItem("DeadShotgunGuy_NoHeadNoArm")
        Stop
	
	
	}}

Actor DeadShotgunGuy_NoHeadNoArm: DeadShotgunGuy1
{Health 300 States{Spawn:
        SZD4 D -1
        Stop
    Death:
		TNT1 A 0 A_NoBlocking
		SPOS A 0 A_CustomMissile ("MeatDeathSmall", 5, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("XDeathArm1", 5, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_SpawnItem("DeadShotgunguySZD3C")
        Stop
		}}

Actor DeadShotgunGuy_Half: DeadShotgunGuy1
{Health 300 States{Spawn:
        SP2X E -1
        Stop
		
		Death:
		TNT1 A 0 A_NoBlocking
		SPOS A 0 A_CustomMissile ("MeatDeathSmall", 5, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_CustomMissile ("XDeathArm1", 5, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_SpawnItem("DeadShotgunguySZD1H")
        Stop}}



ACTOR BeheadedSergeantZombie: DeadShotgunGuy_NoHead
{
	Mass 6
}




Actor DeadShotgunguy_Slumped: ZombiemanTorso
{
+NOPAIN
+NOBLOCKMONST
Health 200
DamageFactor "Head", 15.0
Height 22
Radius 6
States{Spawn:
		TNT1 A 0
		TNT1 A 0 A_Recoil(6)
		BR93 A 6
		TNT1 A 0 A_JumpIf(momx < 0, "LayDown")
		TNT1 A 0 A_JumpIf(momy < 0, "LayDown")
		TNT1 A 0 A_JumpIf(momx > 0, "LayDown")
		TNT1 A 0 A_JumpIf(momy > 0, "LayDown")
		TNT1 A 0 A_SpawnItemEx("HeadshotTarget20", 0, 0, 22)
		BR93 A 16
        Loop  
	LayDown:
	TNT1 A 0 A_NoBlocking
	TNT1 A 0 A_SpawnItem("DeadShotgunguy1")
	Stop
	XDeath:
	Death.Explosives:
	Death.ExplosiveImpact:
		TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_SpawnItem("SargeXDeath")
		Stop	
	
	Death.Head:
		TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_SpawnItemEx("ShotgunguyHeadExplode", 0, 0, 22)
		TNT1 A 0 A_SpawnItem("DeadShotgunguy_Slumped_NoHead")
		Stop
		
	Death:
	    TNT1 A 0 A_NoBlocking
		TNT1 AAA 0 A_CustomMissile ("Guts", 32, 0, random (150, 210), 2, random (0, 40))
		TNT1 AAA 0 A_CustomMissile ("XDeath1", 32, 0, random (150, 210), 2, random (0, 40))
		TNT1 AAA 0 A_CustomMissile ("Xdeath3", 16, 0, random (170, 190), 2, random (0, 40))
		TNT1 AAAA 0 A_CustomMissile ("Brutal_FlyingBlood", 32, 0, random (170, 190), 2, random (0, 40))
		TNT1 AAAA 0 A_CustomMissile ("Brutal_FlyingBloodFaster", 32, 0, random (170, 190), 2, random (0, 40))
		TNT1 AAAA 0 A_CustomMissile ("Brutal_FlyingBloodMuchFaster", 32, 0, random (170, 190), 2, random (0, 40))
		TNT1 AA 0 A_CustomMissile ("SuperWallRedBlood", 32, 0, random (170, 190), 2, random (0, 40))
		TNT1 AAA 0 A_CustomMissile ("BloodMistBig", 40, 0, random (0, 360), 2, random (30, 90))
		TNT1 AA 0 A_CustomMissile ("XDeathArm1", 40, 0, random (0, 360), 2, random (30, 90))
		TNT1 A 0 A_SpawnItemEx("ShotgunguyHeadExplode", 0, 0, 22)
		//TNT1 A 0 A_SpawnItem("DeadShotgunguyJustLegsAreLeft")
		Stop
		}}
		
		
Actor DeadShotgunguy_Slumped_NoHead: ZombiemanTorso
{
+NOPAIN
+NOBLOCKMONST
Height 22
States{Spawn:
		TNT1 A 0
		BR93 B 100
        Loop  
	XDeath:
	Death.Explosives:
	Death.ExplosiveImpact:
		TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_SpawnItem("SargeXDeath")
		Stop	
	Death:
	    TNT1 A 0 A_NoBlocking
		TNT1 AAA 0 A_CustomMissile ("Guts", 32, 0, random (150, 210), 2, random (0, 40))
		TNT1 AAA 0 A_CustomMissile ("XDeath1", 32, 0, random (150, 210), 2, random (0, 40))
		TNT1 AAA 0 A_CustomMissile ("Xdeath3", 16, 0, random (170, 190), 2, random (0, 40))
		TNT1 AAAA 0 A_CustomMissile ("Brutal_FlyingBlood", 32, 0, random (170, 190), 2, random (0, 40))
		TNT1 AAAA 0 A_CustomMissile ("Brutal_FlyingBloodFaster", 32, 0, random (170, 190), 2, random (0, 40))
		TNT1 AAAA 0 A_CustomMissile ("Brutal_FlyingBloodMuchFaster", 32, 0, random (170, 190), 2, random (0, 40))
		TNT1 AA 0 A_CustomMissile ("SuperWallRedBlood", 32, 0, random (170, 190), 2, random (0, 40))
		TNT1 AAA 0 A_CustomMissile ("BloodMistBig", 40, 0, random (0, 360), 2, random (30, 90))
		TNT1 AA 0 A_CustomMissile ("XDeathArm1", 40, 0, random (0, 360), 2, random (30, 90))
		//TNT1 A 0 A_SpawnItem("DeadShotgunguyJustLegsAreLeft")
		Stop	
		}}
		
		
		
Actor DeadSergeantSXSXO: DeadShotgunGuy1
{
States{Spawn:
		SXSX O -1
        Stop 
		
		Death:
		TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_SpawnItem("MeatDeathSmall")
		TNT1 A 0 A_SpawnItem("RipGuts")
		 TNT1 A 0 A_CustomMissile ("XDeathSargeLeg2", 32, 0, random (0, 360), 2, random (0, 160))
		 TNT1 A 0 A_CustomMissile ("XDeathaRM1", 32, 0, random (0, 360), 2, random (0, 160))
		Stop
}}		


	
Actor DeadSergeantSXS2O: DeadShotgunGuy1
{
States{Spawn:
		SXS2 O -1
        Stop 
		
		Death:
		TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_SpawnItem("MeatDeathSmall")
		TNT1 A 0 A_SpawnItem("RipGuts")
		 TNT1 A 0 A_CustomMissile ("XDeathSargeLeg2", 32, 0, random (0, 360), 2, random (0, 160))
		 TNT1 A 0 A_CustomMissile ("XDeathaRM1", 32, 0, random (0, 360), 2, random (0, 160))
		 TNT1 A 0 A_CustomMissile ("ShotgunguyHeadExplode", 32, 0, random (0, 360), 2, random (0, 160))
		Stop
}}	




Actor DeadShotgunguySPO4J: DeadShotgunGuy1
{
States{Spawn:
		SPO4 J -1
        Stop 
		
		Death:
		TNT1 A 0 A_SpawnItem("MeatDeathSmall")
		TNT1 A 0 A_SpawnItem("RipSergeant")
		TNT1 A 0 A_SpawnItem("DeadShotgunguy_Half")
        Stop
}}	



Actor DeadShotgunguySPO4T: DeadShotgunguySPO4J
{
States{Spawn:
		SPO4 J -1
        Stop 
}}	


Actor DeadShotgunguySPOSZ: DeadShotgunGuy_NoBrain
{
States{Spawn:
		SPOS Z -1
        Stop 
}}	


Actor DeadShotgunguy13DGN: DeadShotgunGuy_NoBrain
{
States{Spawn:
		13DG N -1
        Stop 
}}	



Actor DeadShotgunguySPDHE: DeadShotgunGuy_NoHead
{
States{Spawn:
		SPDH E -1
        Stop 
}}	




Actor DeadShotgunguySP2XE: DeadShotgunGuy_Half
{
States{Spawn:
		SP2X E -1
        Stop 
}}	


Actor DeadShotgunguyZXZ7E: DeadShotgunGuy1
{
States{Spawn:
		ZXZ7 E -1
        Stop 
		
		Death:
		TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_SpawnItem("MeatDeathSmall")
		TNT1 A 0 A_SpawnItem("DeadShotgunguySZD3C")
		TNT1 AA 0 A_CustomMissile ("XDeathArm1", 32, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_SpawnItem("ShotgunguyHeadExplode")
		Stop
}}	


Actor DeadShotgunguyZXZ6E: DeadShotgunGuy1
{
States{Spawn:
		ZXZ6 E -1
        Stop 
		
		Death:
		TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_SpawnItem("MeatDeathSmall")
		TNT1 A 0 A_SpawnItem("DeadShotgunguySZD3F")
		TNT1 A 0 A_CustomMissile ("XDeathArm1", 32, 0, random (0, 360), 2, random (0, 160))
		TNT1 A 0 A_SpawnItem("ShotgunguyHeadExplode")
		Stop
}}



Actor DeadShotgunguySZD3C: DeadShotgunGuy1
{
States{Spawn:
		SZD3 C -1
        Stop
		
		Death:
		TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_SpawnItem("MeatDeathSmall")
		TNT1 A 0 A_SpawnItem("RipGuts")
		 TNT1 AA 0 A_CustomMissile ("XDeathSargeLeg2", 32, 0, random (0, 360), 2, random (0, 160))
		Stop
}}	


Actor DeadShotgunguySZD3F: DeadShotgunguySZD3C
{
States{Spawn:
		SZD3 F -1
        Stop 
}}	




Actor DeadShotgunguySZD1H: DeadShotgunGuy1
{
States{Spawn:
		SZD1 H -1
        Stop 
		
		Death:
		TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_SpawnItem("MeatDeathSmall")
		 TNT1 A 0 A_CustomMissile ("XDeathSargeLeg2", 32, 0, random (0, 360), 2, random (0, 160))
		 TNT1 A 0 A_CustomMissile ("GibSargeBoot", 32, 0, random (0, 360), 2, random (0, 160))
		Stop
}}		



Actor DeadShotgunguySZD4D: DeadShotgunGuy1
{
States{Spawn:
		SZD4 D -1
        Stop 
		
		Death:
		TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_SpawnItem("MeatDeathSmall")
		TNT1 A 0 A_SpawnItem("RipGuts")
		 TNT1 AA 0 A_CustomMissile ("XDeathSargeLeg2", 32, 0, random (0, 360), 2, random (0, 160))
		 TNT1 A 0 A_CustomMissile ("XDeathaRM1", 32, 0, random (0, 360), 2, random (0, 160))
		Stop
}}		




Actor FatalizedSGGuy4: deadshotgunguy_nobrain
{
	Health 200 
	States{Spawn:
        SGF8 N -1
        Stop	
        }
}











ACTOR SMGGuy: ShotgunGuy1
{
DropItem "SMGSpawner"
Tag "SMG Zombie"
Obituary "%o got punctured by a SMG Zombie."
	States
	{
	
	Pain.Avoid: 
	  TNT1 A 0
	  TNT1 A 0 A_Jump(255, "AvoidLeft", "AvoidRight")
	  Goto AvoidLeft
	  
	  AvoidLeft:
	    PSS3 A 1 A_FaceTarget
	    TNT1 A 0 ThrustThing(angle*256/360+192, 15, 0, 0)
        ZRO4 ABCDEFGH 2 A_FaceTarget
        Goto Missile
	AvoidRight:
	    PSS3 A 1 A_FaceTarget
	    TNT1 A 0 ThrustThing(angle*256/360+64, 15, 0, 0)
        ZRO3 ABCDEFGH 2 A_FaceTarget
        Goto Missile
	
	ReplaceVanilla:
		TNT1 A 0 A_ChangeFlag("THRUACTORS", 1)
		TNT1 A 0 A_ChangeFlag("COUNTKILL", 0)
		TNT1 A 0 A_SpawnItemEx ("VanillaShotgunguy",0,0,0,0,0,0,0,SXF_NOCHECKPOSITION | SXF_TRANSFERAMBUSHFLAG ,0)
		Stop
    Spawn:
		SHID A 1
		TNT1 A 0 ACS_NamedExecuteAlways("BDCHeckClassicMonsters", 0, 0, 0, 0)//Check if Vanilla Mode is activated
		  TNT1 A 0
		  TNT1 A 0 A_GiveInventory("SKShotgunGuy", 1)
		  TNT1 A 0 A_GiveInventory("TypeSergeant", 1)
		  TNT1 A 0 A_TakeInventory("SergeantAmmo", 6)
		  TNT1 A 0 A_GiveInventory("SergeantAmmo", random(0,5))
		  PSS3 B 1
		  Goto Stand
	Stand:
		TNT1 A 0
		TNT1 A 0 A_CheckSight("Stand2")
		TNT1 AA 0 A_SpawnItem ("HeadshotTarget20", 4, 44,0)
		SHID AB 11 A_Look
		Loop
		
	Stand2:
		SHID AB 11 A_Look
		TNT1 A 0 A_CheckSight("Stand2")
		Goto Stand
  
	FallBack:
	TNT1 A 0 A_CheckSight("Advance")
	TNT1 A 0 A_ChangeFLag("NODROPOFF", 1)
	TNT1 A 0 A_SpawnItem ("HeadshotTarget4", -5, 40,0)
	TNT1 A 0 A_SpawnItem ("LegTarget4", 10)
	PSS3 D 2 A_FaceTarget
	PSS3 D 2 A_Recoil(2)
	TNT1 A 0 A_jump(64, "Missile")
	TNT1 A 0 A_SpawnItem ("HeadshotTarget4", -5, 40,0)
	TNT1 A 0 A_SpawnItem ("LegTarget4", 10)
	PSS3 C 2 A_FaceTarget
	PSS3 C 2 A_Recoil(2)
	TNT1 A 0 A_SpawnItem ("HeadshotTarget4", -5, 40,0)
	TNT1 A 0 A_SpawnItem ("LegTarget4", 10)
	PSS3 B 2 A_FaceTarget
	PSS3 B 2 A_Recoil(2)
	TNT1 A 0 A_SpawnItem ("HeadshotTarget4", -5, 40,0)
	TNT1 A 0 A_SpawnItem ("LegTarget4", 10)
	PSS3 A 2 A_FaceTarget
	PSS3 A 2 A_Recoil(2)
	TNT1 A 0 A_SpawnItem ("HeadshotTarget4", -5, 40,0)
	TNT1 A 0 A_SpawnItem ("LegTarget4", 10)
	PSS3 D 2 A_FaceTarget
	TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
	GOto Missile
	
	
	
	
	SearchForPlayer:
	Idle:
	    TNT1 A 0 A_ClearTarget
	    TNT1 A 0 A_TakeInventory("EnemyMemory", 30)
		TNT1 A 0 A_GiveInventory("SKShotgunGUy", 1)
        TNT1 A 0 A_SpawnItem ("HeadshotTarget10", 5, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SHID A 10 A_Look
        TNT1 A 0 A_SpawnItem ("HeadshotTarget10", 5, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SHID C 10 A_Look
		TNT1 A 0 A_SpawnItem ("HeadshotTarget10", 5, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SHID A 10 A_Look
        TNT1 A 0 A_SpawnItem ("HeadshotTarget10", 5, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SHID D 10 A_Look
		TNT1 A 0 A_SpawnItem ("HeadshotTarget10", 5, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		SHID A 10 A_Look
		
		PSS3 A 4 A_Look
		TNT1 A 0 A_SpawnItem ("HeadshotTarget4", 5, 40,0)
		TNT1 A 0 A_Wander
		
		PSS3 B 4 A_Look
		TNT1 A 0 A_SpawnItem ("HeadshotTarget4", 5, 40,0)
		TNT1 A 0 A_Wander
		
		PSS3 C 4 A_Look
		TNT1 A 0 A_SpawnItem ("HeadshotTarget4", 5, 40,0)
		TNT1 A 0 A_Wander
		
		PSS3 D 4 A_Look
		TNT1 A 0 A_SpawnItem ("HeadshotTarget4", 5, 40,0)
		TNT1 A 0 A_Wander
		
		
		TNT1 A 0 A_Jump(128, "Idle")
		PSS3 A 4 A_Look
		TNT1 A 0 A_SpawnItem ("HeadshotTarget4", 5, 40,0)
		TNT1 A 0 A_Wander
		
		PSS3 B 4 A_Look
		TNT1 A 0 A_SpawnItem ("HeadshotTarget4", 5, 40,0)
		TNT1 A 0 A_Wander
		
		PSS3 C 4 A_Look
		TNT1 A 0 A_SpawnItem ("HeadshotTarget4", 5, 40,0)
		TNT1 A 0 A_Wander
		
		PSS3 D 4 A_Look
		TNT1 A 0 A_SpawnItem ("HeadshotTarget4", 5, 40,0)
		TNT1 A 0 A_Wander
		
		Loop
		
	
	See:
	TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
	TNT1 A 0 A_TakeInventory("SKZombieman", 1)
	TNT1 A 0 A_TakeInventory("EnemyMemory", 15)
	TNT1 A 0 A_CheckSight("SeeNeverSeen")
	Goto SeeContinue
	
	SeeContinue:
	    TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
	    TNT1 A 0 A_JumpIfCloser(200, "FallBack")
		//Advance:
		TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
		TNT1 A 0 A_JumpIfInventory("EnemyMemory", 15, "SearchForPlayer")
		TNT1 A 0 A_GiveInventory("EnemyMemory", 1)
        //TNT1 A 0 A_SpawnItemEx("FootSep", 0, 0, 20, 0, 0)
		TNT1 A 0 A_TakeInventory("SKShotgunGuy", 1)
		
		
		TNT1 A 0 A_SpawnItem("HeadshotTarget6", 10, 44,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		PSS3 AAA 2 A_Chase
		
		TNT1 A 0 A_SpawnItem("HeadshotTarget6", 10, 44,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		PSS3 BBB 2 A_Chase
		
		TNT1 A 0 A_SpawnItem("HeadshotTarget6", 10, 44,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		PSS3 CCC 2 A_Chase
		
		TNT1 A 0 A_SpawnItem("HeadshotTarget6", 10, 44,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		PSS3 DDD 2 A_Chase
		
		
		TNT1 A 0 A_JumpIfInTargetInventory("IsInvisible", 1, "Idle")
		Loop
		
	SeeNeverSeen:
		TNT1 A 0 A_JumpIfCloser(200, "FallBack")
		Advance:
		TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
        //TNT1 A 0 A_SpawnItemEx("FootSep", 0, 0, 10, 0, 0)
		
		
		TNT1 A 0 A_SpawnItem("HeadshotTarget6", 10, 44,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		PSS3 AAA 2 A_Chase
		TNT1 A 0 A_SpawnItem("HeadshotTarget6", 10, 44,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		PSS3 BBB 2 A_Chase
		TNT1 A 0 A_SpawnItem("HeadshotTarget6", 10, 44,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		PSS3 CCC 2 A_Chase
		TNT1 A 0 A_SpawnItem("HeadshotTarget6", 10, 44,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		PSS3 DDD 2 A_Chase
		Loop		
		
	Missile:
	    TNT1 A 0 A_Stop
		TNT1 A 0 A_JumpIfHealthLower(1, "Death")
		TNT1 A 0 A_TakeInventory("EnemyMemory", 10)
		TNT1 A 0 A_SpawnItem("HeadshotTarget10", 0, 40,0)
		TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
		TNT1 A 0 A_TakeInventory("SKShotgunGuy", 1)
		
		//TNT1 A 0 A_TakeInventory("CantFire", 1)
		//TNT1 A 0 A_CustomMissile("MonsterTargetCheck", 34, 0, 0, 0) 
		//TNT1 A 0 A_CustomMissile("MonsterTargetCheckFaster", 34, 0, 0, 0) 
		PSS3 D 3 A_FaceTarget
		//TNT1 A 0 A_JumpIfInventory("CantFire",1, "Advance")
		
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		TNT1 A 0 A_GiveInventory("SergeantAmmo", 1)
		
		PSS3 D 3 A_FaceTarget
		TNT1 A 0 A_SpawnItem("HeadshotTarget10", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		PSS3 E 10 A_FaceTarget
		TNT1 A 0 A_SpawnItem("HeadshotTarget4", 0, 40,0)
		PSS3 E 4 A_FaceTarget
		TNT1 A 0 A_SpawnItem("HeadshotTarget20", 0, 40,0)
        
		TNT1 A 0 A_CustomMissile("ZombieManTracer", 36, 0, random(-7, 7), 1, random(-4, 4))
		TNT1 A 0 A_SpawnItem ("PistolCaseSpawn", 0, 30,0)
		TNT1 A 0 A_PlaySound("FARSHT", 6)
        TNT1 A 0 A_PlaySound("SMGFIRE", 1)
		PSS3 F 1 BRIGHT
		PSS3 E 2 A_FaceTarget
		
		TNT1 A 0 A_CustomMissile("ZombieManTracer", 36, 0, random(-7, 7), 1, random(-4, 4))
		TNT1 A 0 A_SpawnItem ("PistolCaseSpawn", 0, 30,0)
		TNT1 A 0 A_PlaySound("FARSHT", 6)
        TNT1 A 0 A_PlaySound("SMGFIRE", 1)
		PSS3 F 1 BRIGHT
		PSS3 E 2 A_FaceTarget
		
		TNT1 A 0 A_CustomMissile("ZombieManTracer", 36, 0, random(-7, 7), 1, random(-4, 4))
		TNT1 A 0 A_SpawnItem ("PistolCaseSpawn", 0, 30,0)
		TNT1 A 0 A_PlaySound("FARSHT", 6)
        TNT1 A 0 A_PlaySound("SMGFIRE", 1)
		PSS3 F 1 BRIGHT
		PSS3 E 2 A_FaceTarget
		
		TNT1 A 0 A_CustomMissile("ZombieManTracer", 36, 0, random(-7, 7), 1, random(-4, 4))
		TNT1 A 0 A_SpawnItem ("PistolCaseSpawn", 0, 30,0)
		TNT1 A 0 A_PlaySound("FARSHT", 6)
        TNT1 A 0 A_PlaySound("SMGFIRE", 1)
		PSS3 F 1 BRIGHT
		PSS3 E 2 A_FaceTarget
		
		TNT1 A 0 A_CustomMissile("ZombieManTracer", 36, 0, random(-7, 7), 1, random(-4, 4))
		TNT1 A 0 A_SpawnItem ("PistolCaseSpawn", 0, 30,0)
		TNT1 A 0 A_PlaySound("FARSHT", 6)
        TNT1 A 0 A_PlaySound("SMGFIRE", 1)
		PSS3 F 1 BRIGHT
		PSS3 E 2 A_FaceTarget
		
		TNT1 A 0 A_SpawnItem("HeadshotTarget10", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		PSS3 E 10 A_FaceTarget
		TNT1 A 0 A_JumpIfInTargetInventory("IsInvisible", 1, "SearchForPlayer")
		Goto SeeContinue

  Reload:
        TNT1 A 0
		TNT1 A 0 A_SpawnItem ("HeadshotTarget20", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTarget20", 10)
        SPSR A 15
		TNT1 A 0 A_SpawnItem ("HeadshotTarget20", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("HeadshotTarget20", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTarget20", 10)
        ID12 EFG 5
        TNT1 A 0 A_PlaySound("insertshell")
		TNT1 A 0 A_TakeInventory("SergeantAmmo", 1)
		TNT1 A 0 A_SpawnItem ("HeadshotTarget20", 0, 40,0)
        ID12 EFG 5
        TNT1 A 0 A_PlaySound("insertshell")
		TNT1 A 0 A_TakeInventory("SergeantAmmo", 1)
		TNT1 A 0 A_SpawnItem ("HeadshotTarget20", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTarget20", 10)
        ID12 EFG 5
        TNT1 A 0 A_PlaySound("insertshell")
		TNT1 A 0 A_TakeInventory("SergeantAmmo", 1)
		TNT1 A 0 A_SpawnItem ("HeadshotTarget20", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTarget20", 10)
        ID12 EFG 5
        TNT1 A 0 A_PlaySound("insertshell")
		TNT1 A 0 A_TakeInventory("SergeantAmmo", 1)
		TNT1 A 0 A_SpawnItem ("HeadshotTarget20", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTarget20", 10)
		ID12 EFG 5
        TNT1 A 0 A_PlaySound("insertshell")
		TNT1 A 0 A_TakeInventory("SergeantAmmo", 1)
		TNT1 A 0 A_SpawnItem ("HeadshotTarget20", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTarget20", 10)
		ID12 EFG 5
        TNT1 A 0 A_PlaySound("insertshell")
		TNT1 A 0 A_TakeInventory("SergeantAmmo", 1)
		TNT1 A 0 A_SpawnItem ("HeadshotTarget20", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTarget20", 10)
		SPSR A 10
        TNT1 A 0 A_PlaySound("weapons/sgpump")
		TNT1 A 0 A_SpawnItem("HeadshotTarget10", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTarget20", 10)
		SPSR B 10
		TNT1 A 0 A_SpawnItem("HeadshotTarget10", 0, 40,0)
		SPSR A 10
		TNT1 A 0 A_SpawnItem("HeadshotTarget10", 0, 40,0)
        Goto SeeContinue
		

	Pain.Cut:
	Pain.Saw:
		TNT1 A 0
		TNT1 A 0 A_Stop
	Pain:
        TNT1 A 0 A_JumpIfInventory ("IsDown", 1, 9)
		TNT1 A 0 A_TakeInventory("SKShotgunGuy", 1)
		TNT1 A 0 A_SpawnItem("HeadshotTarget4", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		PSS3 G 2
		TNT1 A 0 A_SpawnItem("HeadshotTarget4", 0, 40,0)
		TNT1 A 0 A_SpawnItem ("LegTargetBase", 10)
		PSS3 G 2 A_Pain
		TNT1 A 0 A_Jump(196, "Missile")
		Goto SeeContinue
        TNT1 AAAAA 0
        TNT1 A 0 A_Pain
        ID11 H 6
        Goto GetUp
		
	Pain.Melee:
	    TNT1 A 0
		TNT1 A 0 A_JumpIfInventory ("SKShotgunGuy", 1, "GotoStealthKill")
        TNT1 A 0 A_JumpIfInventory ("IsDown", 1, 6)
		TNT1 A 0 A_SpawnItem("HeadshotTarget4", 0, 40,0)
		PSS3 G 4
		TNT1 A 0 A_SpawnItem("HeadshotTarget4", 0, 40,0)
		PSS3 G 4 A_Pain
		Goto SeeContinue
        TNT1 AAAAA 0
        TNT1 A 0 A_Pain
        ID11 H 8
		ID11 S 35
        TNT1 A 0 A_TakeInventory("IsDown", 1)
		ID11 T 10
        Goto SeeContinue


	Pain.ExplosiveImpact:
	Pain.ExtremePunches:
	Pain.Explosive:
	TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
	TNT1 A 0 A_ChangeFlag("NOBLOCKMONST", 1)
	         TNT1 A 0
	         TNT1 A 0 A_Pain
		 TNT1 A 0 A_JumpIfInventory ("IsDown", 1, "Pain")
		 		    TNT1 A 0 A_TakeInventory("SKShotgunGuy", 1)
         TNT1 A 0 A_GiveInventory("IsDown", 1)
        TNT1 A 0 ThrustThingZ(0,40,0,1)
         SPO4 UUVWXY 4
		Goto FallingAfterImpact


	


	Pain.LowKick:
		TNT1 A 0
		TNT1 A 0 A_JumpIfInventory("IsDown", 1, "Death.LowKick")
		Goto Pain
		
	Death.LowKick:
		TNT1 A 0 A_NoBlocking
		TNT1 A 0 A_GiveToTarget("GoFatality", 1)
        TNT1 A 0 A_GiveToTarget("IsCurbstompingSergeant", 1)
        Stop
		
		
		 
	Pain.Slide:
         TNT1 A 0
		 TNT1 A 0 A_ChangeFlag("NOBLOCKMONST", 1)
		 TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
		  TNT1 A 0 A_ChangeFlag("GHOST", 1)
		 TNT1 A 0 A_ChangeFlag("THRUGHOST", 1)	
		 TNT1 A 0 A_JumpIfInventory ("IsDown", 1, "Pain")
         ID11 G 1 A_Pain
		 TNT1 A 0 A_GiveInventory("IsDown", 1)
		 TNT1 A 0 A_TakeInventory("SKShotgunGuy", 1)
        TNT1 A 0 ThrustThingZ(0,30,0,1)
		TNT1 A 0 A_ChangeFlag("NOPAIN", 1)
		//ID11 E 1 A_Chase ("","")
		SPO4 U 1 A_facetarget
        SPO4 U 3 
		TNT1 A 0 A_Recoil(-5)
        SPO4 UVWXY 3
		TNT1 A 0 A_ChangeFlag("NOPAIN", 0)
		TNT1 A 0 A_ChangeFlag("GHOST", 0)
		TNT1 A 0 A_ChangeFlag("THRUGHOST", 0)	
		Goto FallingAfterImpact
		
		FallingAfterImpact:
		ID11 H 1 A_GiveInventory ("FallingHeight", 1)
		ID11 H 1 A_CheckFloor ("GetUp")
		NULL A 0 A_JumpIf (momz == 0, "GetUp")
		Loop	 
		
    Pain.Kick:
	Pain.HeavyImpact:
	
         TNT1 A 0
		 TNT1 A 0 A_ChangeFlag("NOBLOCKMONST", 1)
		 TNT1 A 0 A_ChangeFLag("NODROPOFF", 0)
		 TNT1 A 0 A_JumpIfInventory ("IsDown", 1, "Pain")
         ID11 G 1 A_Pain
		 TNT1 A 0 A_GiveInventory("IsDown", 1)
		 TNT1 A 0 A_TakeInventory("SKShotgunGuy", 1)
        TNT1 A 0 ThrustThingZ(0,30,0,1)
		TNT1 A 0 A_ChangeFlag("NOPAIN", 1)
		//ID11 E 1 A_Chase ("","")
		SPO4 U 1 A_facetarget
        SPO4 U 3 ThrustThing(angle*256/360+128, 10, 0, 0)
        SPO4 UVWXY 3
		TNT1 A 0 A_ChangeFlag("NOPAIN", 0)
		Goto FallingAfterImpact
		
	FallingAfterImpact:
		ID11 H 1 A_GiveInventory ("FallingHeight", 1)
		ID11 H 1 A_CheckFloor ("GetUp")
		NULL A 0 A_JumpIf (momz == 0, "GetUp")
		Loop
		
	GetUp:
		TNT1 A 0
		TNT1 A 0 A_GiveInventory("IsDown", 1)
		MARN A 0 A_SpawnItem("bdbodythud")
		TNT1 A 0 A_ChangeFlag("FORCEXYBILLBOARD", 1)
		TNT1 A 0 A_ChangeFlag("NOPAIN", 0)
		TNT1 A 0 A_ChangeFLag("GHOST", 1)
		TNT1 A 0 A_JumpIfInventory ("FallingHeight", 5, "FallingDie")
		ID11 S 1
		ID11 SSSSSSSSS 5 A_JumpIf(momz < 0, "FallingAfterImpact")
		TNT1 A 0 A_TakeInventory("FallingHeight", 100)
        
		ID11 T 10
		TNT1 A 0 A_ChangeFlag("FORCEXYBILLBOARD", 0)
		TNT1 A 0 A_TakeInventory("IsDown", 1)
		TNT1 A 0 A_ChangeFlag("GHOST", 0)
        Goto SeeContinue
		 
	FallingDie:
		TNT1 A 0
		TNT1 A 0 A_Stop
		TNT1 A 0 A_CustomMissile("BodyCrash1", 10)
		Goto Getup+8
		
	Death.Fall:
		TNT1 A 0
		TNT1 A 0 A_Scream
		TNT1 A 0 A_NoBLocking
		TNT1 A 0 A_Stop
		TNT1 AAAA 0 A_CustomMissile ("XDeath1", 32, 0, random (0, 360), 2, random (50, 130))
		ID11 EF 2
		TNT1 A 0 A_SpawnItem ("GrowingBloodPool")
		TNT1 A 0 A_SpawnItem("DeadShotgunguy")
		ID11 F 2
		MARN AAA 0 A_SpawnItem("bdbodythud")
		TNT1 A -1
		Stop
	
	
    Pain.KillMe:
        TNT1 A 0
        Goto Missile
		}
}