//// --------------------------------------------------------------------------
//
// Revolver
//ready+12
// --------------------------------------------------------------------------

Actor shellbox_rep: RandomSpawner replaces ShellBox
{
	DropItem "AmmoShellBox" 256 7
	DropItem "Revolver" 256 1
}

ACTOR Revolver : BrutalWeapon
{
	Weapon.AmmoUse1 0
	Weapon.AmmoGive1 6
	Weapon.AmmoUse2 0
	Weapon.AmmoGive2 0
	Weapon.AmmoType1 "Clip1"
	Weapon.AmmoType2 "RevolverAmmo"
	Weapon.Kickback 200
	Obituary "%o was shot down by %k's revolver."
    AttackSound "None"
    Inventory.PickupSound "CLIPIN"
	Inventory.Pickupmessage "You got the Revolver!"
	+WEAPON.WIMPY_WEAPON
    +WEAPON.NOAUTOAIM
    +FORCEXYBILLBOARD
    +WEAPON.NOALERT
    +WEAPON.NOAUTOFIRE
    Scale 0.9
	States
	{    
	PickUp:
	TNT1 A 0
	TNT1 A 0 A_Playsound("PICKUPONELINER")
	TNT1 A 0
	Stop
	
	Steady:
	TNT1 A 1
	Goto Ready
	
	
Ready3:
	Ready:
        TNT1 A 1 A_JumpIfInventory("GoFatality", 1, "Steady")
        TNT1 AAAAAAAA 0
        TNT1 A 0 //A_JumpIfInventory("RifleAmmo",1,2)
        //Goto Reload
        TNT1 AAAA 0
        TNT1 A 0 A_JumpIfInventory("Kicking",1,"DoKick")
        TNT1 A 0 A_JumpIfInventory("ExecuteDownedEnemy", 1, "DoExecution")
        TNT1 A 0 A_JumpIfInventory("Taunting",1,"Taunt")
		TNT1 A 0 A_JumpIfInventory("Salute1", 1, "Salute")
		TNT1 A 0 A_JumpIfInventory("Salute2", 1, "Salute")
        TNT1 A 0 A_JumpIfInventory("Reloading",1,"Reload")
		TNT1 A 0 A_JumpIfInventory("Unloading",1,"Unload")
		TNT1 A 0 A_JumpIfInventory("IsRunning",1,"CheckSprint")
		TNT1 A 0 A_JumpIfInventory("TossGrenade",1,"TossGrenade")
		R1V1 D 4 A_WeaponReady
        //TNT1 A 0 BRIGHT A_FireCustomMissile("Alerter", random(-2,2), 0, -1, 0)
		Goto Ready+9
    Ready2:
    R1V1 D 2 A_WeaponReady(WRF_ALLOWRELOAD)
        TNT1 A 0 A_JumpIfInventory("Kicking",1,"DoKick")
        TNT1 A 0 A_JumpIfInventory("ExecuteDownedEnemy", 1, "DoExecution")
        TNT1 A 0 A_JumpIfInventory("Taunting",1,"Taunt")
        TNT1 A 0 A_JumpIfInventory("Reloading",1,"Reload")
		TNT1 A 0 A_JumpIfInventory("Salute1", 1, "Salute")
		TNT1 A 0 A_JumpIfInventory("Salute2", 1, "Salute")
		TNT1 A 0 A_JumpIfInventory("Unloading",1,"Unload")
		TNT1 A 0 A_JumpIfInventory("IsRunning",1,"CheckSprint")
		TNT1 A 0 A_JumpIfInventory("TossGrenade",1,"TossGrenade")
		Loop
		
		Tryuse:
		TNT1 A 0
		TNT1 A 0 A_TakeInventory("PressedUse", 100)
		RIFF A 0 A_FireCustomMissile("UseAttack", 0, 0, 0, 0, 0, 0)
		RIFF A 0 A_FireCustomMissile("StealthAttack", 0, 0, 0, 0, 0, 0)
		TNT1 A 1
		TNT1 A 0 A_JumpIfInventory("FlashlightOn", 1, "WaitFlashlightOn")
		TNT1 A 0 A_JumpIfInventory("PressedUse", 1, "Interrupt")
		Goto Flash 
		
	Interrupt:	
		TNT1 A 0
		TNT1 A 0 A_TakeInventory("PRessedUse", 1)
		TNT1 A 10
		TNT1 A 0 A_JumpIfInventory("PressedUse", 1, "Interrupt")
		Goto Flash
		
		
		Flash:
		TNT1 A 0
		TNT1 A 0 A_JumpIfInventory("SwitchFlashlight",1,"SwitchFlashlight")
		TNT1 A 0 A_JumpIfInventory("FlashlightOn", 1, "FlashOn")
		TNT1 A 1
		TNT1 A 0 A_JumpIfInventory("PressedUse", 1, "TryUse")
		TNT1 A 3
		TNT1 A 0 A_TakeInventory("UsedStamina", 1)
		Goto Flash
	
	FlashOn:
	    TNT1 A 1 BRIGHT
		TNT1 A 0 A_SpawnItemEx("FlashlightSource", 32, 8, 30)
		TNT1 A 0 A_JumpIfInventory("PressedUse", 1, "TryUse")
		RIFF A 0 A_FireCustomMissile("FlashlightAlerter", 0, 0, 0, 0, 0, 0)
		RIFF A 0 A_FireCustomMissile("FlashlightProjectile", 0, 0, 0, 0, 0, 0)
		RIFF A 0 A_FireCustomMissile("FlashlightProjectile2", 0, 0, 0, 0, 0, 0)
		RIFF A 0 A_FireCustomMissile("FlashlightProjectile3", 0, 0, 0, 0, 0, 0)
		
		TNT1 A 1 BRIGHT
		TNT1 A 0 A_SpawnItemEx("FlashlightSource", 32, 8, 30)
		RIFF A 0 A_FireCustomMissile("FlashlightProjectile", 0, 0, 0, 0, 0, 0)
		RIFF A 0 A_FireCustomMissile("FlashlightProjectile2", 0, 0, 0, 0, 0, 0)
		RIFF A 0 A_FireCustomMissile("FlashlightProjectile3", 0, 0, 0, 0, 0, 0)
		
		TNT1 A 1 BRIGHT
		TNT1 A 0 A_SpawnItemEx("FlashlightSource", 32, 8, 30)
		RIFF A 0 A_FireCustomMissile("FlashlightProjectile", 0, 0, 0, 0, 0, 0)
		RIFF A 0 A_FireCustomMissile("FlashlightProjectile2", 0, 0, 0, 0, 0, 0)
		RIFF A 0 A_FireCustomMissile("FlashlightProjectile3", 0, 0, 0, 0, 0, 0)
		TNT1 A 0 A_JumpIfInventory("PressedUse", 1, "TryUse")
		TNT1 A 1 BRIGHT
		TNT1 A 0 A_SpawnItemEx("FlashlightSource", 32, 8, 30)
		RIFF A 0 A_FireCustomMissile("FlashlightProjectile", 0, 0, 0, 0, 0, 0)
		RIFF A 0 A_FireCustomMissile("FlashlightProjectile2", 0, 0, 0, 0, 0, 0)
		RIFF A 0 A_FireCustomMissile("FlashlightProjectile3", 0, 0, 0, 0, 0, 0)
		
		TNT1 A 0 A_TakeInventory("UsedStamina", 1)
		
		Goto Flash
		
		
	SwitchFlashlight:
		TNT1 A 0
		TNT1 A 0 A_TakeInventory("SwitchFlashlight", 1)
		TNT1 A 0 A_JumpIfInventory("FlashlightOn",1,"TurnFlashOff")
		TNT1 A 0 A_Giveinventory("FlashlightOn",1)
		TNT1 A 0 A_PlaySound("FLASHON", 5)
		
        Goto Flash
	TurnFlashOff:
		TNT1 A 0 A_Takeinventory("FlashlightOn",1)
		TNT1 A 0 A_Light0
		TNT1 A 0 A_PlaySound("FLASHOFF", 5)
        Goto Flash
		
	Deselect:
        R1V1 EFGHI 1
		TNT1 A 0 A_TakeInventory("TossGrenade", 1)
	TNT1 A 1 A_Lower
	Wait

	Select:
		TNT1 A 0 A_Takeinventory("StartDualWield",1)
		TNT1 A 0 A_Giveinventory("GoSpecial",1)
		TNT1 A 0 A_Takeinventory("FistsSelected",1)
		TNT1 A 0 A_Takeinventory("SawSelected",1)
		TNT1 A 0 A_Takeinventory("ShotgunSelected",1)
		TNT1 A 0 A_Takeinventory("SSGSelected",1)
		TNT1 A 0 A_Takeinventory("MinigunSelected",1)
		TNT1 A 0 A_Takeinventory("PlasmaGunSelected",1)
		TNT1 A 0 A_Takeinventory("RocketLauncherSelected",1)
		TNT1 A 0 A_Takeinventory("GrenadeLauncherSelected",1)
		TNT1 A 0 A_Takeinventory("BFGSelected",1)
		TNT1 A 0 A_Takeinventory("BFG10kSelected",1)
		TNT1 A 0 A_Takeinventory("RailGunSelected",1)
		TNT1 A 0 A_Takeinventory("SubMachineGunSelected",1)
		TNT1 A 0 A_Takeinventory("RevenantLauncherSelected",1)
		TNT1 A 0 A_Takeinventory("LostSoulSelected",1)
		TNT1 A 0 A_Takeinventory("FlameCannonSelected",1)
		TNT1 A 0 A_Takeinventory("HasBarrel",1)
	TNT1 A 1
	TNT1 A 1 A_Raise
	TNT1 AAAAAAAAAA 0 A_Raise
	Goto SelectAnimation
	
	SelectAnimation:
	TNT1 A 1
	TNT1 A 0 A_JumpIfInventory("GoFatality", 1, "Steady")
        TNT1 A 0 A_PlaySound("revolver/draw")
         R1V1 ABCD 1
        TNT1 A 0 A_GunFlash
	Goto Ready3
	
    Fire:
        TNT1 A 0 A_JumpIfInventory("RevolverAmmo",1,2)
        Goto Reload
        TNT1 AAAA 0
		R4V1 A 1 BRIGHT A_AlertMonsters
		TNT1 A 0 A_PlaySound("revolver/fire")
		//TNT1 A 0 A_FireCustomMissile("SmokeSpawner",0,0,0,5)
		TNT1 A 0 A_FireCustomMissile("YellowFlareSpawn",0,0,0,0)
		R4V1 B 1 BRIGHT A_FireBullets (0.1, 0.1, -1, 30, "HitPuff")
        R4V1 C 0 A_FireCustomMissile("Tracer", random(-2,2), 0, -1, 0)
        //TNT1 A 0 ACS_Execute(373, 0, 0, 0, 0)
		TNT1 A 0 A_FireCustomMissile("ShakeYourAss", 0, 0, 0, 0)
		TNT1 A 0 A_FireCustomMissile("YellowFlareSpawn",0,0,0,0)
		TNT1 A 0 A_Takeinventory("RevolverAmmo",1)
		R4V1 DEFGH 1 
		R1V1 D 6 A_WeaponReady(1)
		Goto Ready+6
		
  AltFire:
        TNT1 A 0 A_JumpIfInventory("RevolverAmmo",1,2)
        Goto Reload
      R5V1 A 1 BRIGHT A_AlertMonsters
      TNT1 A 0 A_PlaySound("revolver/fire")
      R5V1 B 1 BRIGHT A_FireBullets (0.1, 0.1, -1, 35, "HitPuff")
      R5V1 C 1 A_FireCustomMissile("Tracer", random(-2,2), 0, -1, 0)
      R5V1 DEFG 1 
      TNT1 J 0 A_FireCustomMissile("YellowFlareSpawn",0,0,0,0)
      R5V1 UVWX 1 
	    TNT1 A 0 A_Takeinventory("RevolverAmmo",1)
	    REVF M 0 Offset(0,46) A_Refire
		R1V1 D 0 Offset(0,44)
		R1V1 D 0 Offset(0,41)
		R1V1 D 0 Offset(0,37)
		R1V1 D 0 Offset(0,35)
		R1V1 D 0 Offset(0,34)
		R1V1 D 0 Offset(0,33)
      R1V1 D 6 A_WeaponReady(1)
      Goto Ready+6
TNT1 A 0 A_JumpIfInventory("RevolverAmmo",1,2)
        Goto Reload

		
	NoAmmo:
	R1V1 A 1 A_PlaySound("weapons/empty")
	Goto Ready+12
	
    Reload:
		R1V1 D 5 A_WeaponReady
		TNT1 A 0 A_Takeinventory("Reloading",1)
		TNT1 A 0 A_Takeinventory("ADSmode",1)
		TNT1 A 0 A_JumpIfInventory("RevolverAmmo",6,60)
        TNT1 A 0 A_JumpIfInventory("Clip1",1,3)
        Goto NoAmmo
        TNT1 AAA 0
		TNT1 A 0 A_Takeinventory("Zoomed",1)
        TNT1 A 0 A_ZoomFactor(1.0)
		TNT1 A 0 A_GiveInventory ("Pumping", 1)
		TNT1 A 0 A_Takeinventory("Reloading",1)
        R6V1 ABCDDE 1 
        TNT1 A 0 A_PlaySoundEx("Weapons/Revolver/Open", "Auto")
		R6V1 FGHI 1
	    R6V1 J 1 
		R6V1 KLMNO 1 
		TNT1 A 0 A_PlaySoundEx("Weapons/Revolver/Click2", "Auto")
        R6V1 PQRS 1 
		TNT1 AAAAAA 0 A_FireCustomMissile("RifleCaseSpawn",-2,0,8,0)
        R6V1 T 1
		R6V1 U 1
		R6V1 VWXYZ 1
		R6V2 A 1 A_PlaySoundEx("Weapons/Revolver/Load", "Auto")
		R6V2 BCDEFF 1 
		TNT1 A 0 A_PlaySoundEx("CYLNSPIN", "Auto")
		R6V2 GHI 1
		TNT1 A 0 A_PlaySoundEx("Weapons/Revolver/Close", "Auto")
		R6V2 JKLMNOPQQ 1
		TNT1 A 0 A_TakeInventory("HasUnloaded", 1)
		
		InsertBullets:
		TNT1 AAAA 0
		TNT1 A 0 A_JumpIfInventory("RevolverAmmo",6,15)
		TNT1 A 0 A_JumpIfInventory("Clip1",1,3)
		Goto Ready+6
        TNT1 AAAAAA 0
		TNT1 A 0 A_Giveinventory("RevolverAmmo",1)
		TNT1 A 0 A_Takeinventory("Clip1",1)
		Goto InsertBullets
		
		TNT1 AAAAAAAAAA 0
		TNT1 A 0 A_Takeinventory("Reloading",1)
        Goto Ready+6
		TNT1 AAAA 0
				TNT1 A 0 A_Takeinventory("Reloading",1)
        Goto Ready+6
 	Spawn:
		RVIC A -1
		Stop
		
	CheckSprint:
		R1V1 D 1 A_WeaponReady(WRF_NOFIRE)
		R1V1 D 0 A_JumpIfInventory("IsStandingStill", 1, "Ready3")
		R1V1 D 0 A_JumpIfInventory("IsTacticalClass", 1, "StartSprint")
		Goto Ready3
		
	CheckSprint2:
		RI2G A 1 A_WeaponReady(WRF_NOFIRE)
		R1V1 D 0 A_JumpIfInventory("IsStandingStill", 1, "Ready3")
		R1V1 D 0 A_JumpIfInventory("IsTacticalClass", 1, "StartSprint")
		Goto Ready2	
		
	StartSprint:
		R6V1 E 1 A_WeaponReady(WRF_NOFIRE)
		R6V1 E 0 A_Takeinventory("Zoomed",1)
		R6V1 E 0 A_Takeinventory("ADSmode",1)
		R6V1 E 0 A_ZoomFactor(1.0)
		R6V1 E 0 A_JumpIfInventory("UsedStamina", 40, "StopSprintTired")
		
	Sprinting:	
		R6V1 E 0 offset(-9,32) 
		R6V1 E 0 offset(-9,32) A_JumpIfInventory("IsStandingStill", 1, "Ready3")
		R6V1 E 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.
		R6V1 E 0 offset(-9,32) A_JumpIfInventory("PowerStrength", 1, 2)
		R6V1 E 0 offset(-9,32) A_GiveInventory("UsedStamina", 6)
		R6V1 E 0 offset(-9,32)
		R6V1 E 1 offset(-9,34) A_SetPitch(pitch -0.5)
		R6V1 E 1 offset(-6,36) A_SetPitch(pitch -0.5)
		R6V1 E 1 offset(-3,38) A_SetPitch(pitch -0.5)
		R6V1 E 1 offset(0,38) A_SetPitch(pitch -0.5)
		R6V1 E 1 offset(3,36) A_SetPitch(pitch -0.5)
		R6V1 E 1 offset(6,34) A_SetPitch(pitch -0.5)
		R6V1 E 1 offset(9,32) A_SetPitch(pitch -0.5)
		R6V1 E 0 offset(9,32) A_WeaponReady(WRF_NOBOB)
		R6V1 E 0 A_JumpIfInventory("Kicking",1,"DoKick")
        R6V1 E 0 A_JumpIfInventory("Taunting",1,"Taunt")
        R6V1 E 0 A_JumpIfInventory("Reloading",1,"Reload")
		R6V1 E 0 offset(-9,32) A_GiveInventory("UsedStamina", 6)
		R6V1 E 0 offset(9,33) A_SpawnItemEx("FootStep", 0, 0, 2, 0, 0, -4)
		R6V1 E 1 offset(9,34) A_SetPitch(pitch +0.5)
		R6V1 E 1 offset(6,36) A_SetPitch(pitch +0.5)
		R6V1 E 1 offset(3,38) A_SetPitch(pitch +0.5)
		R6V1 E 1 offset(0,38) A_SetPitch(pitch +0.5)
		R6V1 E 1 offset(-3,36) A_SetPitch(pitch +0.5)
		R6V1 E 1 offset(-6,34) A_SetPitch(pitch +0.5)
		R6V1 E 1 offset(-9,32) A_SetPitch(pitch +0.5)
		R6V1 E 0 offset(-9,32) A_WeaponReady(WRF_NOBOB)
		R6V1 E 0 offset(-9,32) A_JumpIfInventory("IsRunning", 1, "Sprinting")
		
		Goto StopSprint
	StopSprintTired:
		R1V1 D 1
		PLAY A 0 ACS_ExecuteAlways(853, 0, 0, 0, 0)//Makes player slower.
		R1V1 D 0 A_PlaySound("Tired", 2)
		R1V1 D 0 A_TakeInventory("UsedStamina", 2)
		R1V1 D 5 A_WeaponReady
		R1V1 D 0 A_TakeInventory("UsedStamina", 2)
		R1V1 D 5 A_WeaponReady
		R1V1 D 0 A_TakeInventory("UsedStamina", 2)
		R1V1 D 5 A_WeaponReady
		R1V1 D 0 A_TakeInventory("UsedStamina", 2)
		R1V1 D 5 A_WeaponReady
		R1V1 D 0 A_TakeInventory("UsedStamina", 2)
		R1V1 D 5 A_WeaponReady
		Goto Ready3
	StopSprint:
		R1V1 D 1
		R1V1 D 0 A_JumpIfInventory("UsedStamina", 60, "StopSprintTired")
		PLAY A 0 ACS_ExecuteAlways(853, 0, 0, 0, 0)//Makes player slower.
		Goto Ready3
		
	
		////////////////////////////////////////Unloading	

	AlreadyUnloaded:
		R1V1 A 0 A_Takeinventory("Unloading",1)
		Goto Ready+12
	
	Unload:
		R1V1 D 1 A_WeaponReady
		TNT1 A 0 A_JumpIfInventory("HasUnloaded", 1, "AlreadyUnloaded")
		TNT1 A 0 A_ZoomFactor(1.0)
		TNT1 A 0 A_Takeinventory("Unloading",1)
		TNT1 A 0 A_Takeinventory("ADSmode",1)
		TNT1 A 0 A_Takeinventory("Zoomed",1)
        TNT1 A 0 A_JumpIfInventory("RevolverAmmo",1,3)
        Goto Ready+10
        TNT1 AAA 0
		TNT1 A 0 A_Takeinventory("Zoomed",1)
		//TNT1 A 0 A_PlaySound("barrel/open", 1)
		//TNT1 A 0 A_PlaySound("Reload")
        R7V1 ABCDDE 1 
		TNT1 A 0 A_PlaySoundEx("Weapons/Revolver/Open", "Auto")
		TNT1 AAAAAA 0 A_FireCustomMissile("RifleCaseSpawn",-2,0,8,0)
		R7V1 FGHI 1 
		R7V1 J 1 
		R7V1 KLMNO 1
		TNT1 A 0 A_PlaySoundEx("Weapons/Revolver/Click2", "Auto")
		R7V1 PQRST 1 
		R7V1 U 1 
		R7V1 VWXYZ 1 
		R7V2 ABCCDE 1 
		TNT1 A 0 A_PlaySoundEx("Weapons/Revolver/Close", "Auto")
		R7V2 EFGHII 1 
		
		TNT1 A 0 A_GiveInventory ("Pumping", 1)
		TNT1 A 0 A_Takeinventory("Unloading",1)
		
	RemoveBullets:
		TNT1 AAAA 0
		TNT1 A 0 A_JumpIfInventory("RevolverAmmo",1,3)
		Goto FinishUnload
        TNT1 AAAAAA 0
		TNT1 A 0 A_Takeinventory("RevolverAmmo",1)
		TNT1 A 0 A_Giveinventory("Clip1",1)
		Goto RemoveBullets
	
	FInishUnload:
		R1V1 D 1
		//TNT1 A 0 A_PlaySound("barrel/close", 1)
		TNT1 A 0 A_GiveInventory("HasUnloaded", 1)
		TNT1 A 0 A_Takeinventory("Unloading",1)
		Goto Ready+12
		
////////////////////////////////////////Unloading	


     DoKick:
		TNT1 AA 1 A_JumpIfInventory("GoFatality", 1, "Steady")
		TNT1 A 0 A_Takeinventory("HasPlasmaWeapon",1)
		TNT1 A 0 A_TAkeinventory("HasCutingWeapon",1)
		TNT1 A 0 A_Takeinventory("Zoomed",1)
		TNT1 A 0 A_Takeinventory("PowerLightAmp",1)
        TNT1 A 0 A_ZoomFactor(1.0)
		TNT1 A 0 A_Takeinventory("ADSmode",1)
		
		TNT1 A 0 A_JumpIfInventory("ExecuteDownedEnemy", 1, "DoExecution")
		NULL A 0 A_JumpIf (momZ > 0, "AirKick")
		NULL A 0 A_JumpIf (momZ < 0, "AirKick")
		TNT1 A 0 A_JumpIfInventory("IsCrouching", 1, "SlideAttack")
		
        TNT1 A 0 A_jumpifinventory("PowerStrength",1,"BerserkerKick")
		//TNT1 A 0 A_JumpIfInventory("RifleSelected", 1, "RifleBash")
		TNT1 A 0 A_PlaySound("KICK")
		TNT1 A 0 SetPlayerProperty(0,1,0)
		KICK BCD 1
		RIFF A 0 A_FireCustomMissile("KickAttack", 0, 0, 0, -7)
        KICK H 5
		KICK A 0 A_Takeinventory("Kicking",1)
		KICK I 1
		KICK GFEDCBA 1 
		TNT1 A 0 SetPlayerProperty(0,0,0)
		TNT1 A 0 A_JumpIfInventory("ExecuteDownedEnemy", 1, "DoExecution")
		TNT1 A 0 A_JumpIfInventory("GoFatality", 1, "Steady")
		RIBA A 0 A_Takeinventory("Kicking",1)
		Goto SelectingAnimation
		
	
    BerserkerKick:
		TNT1 A 0 A_PlaySound("KICK")
		TNT1 A 0 SetPlayerProperty(0,1,0)
		KICK BCD 1
        RIFF A 0 A_FireCustomMissile("SuperKickAttack", 0, 0, 0, -7)
        KICK H 5
		KICK A 0 A_Takeinventory("Kicking",1)
		KICK I 1
		KICK GFEDCBA 1 
		TNT1 A 0 SetPlayerProperty(0,0,0)
		TNT1 A 0 A_JumpIfInventory("ExecuteDownedEnemy", 1, "DoExecution")
		TNT1 A 0 A_JumpIfInventory("GoFatality", 1, "Steady")
		RIBA A 0 A_Takeinventory("Kicking",1)
		Goto GoingToReady
	
	AirKick:
	    TNT1 A 0 A_jumpifinventory("PowerStrength",1,"SuperAirKick")
		TNT1 A 0 A_PlaySound("KICK")
		TNT1 A 0 A_Recoil (-6)
		KICK JKLMN 1
        RIFF A 0 A_FireCustomMissile("AirKickAttack", 0, 0, 0, -31)
        KICK O 3
		KICK A 0 A_Takeinventory("Kicking",1)
		KICK PQRST 2
		TNT1 A 0 A_JumpIfInventory("ExecuteDownedEnemy", 1, "DoExecution")
		TNT1 A 0 A_JumpIfInventory("GoFatality", 1, "Steady")
		RIBA A 0 A_Takeinventory("Kicking",1)
		Goto GoingToReady
		
	SuperAirKick:
		TNT1 A 0 A_PlaySound("KICK")
		TNT1 A 0 A_Recoil (-6)
		KICK JKLMN 1
        RIFF A 0 A_FireCustomMissile("SuperAirKickAttack", 0, 0, 0, -31)
        KICK O 3
		KICK A 0 A_Takeinventory("Kicking",1)
		KICK PQRST 2
		TNT1 A 0 A_JumpIfInventory("ExecuteDownedEnemy", 1, "DoExecution")
		TNT1 A 0 A_JumpIfInventory("GoFatality", 1, "Steady")
		RIBA A 0 A_Takeinventory("Kicking",1)
		Goto GoingToReady
	
	SlideAttack:
		TNT1 A 0 SetPlayerProperty(0,1,0)
		KICK A 0 A_Takeinventory("Kicking",1)
		TNT1 A 0 A_PlaySound("KICK")
		TNT1 A 0 A_Recoil (-6)
		TNT1 A 0 A_PlaySound("SlideKickStart", 5)
		KICK LMN 1
		TNT1 A 0 A_SetPItch(10)
        RIFF A 0 A_FireCustomMissile("SlideAttack", 0, 0, 0, 10)
        KICK O 1
		TNT1 A 0 A_Recoil (-2)
		TNT1 A 0 A_SetPItch(10)
		TNT1 A 0 A_JumpIfInventory("KickHasHit", 1, "FinishSlideHitWall")
		TNT1 A 0 A_JumpIfInventory("IsCrouching", 1, 1)
		Goto FinishSlide
		KICK O 1 A_FireCustomMissile("SlideAttack", 0, 0, 0, 10)
		TNT1 A 0 A_Recoil (-2)
		TNT1 A 0 A_SetPItch(10)
		TNT1 A 0 A_JumpIfInventory("KickHasHit", 1, "FinishSlideHitWall")
		TNT1 A 0 A_JumpIfInventory("IsCrouching", 1, 1)
		Goto FinishSlide
		
		KICK O 1 A_FireCustomMissile("SlideAttack", 0, 0, 0, 10)
		TNT1 A 0 A_Recoil (-2)
		TNT1 A 0 A_SetPItch(10)
		TNT1 A 0 A_JumpIfInventory("KickHasHit", 1, "FinishSlideHitWall")
		TNT1 A 0 A_JumpIfInventory("IsCrouching", 1, 1)
		Goto FinishSlide
		
		KICK O 1 A_FireCustomMissile("SlideAttack", 0, 0, 0, 10)
		TNT1 A 0 A_Recoil (-2)
		TNT1 A 0 A_SetPItch(10)
		TNT1 A 0 A_JumpIfInventory("KickHasHit", 1, "FinishSlideHitWall")
		TNT1 A 0 A_JumpIfInventory("IsCrouching", 1, 1)
		Goto FinishSlide
		
		KICK O 1 A_FireCustomMissile("SlideAttack", 0, 0, 0, 10)
		TNT1 A 0 A_Recoil (-2)
		TNT1 A 0 A_SetPItch(10)
		TNT1 A 0 A_JumpIfInventory("KickHasHit", 1, "FinishSlideHitWall")
		TNT1 A 0 A_JumpIfInventory("IsCrouching", 1, 1)
		Goto FinishSlide
		
		KICK O 1 A_FireCustomMissile("SlideAttack", 0, 0, 0, 10)
		TNT1 A 0 A_Recoil (-2)
		TNT1 A 0 A_SetPItch(10)
		TNT1 A 0 A_JumpIfInventory("KickHasHit", 1, "FinishSlideHitWall")
		TNT1 A 0 A_JumpIfInventory("IsCrouching", 1, 1)
		Goto FinishSlide
		
		KICK O 1 A_FireCustomMissile("SlideAttack", 0, 0, 0, 10)
		TNT1 A 0 A_Recoil (-2)
		TNT1 A 0 A_SetPItch(10)
		TNT1 A 0 A_JumpIfInventory("KickHasHit", 1, "FinishSlideHitWall")
		TNT1 A 0 A_JumpIfInventory("IsCrouching", 1, 1)
		Goto FinishSlide
		
		KICK O 1 A_FireCustomMissile("SlideAttack", 0, 0, 0, 10)
		TNT1 A 0 A_Recoil (-2)
		TNT1 A 0 A_SetPItch(10)
		TNT1 A 0 A_JumpIfInventory("KickHasHit", 1, "FinishSlideHitWall")
		TNT1 A 0 A_JumpIfInventory("IsCrouching", 1, 1)
		Goto FinishSlide
		
		KICK O 1 A_FireCustomMissile("SlideAttack", 0, 0, 0, 10)
		TNT1 A 0 A_Recoil (-2)
		TNT1 A 0 A_SetPItch(10)
		TNT1 A 0 A_JumpIfInventory("KickHasHit", 1, "FinishSlideHitWall")
		TNT1 A 0 A_JumpIfInventory("IsCrouching", 1, 1)
		Goto FinishSlide
		
		KICK O 1 A_FireCustomMissile("SlideAttack", 0, 0, 0, 10)
		TNT1 A 0 A_Recoil (-2)
		TNT1 A 0 A_SetPItch(10)
		TNT1 A 0 A_JumpIfInventory("KickHasHit", 1, "FinishSlideHitWall")
		TNT1 A 0 A_JumpIfInventory("IsCrouching", 1, 1)
		Goto FinishSlide
		
		KICK O 1 A_FireCustomMissile("SlideAttack", 0, 0, 0, 10)
		TNT1 A 0 A_Recoil (-2)
		TNT1 A 0 A_SetPItch(10)
		TNT1 A 0 A_JumpIfInventory("KickHasHit", 1, "FinishSlideHitWall")
		TNT1 A 0 A_JumpIfInventory("IsCrouching", 1, 1)
		Goto FinishSlide
		
		KICK O 1 A_FireCustomMissile("SlideAttack", 0, 0, 0, 10)
		TNT1 A 0 A_Recoil (-2)
		TNT1 A 0 A_SetPItch(10)
		TNT1 A 0 A_JumpIfInventory("KickHasHit", 1, "FinishSlideHitWall")
		TNT1 A 0 A_JumpIfInventory("IsCrouching", 1, 1)
		Goto FinishSlide
		
		KICK O 1 A_FireCustomMissile("SlideAttack", 0, 0, 0, 10)
		TNT1 A 0 A_Recoil (-2)
		TNT1 A 0 A_SetPItch(10)
		TNT1 A 0 A_JumpIfInventory("KickHasHit", 1, "FinishSlideHitWall")
		TNT1 A 0 A_JumpIfInventory("IsCrouching", 1, 1)
		TNT1 A 0 A_TAkeInventory("KickHasHit", 1)
		Goto FinishSlide
		
		
	FinishSlide:	
		TNT1 A 0
		TNT1 A 0 A_PlaySound("SlideKickStop", 5)
		KICK PQRST 2
		TNT1 A 0 A_JumpIfInventory("ExecuteDownedEnemy", 1, "DoExecution")
		TNT1 A 0 A_JumpIfInventory("GoFatality", 1, "Steady")
		RIBA A 0 A_Takeinventory("Kicking",1)
		TNT1 A 0 SetPlayerProperty(0,0,0)
		Goto GoingToReady	
		
	FinishSlideHitwall:	
		TNT1 A 0
		TNT1 A 0 A_Stop
		KICK PQRST 2
		TNT1 A 0 A_TAkeInventory("KickHasHit", 1)
		TNT1 A 0 A_JumpIfInventory("ExecuteDownedEnemy", 1, "DoExecution")
		TNT1 A 0 A_JumpIfInventory("GoFatality", 1, "Steady")
		RIBA A 0 A_Takeinventory("Kicking",1)
		TNT1 A 0 SetPlayerProperty(0,0,0)
		Goto GoingToReady		

    Taunt:
		TNT1 A 0 A_Takeinventory("Zoomed",1)
        TNT1 A 0 A_ZoomFactor(1.0)
		TNT1 A 0 A_Takeinventory("Taunting",1)
		
        TNT1 A 10
		TNT1 A 0 A_JumpIfInventory("IsPlayingAsPurist", 1, "TauntClassic")
		FUCK A 1
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", 0, 0, -1, 0)
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", -9, 0, -1, 0)
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", 9, 0, -1, 0)
		TNT1 A 0 A_JumpIfInventory("GenderFemale", 1, "TauntFemale")
        FUCK B 1 A_PlaySound("FUCK", 2)
        FUCK CD 1 A_AlertMonsters
		FUCK E 15 A_Takeinventory("Taunting",1)
        FUCK DCBA 1
        TNT1 A 10
		Goto GoingToReady 
		
	TauntFemale:
		TNT1 A 0
		FUCK B 1 A_PlaySound("FTAUNT", 2)
        FUCK CD 1 A_AlertMonsters
		FUCK E 15 A_Takeinventory("Taunting",1)
        FUCK DCBA 1
        TNT1 A 10
		Goto GoingToReady
		
		
		
	TauntClassic:
		
		FVCK A 1
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", 0, 0, -1, 0)
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", -9, 0, -1, 0)
		TNT1 A 0 BRIGHT A_FireCustomMissile("Taunter", 9, 0, -1, 0)
		TNT1 A 0 A_JumpIfInventory("GenderFemale", 1, "TauntFemaleClassic")
        FVCK B 1 A_PlaySound("FUCK", 2)
        FVCK CD 1 A_AlertMonsters
		FVCK E 15 A_Takeinventory("Taunting",1)
        FVCK DCBA 1
        TNT1 A 10
		Goto GoingToReady 
		
	TauntFemaleClassic:
		TNT1 A 0
		FVCK B 1 A_PlaySound("FTAUNT", 2)
        FVCK CD 1 A_AlertMonsters
		FVCK E 15 A_Takeinventory("Taunting",1)
        FVCK DCBA 1
        TNT1 A 10
		Goto GoingToReady	
		
		
		
	Salute:
	    TNT1 A 0 SetPlayerProperty(0,1,0)
		TNT1 A 0 A_ALertMonsters
		NULL A 0 ACS_NamedExecuteAlways("BDStartCamera", 0, 0, 0, 0)//Start Camera
		SALU ABCDEDCDEDCDEDCBA 4
		MARN A 0 ACS_NamedExecuteAlways("BDStopCamera", 0, 0, 0, 0)//Stop Camera
		TNT1 A 0 A_TakeInventory("Salute1",1)
		TNT1 A 0 A_TakeInventory("Salute2",1)
		TNT1 A 0 SetPlayerProperty(0,0,0)
		Goto GoingToReady
	TossGrenade:	
		"----" A 2
		"----" A 0 A_TakeInventory("TossGrenade", 1)
		"----" A 0 A_JumpIfInventory("GrenadeAmmo", 1, 4)
		"----" A 0 A_Print("No Grenades Left.")
		"----" A 0 A_Jump(256, "Ready3")
		"----" AAAAA 0
		"----" A 4
		"----" A 0 A_Takeinventory("HasPlasmaWeapon",1)
		TNT1 A 0 A_TAkeinventory("HasCutingWeapon",1)
		TNT1 A 0 A_Takeinventory("Zoomed",1)
		TNT1 A 0 A_Takeinventory("PowerLightAmp",1)
        TNT1 A 0 A_ZoomFactor(1.0)
		TNT1 A 0 A_Takeinventory("ADSmode",1)
		TNT1 A 0 A_JumpIfInventory("IsPlayingAsPurist", 1, "TossGrenadeClassic")
		GRTH ABCD 1
		TNT1 A 0 A_GiveInventory("FiredGrenade", 1)
		TNT1 A 0 A_Giveinventory("Punching",1)
		TNT1 A 0 A_Giveinventory("GoSpecial",1)
		TNT1 A 0 A_PLaySound ("GRNPIN")
		GRTH EEFG 1
		TNT1 A 0 A_PLaySound ("GRNTOSS")
		GRTH HI 1
		TNT1 A 0 A_TakeInventory("GrenadeAmmo", 1)
		TNT1 A 0 A_FireCustomMissile("FakeGrenade", 0, 0, 0, 0, 0, 0)
	    TNT1 A 0 A_TakeInventory("FiredGrenade", 1)
		GRTH J 1 
		TNT1 A 0 A_FireCustomMissile("HandGrenade", 0, 0, 0, 0, 0, 0)
		GRTH KLM 1
		TNT1 A 1 
		TNT1 A 0 A_TakeInventory("TossGrenade", 1)
		Goto GoingToReady	
		
		
		
	TossGrenadeClassic:	
		
		PRTH ABCD 1
		TNT1 A 0 A_GiveInventory("FiredGrenade", 1)
		TNT1 A 0 A_PLaySound ("GRNPIN")
		PRTH EEFG 1
		TNT1 A 0 A_PLaySound ("GRNTOSS")
		PRTH HI 1
		TNT1 A 0 A_TakeInventory("GrenadeAmmo", 1)
		TNT1 A 0 A_FireCustomMissile("HandGrenade", random(-2,2), 0, 0, 0, 0, 0)
	    TNT1 A 0 A_TakeInventory("FiredGrenade", 1)
		PRTH JKLM 1
		TNT1 A 1 
		TNT1 A 0 A_TakeInventory("TossGrenade", 1)
		Goto GoingToReady		
		
		
		
		
		
	DoExecution:
		TNT1 A 0 A_SetPitch(65)
		TNT1 A 1
		TNT1 A 0 A_ChangeFLag("NOPAIN", 1)
		TNT1 A 0 A_ChangeFLag("PUSHABLE", 0)
		TNT1 A 0 A_Stop
		TNT1 A 0 SetPlayerProperty(0,1,4)
		KICK A 0 A_Takeinventory("Kicking",1)
		KICK A 0 A_Takeinventory("ExecuteDownedEnemy",1)
		TNT1 A 0 A_JumpIfInventory("IsFloating", 1, "ExecuteAirStomp")
		TNT1 A 0 A_JumpIfInventory("ExecuteBashWall", 1, "BashWall")
		TNT1 A 0 A_JumpIfInventory("ExecuteStompWall", 1, "StompWall")
		
		TNT1 AAAAA 1 A_SetPitch(70)
		TNT1 A 0 A_Jump(255, "Execution1", "Execution2")
		Goto Execution1
	
	Stompwall:
		TNT1 A 0 A_Stop
		//TTNT1 A 0 A_JumpIfInventory("IsFloating", 1, "ExecuteAirStomp")
		TNT1 A 0 A_SetPitch(10)
		TNT1 A 0 A_Recoil(-1)

		KICK JKLMN 1 A_Recoil(-1)
        RIFF A 0 A_FireCustomMissile("ExecutionAttackStompWall", 0, 0, 0, -7)
		
        KICK OOO 2  A_Recoil(-1)
		KICK A 0 A_Takeinventory("Kicking",1)
		KICK PQRST 1
		
		KICK A 0 A_Takeinventory("ExecuteStompWall",1)
		KICK A 0 A_Takeinventory("ExecuteBashWall",1)
		TNT1 A 5
		Goto FinishExecution+8
		
			
	Bashwall:
		TNT1 A 0
		//TTNT1 A 0 A_JumpIfInventory("IsFloating", 1, "ExecuteAirStomp")
		TNT1 A 0 A_PlaySound("imp/pain", 4)
		TNT1 A 0 A_SetPitch(10)
		TNT1 A 0 A_ZoomFactor(1.3)
		IEHW A 2
		TNT1 A 0 A_ZoomFactor(1.0)
		IEHW A 8
		IEHW AAA 1 A_SetAngle(angle+6)
		IEHW BCDEF 1 A_SetAngle(angle+6)
		IEHW G 3
		TNT1 AA 0 A_CustomMissile("XDeath1", 48, 0, 45, 2)
		TNT1 A 0 A_PlaySound("imp/pain", 4)
		TNT1 A 0 A_CustomMissile("KickAttack", 48, 0, 45, 2)
		
		IEHW HIJKKK 1 A_SetAngle(angle-3)
		IEHW KKKJIH 1 A_SetAngle(angle+3)
		IEHW FG 3
		TNT1 AA 0 A_CustomMissile("XDeath1", 48, 0, 45, 2)
		TNT1 A 0 A_PlaySound("imp/pain", 4)
		TNT1 A 0 A_CustomMissile("KickAttack", 48, 0, 45, 2)
		
		IEHW HIJKKK 1 A_SetAngle(angle-3)
		IEHW KKKJIH 1 A_SetAngle(angle+3)
		IEHW FG 3
		TNT1 AA 0 A_CustomMissile("XDeath1", 48, 0, 45, 2)
		TNT1 A 0 A_PlaySound("imp/pain", 4)
		TNT1 A 0 A_CustomMissile("KickAttack", 48, 0, 45, 2)
		
		IEHW HIJKKK 1 A_SetAngle(angle-3)
		IEHW KKKJIH 1 A_SetAngle(angle+3)
		TNT1 AA 0 A_CustomMissile("XDeath1", 48, 0, 45, 2)
		TNT1 A 0 A_CustomMissile("ImpHeadExplode", 48, 0, 45, 2)
		TNT1 A 0 A_CustomMissile("XDeath2", 48, 0, 45, 2)
		TNT1 AAA 0 A_CustomMissile("KickAttack", 48, 0, 45, 2)
		IEHW LMNO 1
		IEHW O 6
		IEHW PQRST 2 A_SetAngle(angle-4)
		TNT1 A 0 A_SpawnItem ("GrowingBloodPool")
		TNT1 A 0 A_SpawnItem("DeadImp_NoHead")
		TNT1 AAA 1 A_SetAngle(angle-3)
		
		KICK A 0 A_Takeinventory("Kicking",1)
		KICK A 0 A_Takeinventory("ExecuteBashWall",1)
		KICK A 0 A_Takeinventory("ExecuteStompWall",1)
		
		TNT1 A 5
		Goto FinishExecution+8	
		
	ExecuteAirStomp:
		TNT1 A 0
		TNT1 A 0 A_Stop
		TNT1 A 0 A_GiveInventory("IsExecutingOnAir", 1)
		TNT1 A 0 ThrustThingZ(0, 10, 0, 1)
		STOM ABCCCCC 1 A_SetPitch(80)
		STOM CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC 1 A_CheckFloor("DoAirStomp")
	DoAirStomp:
		RIFF AAA 0 A_FireCustomMissile("ExecutionAttackKick", 0, 0, 0, 0)
        STOM D 5
		TNT1 A 0 ThrustThingZ(0, 20, 1, 1)
		TNT1 A 0 A_TakeInventory("IsExecutingOnAir", 1)
		KICK A 0 A_Takeinventory("ExecuteStompWall",1)
		KICK A 0 A_Takeinventory("ExecuteBashWall",1)
		Goto FinishExecution
		
	Execution1:	
		KICK BCD 1
		//TTNT1 A 0 A_JumpIfInventory("IsFloating", 1, "ExecuteAirStomp")
		RIFF A 0 A_FireCustomMissile("ExecutionAttackKick", 0, 0, 0, -7)
        KICK H 5
		KICK A 0 A_Takeinventory("Kicking",1)
		KICK I 1
		KICK GFEDCBA 1
		TNT1 A 5
		Goto FinishExecution
		
	Execution2:
		TNT1 A 0
		TNT1 A 0 A_ZoomFactor(1.2)
		//TTNT1 A 0 A_JumpIfInventory("IsFloating", 1, "ExecuteAirStomp")
		PONG B 1 A_Stop
        PONG C 1 A_PlaySound("skeleton/swing")
		PONG D 1 A_FireCustomMissile("ExecutionAttackMelee", 0, 0, 0, 0)
		PONG E 3 A_Stop
		PONG DCB 2 A_Stop
		PUN3 A 1 A_Stop
        PUN3 B 1 A_PlaySound("skeleton/swing")
		PUN3 C 1 A_FireCustomMissile("ExecutionAttackMelee", 0, 0, 0, 0)
		PUN3 E 3 A_Stop
		PUN3 CBA 2 A_Stop
		
		PONG B 1 A_Stop
        PONG C 1 A_PlaySound("skeleton/swing")
		PONG D 1 A_FireCustomMissile("ExecutionAttackMelee", 0, 0, 0, 0)
		PONG E 3 A_Stop
		PONG DCB 2 A_Stop
		PUN3 A 1 A_Stop
        PUN3 B 1 A_PlaySound("skeleton/swing")
		PUN3 C 1 A_FireCustomMissile("ExecutionAttackMelee", 0, 0, 0, 0)
		PUN3 E 3 A_Stop
		PUN3 CBA 2 A_Stop
		
		PONG B 1 A_Stop
        PONG C 1 A_PlaySound("skeleton/swing")
		PONG D 1 A_FireCustomMissile("ExecutionAttackMelee", 0, 0, 0, 0)
		PONG E 3 A_Stop
		PONG DCB 2 A_Stop
		
		TNT1 A 1
		PUN3 A 1 A_Stop
        PUN3 B 1 A_PlaySound("skeleton/swing")
		PUN3 C 1 
		TNT1 AAA 0 A_FireCustomMissile("ExecutionAttackKick", 0, 0, 0, 0)
		PUN3 E 6 A_Stop
		PUN3 CBA 2 A_Stop
		TNT1 A 0 A_ZoomFactor(1.0)
		
		TNT1 A 5
		Goto FinishExecution
		
		
	Execution3:
		
		KIKF ABC 1
		//TTNT1 A 0 A_JumpIfInventory("IsFloating", 1, "ExecuteAirStomp")
        TNT1 A 0 A_PlaySound("KICK")
		KIKF D 1
		TNT1 AAA 0 A_FireCustomMissile("ExecutionAttackFatality", 0, 0, 0, 0)
		KIKF DDDDDDD 1 A_SetPitch(Pitch-10)
		KIKF ECBA 2
		TNT1 A 0 SetPlayerProperty(0,0,4)
		TNT1 A 0 A_ChangeFLag("NOPAIN", 0)
		TNT1 A 0 A_ChangeFLag("PUSHABLE", 1)
		TNT1 A 5 
		KICK A 0 A_Takeinventory("ExecuteDownedEnemy",1)
		Goto GoingToReady
		
	FinishExecution:
		TNT1 A 0
		TNT1 AAAAAAAA 1 A_SetPitch(Pitch-10)
		TNT1 A 0 A_ChangeFLag("NOPAIN", 0)
		TNT1 A 0 A_ChangeFLag("PUSHABLE", 1)
		TNT1 A 0 SetPlayerProperty(0,0,4)
		KICK A 0 A_Takeinventory("ExecuteDownedEnemy",1)
		Goto GoingToReady
	}
}
 

ACTOR RevolverAmmo : Ammo
{
   Inventory.Amount 0
   Inventory.MaxAmount 6
   Ammo.BackpackAmount 0
   Ammo.BackpackMaxAmount 6
}