Actor PistolSilencerOn : Inventory
{Inventory.MaxAmount 1}

Actor PistolEmpty : Inventory
{Inventory.MaxAmount 1}


ACTOR BrutalPistol : BrutalWeapon
{
	Weapon.AmmoUse1 0
	Weapon.AmmoGive1 0
	Weapon.AmmoUse2 0
	Weapon.AmmoGive2 0
	Weapon.AmmoType1 "Clip1"
	Weapon.AmmoType2 "BDPistolAmmo"
	weapon.selectionorder 3800
	Obituary "%o was shot down by %k's pistol."
    AttackSound "None"
    Inventory.PickupSound "CLIPIN"
	Inventory.Pickupmessage "$GOTPISTOL"
    +WEAPON.NOAUTOAIM
	+WEAPON.NOAUTOFIRE
	+WEAPON.NOALERT
	+WEAPON.NO_AUTO_SWITCH
	+WEAPON.WIMPY_WEAPON
    +FORCEXYBILLBOARD
	Scale 0.9
	Tag "Pistol"
	States
	{
	





//XXX
	CheckGrab:
		TNT1 A 0
		TNT1 A 0 A_TakeInventory("PressedUse", 1)
		TNT1 A 0 A_TakeInventory("MeatAmmo", 100)
		TNT1 A 0 A_JumpIfInTargetInventory("IsPickable",1, "Pick")
		TNT1 A 0 A_JumpIfInTargetInventory("SKZombieman",1, "StealthAttack")
		TNT1 A 0 A_JumpIfInTargetInventory("SKShotgunguy",1, "StealthAttack")
		TNT1 A 0 A_JumpIfInTargetInventory("SKChaingunguy",1, "StealthAttack")
		TNT1 A 0 A_JumpIfInTargetInventory("SKNazi",1, "StealthAttack")
		TNT1 A 0 A_JumpIfInTargetInventory("SKLabguy",1, "StealthAttack")
		TNT1 A 0 A_JumpIfInTargetInventory("SKBLabguy",1, "StealthAttack")
		TNT1 A 0 A_JumpIfInTargetInventory("SKImp",1, "StealthAttack")
	//	pong A 1
		//TNT1 A 0 A_JumpIfInventory("PowerStrength",1, "GrabCheckDist")
	GOTO GrabCheckDist //

		TNT1 A 0 A_JumpIf(CheckClass("ExplosiveBarrel1",AAPTR_PLAYER_GETTARGET,TRUE),"Ready3")
		TNT1 A 0 A_JumpIfCloser(150, "StealthAttack")
		Goto Ready3
		
		
	CheckGrab2:
		TNT1 A 0
		TNT1 A 0 A_TakeInventory("StartDualWield", 1)
		TNT1 A 0 A_TakeInventory("MeatAmmo", 100)
		TNT1 A 0 A_JumpIfInTargetInventory("IsPickable",1, "Pick")
		TNT1 A 0 A_JumpIfInTargetInventory("SKZombieman",1, "StealthAttack")
		TNT1 A 0 A_JumpIfInTargetInventory("SKShotgunguy",1, "StealthAttack")
		TNT1 A 0 A_JumpIfInTargetInventory("SKChaingunguy",1, "StealthAttack")
		TNT1 A 0 A_JumpIfInTargetInventory("SKNazi",1, "StealthAttack")
		TNT1 A 0 A_JumpIfInTargetInventory("SKLabguy",1, "StealthAttack")
TNT1 A 0 A_JumpIfInTargetInventory("SKBLabguy",1, "StealthAttack")
		TNT1 A 0 A_JumpIfInTargetInventory("SKImp",1, "StealthAttack")
		pong A 1
		TNT1 A 0 A_JumpIfInventory("PowerStrength",1, "GrabAttack")
		TNT1 A 0 A_JumpIf(CheckClass("ExplosiveBarrel1",AAPTR_PLAYER_GETTARGET,TRUE),"Ready3")
		TNT1 A 0 A_JumpIfCloser(150, "StealthAttack")
		Goto Ready3
		
	StealthAttack:	
		PUNS A 0 
		TNT1 A 0 A_GiveInventory("GoSpecial")
		TNT1 A 0 A_GiveInventory("Punching")
		PONG A 0 A_FireCustomMissile("StealthAttack", 0, 0, 0)
		PONG AAA 1 A_JUmpIfInventory("ExecuteDownedEnemy", 1, "DoExecution")
		//TNT1 A 0 ACS_ExecuteAlways(310)//Forced select pistol
		PONG AAAAAA 1 A_JUmpIfInventory("ExecuteDownedEnemy", 1, "DoExecution")
		TNT1 A 0 A_TakeInventory("PressedUse", 1)
		Goto Fire
		
	Pick:	
		PUNS A 0
		TNT1 A 0 A_GiveInventory("GoSpecial")
		TNT1 A 0 A_GiveInventory("Punching")
		PKUP E 1
		PONG A 0 A_FireCustomMissile("PickMissile", 0, 0, 0)
		PKUP FG 1
		TNT1 A 0 A_TakeInventory("PressedUse", 1)
		Goto Jab	
		
	GrabCheckDist:
		TNT1 A 0
		//pong A 1
		TNT1 A 0 A_TakeInventory("PressedUse", 1)
		TNT1 A 0 A_JumpIfCloser(150, "GrabAttack")
		Goto Ready3
		
	GrabAttack:
		PKUP ABCD 2
		TNT1 A 0 A_FireCustomMissile("BerserkGrabAttack",0,0,0)
		TNT1 A 0 A_GiveInventory("Reloading", 1)
		PKUP E 1
		TNT1 A 0 A_TakeInventory("Reloading", 1)
		TNT1 A 0 A_JumpIfInventory("HasBarrel",1,"PickBarrel")
		TNT1 A 0 A_JumpIfInventory("GrabbedAZombieman",1,"PickZombieman")
		TNT1 A 0 A_JumpIfInventory("GrabbedAShotgunguy",1,"PickShotgunguy")
		TNT1 A 0 A_JumpIfInventory("GrabbedAChaingunguy",1,"PickChaingunguy")
		TNT1 A 0 A_JumpIfInventory("GrabbedAZombieCivilian",1,"PickZombieCivilian")

TNT1 A 0 A_JumpIfInventory("GrabbedABZombieCivilian",1,"PickBZombieCivilian")
TNT1 A 0 A_JumpIfInventory("GrabbedAFZombieCivilian",1,"PickFZombieCivilian")

		TNT1 A 0 A_JumpIfInventory("GrabbedAEvilMarine",1,"PickEvilMarine")
		TNT1 A 0 A_JumpIfInventory("GrabbedANazi",1,"PickNazi")
		TNT1 A 0 A_JumpIfInventory("GrabbedAImp",1,"PickImp")
TNT1 A 0 A_JumpIfInventory("GrabbedADarkImp",1,"PickDarkImp")
		PKUP E 1
		PKUP FG 2
		TNT1 A 0 A_JumpIfInventory("HasBarrel",1,"PickBarrel")
		TNT1 A 0 A_JumpIfInventory("GrabbedAZombieman",1,"PickZombieman")
		TNT1 A 0 A_JumpIfInventory("GrabbedAShotgunguy",1,"PickShotgunguy")
		TNT1 A 0 A_JumpIfInventory("GrabbedAChaingunguy",1,"PickChaingunguy")
		TNT1 A 0 A_JumpIfInventory("GrabbedAZombieCivilian",1,"PickZombieCivilian")
TNT1 A 0 A_JumpIfInventory("GrabbedABZombieCivilian",1,"PickBZombieCivilian")
TNT1 A 0 A_JumpIfInventory("GrabbedAFZombieCivilian",1,"PickFZombieCivilian")
		TNT1 A 0 A_JumpIfInventory("GrabbedAEvilMarine",1,"PickEvilMarine")
		TNT1 A 0 A_JumpIfInventory("GrabbedANazi",1,"PickNazi")
		TNT1 A 0 A_JumpIfInventory("GrabbedAImp",1,"PickImp")
TNT1 A 0 A_JumpIfInventory("GrabbedADarkImp",1,"PickDarkImp")
		Goto Ready
//xxx


	Ready3:
	Ready:
TNT1 A 0 A_JumpIfInventory("PistolSilencerOn",1,"Ready2")

//XXX
TNT1 A 0 A_JumpIfInventory("PressedUSe",1,"CheckGrab")
		

TNT1 A 0 
		//TNT1 A 0 A_JumpIfInventory("ShotgunguyHead",1,"ShotgunguyHeadFire")
		//TNT1 A 0 A_JumpIfInventory("HasImpFatality",1,"ImpFatalityFire")
		//TNT1 A 0 A_JumpIfInventory("HasHearthFatality",1,"HasHearthFatalityFire")
		//TNT1 A 0 A_JumpIfInventory("HasCacoEye",1,"CacoeyeFire")
		TNT1 A 0 A_jumpifinventory("LostSoulFatality",1,"LSFire")
		TNT1 A 0 A_JumpIfInventory("HasBarrel",1,"FireBarrel")
		TNT1 A 0 A_JumpIfInventory("GrabbedAZombieman",1,"ThrowZombieman")
		TNT1 A 0 A_JumpIfInventory("GrabbedAShotgunguy",1,"ThrowShotgunguy")
		TNT1 A 0 A_JumpIfInventory("GrabbedAChaingunguy",1,"ThrowChaingunguy")
		TNT1 A 0 A_JumpIfInventory("GrabbedAZombieCivilian",1,"ThrowZombieCivilian")
TNT1 A 0    A_JumpIfInventory("GrabbedABZombieCivilian",1,"ThrowBZombieCivilian")
TNT1 A 0 A_JumpIfInventory("GrabbedAFZombieCivilian",1,"ThrowFZombieCivilian")

		TNT1 A 0 A_JumpIfInventory("GrabbedAEvilMarine",1,"ThrowEvilMarine")
		TNT1 A 0 A_JumpIfInventory("GrabbedANazi",1,"ThrowNazi")
		TNT1 A 0 A_JumpIfInventory("GrabbedAImp",1,"ThrowImp")
TNT1 A 0 A_JumpIfInventory("GrabbedADarkImp",1,"ThrowDarkImp")
//XXX




TNT1 A 0
PIST F 0 A_JumpIfInventory("LaserOff",1,2)
TNT1 A 0 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)

//TNT1 A 0 A_JumpIfInventory("BDPistolAmmo",1,"go")
//TNT1 A 0 A_JumpIfInventory("Clip1",1,"go")
//Goto Empty
//Go:
        PIST F 0 A_JumpIfInventory("Kicking",1,"DoKick")
        PIST F 0 A_JumpIfInventory("Taunting",1,"Taunt")
		PIST F 0 A_JumpIfInventory("Salute1", 1, "Salute")
		PIST F 0 A_JumpIfInventory("Salute2", 1, "Salute")
        PIST F 0 A_JumpIfInventory("Reloading",1,"Reload")
		PIST F 0 A_JumpIfInventory("TossGrenade",1,"TossGrenade")
TNT1 A 0 A_JumpIfInventory("WeapSpecial",1,"Continue")
		PIST F 0 A_JumpIfInventory("Unloading",1,"Unload")
Goto ContinueTwo
Continue:
PIST F 0 A_JumpIfInventory("Unloading",1,"Reload")
ContinueTwo:
		PIST F 1 A_WeaponReady(WRF_ALLOWRELOAD)
		PIST F 0 A_Takeinventory("PistolFireAnimation1",1)
		PIST F 0 A_JumpIfInventory("IsRunning",1,"CheckSprint")
		PIST F 0 A_JumpIfInventory("StartDualWield",1,"DualWield")		
//PIST F 0 A_JumpIfInventory("BDPistolAmmo",1,"Ready")
      	goto Ready

Empty:
TNT1 A 0 A_Giveinventory("PistolEmpty",1)
PIST F 0 A_JumpIfInventory("PistolSilencerOn",1,"Ready2Empty")

Emptied:
PIST F 0 A_JumpIfInventory("LaserOff",1,2)
TNT1 A 0 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)

        P1ST F 0 A_JumpIfInventory("Kicking",1,"DoKick")
        P1ST F 0 A_JumpIfInventory("Taunting",1,"Taunt")
		P1ST F 0 A_JumpIfInventory("Salute1", 1, "Salute")
		P1ST F 0 A_JumpIfInventory("Salute2", 1, "Salute")
        P1ST F 0 A_JumpIfInventory("Reloading",1,"Reloadempty")
		P1ST F 0 A_JumpIfInventory("TossGrenade",1,"TossGrenade")
TNT1 A 0 A_JumpIfInventory("WeapSpecial",1,"Continue1")
		PIST F 0 A_JumpIfInventory("Unloading",1,"Unloadempty")
Goto Continue2
Continue1:
PIST F 0 A_JumpIfInventory("Unloading",1,"Reload")
Continue2:
		P1ST F 1 A_WeaponReady(WRF_ALLOWRELOAD)
		P1ST F 0 A_Takeinventory("PistolFireAnimation1",1)
		P1ST F 0 A_JumpIfInventory("IsRunning",1,"CheckSprint")
		P1ST F 0 A_JumpIfInventory("StartDualWield",1,"DualWield")
