Actor GuyAR: Weapon{
	Inventory.RestrictedTo "Stickguyclass"
	Weapon.AmmoUse 1
	Weapon.AmmoType "Clip"
	Weapon.SelectionOrder 700
	Weapon.SlotNumber 4
	Scale 0.1
	+Weapon.noalert
	+WEAPON.AMMO_CHECKBOTH
	+WEAPON.ALT_AMMO_OPTIONAL
	Obituary "%o Felt a taste of %k 's Burst Rifle"
    Inventory.Pickupmessage "A Burst rifle? neat!"
    Tag "Burst rifle"
	STATES
	{
	 Ready:
		REAR A 1 A_weaponready(WRF_ALLOWRELOAD)
		Loop
	 Deselect:
		REAR A 1 A_Lower
		Loop
	 Select:
		REAR A 1 A_Raise
		Loop
	 Spawn:
		REAP A -1
		STOP
	  
	 Fire:
		REAR A 0 A_Jumpifinventory("Clip",1,2)
		REAR A 0 A_Gunflash("SoundFlash")
		Goto SilentClick
		REAR A 0 A_JUMPIFinventory("Stickguyfastfingers",1,"SpeedFire")
		REAR B 2 Bright Offset(0,40) A_FireBullets(0.5, 0.5, 1, 7, "SGBurstPuf") 
		TNT1 A 0 A_PlaySound("Stickguy/SROAR", CHAN_WEAPON)
		TNT1 A 0 A_AlertMonsters
		TNT1 A 0 A_SetPitch (pitch-0.2)
		TNT1 A 0 A_GunFlash
		REAR A 1 Offset(0,35)A_weaponready(WRF_NOPRIMARY|WRF_DISABLESWITCH|WRF_NOBOB)
		REAR A 0 A_Jumpifinventory("Clip",1,2)
		REAR A 0 A_Gunflash("SoundFlash")
		Goto Click+1
		REAR C 2 Bright Offset(0,42) A_FireBullets(0.5, 0.5, 1, 7, "SGBurstPuf")
		TNT1 A 0 A_PlaySound("Stickguy/SROAR", CHAN_WEAPON)
		TNT1 A 0 A_SetPitch (pitch-0.2)
		REAR A 1 Offset(0,37) A_weaponready(WRF_NOPRIMARY|WRF_DISABLESWITCH|WRF_NOBOB)
		REAR A 0 A_Jumpifinventory("Clip",1,2)
		REAR A 0 A_Gunflash("SoundFlash")
		Goto Click
		REAR B 2 Bright Offset(0,44)A_FireBullets(0.5, 0.5, 1, 7, "SGBurstPuf")
		TNT1 A 0 A_PlaySound("Stickguy/SROAR", CHAN_WEAPON)
		TNT1 A 0 A_SetPitch (pitch-0.2)
		REAR A 1 Offset(0,39)
		REAR D 1 Offset(0,35)
		REAR AAA 3 Offset(0,32) A_SetPitch(pitch+0.2)
		REAR A 1 A_REFIRE
		Goto ready
	 SpeedFire:
		REAR A 0 A_Jumpifinventory("Clip",1,2)
		REAR A 0 A_Gunflash("SoundFlash")
		Goto SilentClick
		TNT1 A 0 A_Takeinventory("Clip",1)
		TNT1 A 0 A_PlaySound("Stickguy/SROAR", CHAN_WEAPON)
		TNT1 A 0 A_SetPitch (pitch-0.1)
		REAS A 2 Bright Offset(0,42) A_FireBullets(12.5, 8.5, 1, 5, "Stickguypuffs")
		REAS B 1 Offset(0,37) A_SetPitch (pitch+0.1)
		REAS B 2 A_Jumpifinventory("Clip",1,2)
		REAS B 0 A_Gunflash("SoundFlash")
		Goto SpeedClick
		TNT1 A 0 A_Takeinventory("Clip",1)
		TNT1 A 0 A_PlaySound("Stickguy/SROAR", CHAN_WEAPON)
		TNT1 A 0 A_SetPitch (pitch-0.1)
		REAS C 2 Bright Offset(0,42) A_FireBullets(12.5, 8.5, 1, 5, "Stickguypuffs")
		REAS D 1 Offset(0,37) A_SetPitch (pitch+0.1)
		REAS D 2 
		REAR A 1 A_REFIRE
		Goto ready
	 SilentClick:
	   "####" "#" 2 Offset(0,33)
	   "####" "#" 2 Offset(0,32)
	   Goto Ready
	 Click:
	   "####" "#" 2 Offset(0,40) A_SetPitch(pitch+0.2)
	   "####" "#" 2 Offset(0,32) A_SetPitch(pitch+0.2)
	   Goto ready
	 SpeedClick:
	   "####" "#" 1 Offset(0,34) A_SetPitch(pitch+0.1)
	   Goto Ready
	 Flash:
		TNT1 A 2 Bright A_Light1
		Goto LightDone
	SoundFlash:
		TNT1 A 0  A_PlaySound("Stickguy/Tick", CHAN_WEAPON)
		Goto LightDone
	//---------------------------------------MELEE STUFF
	  Altfire:
		TNT1 A 0 Offset(0,32) A_JumpIfInventory("GuyStick",1,"XiaoMelee")
		TNT1 A 1 Offset(0,32) A_JumpIfInventory("StickguyMeleeStack",20,"BerserkFire")
	  QuickPunch:
		REFT D 2 A_FireCustomMissile("FistImpact",0,0,0,1)
		REFT D 2 Offset(-2,32) A_AlertMonsters 
		REFT C 2 Offset(0,32)
		REFT B 2
		TNT1 A 6
		Goto Ready
	  BerserkFire:
		REFT M 1 Offset(104,18) A_FireCustomMissile("ZerkFist",0,0,0,1)
		REFT N 2 Offset(0,32) A_AlertMonsters
		REFT P 2 
		REFT P 2 
		REFT U 1 
		TNT1 A 1 Offset(0,32)
		Goto Ready
	  XiaoMelee:
		TNT1 A 1 Offset(0,32) A_JumpIfInventory("StickguyMeleeStack",10,"XiaoZerk")
		RXXS A 2 A_FireCustomMissile("StickImpact",0,0,0,1)
		RXXS B 2 A_alertMonsters
		Goto RestOfStickmelee	
	  XiaoZerk:
		RXXS E 2 A_FireCustomMissile("ZerkStick",0,0,0,1)
		RXXS F 2 A_alertMonsters
	  RestOfStickmelee:
		RXXS CD 2
		TNT1 A 4
		Goto Ready
	}
}