ACTOR CrowKatana : DravenWeaponBase
{
	+Weapon.NoAlert
	Weapon.Kickback 100
	Inventory.PickupMessage "You got Top Dollar's Katana!"
	Obituary "%o was slashed to pieces by %k's sword."
	Tag "Japanese Sword"
	+WEAPON.MELEEWEAPON
	+WEAPON.ALLOW_WITH_RESPAWN_INVUL
	Weapon.BobStyle inversesmooth
	Weapon.BobSpeed 2.0
	Weapon.BobRangeX 0.75
	Weapon.BobRangeY 0.75
	Weapon.UpSound "crowkatana/select"
	inventory.pickupsound "crowkatana/pickup"
	+FORCEXYBILLBOARD
	Weapon.SlotNumber 1
	Weapon.SelectionOrder 3700
	+weapon.noautoaim
	Scale 0.75
	States
	{
	Ready:
		KATR Z 1 A_WeaponReady(WRF_ALLOWZOOM|WRF_ALLOWRELOAD)
		Loop
	Deselect:
		KATR Z 1 A_Lower
		WEPK AA 0 A_Lower
		Loop
	Select:
		KATR Z 1 A_Raise
		WEPK AA 0 A_Raise
		Loop
	Fire:
		TNT1 A 0 A_JumpifInventory("CrowIsSlashing",1,"Hold")
		KATR ZYXWV 1
		Goto Hold
	Hold:
		TNT1 A 0 A_PlaySoundEx("crowkatana/swing","Soundslot7",0,0)
		TNT1 A 0 A_Jump(256,"Hold2","Hold3","Hold4","Hold5","Hold6","Hold7")
		Goto Hold1
	Hold1:
		TNT1 A 0 A_GiveInventory("CrowisSlashing",1)
		KATN AB 1
		TNT1 A 0 A_CustomPunch(50,0,0,"CrowSwordPuff")
		KATN CDE 1
		Goto Ready2
	Hold2:
		TNT1 A 0 A_GiveInventory("CrowisSlashing",1)
		KATN FG 1
		TNT1 A 0 A_CustomPunch(50,0,0,"CrowSwordPuff")
		KATN HIJ 1
		Goto Ready2
	Hold3:
		TNT1 A 0 A_GiveInventory("CrowisSlashing",1)
		KATN KLM 1
		TNT1 A 0 A_CustomPunch(50,0,0,"CrowSwordPuff")
		KATN NOP 1
		Goto Ready2
	Hold4:
		TNT1 A 0 A_GiveInventory("CrowisSlashing",1)
		KATN QRS 1
		TNT1 A 0 A_CustomPunch(50,0,0,"CrowSwordPuff")
		KATN TU 1
		Goto Ready2
	Hold5:
		TNT1 A 0 A_GiveInventory("CrowisSlashing",1)
		KATN VWX 1
		TNT1 A 0 A_CustomPunch(50,1,0,"CrowSwordPuff")
		KATN YZ 1
		Goto Ready2
	Hold6:
		TNT1 A 0 A_GiveInventory("CrowisSlashing",1)
		KAT2 ABC 1
		TNT1 A 0 A_CustomPunch(50,1,0,"CrowSwordPuff")
		KAT2 DEF 1
		Goto Ready2
	Hold7:
		TNT1 A 0 A_GiveInventory("CrowisSlashing",1)
		KAT2 GHI 1
		TNT1 A 0 A_CustomPunch(50,1,0,"CrowSwordPuff")
		KAT2 JKL 1
		Goto Ready2
	Ready2:
		TNT1 A 10
		TNT1 A 10 A_WeaponReady(WRF_NOSWITCH)
		KATR VWXYZ 1
		TNT1 A 0 A_TakeInventory("CrowisSlashing",999)
		Goto Ready
	Spawn:
		KATP A -1
		Stop
	KickFlash:
		KATR A 19 A_WeaponReady(WRF_NOFIRE|WRF_NOSWITCH)
		Stop
	AltFire:
		KATR ZYXWV 1
		TNT1 A 2
		KATD ABCDE 1
		Goto AltHold
	AltHold:
		KATD E 1
		FEXT P 0 A_SpawnItemEX("CrowMeleeDeflect",40,0,32)
		TNT1 A 0 A_Refire("AltHold")
		KATD EDCBA 1
		TNT1 A 3
		Goto Ready
	}
}

ACTOR CrowisSlashing: Inventory
{inventory.maxamount 1}

ACTOR CrowMeleeDeflect
{
   Health 5
   Height 50
   Radius 18
   Speed  7
   Species "BULLETS"
   +THRUSPECIES
   +SHOOTABLE
   +NOGRAVITY
   +DONTSPLASH
   +NOBLOOD
   +NOPAIN
	Species "KatanaShield"
	+THRUSPECIES
   States
   {
   Spawn: 
      TNT1 A 1 
      Stop
   Death: 
      SARG A 0
      Stop
   }
}