//PIST F 0 A_JumpIfInventory("BDPistolAmmo",1,"Ready")
goto Empty

Unloadempty:
PIST F 0 A_Takeinventory("Unloading",1)
goto Emptied

Reloadempty:
PIST F 0 A_Takeinventory("Reloading",1)
PIST F 0 A_JumpIfInventory("Clip1",1,"Reload")
goto Emptied

		
	CheckSprint:
		PIST F 1 A_WeaponReady(WRF_NOFIRE)
		PIST F 0 A_JumpIfInventory("IsStandingStill", 1, "Ready3")
		PIST F 0 A_JumpIfInventory("IsTacticalClass", 1, "StartSprint")
		Goto Ready
		
	StartSprint:
		PIST F 1 A_WeaponReady(WRF_NOFIRE)
		PIST F 0 A_JumpIfInventory("UsedStamina", 40, "StopSprintTired")
		
	Sprinting:	
		PISP A 0 offset(-9,32) 
		PIST F 0 offset(-9,32) A_JumpIfInventory("IsStandingStill", 1, "Ready3")
		PIST F 0 offset(-9,32) A_JumpIfInventory("UsedStamina", 100, "StopSprintTired")
		PLAY A 0 offset(-9,32) ACS_ExecuteAlways(852, 0, 0, 0, 0)//Makes player faster.
		PIST F 0 offset(-9,32) A_JumpIfInventory("PowerStrength", 1, 2)
		PIST F 0 offset(-9,32) A_GiveInventory("UsedStamina", 2)
		PIST F 0 offset(-9,32)
		PISP F 1 offset(-9,34) A_SetPitch(pitch -0.5)
		PISP F 1 offset(-6,36) A_SetPitch(pitch -0.5)
		PISP F 1 offset(-3,38) A_SetPitch(pitch -0.5)
		PISP F 1 offset(0,38) A_SetPitch(pitch -0.5)
		PISP F 1 offset(3,36) A_SetPitch(pitch -0.5)
		PISP F 1 offset(6,34) A_SetPitch(pitch -0.5)
		PISP F 1 offset(9,32) A_SetPitch(pitch -0.5)
		PIST F 0 offset(9,32) A_WeaponReady(WRF_NOBOB)
		PIST F 0 A_JumpIfInventory("Kicking",1,"DoKick")
        PIST F 0 A_JumpIfInventory("Taunting",1,"Taunt")
        PIST F 0 A_JumpIfInventory("Reloading",1,"Reload")
		PIST F 0 offset(-9,32) A_GiveInventory("UsedStamina", 3)
		PIST F 0 offset(9,33) A_SpawnItemEx("FootStep", 0, 0, 2, 0, 0, -4)
		PISP F 1 offset(9,34) A_SetPitch(pitch +0.5)
		PISP F 1 offset(6,36) A_SetPitch(pitch +0.5)
		PISP F 1 offset(3,38) A_SetPitch(pitch +0.5)
		PISP F 1 offset(0,38) A_SetPitch(pitch +0.5)
		PISP F 1 offset(-3,36) A_SetPitch(pitch +0.5)
		PISP F 1 offset(-6,34) A_SetPitch(pitch +0.5)
		PISP F 1 offset(-9,32) A_SetPitch(pitch +0.5)
		PIST F 0 offset(-9,32) A_WeaponReady(WRF_NOBOB)
		PIST F 0 offset(-9,32) A_JumpIfInventory("IsRunning", 1, "Sprinting")
		
		Goto StopSprint
	StopSprintTired:
		PIST F 1
		PLAY A 0 ACS_ExecuteAlways(853, 0, 0, 0, 0)//Makes player slower.
		PIST F 0 A_PlaySound("Tired", 2)
		PIST F 0 A_TakeInventory("UsedStamina", 2)
		PIST F 5 A_WeaponReady
		PIST F 0 A_TakeInventory("UsedStamina", 2)
		PIST F 5 A_WeaponReady
		PIST F 0 A_TakeInventory("UsedStamina", 2)
		PIST F 5 A_WeaponReady
		PIST F 0 A_TakeInventory("UsedStamina", 2)
		PIST F 5 A_WeaponReady
		PIST F 0 A_TakeInventory("UsedStamina", 2)
		PIST F 5 A_WeaponReady
		Goto Ready
	StopSprint:
		PISP A 1
		PIST F 0 A_JumpIfInventory("UsedStamina", 60, "StopSprintTired")
		PLAY A 0 ACS_ExecuteAlways(853, 0, 0, 0, 0)//Makes player slower.
		Goto Ready	
		
	Deselect:
PIST F 0 A_JumpIfInventory("PistolSilencerOn",1,"Deselecting")
//PISS BA 1
Deselecting:
//PIST F 0 A_Takeinventory("PistolSilencerOn",1)

//PISS BA 1        
TNT1 A 0 A_JumpIfInventory("HasBarrel",1,"FireBarrel")
		TNT1 A 0 A_JumpIfInventory("GrabbedAZombieman",1,"ThrowZombieman")
		TNT1 A 0 A_JumpIfInventory("GrabbedAShotgunguy",1,"ThrowShotgunguy")
		TNT1 A 0 A_JumpIfInventory("GrabbedAChaingunguy",1,"ThrowChaingunguy")
		TNT1 A 0 A_JumpIfInventory("GrabbedAZombieCivilian",1,"ThrowZombieCivilian")
		TNT1 A 0 A_JumpIfInventory("GrabbedABZombieCivilian",1,"ThrowZombieCivilian")
TNT1 A 0 A_JumpIfInventory("GrabbedAFZombieCivilian",1,"ThrowFZombieCivilian")
		TNT1 A 0 A_JumpIfInventory("GrabbedAEvilMarine",1,"ThrowEvilMarine")
		TNT1 A 0 A_JumpIfInventory("GrabbedANazi",1,"ThrowNazi")
		TNT1 A 0 A_JumpIfInventory("GrabbedAImp",1,"ThrowImp")
TNT1 A 0 A_JumpIfInventory("GrabbedADarkImp",1,"ThrowDarkImp")

		TNT1 AAAAAAAAAAAAAAAAAA 0 A_Lower
		PIST F 0 A_TakeInventory("TossGrenade", 1)
		TNT1 A 1 A_Lower
TNT1 A 0 A_Takeinventory("WeapSpecial",1)
		Wait
		
	Select:
		PIST F 0 A_Takeinventory("StartDualWield",1)
		PIST F 0 A_Giveinventory("GoSpecial",1)
TNT1 A 0 A_Takeinventory("WeapSpecial",1)		
PIST F 0 A_Takeinventory("FistsSelected",1)
		PIST F 0 A_Takeinventory("SawSelected",1)
		PIST F 0 A_Takeinventory("ShotgunSelected",1)
		PIST F 0 A_Takeinventory("SSGSelected",1)
		PIST F 0 A_Takeinventory("MinigunSelected",1)
		PIST F 0 A_Takeinventory("PlasmaGunSelected",1)
		PIST F 0 A_Takeinventory("RocketLauncherSelected",1)
		PIST F 0 A_Takeinventory("GrenadeLauncherSelected",1)
		PIST F 0 A_Takeinventory("BFGSelected",1)
		PIST F 0 A_Takeinventory("BFG10kSelected",1)
		PIST F 0 A_Takeinventory("RailGunSelected",1)
		PIST F 0 A_Takeinventory("SubMachineGunSelected",1)
		PIST F 0 A_Takeinventory("RevenantLauncherSelected",1)
		PIST F 0 A_Takeinventory("LostSoulSelected",1)
		PIST F 0 A_Takeinventory("FlameCannonSelected",1)
		PIST F 0 A_Takeinventory("HasBarrel",1)
		TNT1 A 1
		TNT1 A 1 A_Raise
		TNT1 AAAAAAAAAA 0 A_Raise
		Goto SelectAnimation
		
		
	SelectAnimation:
		TNT1 A 1
	    PIST F 0 A_JumpIfInventory("GoFatality", 1, "Steady")
        PIST F 0 A_PlaySound("CLIPIN")
        PISS AB 1
		PIST F 0 A_Takeinventory("StartDualWield",1)
        PIST F 0 A_GunFlash
		Goto Ready

	
Fire:
TNT1 A 0 A_JumpIfInventory("PistolSilencerOn",1,"FireSilencer")

//xxx
//TNT1 A 0 A_JumpIfInventory("ShotgunguyHead",1,"ShotgunguyHeadFire")
		//TNT1 A 0 A_JumpIfInventory("HasImpFatality",1,"ImpFatalityFire")
		//TNT1 A 0 A_JumpIfInventory("HasHearthFatality",1,"HasHearthFatalityFire")
		//TNT1 A 0 A_JumpIfInventory("HasCacoEye",1,"CacoeyeFire")
		TNT1 A 0 A_jumpifinventory("LostSoulFatality",1,"LSFire")
		TNT1 A 0 A_JumpIfInventory("HasBarrel",1,"FireBarrel")
		TNT1 A 0 A_JumpIfInventory("GrabbedAZombieman",1,"ThrowZombieman")
		TNT1 A 0 A_JumpIfInventory("GrabbedAShotgunguy",1,"ThrowShotgunguy")
		TNT1 A 0 A_JumpIfInventory("GrabbedAChaingunguy",1,"ThrowChaingunguy")
		TNT1 A 0 A_JumpIfInventory("GrabbedAZombieCivilian",1,"ThrowZombieCivilian")
TNT1 A 0 A_JumpIfInventory("GrabbedABZombieCivilian",1,"ThrowBZombieCivilian")
TNT1 A 0 A_JumpIfInventory("GrabbedAFZombieCivilian",1,"ThrowFZombieCivilian")
		TNT1 A 0 A_JumpIfInventory("GrabbedAEvilMarine",1,"ThrowEvilMarine")
		TNT1 A 0 A_JumpIfInventory("GrabbedANazi",1,"ThrowNazi")
		TNT1 A 0 A_JumpIfInventory("GrabbedAImp",1,"ThrowImp")
		TNT1 A 0 A_JumpIfInventory("GrabbedADarkImp",1,"ThrowDarkImp")
//xxx


TNT1 A 0 A_JumpIfInventory("BDPistolAmmo",1,"Contfire")
TNT1 A 0 A_JumpIfInventory("WeapSpecial",1,"Reload")
//TNT1 A 0 A_JumpIfInventory("PistolEmpty",1,"Empty")
goto ClickP
TNT1 A 0
Goto NoAmmo
Contfire:
        TNT1 AAAA 0
		PIST F 0 A_AlertMonsters
		
		TNT1 A 0 A_JumpIFInventory("PistolBurstFire", 1, "Fire2")
		PIST F 0 A_PlaySound("FARSHT", 6)
        PIST F 0 A_PlaySound("PFIRE", 1)
		PIST F 0 A_ZoomFactor(0.98)
		PIST A 1 BRIGHT A_FireBullets (1, 1, -1, 20, "WeakPuff", FBF_NORANDOM) //18

		PIST F 0 A_ZoomFactor(1.0)

        RIFF A 0 A_FireCustomMissile("DecorativeTracer", random(-1,1), 0, 0, 0)

		PIST F 0 A_Takeinventory("BDPistolAmmo",1)
		PIST F 0 A_Takeinventory("BDDualPistolAmmo",1)
//PIST F 0 A_JumpIfInventory("LaserOff",1,2)        
//PIST B 1 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
		PIST F 0 A_FireCustomMissile("PistolCaseSpawn",5,0,0,-9)
//PIST F 0 A_JumpIfInventory("LaserOff",1,2)
		PIST C 1 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
		PIST F 0 A_JumpIfInventory("IsTacticalClass", 1, "FireEndTactical")
//PIST F 0 A_JumpIfInventory("LaserOff",1,2)
		PIST D 1 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)


//		PIST F 0 A_JumpIfInventory("Reloading",1,"Reload")
//		PIST F 0 A_JumpIfInventory("TossGrenade",1,"TossGrenade")
//		PIST F 3 A_WeaponReady(WRF_NOBOB | WRF_ALLOWRELOAD)

//		PIST F 0 A_REfire
//TNT1 A 0 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)

		Goto Ready

		
ClickP: 
TNT1 A 0 A_JumpIfinventory("PistolEmpty",1,"ReadyEmptyReload")
TNT1 A 0 A_PlaySound("weapons/pistolup")
	PIST F 4 //P1ST F 5
	P1ST F 1
RIFG A 0 A_JumpIfInventory("Clip1",1,"Reload")
goto Empty


ReadyEmptyReload:
P1ST F 1
RIFG A 0 A_JumpIfInventory("Clip1",1,"Reload")
goto Empty



	Fire2:
        TNT1 A 0

//xxx
//TNT1 A 0 A_JumpIfInventory("ShotgunguyHead",1,"ShotgunguyHeadFire")
//TNT1 A 0 A_JumpIfInventory("HasImpFatality",1,"ImpFatalityFire")
		//TNT1 A 0 A_JumpIfInventory("HasHearthFatality",1,"HasHearthFatalityFire")
