// Small ammo

class ShotboltAmmo : Ammo
{
	Default
	{
		Inventory.PickupMessage "$GOTSHOTBOLTS";
		Inventory.Amount 4;
		Inventory.MaxAmount 40;
		Ammo.BackpackAmount 20;
		Ammo.BackpackMaxAmount 40;
		Inventory.Icon "SHBAA0";
	}
	States
	{
	Spawn:
		SHBA A -1;
		Stop;
	}
}

class ShotboltAmmo2 : ShotboltAmmo
{
	Default
	{
		Inventory.PickupMessage "$GOTSHOTBOLTS2";
		Inventory.Amount 6;
	}
}

class PaintAmmo : Ammo
{
	Default
	{
		Inventory.PickupMessage "$GOTPAINTCLIP";
		Inventory.Amount 10;
		Inventory.MaxAmount 200;
		Ammo.BackpackAmount 50;
		Ammo.BackpackMaxAmount 200;
		Inventory.Icon "PNTAA0";
	}
	States
	{
	Spawn:
		PNTA A -1;
		Stop;
	}
}

class PaintAmmo2 : PaintAmmo
{
	Default
	{
		Inventory.PickupMessage "$GOTPAINTCLIP2";
		Inventory.Amount 15;
	}
}

class OoziAmmo : Ammo
{
	Default
	{
		Inventory.PickupMessage "$GOTOOZECLIP";
		Inventory.Amount 10;
		Inventory.MaxAmount 150;
		Ammo.BackpackAmount 40;
		Ammo.BackpackMaxAmount 150;
		Inventory.Icon "OOZAA0";
	}
	States
	{
	Spawn:
		OOZA A -1;
		Stop;
	}
}

class OoziAmmo2 : OoziAmmo
{
	Default
	{
		Inventory.PickupMessage "$GOTOOZECLIP2";
		Inventory.Amount 15;
	}
}

class HellshellAmmo : Ammo
{
	Default
	{
		Inventory.PickupMessage "$GOTHELLSHELL";
		Inventory.Amount 1;
		Inventory.MaxAmount 30;
		Ammo.BackpackAmount 2;
		Ammo.BackpackMaxAmount 30;
		Inventory.Icon "HLSAA0";
	}
	States
	{
	Spawn:
		HLSA A -1;
		Stop;
	}
}

// Big ammo

class ShotboltAmmoBig : ShotboltAmmo
{
	Default
	{
		Inventory.PickupMessage "$GOTSHOTBOLTQUIVER";
		Inventory.Amount 20;
	}
	States
	{
	Spawn:
		SHBA B -1;
		Stop;
	}
}

class ShotboltAmmoBig2 : ShotboltAmmoBig
{
	Default
	{
		Inventory.PickupMessage "$GOTSHOTBOLTQUIVER2";
		Inventory.Amount 30;
	}
}

class PaintAmmoBig : PaintAmmo
{
	Default
	{
		Inventory.PickupMessage "$GOTPAINTBUCKET";
		Inventory.Amount 50;
	}
	States
	{
	Spawn:
		PNTA B -1;
		Stop;
	}
}

class PaintAmmoBig2 : PaintAmmoBig
{
	Default
	{
		Inventory.PickupMessage "$GOTPAINTBUCKET2";
		Inventory.Amount 75;
	}
}

class OoziAmmoBig : OoziAmmo
{
	Default
	{
		Inventory.PickupMessage "$GOTOOZEBEAKER";
		Inventory.Amount 40;
	}
	States
	{
	Spawn:
		OOZA B -1;
		Stop;
	}
}

class OoziAmmoBig2 : OoziAmmoBig
{
	Default
	{
		Inventory.PickupMessage "$GOTOOZEBEAKER2";
		Inventory.Amount 60;
	}
}

class HellShellAmmoBig : HellShellAmmo
{
	Default
	{
		Inventory.PickupMessage "$GOTHELLSHELLBOX";
		Inventory.Amount 5;
	}
	States
	{
	Spawn:
		HLSA B -1;
		Stop;
	}
}

class NumberofGoonades : Ammo
{
	Default
	{
		Inventory.Amount 1;
		Inventory.MaxAmount 9;
	}
}

class Goonades : CustomInventory
{
	Default
	{
		Inventory.PickupMessage "$GOTGOONADES";
		Inventory.PickupSound "misc/w_pkup";
	}
	States
	{
	Spawn:
		GOOP A 0;
		GOOP A -1 { self.bDropped = false; }
		Stop;
	Pickup:
		TNT1 A 0 A_JumpIfInventory("NumberOfGoonades", 0, "FailState");
		TNT1 A 0 A_GiveInventory("NumberOfGoonades", 3);
		// fall through
	NoSelect:
		TNT1 A 0;
		Stop;
	FailState:
		TNT1 A 0;
		Fail;
	}
}

class AmmoCase : CustomInventory
{
	Default
	{
		+DONTGIB;
		Inventory.PickupMessage "$GOTAMMO";
		Inventory.PickupSound "misc/i_pkup";
	}
	States
	{
	Spawn:
		AMMC A -1;
		Stop;
	Pickup:
		AMMC A 0 A_GiveInventory("PaintAmmo", 5);
		AMMC A 0 A_GiveInventory("OoziAmmo", 5);
		Stop;
	}
}

class AmmoCase2 : AmmoCase
{
	Default
	{
		Translation "155:159=90:95";
	}
	States
	{
	Pickup:
		AMMC A 0 A_GiveInventory("PaintAmmo", 8);
		AMMC A 0 A_GiveInventory("OoziAmmo", 8);
		Stop;
	}
}

class SquareBackpack : BackpackItem
{
	Default
	{
		Height 26;
		Inventory.PickupSound "misc/p_pkup";
		Inventory.PickupMessage "$GOTBACKPACKFULLOCRAP";
	}
	States
	{
	Spawn:
		BKPA A -1;
		Stop;
	}
}

class MarbleAmmo : Ammo
{
	Default
	{
		Inventory.PickupMessage "$GOTMARBLEAMMO";
		Inventory.Amount 10;
		Inventory.MaxAmount 120;
		Inventory.Icon "MRBAA0";
	}
	States
	{
	Spawn:
		MRBA A -1;
		Loop;
	}
}

class MarbleAmmoBig : MarbleAmmo
{
	Default
	{
		Inventory.PickupMessage "$GOTBIGMARBLEAMMO";
		Inventory.Amount 40;
	}
	States
	{
	Spawn:
		MRBA B -1;
		Loop;
	}
}

class MarbleAmmo2 : MarbleAmmo
{
	Default
	{
		Inventory.PickupMessage "$GOTMARBLEAMMO2";
		Inventory.Amount 15;
	}
}

class MarbleAmmoBig2 : MarbleAmmoBig
{
	Default
	{
		Inventory.PickupMessage "$GOTBIGMARBLEAMMO2";
		Inventory.Amount 60;
	}
}
