ACTOR CrowRevolver: DravenWeaponBase Replaces Shotgun
{
  	Weapon.AmmoType1 "RevolverChamber"
  	Weapon.AmmoType2 "Shell"
  	Weapon.AmmoGive2 24
  	+WEAPON.NOALERT
  	+FloorClip
  	weapon.bobstyle inversesmooth
    weapon.bobspeed 2.0
  	weapon.bobrangex 0.75
  	weapon.bobrangey 0.75
  	Inventory.Pickupmessage "You got the Revolver!"
	inventory.pickupsound "misc/w_pkup"
	Weapon.UpSound "Weapon/switch"
	Obituary "%o was shot by %k's revolver."
	+FORCEXYBILLBOARD
	+weapon.noautoaim
	+WEAPON.AMMO_CHECKBOTH
	Tag "S&W-500 Revolver"
	Scale 0.4
	States
	{
	Ready:
		TNT1 A 0 A_JumpifNoAmmo("ReadyEmpty")
		EDRV A 1 A_WeaponReady(WRF_ALLOWZOOM|WRF_ALLOWRELOAD)
		Loop
	Fire:
		PIST A 0 A_JumpIfInventory("RevolverChamber",1,1) // Makes sure you have clip ammo before firing
		Goto AltFire
		TNT1 A 0 A_SetPitch(pitch-2)
		TNT1 A 0 A_GunFlash
		TNT1 A 0 A_TakeInventory("RevolverChamber",1)
		TNT1 A 0 A_AlertMonsters
		TNT1 A 0 A_PlaySound("Revolver/Fire",1)
		EDRV B 1 Bright A_FireBullets(1,1,1,50,"CrowBuckshot")
		TNT1 A 0 A_SetPitch(pitch+3)
		EDRV IJJLMNC 1
		EDRV C 5
		EDRV DE 2
		TNT1 A 0 A_PlaySound("Revolver/Hammer",CHAN_WEAPON)
		EDRV FGHK 2
		EDRV A 5 //Needs a but of cooldown
		Goto Ready
	ReadyEmpty:
		EDRV C 1 A_WeaponReady(WRF_ALLOWZOOM|WRF_ALLOWRELOAD)
		Loop
	Select:
		BNJO AAAAAAAAA 0 A_Raise
		BNJO A 0 A_WeaponReady
		Goto RaiseWeapon
	RaiseWeapon:
		EDRS ABCDE 1 A_WeaponReady(WRF_NOSWITCH|WRF_NOFIRE)
		Goto Ready
	Deselect:
		EDRR ABCDE 1 A_WeaponReady(WRF_NOSWITCH|WRF_NOFIRE)
		EDRV AAAAAAAAAAA 0 A_Lower
		Wait
	Spawn:
		EDRV Z -1
		Loop
	Altfire:
		PISG A 0 A_JumpIfInventory("RevolverChamber",6,"Ready")
		PISG A 0 A_JumpIfInventory("Shell",1,1)
		Goto Ready
		EDRR ABCDEF 1
		TNT1 A 0 A_PlaySound("revolver/open",4)
		TNT1 A 5
	ReloadCalc: // Does the actual calculations for reloading
		PISG A 0 A_JumpIfInventory("RevolverChamber",6,"GoGoGo") // Makes sure you have less than the max clip size [this weapon has it set to 6]
		PISG A 0 A_JumpIfInventory("Shell",1,1) // Makes sure you have reserve ammo before calculating
		Goto Ready
		PISG A 0 A_TakeInventory("Shell",1) // Takes reserve
		TNT1 A 3 A_PlaySound("revolver/bulletin")
		TNT1 A 0 A_FireCustomMissile("ShotCaseSpawn",5,0,12,-14)
		PISG A 0 A_GiveInventory("RevolverChamber",1) // Gives clip
		Goto ReloadCalc // loops until the clip is full
	Gogogo:
		TNT1 A 5
		TNT1 A 3 A_PlaySound("revolver/close",1)
		EDRR FEDCBA 1 A_WeaponReady(WRF_NOFIRE|WRF_NOSWITCH)
		Goto Ready
	KickFlash:
		EDRV A 19 A_WeaponReady(WRF_NOFIRE|WRF_NOSWITCH)
		stop
	}
}
ACTOR RevolverChamber : Ammo
{
  Inventory.MaxAmount 6 // clip size of pistol
  Inventory.Icon "CLIPA0"
  +IGNORESKILL
}