//TNT1 A 0 A_JumpIfInventory("HasCacoEye",1,"CacoeyeFire")
		TNT1 A 0 A_jumpifinventory("LostSoulFatality",1,"LSFire")
		TNT1 A 0 A_JumpIfInventory("HasBarrel",1,"FireBarrel")
		TNT1 A 0 A_JumpIfInventory("GrabbedAZombieman",1,"ThrowZombieman")
		TNT1 A 0 A_JumpIfInventory("GrabbedAShotgunguy",1,"ThrowShotgunguy")
		TNT1 A 0 A_JumpIfInventory("GrabbedAChaingunguy",1,"ThrowChaingunguy")
		TNT1 A 0 A_JumpIfInventory("GrabbedAZombieCivilian",1,"ThrowZombieCivilian")
TNT1 A 0 A_JumpIfInventory("GrabbedABZombieCivilian",1,"ThrowBZombieCivilian")
TNT1 A 0 A_JumpIfInventory("GrabbedAFZombieCivilian",1,"ThrowFZombieCivilian")
		TNT1 A 0 A_JumpIfInventory("GrabbedAEvilMarine",1,"ThrowEvilMarine")
		TNT1 A 0 A_JumpIfInventory("GrabbedANazi",1,"ThrowNazi")
		TNT1 A 0 A_JumpIfInventory("GrabbedAImp",1,"ThrowImp")
TNT1 A 0 A_JumpIfInventory("GrabbedADarkImp",1,"ThrowDarkImp")
//xxx


TNT1 A 0 A_JumpIfInventory("BDPistolAmmo",1,"contP2") 
goto ClickP
ContP2:


		PIST F 0 A_PlaySound("FARSHT", 6)
        PIST F 0 A_PlaySound("PFIRE", 1)
		PIST F 0 A_ZoomFactor(0.98)
		PIST A 1 BRIGHT A_FireBullets (1, 1, -1, 20, "WeakPuff", FBF_NORANDOM)
		PIST F 0 A_ZoomFactor(1.0)
        RIFF A 0 A_FireCustomMissile("DecorativeTracer", random(-1,1), 0, 0, 0)
		PIST F 0 A_Takeinventory("BDPistolAmmo",1)
		PIST F 0 A_Takeinventory("BDDualPistolAmmo",1)
		PIST F 0 A_JumpIfInventory("BDPistolAmmo",1,2)
		Goto NoAmmo
        PIST B 0
		PIST F 0 A_FireCustomMissile("PistolCaseSpawn",5,0,0,-9)
		PIST F 0 A_PlaySound("FARSHT", 6)
        PIST F 0 A_PlaySound("PFIRE", 1)
		PIST F 0 A_ZoomFactor(0.98)
		PIST A 0 BRIGHT A_FireBullets (1, 1, -1, 20, "WeakPuff", FBF_NORANDOM)
		TNT1 A 0 A_SetPitch(pitch-1)
		PIST F 0 A_ZoomFactor(1.0)
        RIFF A 0 A_FireCustomMissile("DecorativeTracer", random(-1,1), 0, 0, 0)
		PIST F 0 A_Takeinventory("BDPistolAmmo",1)
		PIST F 0 A_Takeinventory("BDDualPistolAmmo",1)
		PIST F 0 A_JumpIfInventory("BDPistolAmmo",1,2)
		Goto NoAmmo
PIST F 0 A_JumpIfInventory("LaserOff",1,2)
        PIST B 0 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
//PIST F 0 A_JumpIfInventory("LaserOff",1,2)        
PIST B 1 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)

		TNT1 A 0 A_SetPitch(pitch-1)
		PIST F 0 A_FireCustomMissile("PistolCaseSpawn",5,0,0,-9)
		PIST F 0 A_PlaySound("FARSHT", 6)
        PIST F 0 A_PlaySound("PFIRE", 1)
		PIST F 0 A_ZoomFactor(0.98)
		PIST A 1 BRIGHT A_FireBullets (2, 2, -1, 20, "WeakPuff", FBF_NORANDOM)
		PIST F 0 A_ZoomFactor(1.0)
        RIFF A 0 A_FireCustomMissile("DecorativeTracer", random(-1,1), 0, 0, 0)
		PIST F 0 A_Takeinventory("BDPistolAmmo",1)
		PIST F 0 A_Takeinventory("BDDualPistolAmmo",1)
		TNT1 A 0 A_SetPitch(pitch-1)
		PIST F 0 A_JumpIfInventory("BDPistolAmmo",1,2)
		Goto NoAmmo
PIST F 0 A_JumpIfInventory("LaserOff",1,2)
        PIST B 0 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
//PIST F 0 A_JumpIfInventory("LaserOff",1,2)        
PIST B 1 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)

		PIST F 0 A_FireCustomMissile("PistolCaseSpawn",5,0,0,-9)
//PIST F 0 A_JumpIfInventory("LaserOff",1,2)
		PIST C 1 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
//PIST F 0 A_JumpIfInventory("LaserOff",1,2)		
PIST DE 1 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)

		PIST F 0 A_JumpIfInventory("Reloading",1,"Reload")
		PIST F 2 A_JumpIfInventory("TossGrenade",1,"TossGrenade")
		PIST F 0 A_JumpIfInventory("Reloading",1,"Reload")
		PIST F 0 A_JumpIfInventory("TossGrenade",1,"TossGrenade")
		PIST F 2 A_WeaponReady(WRF_NOBOB | WRF_ALLOWRELOAD)
		Goto Ready	
		
	FireEndTactical:
		PIST F 0
		PIST F 0 A_JumpIfInventory("IsRunning", 1, "FireEndTactical2")
		PIST E 1 A_WeaponReady(1)
		PLAY A 0 ACS_ExecuteAlways(853, 0, 0, 0, 0)//Makes player slower.
		PIST F 7 A_WeaponReady(1)
		Goto Ready
		
	FireEndTactical2:
		PIST F 0
		PLAY A 0 ACS_ExecuteAlways(852, 0, 0, 0, 0)//Makes player faster.
		PIST F 0 A_GiveInventory("UsedStamina", 4)
		PIST E 1 A_WeaponReady(1)
		PIST F 5 A_WeaponReady(1)
		Goto Sprinting
		
	NoAmmo:
		RIFG A 0
		RIFG A 0 A_ZoomFactor(1.0)
		RIFG A 0 A_Takeinventory("Zoomed",1)
		RIFG A 0 A_Takeinventory("ADSmode",1)
		RIFG A 0 A_JumpIfInventory("TurboReload",1,"TurboReload")
TNT1 A 0 A_JumpIfinventory("PistolEmpty",1,"Ready")
		TNT1 A 0 A_PlaySound("weapons/empty", 4)
		NoAmmo2:
		RIFG A 0 A_JumpIfInventory("TossGrenade",1,"TossGrenade")
	    RIFG A 0 A_JumpIfInventory("Taunting",1,"Taunt")
		RIFG A 0 A_JumpIfInventory("Salute1", 1, "Salute")
		RIFG A 0 A_JumpIfInventory("Salute2", 1, "Salute")
		RIFG A 0 A_JumpIfInventory("IsRunning",1,"CheckSprint")
		RIFG A 0 A_JumpIfInventory("ExecuteDownedEnemy", 1, "DoExecution")
		RIFG A 0 A_JumpIfInventory("Kicking",1,"DoKick")
		PIST F 5 A_WeaponReady(WRF_ALLOWRELOAD | WRF_NOFIRE)
		RIFG A 0 A_JumpIfInventory("Reloading",1,"Reload")
		RIFG A 0 A_JumpIfInventory("TurboReload",1,"TurboReload")
		TNT1 A 0 A_JumpIfInventory("NoAutoReload", 1, "Ready3")
		RIFG A 0 A_JumpIfInventory("Clip1",1,"Reload")
		RIFG A 0 A_JumpIfInventory("FiredPrimary",1,"NoAmmo2")
		Goto Ready3
	
    Reload:
TNT1 A 0 A_Takeinventory("PistolEmpty",1)
TNT1 A 0 A_Takeinventory("Unloading",1)
TNT1 A 0 A_Takeinventory("WeapSpecial",1)
		PIST F 0 A_WeaponReady
			PIST F 0 A_Takeinventory("Reloading",1)
		PIST F 0 A_Takeinventory("ADSmode",1)

PIST F 0 A_JumpIfInventory("BDPistolAmmo",15,"SilencerOn")
		PIST F 0 A_JumpIfInventory("BDPistolAmmo",16,"SilencerOn")

PIST F 0 A_JumpIfInventory("PistolSilencerOn",1,"ReloadSilencer")
		
    
    PIST F 0 A_JumpIfInventory("Clip1",1,3)
        Goto NoAmmo //FinishReloading
        TNT1 AAA 0
		PIST F 0 A_Takeinventory("Zoomed",1)
        PIST F 0 A_ZoomFactor(1.0)
		PIST F 0 A_GiveInventory ("Pumping", 1)
		PIST F 0 A_Takeinventory("Reloading",1)
		PIST F 0 A_JumpIfInventory("TurboReload",1,"TurboReload")
PIST F 0 A_JumpIfInventory("HasUnloaded", 1, 3)
RIFR C 0 A_FireCustomMissile("EmptyPistolClipSpawn",-5,0,8,-4) 
		TNT1 A 0 A_PlaySound("reload")
		TNT1 AA 0
//PISR AB 1
		


PIST F 0 A_Takeinventory("HasUnloaded",1)
PIST F 0 A_JumpIfInventory("BDPistolAmmo",1,"InsertBullets2") //15+1 effect
Goto InsertBullets		

	TurboReload:
		PIST F 0 A_Takeinventory("HasUnloaded",1)
RIFG A 0 A_JumpIfInventory("Clip1",1,3)
		Goto Ready
//        PISS BA 0
        Goto InsertBullets
		
	InsertBullets:

TNT1 A 0 A_JumpIfInventory("NoMagReload",1,"NoMagReloading")
TNT1 A 0 A_Takeinventory("BDPistolAmmo")
NoMagReloading:
InsertBulletsB:
		TNT1 AAAA 0
		PIST F 0 A_JumpIfInventory("BDPistolAmmo",15,15)
		PIST F 0 A_JumpIfInventory("Clip1",1,3)
		Goto FinishReload
        TNT1 AAAAAA 0
		PIST F 0 A_Giveinventory("BDPistolAmmo",1)
		PIST F 0 A_Giveinventory("BDDualPistolAmmo",1)
		PIST F 0 A_Takeinventory("Clip1",1)
		Goto InsertBulletsB
		
		TNT1 AAAAAAAAAA 0
		PIST F 0 A_Takeinventory("Reloading",1)
		
	//	PIST F 0 A_Refire
        Goto FinishReload
		TNT1 AAAA 0
		PIST F 0 A_Takeinventory("Reloading",1)
		
//		PIST F 0 A_Refire
        Goto FinishReload

		
FinishReload:
PISR CDEFFFFF 1 
		PIST F 0 A_PlaySound("prel")
        PISR GHIIJKLL 1
TNT1 A 0 A_PlaySound("weapons/empty", 0)
PISR MNNNOPQR 1
//PIST F 0 A_Refire
Goto Ready
		
	InsertBullets2:
TNT1 A 0 A_JumpIfInventory("NoMagReload",1,"NoMagReloading2")
TNT1 A 0 A_Takeinventory("BDPistolAmmo")
TNT1 A 0 A_Giveinventory("BDPistolAmmo",1)
NoMagReloading2:
InsertBullets2B:
		TNT1 AAAA 0
		PIST F 0 A_JumpIfInventory("BDPistolAmmo",16,15)
		PIST F 0 A_JumpIfInventory("Clip1",1,3)
		Goto FinishReload2
        TNT1 AAAAAA 0
		PIST F 0 A_Giveinventory("BDPistolAmmo",1)
		PIST F 0 A_Giveinventory("BDDualPistolAmmo",1)
		PIST F 0 A_Takeinventory("Clip1",1)
		Goto InsertBullets2B
		
		TNT1 AAAAAAAAAA 0
		PIST F 0 A_Takeinventory("Reloading",1)
	//	PIST F 0 A_Refire
        Goto FinishReload2
		TNT1 AAAA 0
		PIST F 0 A_Takeinventory("Reloading",1)
		
	//	PIST F 0 A_Refire
        Goto FinishReload2

Finishreload2:
P1SR CDEFFFFF 1 
		PIST F 0 A_PlaySound("prel")
P1SR GHIIJKLMNNNOPQ 1
	  PISR R 1

// PIST F 0 A_Refire
Goto Ready

	
 	Spawn:
		PIST A 0
		PIST G -1
		Stop
		
		
	AltFire:
		TNT1 A 0



TNT1 A 0 A_JumpIfInventory("GrabbedAZombieman",1,"ShieldZombieman")
		TNT1 A 0 A_JumpIfInventory("GrabbedAShotgunguy",1,"ShieldShotgunguy")
		TNT1 A 0 A_JumpIfInventory("GrabbedAChaingunguy",1,"ShieldChaingunguy")
		TNT1 A 0 A_JumpIfInventory("GrabbedAZombieCivilian",1,"ShieldZombieCivilian")
