Actor GuyPP: Weapon{
	Inventory.RestrictedTo "Stickguyclass"
	Weapon.AmmoUse 1
	Weapon.AmmoGive 40
	Weapon.AmmoType "Cell"
	Weapon.SelectionOrder 100
	Weapon.SlotNumber 6
	+Weapon.noalert
    Inventory.Pickupmessage "What is this some kinda of miniature building?"
    Tag "Plasmator"
	STATES
	{
	 Ready:
		SGPR A 1 A_weaponready(WRF_ALLOWRELOAD)
		Loop
	 Deselect:
		SGPR A 1 A_Lower
		Loop
	 Select:
		SGPR A 1 A_Raise
		Loop
	 Spawn:
		REPP A -1
		STOP
	 Fire:
		REGL A 0 A_Jumpifinventory("Cell",1,1)
		Goto Click
		TNT1 A 0 A_AlertMonsters
		TNT1 A 0 A_JumpIfInventory("Stickguyfastfingers",1,"SpeedFire")
		SGPR A 1 Bright A_FireCustomMissile("Redplasma",0,1)
		SGPR A 1 OFFSET(0,38) A_SETpitch(pitch-0.2)
		SGPR A 1 OFFSET(0,34) A_SETpitch(pitch+0.2)
		SGPR A 0 A_Gunflash
		SGPR A 0 A_ReFire
	 RestOfFire:
		SGPR A 2 
		SGPR A 2 
		SGPR A 2 Offset(0,35)
		SGPR D 2 Offset(0,36)
		SGPR D 10 A_weaponready(WRF_NOFIRE|WRF_ALLOWRELOAD)
		SGPR D 2 Offset(0,34)
		SGPR A 2 Offset(0,32)
		SGPR A 2 
		Goto Ready
	  Flash:
		SGPR B 2 Bright A_Light1
		SGPR C 2 Bright A_Light1
		Goto LightDone
	  SpeedFire:
		TNT1 A 0 A_AlertMonsters
		SGPR BC 1 BRIGHT A_FireCustomMissile("SpeedRedplasma",random(-15,15),1,0,8,0,random(-10,10))
		TNT1 A 0 A_JumpifInventory("Stickguyfastfingers",1,"SpeedFire")
	  SRestOfFire:
		SGPR A 2 Offset(0,33)
		SGPR D 2 Offset(0,32)
		SGPR D 2 Offset(-2,32)
		SGPR E 2 Offset(12,36)
		SGPR E 2 Offset(0,33)
		SGPR E 2 Offset(-1,32)
		SGPR E 2 Offset(0,32)
		SGPR F 1 Offset(0,36)
		SGPR F 2 Offset(0,37)
		SGPR F 2 Offset(3,35)
		SGPR F 2 Offset(7,36)
		SGPR F 2 Offset(12,38)
		SGPR A 2 Offset(-5,36)
		SGPR A 2 Offset(0,34)
		SGPR A 2 Offset(0,32)
		Goto Ready
	  Click:
		"####" "#" 2 offset(0,48) A_PlaySound("Stickguy/Tick", CHAN_WEAPON)
		"####" "#" 2 Offset(0,40)
		"####" "#" 2 Offset(0,32)
		Goto ready
	//---------------------------------------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
	}
}