Actor Pico2Uzi : Weapon
{
	+INVENTORY.UNTOSSABLE
	Weapon.SlotNumber 4
	Weapon.AmmoUse 1
	Weapon.AmmoGive 30
	Weapon.AmmoType "PicoUziMag"
	+WEAPON.AMMO_OPTIONAL
	Inventory.RestrictedTo "Pico"
	Inventory.Pickupmessage "Got yourself another Uzi, Now you are ready for anything!"
	Inventory.PickupSound "Pico/equip"
	Tag "2 Uzis"
	+Weapon.NOALERT
	STATES
	{
	Ready:
		PC2Z E 1 A_weaponready
		Loop
	SecondUzi:
		PC2Z A 1
		Loop
	Deselect:
		PC2Z A 1 A_Lower
		TNT1 A 0 A_Lower
		TNT1 A 0 A_Lower
		TNT1 A 0 A_Lower
		TNT1 A 0 A_Lower
		TNT1 A 0 A_Lower
		TNT1 A 0 A_Lower
		Loop
	Select:
		TNT1 A 0 A_GunFlash("SecondUzi")
		PC2Z E 1 A_Raise
		TNT1 A 0 A_Raise
		TNT1 A 0 A_Raise
		TNT1 A 0 A_Raise
		TNT1 A 0 A_Raise
		TNT1 A 0 A_Raise
		TNT1 A 0 A_Raise
		Loop
	Fire:
		PC2Z E 0 A_Jumpifnoammo("Click")
		PC2Z F 2 Bright
		TNT1 A 0 A_Alertmonsters
		TNT1 A 0 A_FireBullets(9, 4, -1, 5, "PicoBulletPuff")
		TNT1 A 0 a_setpitch(pitch-0.125)
		TNT1 A 0 a_quake(1,3,0,128,"NOSOUND")
		TNT1 A 0 A_PlaySound("PicoUzi/Fire", CHAN_WEAPON)	
		TNT1 A 0 A_GunFlash("Fire2")
		PC2Z G 2 Bright 
		PC2Z E 3 A_Refire
		PC2Z E 2 
		GOTO Ready
	Fire2:
		PC2Z A 0 A_Jumpifnoammo("Click2")
		PC2Z B 2 Bright
		TNT1 A 0 A_FireBullets(9, 4, -1, 5, "PicoBulletPuff")
		TNT1 A 0 a_setpitch(pitch-0.125)
		TNT1 A 0 a_quake(1,3,0,128,"NOSOUND")
		TNT1 A 0 A_PlaySound("PicoUzi/Fire", CHAN_WEAPON)	
		PC2Z C 2 Bright
		PC2Z A 3 
		PC2Z A 2 
		GOTO SecondUzi
	Click:
		TNT1 A 0 a_gunflash("click2")
		PC2Z H 2 A_playsound("Pico/WeaponClick",CHAN_AUTO)
		PC2Z H 10 
		PC2Z H 1 
		PC2Z H 2 
		PC2Z E 1 
		PC2Z E 0 
		GOTO READY
	Click2:
		PC2Z D 2 A_playsound("Pico/WeaponClick",CHAN_AUTO)
		PC2Z D 10 
		PC2Z D 1 
		PC2Z D 2 
		PC2Z A 1 
		PC2Z A 0 
		GOTO SecondUzi
	Altfire:
		"####" "#" 0 A_jumpifInventory("PicoMeterCountdown",0,1)
		Goto Click
		"####" "#"1 Offset(4,34) 
		"####" "#"1 Offset(9,36)
		"####" "#"1 Offset(15,40)
		"####" "#"1 Offset(15,40)
		"####" "#"1 Offset(22,48)
		"####" "#"1 Offset(30,54)
		"####" "#"1 Offset(39,65)
		"####" "#"1 Offset(45,72)
	Weed:
		TNT1 A 0 Offset(-1,32)
		TNT1 A 0 A_takeinventory("PicoAnxyStack",100)
		TNT1 A 0 A_takeinventory("PowerSlowdown",1)
		TNT1 A 0 A_takeinventory("PowerSlowerdown",1)
		TNT1 A 0 A_takeinventory("PowerSlowestdown",1)
		TNT1 A 0 A_takeinventory("PowerPicoDamage",1)
		TNT1 A 0 A_takeinventory("PowerPicoDamage1",1)
		TNT1 A 0 A_takeinventory("PowerPicoDamage2",1)
		TNT1 A 0 A_takeinventory("PowerPicoVulnerability",1)
		TNT1 A 0 A_takeinventory("PowerPicoVulnerability1",1)
		TNT1 A 0 A_takeinventory("PowerPicoVulnerability2",1)
		TNT1 A 0 A_Giveinventory("PicoWeedCoolDown",1)
		P2WD A 1 OFFSET(0,36) A_takeinventory("PicoMeterCountdown",256)
		P2WD A 1 OFFSET(0,33) Healthing(15,100)
		P2WD A 2 OFFSET(0,32)
		P2WD BCD 4
		P2WD E 2
		P2WD E 1 Offset(0,34)
		P2WD E 1 Offset(0,38)
		Goto Select
	Spawn:
		TNT1 A -1 
		Stop
	}
}