TNT1 A 0 A_JumpIfInventory("GrabbedABZombieCivilian",1,"ShieldBZombieCivilian")
TNT1 A 0 A_JumpIfInventory("GrabbedAFZombieCivilian",1,"ShieldFZombieCivilian")
		TNT1 A 0 A_JumpIfInventory("GrabbedAEvilMarine",1,"ShieldEvilMarine")
		TNT1 A 0 A_JumpIfInventory("GrabbedANazi",1,"ShieldNazi")
		TNT1 A 0 A_JumpIfInventory("GrabbedAImp",1,"ShieldImp")
TNT1 A 0 A_JumpIfInventory("GrabbedADarkImp",1,"ShieldDarkImp")
		TNT1 A 0 A_jumpifinventory("LostSoulFatality",1,"LSFire")
		TNT1 A 0 A_JumpIfInventory("HasBarrel",1,"AltFireBarrel")
		TNT1 A 0 A_JumpIfInventory("GoFatality", 1, "Steady")




		TNT1 A 0 A_JumpIFInventory("PistolBurstFire", 1, "StopAlt")
		TNT1 A 0 A_GiveInventory("PistolBurstFire", 1)
		TNT1 A 0 A_Print("Burst fire")

PIST F 0 A_JumpIfInventory("PistolEmpty",1,"Empty")
		Goto Ready3
		
	StopAlt:
		TNT1 A 0
		TNT1 A 0 A_TakeInventory("PistolBurstFire", 1)
		TNT1 A 0 A_Print("Single shot")
PIST F 0 A_JumpIfInventory("PistolEmpty",1,"Empty")
		Goto Ready3
		
	AltFire2:	
		PIST F 0
		PIST F 0 A_JumpIfInventory("PistolFireAnimation1", 1, 5)
		PISA ABC 1
        TNT1 A 4
		PIST F 0
		PIST F 0 A_PlaySound("skeleton/swing")
		PIST F 0 A_Giveinventory("Punching",1)
		PIST F 0 A_Giveinventory("PistolFireAnimation1",1)
		PISA DE 1 
		PONG A 0 A_FireCustomMissile("MeleeStrikeNormal", 0, 0, 0, 2)
		PISA FFFG 1
		PISA H 1 A_Weaponready(1)
		PIST F 0 A_JumpIfInventory("Kicking",1,"KickLeft")
		PISA IJ 1 A_Weaponready(1)
		PIST F 0 A_JumpIfInventory("Kicking",1,"KickLeft")
		PISA CBA 1 A_Weaponready(1)
		PIST F 0 A_Takeinventory("PistolFireAnimation1",1)
		Goto Ready	
		
	KickLeft:
		KIK1 ABC 1
        PIST F 0 A_PlaySound("KICK")
		PIST F 0 A_Giveinventory("Punching",1)
		PIST F 0 A_SetPitch(-6 + pitch)
		KIK1 D 1
		PUN2 A 0 A_Custompunch(35,0,1,"MeleePuff", 100)
		KIK1 DD 1
		KIK1 ECBA 1
		TNT1 A 5 A_TakeInventory("Kicking",1)
		Goto Ready	
		
	Steady:
		TNT1 A 1
		Goto Ready	
		
		
	Unload:
PIST F 0 A_JumpIfInventory("PistolSilencerOn",1,"UnloadSilencer")
TNT1 A 0 A_JumpifInventory("BDPistolAmmo",1,"ContinueUnload")
Goto Emptied
ContinueUnload:

		PIST F 1 A_WeaponReady
		PIST F 0 A_Takeinventory("Unloading",1)
		PIST F 0 A_Takeinventory("ADSmode",1)
		PIST F 0 A_JumpIfInventory("BDPistolAmmo",1,3)
        Goto NoAmmo
        TNT1 AAA 0
		PIST F 0 A_Takeinventory("Zoomed",1)
        PIST F 0 A_ZoomFactor(1.0)
		PIST F 0 A_GiveInventory ("Pumping", 1)
		PIST F 0 A_Takeinventory("Reloading",1)
TNT1 A 0 A_PlaySound("reload")        
PISR RQPONNNMLL 1
TNT1 A 0 A_FireCustomMissile("9mmCaseSpawnCold",5,0,18,-4) //5,0,6,-14)
PISR KJIIHG 1
		PIST F 0 A_PlaySound("prel")
		PISR FFFEDCBA 1
		PIST F 0 A_Giveinventory("HasUnloaded",1)
		PIST F 0 A_JumpIfInventory("BDPistolAmmo",1,"RemoveBullets")


	RemoveBullets:
		TNT1 AAAA 0
		PIST F 0 A_JumpIfInventory("BDPistolAmmo",1,3)
		Goto FinishUnload
        TNT1 AAAAAA 0
		PIST F 0 A_Takeinventory("BDPistolAmmo",1)
		PIST F 0 A_Takeinventory("BDDualPistolAmmo",1)
		PIST F 0 A_Giveinventory("Clip1",1)
		Goto RemoveBullets
		
		TNT1 AAAAAAAAAA 0
		PIST F 0 A_Takeinventory("Reloading",1)
		
		PIST F 0 A_Refire
        Goto FinishUnload
		TNT1 AAAA 0
		PIST F 0 A_Takeinventory("Reloading",1)
		
		PIST F 0 A_Refire
        Goto FinishUnload
		
FinishUnload:
TNT1 A 0 A_Giveinventory("WeapSpecial",1)
TNT1 A 0 A_Takeinventory("Clip1",1)
Goto Empty
		

DualWieldSil:
TNT1 A 0
PIST F 0 A_Takeinventory("StartDualWield",1)
PIST F 0 A_JumpIfInventory("DualPistols", 1, "GetDualSil")
PIST F 0 A_Print("You must have two identical weapons to dual wield.")
goto Ready2

GetDualSil:
BE5G ABCDE 1
TNT1 A 0 A_PlaySound("CMGATCH",4)	
TNT1 A 8
TNT1 A 0 A_PlaySound("CMGATCH",5)		
TNT1 A 8
TNT1 A 0 A_PlaySound("CMGATCH",7)		
		TNT1 A 15
PIST F 0 A_Takeinventory("PistolSilencerOn",1)
//TNT1 A 0 A_Lower

		PIST F 0
		PIST F 0 A_Takeinventory("Zoomed",1)
		PIST F 0 A_Takeinventory("ADSmode",1)
		PIST F 0 A_TakeInventory("TossGrenade", 1)
		PIST F 0 A_TakeInventory("Kicking",1)
        PIST F 0 A_TakeInventory("Taunting",1)
        PIST F 0 A_TakeInventory("Reloading",1)
		PIST F 0 A_TakeInventory("Unloading",1)
		PIST F 0 A_TakeInventory("Salute1", 1)
		PIST F 0 A_TakeInventory("Salute2", 1)
        PIST F 0 A_ZoomFactor(1.0)
		PIST F 0 A_SelectWEapon("DualPistols")
goto Ready2


	DualWield:
PIST F 0 A_JumpIfInventory("PistolSilencerOn", 1, "DualWieldSil")

		TNT1 A 0 //1
		PIST F 0 A_Takeinventory("StartDualWield",1)
//		PIST F 0 A_JumpIfInventory("IsTacticalClass", 1, "NoDual")//Tactical mode cant dual
		PIST F 0 A_JumpIfInventory("DualPistols", 1, "GetDual")
		PIST F 0 A_Print("You must have two identical weapons to dual wield.")
		Goto Ready
		
	 GetDual:	
		PIST F 0
		PIST F 0 A_Takeinventory("Zoomed",1)
		PIST F 0 A_Takeinventory("ADSmode",1)
		PIST F 0 A_TakeInventory("TossGrenade", 1)
		PIST F 0 A_TakeInventory("Kicking",1)
        PIST F 0 A_TakeInventory("Taunting",1)
        PIST F 0 A_TakeInventory("Reloading",1)
		PIST F 0 A_TakeInventory("Unloading",1)
		PIST F 0 A_TakeInventory("Salute1", 1)
		PIST F 0 A_TakeInventory("Salute2", 1)
        PIST F 0 A_ZoomFactor(1.0)
		PIST F 0 A_SelectWEapon("DualPistols")
		Goto Ready	
		
	NoDual:
		PIST F 1
		PIST F 0 A_Print("You can't dual wield pistols when playing in Tactical Mode.",1)
		Goto Ready	



SilencerOn:
        	TNT1 A 0 A_ZoomFactor(1.0)
		TNT1 A 0 A_Takeinventory("Zoomed",1)
		TNT1 A 0 A_Takeinventory("ADSmode",1)
		TNT1 AA 0 A_JumpIfInventory("GoFatality", 1, "Steady")

Goto AttachSilencer 
//
//		TNT1 A 0 A_JumpIfInventory("SilencerUpgrade", 1, "AttachSilencer")
	//	Goto NoSilencer
	
	AttachSilencer:
		TNT1 A 0 A_JumpIfInventory("PistolSilencerOn", 1, "RemoveSilencer")
		TNT1 A 0 A_GiveInventory("PistolSilencerOn", 1)
		
PISS BA 1
//CMGS DCBA 1//xx

TNT1 A 0 A_PlaySound("CMGATCH",4)	
TNT1 A 8
TNT1 A 0 A_PlaySound("CMGATCH",5)		
TNT1 A 8
TNT1 A 0 A_PlaySound("CMGATCH",7)		
		TNT1 A 15

		BE5G EDCBA 1

		TNT1 A 0 A_print("Silencer Attached",2)
		Goto Ready2
		
	RemoveSilencer:
		TNT1 A 0 A_TakeInventory("PistolSilencerOn", 1)
		TNT1 A 0 A_print("Silencer Detached",2)
		
BE5G ABCDE 1

TNT1 A 0 A_PlaySound("CMGATCH",4)		
TNT1 A 8
TNT1 A 0 A_PlaySound("CMGATCH",5)		
TNT1 A 8
TNT1 A 0 A_PlaySound("CMGATCH",7)				
		TNT1 A 15

PISS ABB 1 //xx 
	//	CMGS ABCD 1//xx

		TNT1 A 0 A_takeinventory("PistolSilencerOn",1)
		goto Ready

	NoSilencer:
		TNT1 A 0
		TNT1 A 0 A_Print("You need a Tactical Silencer", 2)
		Goto Ready




	FireSilencer:
TNT1 A 0 A_JumpIFInventory("PistolBurstFire", 1, "FireSilencer2")
PIST F 0 A_JumpIfInventory("LaserOff",1,2)
TNT1 A 0 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)

TNT1 A 0 A_JumpIfInventory("BDPistolAmmo",1,"cont") 
goto Click
Cont:
TNT1 A 0 A_PlaySound("PISFIRE",1,0.3)
		TNT1 A 0 A_PlaySound("SPIFIR",5)
		TNT1 A 0 A_ZoomFactor(0.99)
	//	BE5F A 1 BRIGHT A_FireBullets (1.2,1.2,-1,9,"HitPuff",1)

BE5F A 1 BRIGHT A_FireBullets (1, 1, -1, 19, "WeakPuff", FBF_NORANDOM) //18
		PIST F 0 A_ZoomFactor(1.0)
        RIFF A 0 A_FireCustomMissile("DecorativeTracer", random(-1,1), 0, 0, 0)
PIST F 0 A_JumpIfInventory("LaserOff",1,2)
TNT1 A 0 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
		TNT1 A 0 A_setpitch(pitch-0.2)
//		TNT1 A 0 A_FireCustomMissile("Tracer",frandom(-2,2),0,-1,0,0,frandom(-2,2))
		TNT1 A 0 A_FireCustomMissile("ShakeYourAssMinor",0,0,0,0)
		TNT1 A 0 A_TakeInventory("BDPistolAmmo",1)
PIST F 0 A_Takeinventory("BDDualPistolAmmo",1)
		BE5F B 1 A_setpitch(pitch+0.2)
PIST F 0 A_JumpIfInventory("LaserOff",1,2)
TNT1 A 0 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
		TNT1 A 0 A_ZoomFactor(1.00)
TNT1 A 0 A_FireCustomMissile("PistolCaseSpawn",5,0,6,-8)
//PIST F 0 A_FireCustomMissile("PistolCaseSpawn",5,0,0,-9)
//PIST F 0 A_JumpIfInventory("LaserOff",1,2)
		BE5F CD 1 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)

//		BE5G A 1 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
		BE5G A 0 A_WeaponReady //7
PIST F 0 A_JumpIfInventory("LaserOff",1,2)
TNT1 A 0 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
TNT1 A 0 
		Goto Ready2


FireSilencer2:
PIST F 0 A_JumpIfInventory("LaserOff",1,2)
TNT1 A 0 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
		

TNT1 A 0 A_JumpIfInventory("BDPistolAmmo",1,"contAlt") 
goto Click
ContAlt:
TNT1 A 0 A_PlaySound("PISFIRE",1,0.3)
		TNT1 A 0 A_PlaySound("SPIFIR",5)
		TNT1 A 0 A_ZoomFactor(0.98)
	//	BE5F A 1 BRIGHT A_FireBullets (1.2,1.2,-1,9,"HitPuff",1)

BE5F A 1 BRIGHT A_FireBullets (1, 1, -1, 19, "WeakPuff", FBF_NORANDOM) //18
		TNT1 A 0 A_SetPitch(pitch-1)
		PIST F 0 A_ZoomFactor(1.0)
        RIFF A 0 A_FireCustomMissile("DecorativeTracer", random(-1,1), 0, 0, 0)
PIST F 0 A_JumpIfInventory("LaserOff",1,2)
TNT1 A 0 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
		TNT1 A 0 A_setpitch(pitch-0.2)
//		TNT1 A 0 A_FireCustomMissile("Tracer",frandom(-2,2),0,-1,0,0,frandom(-2,2))
		TNT1 A 0 A_FireCustomMissile("ShakeYourAssMinor",0,0,0,0)
		TNT1 A 0 A_TakeInventory("BDPistolAmmo",1)
PIST F 0 A_Takeinventory("BDDualPistolAmmo",1)
		BE5F B 1 A_setpitch(pitch+0.2)
PIST F 0 A_JumpIfInventory("LaserOff",1,2)
TNT1 A 0 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
		TNT1 A 0 A_ZoomFactor(1.00)
TNT1 A 0 A_FireCustomMissile("PistolCaseSpawn",5,0,6,-8)
//PIST F 0 A_FireCustomMissile("PistolCaseSpawn",5,0,0,-9)

//		BE5F CD 1 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)

//		BE5G A 1 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
		BE5G A 0 //A_WeaponReady //7
PIST F 0 A_JumpIfInventory("LaserOff",1,2)
TNT1 A 0 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)



TNT1 A 0 A_JumpIfInventory("BDPistolAmmo",1,"contAlt2") 
goto Click
ContAlt2:
TNT1 A 0 A_PlaySound("PISFIRE",1,0.3)
		TNT1 A 0 A_PlaySound("SPIFIR",5)
		TNT1 A 0 A_ZoomFactor(0.98)
	//	BE5F A 1 BRIGHT A_FireBullets (1.2,1.2,-1,9,"HitPuff",1)

BE5F A 1 BRIGHT A_FireBullets (2, 2, -1, 19, "WeakPuff", FBF_NORANDOM) //18
		TNT1 A 0 A_SetPitch(pitch-1)
		PIST F 0 A_ZoomFactor(1.0)
        RIFF A 0 A_FireCustomMissile("DecorativeTracer", random(-1,1), 0, 0, 0)
PIST F 0 A_JumpIfInventory("LaserOff",1,2)
TNT1 A 0 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
		TNT1 A 0 A_setpitch(pitch-0.2)
//		TNT1 A 0 A_FireCustomMissile("Tracer",frandom(-2,2),0,-1,0,0,frandom(-2,2))
		TNT1 A 0 A_FireCustomMissile("ShakeYourAssMinor",0,0,0,0)
		TNT1 A 0 A_TakeInventory("BDPistolAmmo",1)
PIST F 0 A_Takeinventory("BDDualPistolAmmo",1)
		BE5F B 1 A_setpitch(pitch+0.2)
PIST F 0 A_JumpIfInventory("LaserOff",1,2)
TNT1 A 0 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
		TNT1 A 0 A_ZoomFactor(1.00)
TNT1 A 0 A_FireCustomMissile("PistolCaseSpawn",5,0,6,-8)
//PIST F 0 A_FireCustomMissile("PistolCaseSpawn",5,0,0,-9)

//		BE5F CD 1 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)

//		BE5G A 1 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
		BE5G A 0 //A_WeaponReady //7
PIST F 0 A_JumpIfInventory("LaserOff",1,2)
TNT1 A 0 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)


TNT1 A 0 A_JumpIfInventory("BDPistolAmmo",1,"contAlt3") 
goto Click
ContAlt3:
TNT1 A 0 A_PlaySound("PISFIRE",1,0.3)
		TNT1 A 0 A_PlaySound("SPIFIR",5)
		TNT1 A 0 A_ZoomFactor(0.98)
	//	BE5F A 1 BRIGHT A_FireBullets (1.2,1.2,-1,9,"HitPuff",1)

BE5F A 1 BRIGHT A_FireBullets (1, 1, -1, 19, "WeakPuff", FBF_NORANDOM) //18
		TNT1 A 0 A_SetPitch(pitch-1)
		PIST F 0 A_ZoomFactor(1.0)
        RIFF A 0 A_FireCustomMissile("DecorativeTracer", random(-1,1), 0, 0, 0)
PIST F 0 A_JumpIfInventory("LaserOff",1,2)
TNT1 A 0 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
		TNT1 A 0 A_setpitch(pitch-0.2)
//		TNT1 A 0 A_FireCustomMissile("Tracer",frandom(-2,2),0,-1,0,0,frandom(-2,2))
		TNT1 A 0 A_FireCustomMissile("ShakeYourAssMinor",0,0,0,0)
		TNT1 A 0 A_TakeInventory("BDPistolAmmo",1)
PIST F 0 A_Takeinventory("BDDualPistolAmmo",1)
		BE5F B 1 A_setpitch(pitch+0.2)
PIST F 0 A_JumpIfInventory("LaserOff",1,2)
TNT1 A 0 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
		TNT1 A 0 A_ZoomFactor(1.00)
TNT1 A 0 A_FireCustomMissile("PistolCaseSpawn",5,0,6,-8)
//PIST F 0 A_FireCustomMissile("PistolCaseSpawn",5,0,0,-9)
//PIST F 0 A_JumpIfInventory("LaserOff",1,2)
		BE5F CD 1 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)

//		BE5G A 1 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
		BE5G A 2 //A_WeaponReady //7
//PIST F 0 A_JumpIfInventory("LaserOff",1,2)
BE5G A 2 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)

		Goto Ready2



Ready2:
PIST F 0 A_JumpIfInventory("LaserOff",1,2)
TNT1 A 0 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
	PIST F 0 A_JumpIfInventory("Kicking",1,"DoKick")
        PIST F 0 A_JumpIfInventory("Taunting",1,"Taunt")
		PIST F 0 A_JumpIfInventory("Salute1", 1, "Salute")
		PIST F 0 A_JumpIfInventory("Salute2", 1, "Salute")
        PIST F 0 A_JumpIfInventory("Reloading",1,"Reload")
//	PIST F 0 A_JumpIfInventory("TossGrenade",1,"TossGrenade")
TNT1 A 0 A_JumpIfInventory("WeapSpecial",1,"Continue")
		PIST F 0 A_JumpIfInventory("Unloading",1,"Unload")

	//	TNT1 A 0 A_JumpIfInventory("WeapSpecial",1,"WeapSpecial")
		TNT1 A 0 A_JumpIfInventory("StartDualWield",1,"DualWieldSil")
		BE5G A 1 A_WeaponReady
		Loop

Ready2Empty:
TNT1 A 0 A_Giveinventory("PistolEmpty",1)
PIST F 0 A_JumpIfInventory("LaserOff",1,2)
TNT1 A 0 A_FireBullets(0,0,1,0,"LaserDot",FBF_NOFLASH|FBF_NORANDOMPUFFZ)
	PIST F 0 A_JumpIfInventory("Kicking",1,"DoKick")
        PIST F 0 A_JumpIfInventory("Taunting",1,"Taunt")
		PIST F 0 A_JumpIfInventory("Salute1", 1, "Salute")
		PIST F 0 A_JumpIfInventory("Salute2", 1, "Salute")
        PIST F 0 A_JumpIfInventory("Reloading",1,"Reloadempty2")
//	PIST F 0 A_JumpIfInventory("TossGrenade",1,"TossGrenade")
TNT1 A 0 A_JumpIfInventory("WeapSpecial",1,"Continue")
		PIST F 0 A_JumpIfInventory("Unloading",1,"Unloadempty2")

	//	TNT1 A 0 A_JumpIfInventory("WeapSpecial",1,"WeapSpecial")
		TNT1 A 0 A_JumpIfInventory("StartDualWield",1,"DualWieldSil")
		BE7G A 1 A_WeaponReady
		Loop

Unloadempty2:
PIST F 0 A_Takeinventory("Unloading",1)
goto Ready2Empty

Reloadempty2:
PIST F 0 A_Takeinventory("Reloading",1)
PIST F 0 A_JumpIfInventory("Clip1",1,"ReloadSilencer")
goto Ready2Empty


Ready2EmptyReload:
BE7G A 1
RIFG A 0 A_JumpIfInventory("Clip1",1,"ReloadSilencer")
goto Ready2Empty


Click:
TNT1 A 0 A_JumpIfinventory("PistolEmpty",1,"Ready2EmptyReload") //xx
//TNT1 A 0 A_PlaySound("weapons/empty", 4)
	BE5G A 1
TNT1 A 0 A_PlaySound("weapons/pistolup")
RIFG A 0 A_JumpIfInventory("Clip1",1,"Reload")
goto Ready2Empty

ReloadSilencer:
TNT1 A 0 A_Takeinventory("PistolEmpty",1)
PIST F 0 A_JumpIfInventory("Clip1",1,"ReloadingSilencer")
goto Ready2

ReloadingSilencer:
TNT1 A 0 A_PlaySound("prel")

PIST F 0 A_JumpIfInventory("BDPistolAmmo",1,"ReloadSilencer2")
TNT1 A 0 A_JumpIfInventory("HasUnloaded",1,"Mag")		
		BE6R ZZYY 1 //ZY 1 
		BE6R WXX 1 //WXA
TNT1 A 0 A_PlaySound("reload")
//	BE5R AB 1 
	//	BE6R CDE 1 //BBCCDDEE 1

		TNT1 A 0 A_JumpIfInventory("HasUnloaded",1,2)
TNT1 A 0 A_FireCustomMissile("EmptyPistolClipSpawn",5,0,8,-4)
BE6R F 1 //FFFFFF 1
goto NoMag
Mag:
BE6R ZZYY 1 //ZY 1 
BE6R WXA 1 //WXA
NoMag:
		BE6R FFFFFFGG 1
TNT1 A 0 A_PlaySound("PistolReload5")
		BE6R H 2
TNT1 A 0 A_PlaySound("weapons/pistolup")	
		BE6R IIJJKK 1
BE6R LLMMNNOQP 1 //LLLLMMNNOQP 1
		TNT1 A 0 A_TakeInventory("Reloading",1)
		Goto ReloadLoop


ReloadSilencer2:

		BE6R ZZYYWX 1 
TNT1 A 0 A_JumpIfInventory("HasUnloaded",1,"Mag2")
TNT1 A 0 A_PlaySound("reload")
//	BE5R AB 1	
//BE5R CDE 1 //ABBCCDDEE 1
		TNT1 A 0 A_JumpIfInventory("HasUnloaded",1,2)
TNT1 A 0 A_FireCustomMissile("EmptyPistolClipSpawn",5,0,8,-4)
BE5R F 1 //FFFFFF 1
Mag2:
		BE5R FFFFFFGG 1
TNT1 A 0 A_PlaySound("PistolReload5")
		BE5R HIJ 2
		BE5R KKLL 1 //LLLL
BE6R MMNNOQP 1
		TNT1 A 0 A_TakeInventory("Reloading",1)
		Goto ReloadLoop2

	ReloadLoop:
TNT1 A 0 A_JumpIfInventory("NoMagReload",1,"ReloadLoopSil")
TNT1 A 0 A_Takeinventory("BDPistolAmmo")
ReloadLoopSil:

		TNT1 A 0 A_JumpIfInventory("BDPistolAmmo",15,"ReloadDone")
		TNT1 A 0 A_JumpIfInventory("Clip1",1,1)
		Goto ReloadDone
		TNT1 A 0 A_Giveinventory("BDPistolAmmo",1)
		TNT1 A 0 A_TakeInventory("Clip1",1)
		Goto ReloadLoopSil

	ReloadLoop2:
TNT1 A 0 A_JumpIfInventory("NoMagReload",1,"ReloadLoopSil2")
TNT1 A 0 A_Takeinventory("BDPistolAmmo")
ReloadLoopSil2:

		TNT1 A 0 A_JumpIfInventory("BDPistolAmmo",16,"ReloadDone")
		TNT1 A 0 A_JumpIfInventory("Clip1",1,1)
		Goto ReloadDone
		TNT1 A 0 A_Giveinventory("BDPistolAmmo",1)
		TNT1 A 0 A_TakeInventory("Clip1",1)
		Goto ReloadLoopSil2
		
	ReloadDone:
		TNT1 A 0 A_TakeInventory("Reloading",1)
		TNT1 A 0 A_TakeInventory("HasUnloaded",1)
		TNT1 A 0 A_Refire
		Goto Ready2


UnloadSilencer:
TNT1 A 0 A_TakeInventory("Unloading",1)
TNT1 A 0 A_JumpIfInventory("Hasunloaded",1,"Ready2")
TNT1 A 0 A_JumpifInventory("BDPistolAmmo",1,"ContinueUnloadSilencer")
Goto Ready2Empty
ContinueUnloadSilencer:
PIST F 0 A_PlaySound("prel")        
		BE6R PQON 1
BE5R KJIH 2
BE5R GGF 1 //GGFFFFFF 1
	UnloadLoopSilencer:
		TNT1 A 0 A_JumpIfInventory("BDPistolAmmo",1,1)
		Goto UnloadDoneSilencer
		TNT1 A 0 A_TakeInventory("BDPistolAmmo",1)
		TNT1 A 0 A_Giveinventory("Clip1",1)
		Goto UnloadLoopSilencer
	
	UnloadDoneSilencer:
TNT1 A 0 A_GiveInventory("BDPistolAmmo",1)
TNT1 A 0 A_Takeinventory("Clip1",1)
TNT1 A 0 A_PlaySound("weapons/pistolup")	
BE5R FF 1
BE7R AD 2
TNT1 A 0 A_FireCustomMissile("9mmCaseSpawnCold",5,0,6,-2) //5,0,6,-14)
TNT1 A 0 A_TakeInventory("BDPistolAmmo",1)
BE7R EE 2
//BE7R AA 1 //BE7R BC 2
BE6R QP 1
		TNT1 A 0 A_GiveInventory("HasUnloaded",1)
		Goto Ready2Empty
//xxx




	ReadySoul:
        TNT1 A 0 A_JumpIfInventory("Kicking",1,"DoKick")
		TNT1 A 0 A_JumpIfInventory("Reloading",1,"KillLS")
        THEA A 7 BRIGHT A_WeaponReady
        TNT1 A 0 A_FireCustomMissile("LostSoulOnHandFireSpawner",40,0,0,5)
        THEA B 7 BRIGHT A_WeaponReady
        TNT1 A 0 A_FireCustomMissile("LostSoulOnHandFireSpawner",40,0,0,5)
        THEA A 7 BRIGHT A_WeaponReady
        TNT1 A 0 A_FireCustomMissile("LostSoulOnHandFireSpawner",40,0,0,5)
        THEA B 7 BRIGHT A_WeaponReady
        TNT1 A 0 A_FireCustomMissile("LostSoulOnHandFireSpawner",40,0,0,5)
        THEA C 7 BRIGHT A_WeaponReady
        TNT1 A 0 A_FireCustomMissile("LostSoulOnHandFireSpawner",40,0,0,5)
        THEA D 7 BRIGHT A_WeaponReady
        TNT1 A 0 A_FireCustomMissile("LostSoulOnHandFireSpawner",40,0,0,5)
        THEA C 7 BRIGHT A_WeaponReady
        TNT1 A 0 A_FireCustomMissile("LostSoulOnHandFireSpawner",40,0,0,5)
        THEA D 7 BRIGHT A_WeaponReady
        TNT1 A 0 A_FireCustomMissile("LostSoulOnHandFireSpawner",40,0,0,5)
		Goto Ready3
		
	
			
	LSFire:
		THEF A 4
        TNT1 A 0 A_PlaySound("skeleton/swing")
		TNT1 A 0 A_Giveinventory("Punching",1)
        THEF B 1 A_FireCustomMissile("PoorLostSoul", 0, 1, 0, 0)
        THEF CDEF 1
        TNT1 A 0 A_TakeInventory("LostSoulFatality",1)
		Goto Ready
		
    KillLS:
        THEA E 8
        TNT1 A 0 A_FireCustomMissile("LSOHK",40,0,0,5)
        TNT1 A 0 A_Takeinventory("LostSoulFatality",1)
        THEA F 8
		THEA F 1 A_Lower
		Wait		
		
	
	ReadyBarrel:
        TNT1 A 0 A_JumpIfInventory("Kicking",1,"DoKick")
		MARN A 0 ACS_ExecuteAlways(294, 0, 0, 0, 0)//Makes player slower.
        THRG C 1 A_WeaponReady
		TNT1 A 0 A_JumpIfInventory("ImpactMovesSling", 1, "ReadyBarrelShake")
		Goto ReadyBarrel
	
	PickBarrel:	
		TNT1 A 0
		MARN A 0 ACS_ExecuteAlways(294, 0, 0, 0, 0)//Makes player slower.
        THRG C 1 offset(-12,48)
		THRG C 1 offset(-9,42)
		THRG C 1 offset(-7,39)
		THRG C 1 offset(-4,36)
		THRG C 1 offset(-2,33)
	ReadyBarrelShake:
        TNT1 A 0 A_JumpIfInventory("Kicking",1,"DoKick")
		MARN A 0 ACS_ExecuteAlways(294, 0, 0, 0, 0)//Makes player slower.
		TNT1 A 0 A_TakeInventory("ImpactMovesSling", 1)
        THRG DE 1 A_WeaponReady
		TNT1 A 0 A_JumpIfInventory("Kicking",1,"DoKick")
		THRG EDCBA 1 A_WeaponReady
		TNT1 A 0 A_JumpIfInventory("Kicking",1,"DoKick")
		THRG ABC 1 A_WeaponReady
		TNT1 A 0 A_JumpIfInventory("Kicking",1,"DoKick")
		TNT1 A 0 A_JumpIfInventory("ImpactMovesSling", 1, "ReadyBarrelShake")
		THRG DEEDCBA 2 A_WeaponReady
		TNT1 A 0 A_JumpIfInventory("Kicking",1,"DoKick")
		TNT1 A 0 A_JumpIfInventory("ImpactMovesSling", 1, "ReadyBarrelShake")
		THRG AB 3 A_WeaponReady
		TNT1 A 0 A_JumpIfInventory("Kicking",1,"DoKick")
		TNT1 A 0 A_JumpIfInventory("ImpactMovesSling", 1, "ReadyBarrelShake")
		Goto ReadyBarrel	
		
	FireBarrel:
		THRG C 1 offset(4,34)
		THRG C 1 offset(24,41)
		THRG C 1 offset(48,49)
		THRG C 1 offset(56,51)
		THRG C 1 offset(52,49)
		THRG C 1 offset(36,41)
		THRG C 1 offset(12,34)
		THRG C 1 offset(-6,32)
		THRG C 1 offset(-14,32)
		TNT1 A 0 A_FireCustomMissile("ThrowedBarrel", 0, 1, 0, 0)
        TNT1 A 0 A_PlaySound("skeleton/swing")
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("HasBarrel",1)
		MARN A 0 ACS_ExecuteAlways(295, 0, 0, 0, 0)//Makes player have normal speed.
        THRF ABCDEF 3 
		TNT1 A 0 A_TakeInventory("StartDualWield", 1)
		Goto Ready
	AltFireBarrel:
		THRG C 1 offset(-2,33)
		THRG C 1 offset(-4,36)
		THRG C 1 offset(-7,39)
		THRG C 1 offset(-9,42)
		THRG C 1 offset(-12,48)
		THRF A 0 A_SpawnItemEx ("ExplosiveBarrel",40,0,0,0,0,0,0,SXF_NOCHECKPOSITION,0)
		MARN A 0 ACS_ExecuteAlways(295, 0, 0, 0, 0)//Makes player have normal speed.
        TNT1 A 0 A_PlaySound("skeleton/swing")
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("HasBarrel",1)
		TNT1 A 0 A_TakeInventory("StartDualWield", 1)
		PONG A 5
		Goto Ready


	//PICKING UP ENEMIES ////////////////////////////////////////////////////////////////////
	PickZombieman:	
		TNT1 A 0
		GRZ1 C 1 offset(12, 32)
		GRZ1 C 1 offset(6, 32)
		GRZ1 C 1  A_WeaponReady(WRF_NOSWITCH)
		TNT1 A 0
		TNT1 A 0 A_JumpIfInventory("MeatAmmo", 60, "ZombiemanDie")
		TNT1 A 0 A_SpawnItemEx("MeatShield", 15, 0, 15, 0)
		GRZ1 A 3 A_WeaponReady(WRF_NOSWITCH)
		TNT1 A 0 A_Jump(20, 2)
		Goto PickZombieman+5
		TNT1 AAAA 0
		GRZ1 ABACACA 4 A_WeaponReady(WRF_NOSWITCH)
		Goto PickZombieman+5
	
	ThrowZombieman:
		TNT1 A 0
		TNT1 A 0 A_JumpIfHealthLower(1, "ZombiemanDie")
		GRZ1 D 1 offset(-4, 32)
		GRZ1 D 1 offset(-9, 33)
		GRZ1 D 1 offset(-16, 34)
		GRZ1 D 2 offset(-24, 35)
		GRZ1 D 3 offset(-36, 48)
		GRZ1 D 1 offset(-24, 35)
		GRZ1 B 1 offset(-16, 34)
		GRZ1 B 1 offset(-9, 33)
		GRZ1 B 1 offset(-1, 32)
		TNT1 A 0 A_PlaySound("skeleton/swing")
		TNT1 A 0 A_FireCustomMissile("ThrowedZman", 0, 0, 0, 0)
		TNT1 A 0 A_TakeInventory("GoSpecial",1)
		TNT1 A 0 A_TakeInventory("GotMeatShield", 1)
		TNT1 A 0 A_TakeInventory("HasZmanShield",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("GrabbedAZombieman",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
        THEF BCDEF 1 
		TNT1 A 10
		TNT1 A 0 A_TakeInventory("StartDualWield", 1)
		Goto Ready
		
	ShieldZombieman:
		TNT1 A 0 A_TakeInventory("GrabbedAZombieman",1)
		TNT1 A 0 A_TakeInventory("GrabbedAShotgunguy",1)
		TNT1 A 0 A_TakeInventory("GrabbedAChaingunguy",1)
		TNT1 A 0 A_TakeInventory("GrabbedAZombieCivilian",1)
TNT1 A 0 A_TakeInventory("GrabbedABZombieCivilian",1)
TNT1 A 0 A_TakeInventory("GrabbedAFZombieCivilian",1)
TNT1 A 0 A_TakeInventory("GrabbedADarkImp",1)
		TNT1 A 0 A_TakeInventory("GrabbedAImp",1)
		TNT1 A 0 A_GiveInventory("ZMANShield",1)
		GRZ1 A 1 offset(0,40)
		GRZ1 A 1 offset(0,48)
		TNT1 A 0 A_SelectWeapon("ZMANShield")
		TNT1 A 1 A_WeaponReady(WRF_NOFIRE)
		Goto Ready
		
	ZombiemanDie:
		TNT1 A 0
		TNT1 A 0 A_SpawnItem("SargeXDeath", 0, 40)
		TNT1 A 0 A_TakeInventory("GoSpecial",1)
		TNT1 A 0 A_TakeInventory("GotMeatShield", 1)
		TNT1 A 0 A_TakeInventory("HasZmanShield",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("GrabbedAZombieman",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		Goto Ready
		
		
	//---------------------------------------------------Zombieman End
	//Imp Start
	
	PickImp:	
		TNT1 A 0
		GRZ3 C 1 offset(12, 32)
		GRZ3 C 1 offset(6, 32)
		GRZ3 C 1  A_WeaponReady(WRF_NOSWITCH)
		TNT1 A 0
		TNT1 A 0 A_JumpIfInventory("MeatAmmo", 60, "ImpDie")
		TNT1 A 0 A_SpawnItemEx("MeatShield", 15, 0, 15, 0)
		GRZ3 A 3 A_WeaponReady(WRF_NOSWITCH)
		TNT1 A 0 A_Jump(20, 2)
		Goto PickImp+5
		TNT1 AAAA 0
		GRZ3 ABACACA 4 A_WeaponReady(WRF_NOSWITCH)
		Goto PickImp+5
	
	ThrowImp:
		TNT1 A 0
		TNT1 A 0 A_JumpIfHealthLower(1, "ImpDie")
		GRZ3 D 1 offset(-4, 32)
		GRZ3 D 1 offset(-9, 33)
		GRZ3 D 1 offset(-16, 34)
		GRZ3 D 2 offset(-24, 35)
		GRZ3 D 3 offset(-36, 48)
		GRZ3 D 1 offset(-24, 35)
		GRZ3 B 1 offset(-16, 34)
		GRZ3 B 1 offset(-9, 33)
		GRZ3 B 1 offset(-1, 32)
		TNT1 A 0 A_PlaySound("skeleton/swing")
		TNT1 A 0 A_FireCustomMissile("ThrowedImp", 0, 0, 0, 0)
		TNT1 A 0 A_TakeInventory("GoSpecial",1)
		TNT1 A 0 A_TakeInventory("GotMeatShield", 1)
		TNT1 A 0 A_TakeInventory("HasZmanShield",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("GrabbedAImp",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
        THEF BCDEF 1 
		TNT1 A 10
		TNT1 A 0 A_TakeInventory("StartDualWield", 1)
		Goto Ready
		
	ShieldImp:
		TNT1 A 0 A_TakeInventory("GrabbedAImp",1)
		TNT1 A 0 A_TakeInventory("GrabbedAShotgunguy",1)
		TNT1 A 0 A_TakeInventory("GrabbedAChaingunguy",1)
		TNT1 A 0 A_TakeInventory("GrabbedAZombieCivilian",1)
TNT1 A 0 A_TakeInventory("GrabbedABZombieCivilian",1)
TNT1 A 0 A_TakeInventory("GrabbedAFZombieCivilian",1)
TNT1 A 0 A_TakeInventory("GrabbedADarkImp",1)
		TNT1 A 0 A_TakeInventory("GrabbedAImp",1)
		TNT1 A 0 A_GiveInventory("ImpShield",1)
		GRZ3 A 1 offset(0,40)
		GRZ3 A 1 offset(0,48)
		TNT1 A 0 A_SelectWeapon("ImpShield")
		TNT1 A 1 A_WeaponReady(WRF_NOFIRE)
		Goto Ready
		
	ImpDie:
		TNT1 A 0
		TNT1 A 0 A_SpawnItem("ImpXDeath", 0, 40)
		TNT1 A 0 A_TakeInventory("GoSpecial",1)
		TNT1 A 0 A_TakeInventory("GotMeatShield", 1)
		TNT1 A 0 A_TakeInventory("HasZmanShield",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("GrabbedAImp",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		Goto Ready
		
		
	//---------------------------------------------------Imp End

//DarkImp Start
	
	PickDarkImp:	
		TNT1 A 0
		GRZ8 C 1 offset(12, 32)
		GRZ8 C 1 offset(6, 32)
		GRZ8 C 1  A_WeaponReady(WRF_NOSWITCH)
		TNT1 A 0
		TNT1 A 0 A_JumpIfInventory("MeatAmmo", 60, "DarkImpDie")
		TNT1 A 0 A_SpawnItemEx("MeatShield", 15, 0, 15, 0)
		GRZ8 A 3 A_WeaponReady(WRF_NOSWITCH)
		TNT1 A 0 A_Jump(20, 2)
		Goto PickDarkImp+5
		TNT1 AAAA 0
		GRZ8 ABACACA 4 A_WeaponReady(WRF_NOSWITCH)
		Goto PickDarkImp+5
	
	ThrowDarkImp:
		TNT1 A 0
		TNT1 A 0 A_JumpIfHealthLower(1, "DarkImpDie")
		GRZ8 D 1 offset(-4, 32)
		GRZ8 D 1 offset(-9, 33)
		GRZ8 D 1 offset(-16, 34)
		GRZ8 D 2 offset(-24, 35)
		GRZ8 D 3 offset(-36, 48)
		GRZ8 D 1 offset(-24, 35)
		GRZ8 B 1 offset(-16, 34)
		GRZ8 B 1 offset(-9, 33)
		GRZ8 B 1 offset(-1, 32)
		TNT1 A 0 A_PlaySound("skeleton/swing")
		TNT1 A 0 A_FireCustomMissile("ThrowedDarkImp", 0, 0, 0, 0)
		TNT1 A 0 A_TakeInventory("GoSpecial",1)
		TNT1 A 0 A_TakeInventory("GotMeatShield", 1)
		TNT1 A 0 A_TakeInventory("HasZmanShield",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		//TNT1 A 0 A_TakeInventory("GrabbedAImp",1)
		TNT1 A 0 A_TakeInventory("GrabbedADarkImp",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
        THEF BCDEF 1 
		TNT1 A 10
		TNT1 A 0 A_TakeInventory("StartDualWield", 1)
		Goto Ready
		
	ShieldDarkImp:
		TNT1 A 0 A_TakeInventory("GrabbedAImp",1)
		TNT1 A 0 A_TakeInventory("GrabbedAShotgunguy",1)
		TNT1 A 0 A_TakeInventory("GrabbedAChaingunguy",1)
		TNT1 A 0 A_TakeInventory("GrabbedAZombieCivilian",1)
TNT1 A 0 A_TakeInventory("GrabbedABZombieCivilian",1)
TNT1 A 0 A_TakeInventory("GrabbedAFZombieCivilian",1)		
TNT1 A 0 A_TakeInventory("GrabbedADarkImp",1)
		TNT1 A 0 A_GiveInventory("DarkImpShield",1)
		GRZ8 A 1 offset(0,40)
		GRZ8 A 1 offset(0,48)
		TNT1 A 0 A_SelectWeapon("DarkImpShield")
		TNT1 A 1 A_WeaponReady(WRF_NOFIRE)
		Goto Ready
		
	DarkImpDie:
		TNT1 A 0
		TNT1 A 0 A_SpawnItem("DarkImpXDeath", 0, 40)
		TNT1 A 0 A_TakeInventory("GoSpecial",1)
		TNT1 A 0 A_TakeInventory("GotMeatShield", 1)
		TNT1 A 0 A_TakeInventory("HasZmanShield",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("GrabbedADarkImp",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		Goto Ready
		
//---------------------------------------------------DarkImp End

	//Shotgunguy Start	----------------------------------------
	PickShotgunguy:	
		TNT1 A 0
		GRZ2 C 1 offset(12, 32)
		GRZ2 C 1 offset(6, 32)
		GRZ2 C 1  A_WeaponReady(WRF_NOSWITCH)
		TNT1 A 0
		TNT1 A 0 A_JumpIfInventory("MeatAmmo", 60, "ShotgunguyDie")
		TNT1 A 0 A_SpawnItemEx("MeatShield", 15, 0, 15, 0)
		GRZ2 A 3 A_WeaponReady(WRF_NOSWITCH)
		TNT1 A 0 A_Jump(20, 2)
		Goto PickShotgunguy+5
		TNT1 AAAA 0
		GRZ2 ABACACA 4 A_WeaponReady(WRF_NOSWITCH)
		Goto PickShotgunguy+5
	
	ThrowShotgunguy:
		TNT1 A 0
		TNT1 A 0 A_JumpIfHealthLower(1, "ShotgunguyDie")
		GRZ2 D 1 offset(-4, 32)
		GRZ2 D 1 offset(-9, 33)
		GRZ2 D 1 offset(-16, 34)
		GRZ2 D 2 offset(-24, 35)
		GRZ2 D 3 offset(-36, 48)
		GRZ2 D 1 offset(-24, 35)
		GRZ2 B 1 offset(-16, 34)
		GRZ2 B 1 offset(-9, 33)
		GRZ2 B 1 offset(-1, 32)
		TNT1 A 0 A_PlaySound("skeleton/swing")
		TNT1 A 0 A_FireCustomMissile("ThrowedShotgunguy", 0, 0, 0, 0)
		TNT1 A 0 A_TakeInventory("GoSpecial",1)
		TNT1 A 0 A_TakeInventory("GotMeatShield", 1)
		TNT1 A 0 A_TakeInventory("HasZmanShield",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("GrabbedAShotgunguy",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
        THEF BCDEF 1 
		TNT1 A 10
		TNT1 A 0 A_TakeInventory("StartDualWield", 1)
		Goto Ready
		
	ShieldShotgunguy:
		TNT1 A 0 A_TakeInventory("GrabbedAShotgunguy",1)
		TNT1 A 0 A_TakeInventory("GrabbedAShotgunguy",1)
		TNT1 A 0 A_TakeInventory("GrabbedAChaingunguy",1)
		TNT1 A 0 A_TakeInventory("GrabbedAZombieCivilian",1)
TNT1 A 0 A_TakeInventory("GrabbedABZombieCivilian",1)
TNT1 A 0 A_TakeInventory("GrabbedAFZombieCivilian",1)
TNT1 A 0 A_TakeInventory("GrabbedADarkImp",1)
		TNT1 A 0 A_TakeInventory("GrabbedAImp",1)
		TNT1 A 0 A_GiveInventory("SguyShield",1)
		GRZ2 A 1 offset(0,40)
		GRZ2 A 1 offset(0,48)
		TNT1 A 0 A_SelectWeapon("SGuyShield")
		TNT1 A 1 A_WeaponReady(WRF_NOFIRE)
		Goto Ready
		
	ShotgunguyDie:
		TNT1 A 0
		TNT1 A 0 A_SpawnItem("SargeXDeath", 0, 40)
		TNT1 A 0 A_TakeInventory("GoSpecial",1)
		TNT1 A 0 A_TakeInventory("GotMeatShield", 1)
		TNT1 A 0 A_TakeInventory("HasZmanShield",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("GrabbedAShotgunguy",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		Goto Ready
		
	//End Shotgunguy-------------------------------------------------
	//CHaingunguy Start------------------------------------------------
	
	PickChaingunguy:	
		TNT1 A 0
		GRZ4 C 1 offset(12, 32)
		GRZ4 C 1 offset(6, 32)
		GRZ4 C 1  A_WeaponReady(WRF_NOSWITCH)
		TNT1 A 0
		TNT1 A 0 A_JumpIfInventory("MeatAmmo", 60, "ChaingunguyDie")
		TNT1 A 0 A_SpawnItemEx("MeatShield", 15, 0, 15, 0)
		GRZ4 A 3 A_WeaponReady(WRF_NOSWITCH)
		TNT1 A 0 A_Jump(20, 2)
		Goto PickChaingunguy+5
		TNT1 AAAA 0
		GRZ4 ABACACA 4 A_WeaponReady(WRF_NOSWITCH)
		Goto PickChaingunguy+5
	
	ThrowChaingunguy:
		TNT1 A 0
		TNT1 A 0 A_JumpIfHealthLower(1, "ChaingunguyDie")
		GRZ4 D 1 offset(-4, 32)
		GRZ4 D 1 offset(-9, 33)
		GRZ4 D 1 offset(-16, 34)
		GRZ4 D 2 offset(-24, 35)
		GRZ4 D 3 offset(-36, 48)
		GRZ4 D 1 offset(-24, 35)
		GRZ4 B 1 offset(-16, 34)
		GRZ4 B 1 offset(-9, 33)
		GRZ4 B 1 offset(-1, 32)
		TNT1 A 0 A_PlaySound("skeleton/swing")
		TNT1 A 0 A_FireCustomMissile("ThrowedChaingunguy", 0, 0, 0, 0)
		TNT1 A 0 A_TakeInventory("GoSpecial",1)
		TNT1 A 0 A_TakeInventory("GotMeatShield", 1)
		TNT1 A 0 A_TakeInventory("HasZmanShield",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("GrabbedAChaingunguy",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
        THEF BCDEF 1 
		TNT1 A 10
		TNT1 A 0 A_TakeInventory("StartDualWield", 1)
		Goto Ready
		
	ShieldChaingunguy:
		TNT1 A 0 A_TakeInventory("GrabbedAChaingunguy",1)
		TNT1 A 0 A_TakeInventory("GrabbedAImp",1)
		TNT1 A 0 A_GiveInventory("CguyShield",1)
		GRZ4 A 1 offset(0,40)
		GRZ4 A 1 offset(0,48)
		TNT1 A 0 A_SelectWeapon("CGuyShield")
		TNT1 A 1 A_WeaponReady(WRF_NOFIRE)
		Goto Ready
		
	ChaingunguyDie:
		TNT1 A 0
		TNT1 A 0 A_SpawnItem("SargeXDeath", 0, 40)
		TNT1 A 0 A_TakeInventory("GoSpecial",1)
		TNT1 A 0 A_TakeInventory("GotMeatShield", 1)
		TNT1 A 0 A_TakeInventory("HasZmanShield",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("GrabbedAChaingunguy",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		Goto Ready
		
	//End Chaingunguy-------------------------------------------------
	//Labguy Start------------------------------------------------	
	
	PickZombieCivilian:	
		TNT1 A 0
		GRZ7 C 1 offset(12, 32)
		GRZ7 C 1 offset(6, 32)
		GRZ7 C 1  A_WeaponReady(WRF_NOSWITCH)
		TNT1 A 0
		TNT1 A 0 A_JumpIfInventory("MeatAmmo", 60, "ZombieCivilianDie")
		TNT1 A 0 A_SpawnItemEx("MeatShield", 15, 0, 15, 0)
		GRZ7 A 3 A_WeaponReady(WRF_NOSWITCH)
		TNT1 A 0 A_Jump(20, 2)
		Goto PickZombieCivilian+5
		TNT1 AAAA 0
		GRZ7 ABACACA 4 A_WeaponReady(WRF_NOSWITCH)
		Goto PickZombieCivilian+5
	
	ThrowZombieCivilian:
		TNT1 A 0
		TNT1 A 0 A_JumpIfHealthLower(1, "ZombieCivilianDie")
		GRZ7 D 1 offset(-4, 32)
		GRZ7 D 1 offset(-9, 33)
		GRZ7 D 1 offset(-16, 34)
		GRZ7 D 2 offset(-24, 35)
		GRZ7 D 3 offset(-36, 48)
		GRZ7 D 1 offset(-24, 35)
		GRZ7 B 1 offset(-16, 34)
		GRZ7 B 1 offset(-9, 33)
		GRZ7 B 1 offset(-1, 32)
		TNT1 A 0 A_PlaySound("skeleton/swing")
		TNT1 A 0 A_FireCustomMissile("ThrowedZombieCivilian", 0, 0, 0, 0)
		TNT1 A 0 A_TakeInventory("GoSpecial",1)
		TNT1 A 0 A_TakeInventory("GotMeatShield", 1)
		TNT1 A 0 A_TakeInventory("HasZmanShield",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("GrabbedAZombieCivilian",1)
TNT1 A 0 A_TakeInventory("GrabbedABZombieCivilian",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
        THEF BCDEF 1 
		TNT1 A 10
		TNT1 A 0 A_TakeInventory("StartDualWield", 1)
		Goto Ready
		
	ShieldZombieCivilian:
		TNT1 A 0 A_TakeInventory("GrabbedAZombieCivilian",1)
TNT1 A 0 A_TakeInventory("GrabbedAZombieCivilian",1)
		TNT1 A 0 A_TakeInventory("GrabbedAImp",1)
		TNT1 A 0 A_GiveInventory("ZombieCivilianShield",1)
		GRZ7 A 1 offset(0,40)
		GRZ7 A 1 offset(0,48)
		TNT1 A 0 A_SelectWeapon("ZombieCivilianShield")
		TNT1 A 1 A_WeaponReady(WRF_NOFIRE)
		Goto Ready
		
	ZombieCivilianDie:
		TNT1 A 0
		TNT1 A 0 A_SpawnItem("SargeXDeath", 0, 40)
		TNT1 A 0 A_TakeInventory("GoSpecial",1)
		TNT1 A 0 A_TakeInventory("GotMeatShield", 1)
		TNT1 A 0 A_TakeInventory("HasZmanShield",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("GrabbedAZombieCivilian",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		Goto Ready
		
	//Civilian End------------------------------------------------	




//BLabguy Start------------------------------------------------	
	
	PickBZombieCivilian:	
		TNT1 A 0
		GRZ9 C 1 offset(12, 32)
		GRZ9 C 1 offset(6, 32)
		GRZ9 C 1  A_WeaponReady(WRF_NOSWITCH)
		TNT1 A 0
		TNT1 A 0 A_JumpIfInventory("MeatAmmo", 60, "BZombieCivilianDie")
		TNT1 A 0 A_SpawnItemEx("MeatShield", 15, 0, 15, 0)
		GRZ9 A 3 A_WeaponReady(WRF_NOSWITCH)
		TNT1 A 0 A_Jump(20, 2)
		Goto PickBZombieCivilian+5
		TNT1 AAAA 0
		GRZ9 ABACACA 4 A_WeaponReady(WRF_NOSWITCH)
		Goto PickBZombieCivilian+5
	
	ThrowBZombieCivilian:
		TNT1 A 0
		TNT1 A 0 A_JumpIfHealthLower(1, "ZombieCivilianDie")
		GRZ9 D 1 offset(-4, 32)
		GRZ9 D 1 offset(-9, 33)
		GRZ9 D 1 offset(-16, 34)
		GRZ9 D 2 offset(-24, 35)
		GRZ9 D 3 offset(-36, 48)
		GRZ9 D 1 offset(-24, 35)
		GRZ9 B 1 offset(-16, 34)
		GRZ9 B 1 offset(-9, 33)
		GRZ9 B 1 offset(-1, 32)
		TNT1 A 0 A_PlaySound("skeleton/swing")
		TNT1 A 0 A_FireCustomMissile("ThrowedBZombieCivilian", 0, 0, 0, 0)
		TNT1 A 0 A_TakeInventory("GoSpecial",1)
		TNT1 A 0 A_TakeInventory("GotMeatShield", 1)
		TNT1 A 0 A_TakeInventory("HasZmanShield",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("GrabbedABZombieCivilian",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
        THEF BCDEF 1 
		TNT1 A 10
		TNT1 A 0 A_TakeInventory("StartDualWield", 1)
		Goto Ready
		
	ShieldBZombieCivilian:
		TNT1 A 0 A_TakeInventory("GrabbedABZombieCivilian",1)
		TNT1 A 0 A_TakeInventory("GrabbedAImp",1)
		TNT1 A 0 A_GiveInventory("BZombieCivilianShield",1)
		GRZ9 A 1 offset(0,40)
		GRZ9 A 1 offset(0,48)
		TNT1 A 0 A_SelectWeapon("BZombieCivilianShield")
		TNT1 A 1 A_WeaponReady(WRF_NOFIRE)
		Goto Ready
		
	BZombieCivilianDie:
		TNT1 A 0
		TNT1 A 0 A_SpawnItem("SargeXDeath", 0, 40)
		TNT1 A 0 A_TakeInventory("GoSpecial",1)
		TNT1 A 0 A_TakeInventory("GotMeatShield", 1)
		TNT1 A 0 A_TakeInventory("HasZmanShield",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("GrabbedABZombieCivilian",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		Goto Ready
		
	//BCivilian End------------------------------------------------	

//Labgalstart------------------------------------------------	
	
	PickFZombieCivilian:	
		TNT1 A 0
		GRZZ C 1 offset(12, 32)
		GRZZ C 1 offset(6, 32)
		GRZZ C 1  A_WeaponReady(WRF_NOSWITCH)
		TNT1 A 0
		TNT1 A 0 A_JumpIfInventory("MeatAmmo", 60, "FZombieCivilianDie")
		TNT1 A 0 A_SpawnItemEx("MeatShield", 15, 0, 15, 0)
		GRZZ A 3 A_WeaponReady(WRF_NOSWITCH)
		TNT1 A 0 A_Jump(20, 2)
		Goto PickFZombieCivilian+5
		TNT1 AAAA 0
		GRZZ ABACACA 4 A_WeaponReady(WRF_NOSWITCH)
		Goto PickFZombieCivilian+5
	
	ThrowFZombieCivilian:
		TNT1 A 0
		TNT1 A 0 A_JumpIfHealthLower(1, "FZombieCivilianDie")
		GRZZ D 1 offset(-4, 32)
		GRZZ D 1 offset(-9, 33)
		GRZZ D 1 offset(-16, 34)
		GRZZ D 2 offset(-24, 35)
		GRZZ D 3 offset(-36, 48)
		GRZZ D 1 offset(-24, 35)
		GRZZ B 1 offset(-16, 34)
		GRZZ B 1 offset(-9, 33)
		GRZZ B 1 offset(-1, 32)
		TNT1 A 0 A_PlaySound("skeleton/swing")
		TNT1 A 0 A_FireCustomMissile("ThrowedFZombieCivilian", 0, 0, 0, 0)
		TNT1 A 0 A_TakeInventory("GoSpecial",1)
		TNT1 A 0 A_TakeInventory("GotMeatShield", 1)
		TNT1 A 0 A_TakeInventory("HasZmanShield",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("GrabbedAFZombieCivilian",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
        THEF BCDEF 1 
		TNT1 A 10
		TNT1 A 0 A_TakeInventory("StartDualWield", 1)
		Goto Ready
		
	ShieldFZombieCivilian:
		TNT1 A 0 A_TakeInventory("GrabbedAFZombieCivilian",1)
		TNT1 A 0 A_TakeInventory("GrabbedAImp",1)
		TNT1 A 0 A_GiveInventory("FZombieCivilianShield",1)
		GRZZ A 1 offset(0,40)
		GRZZ A 1 offset(0,48)
		TNT1 A 0 A_SelectWeapon("FZombieCivilianShield")
		TNT1 A 1 A_WeaponReady(WRF_NOFIRE)
		Goto Ready
		
	FZombieCivilianDie:
		TNT1 A 0
		TNT1 A 0 A_SpawnItem("LabgalHeadExplode", 0, 40) //labgalxdeath
		TNT1 A 0 A_TakeInventory("GoSpecial",1)
		TNT1 A 0 A_TakeInventory("GotMeatShield", 1)
		TNT1 A 0 A_TakeInventory("HasZmanShield",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("GrabbedAFZombieCivilian",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		Goto Ready
		
	//LABGALEnd-----------------------------------------------


	//Evil Marine Start------------------------------------------------
	
	PickEvilMarine:	
		TNT1 A 0
		GRZ5 C 1 offset(12, 32)
		GRZ5 C 1 offset(6, 32)
		GRZ5 C 1  A_WeaponReady(WRF_NOSWITCH)
		TNT1 A 0
		TNT1 A 0 A_JumpIfInventory("MeatAmmo", 60, "EvilMarineDie")
		TNT1 A 0 A_SpawnItemEx("MeatShield", 15, 0, 15, 0)
		GRZ5 A 3 A_WeaponReady(WRF_NOSWITCH)
		TNT1 A 0 A_Jump(20, 2)
		Goto PickEvilMarine+5
		TNT1 AAAA 0
		GRZ5 ABACACA 4 A_WeaponReady(WRF_NOSWITCH)
		Goto PickEvilMarine+5
	
	ThrowEvilMarine:
		TNT1 A 0
		TNT1 A 0 A_JumpIfHealthLower(1, "EvilMarineDie")
		GRZ5 D 1 offset(-4, 32)
		GRZ5 D 1 offset(-9, 33)
		GRZ5 D 1 offset(-16, 34)
		GRZ5 D 2 offset(-24, 35)
		GRZ5 D 3 offset(-36, 48)
		GRZ5 D 1 offset(-24, 35)
		GRZ5 B 1 offset(-16, 34)
		GRZ5 B 1 offset(-9, 33)
		GRZ5 B 1 offset(-1, 32)
		TNT1 A 0 A_PlaySound("skeleton/swing")
		TNT1 A 0 A_FireCustomMissile("ThrowedEvilMarine", 0, 0, 0, 0)
		TNT1 A 0 A_TakeInventory("GoSpecial",1)
		TNT1 A 0 A_TakeInventory("GotMeatShield", 1)
		TNT1 A 0 A_TakeInventory("HasZmanShield",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("GrabbedAEvilMarine",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
        THEF BCDEF 1 
		TNT1 A 10
		TNT1 A 0 A_TakeInventory("StartDualWield", 1)
		Goto Ready
		
	ShieldEvilMarine:
		TNT1 A 0 A_TakeInventory("GrabbedAEvilMarine",1)
		TNT1 A 0 A_TakeInventory("GrabbedAImp",1)
		TNT1 A 0 A_GiveInventory("EvilMarineShield",1)
		GRZ5 A 1 offset(0,40)
		GRZ5 A 1 offset(0,48)
		TNT1 A 0 A_SelectWeapon("EvilMarineShield")
		TNT1 A 1 A_WeaponReady(WRF_NOFIRE)
		Goto Ready
		
	EvilMarineDie:
		TNT1 A 0
		TNT1 A 0 A_SpawnItem("SargeXDeath", 0, 40)
		TNT1 A 0 A_TakeInventory("GoSpecial",1)
		TNT1 A 0 A_TakeInventory("GotMeatShield", 1)
		TNT1 A 0 A_TakeInventory("HasZmanShield",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("GrabbedAEvilMarine",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		Goto Ready	
		
		
	//Evil Marine End------------------------------------------------	
	//Nazi Start------------------------------------------------
	
	PickNazi:	
		TNT1 A 0
		GRZ6 C 1 offset(12, 32)
		GRZ6 C 1 offset(6, 32)
		GRZ6 C 1  A_WeaponReady(WRF_NOSWITCH)
		TNT1 A 0
		TNT1 A 0 A_JumpIfInventory("MeatAmmo", 60, "NaziDie")
		TNT1 A 0 A_SpawnItemEx("MeatShield", 15, 0, 15, 0)
		GRZ6 A 3 A_WeaponReady(WRF_NOSWITCH)
		TNT1 A 0 A_Jump(20, 2)
		Goto PickNazi+5
		TNT1 AAAA 0
		GRZ6 ABACACA 4 A_WeaponReady(WRF_NOSWITCH)
		Goto PickNazi+5
	
	ThrowNazi:
		TNT1 A 0
		TNT1 A 0 A_JumpIfHealthLower(1, "NaziDie")
		GRZ6 D 1 offset(-4, 32)
		GRZ6 D 1 offset(-9, 33)
		GRZ6 D 1 offset(-16, 34)
		GRZ6 D 2 offset(-24, 35)
		GRZ6 D 3 offset(-36, 48)
		GRZ6 D 1 offset(-24, 35)
		GRZ6 B 1 offset(-16, 34)
		GRZ6 B 1 offset(-9, 33)
		GRZ6 B 1 offset(-1, 32)
		TNT1 A 0 A_PlaySound("skeleton/swing")
		TNT1 A 0 A_FireCustomMissile("ThrowedNazi", 0, 0, 0, 0)
		TNT1 A 0 A_TakeInventory("GoSpecial",1)
		TNT1 A 0 A_TakeInventory("GotMeatShield", 1)
		TNT1 A 0 A_TakeInventory("HasZmanShield",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("GrabbedANazi",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
        THEF BCDEF 1 
		TNT1 A 10
		TNT1 A 0 A_TakeInventory("StartDualWield", 1)
		Goto Ready
		
	ShieldNazi:
		TNT1 A 0 A_TakeInventory("GrabbedANazi",1)
		TNT1 A 0 A_TakeInventory("GrabbedAImp",1)
		TNT1 A 0 A_GiveInventory("NaziShield",1)
		GRZ6 A 1 offset(0,40)
		GRZ6 A 1 offset(0,48)
		TNT1 A 0 A_SelectWeapon("NaziShield")
		TNT1 A 1 A_WeaponReady(WRF_NOFIRE)
		Goto Ready
		
	NaziDie:
		TNT1 A 0
		TNT1 A 0 A_SpawnItem("SargeXDeath", 0, 40)
		TNT1 A 0 A_TakeInventory("GoSpecial",1)
		TNT1 A 0 A_TakeInventory("GotMeatShield", 1)
		TNT1 A 0 A_TakeInventory("HasZmanShield",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_TakeInventory("GrabbedANazi",1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		Goto Ready		



	}
}
//xxx


ACTOR Laserdot
{ 
	Decal "None"
    Mass 0
    Scale 0.1
    Radius 1
    Height 2
    +NOBLOCKMAP
    +NOGRAVITY
    +BLOODLESSIMPACT
    +ALWAYSPUFF
    +PUFFONACTORS
    +DONTSPLASH
    +FORCEXYBILLBOARD
    Renderstyle Add
    Alpha 0.75
    States
    {
	Spawn:
		LEYS G 0
		LEYS G 1 BRIGHT
		Stop
	}
}




