All normal weapons in MM8BDM should inherit from BaseMM8BDMWep and override the SpawnLoop state. This allows the pickup access to all spawn functions of type SFT_WEP.

Weapons inheriting from this actor will not be able to be picked up or used by classes which inherit from [CustWepClassBase](<https://mm8bdm.notion.site/CustWepClassBase-6e611b72560446bbbdca59d11f19bcf8>) by design. If you need a weapon to be used by that type of class, look at [BaseMM8BDMCustWep](<https://mm8bdm.notion.site/BaseMM8BDMCustWep-d23769c5353f40169bf4355492943907>).

DECORATE Definition

<aside> 🚨 Wait! Stop! Before you copy this actor's definition into your mod, remember the following things:

actor BaseMM8BDMWep0 : Weapon
{
	//$NotAngled
	//$Color 5
	+WEAPON.AMMO_OPTIONAL
	+WEAPON.ALT_AMMO_OPTIONAL
	+WEAPON.ALT_USES_BOTH
	+WEAPON.DONTBOB
	+THRUACTORS
	var int user_RemoveAsWeapon;
	inventory.pickupsound "weapon/weaponup"
	Scale 2.0
	States
	{
		Spawn:
			TNT1 A 0
			TNT1 A 1 A_GiveInventory("MM8BDMWepSpawnFunc",1)
			TNT1 A 0 A_ChangeFlag("THRUACTORS", false)
			TNT1 A 1 A_Jump(256, "SpawnLoop")
			wait
		SpawnLoop:
			WEAP X 1
			loop
	
		DeselectSwap:
			"----" "#" 0 A_JumpIfHealthLower(1,"DeselectDeath")
			"----" "######################" 0 A_Lower
			"----" "#" 1 A_Lower
			Goto DeselectSwap+1
		DeselectDeath:
			"----" "#" 0 A_GunFlash("NoFlash",GFF_NOEXTCHANGE)
			goto DeselectSwap+1
			
		SelectSwap:
			"----" "######################" 0 A_Raise
			"----" "#" 1 A_Raise
			Loop
	
		Altfire:
			"----" A 1 A_JumpIfInventory("MM8BDMPlayer", 1, "Fire")
			"----" A 1 A_Jump(256, "NoAmmo")
			wait
	
		Flashloop:
			TNT1 A 0
			stop
		NoFlash:
			TNT1 A 0
			stop
		Sound.BusterCharge:
			TNT1 A 9 A_PlaySoundEx("weapon/adapterchargeloop","Weapon",0)
			TNT1 A 1 A_JumpIfInventory("WeaponCharge",1,"Sound.BusterCharge")
	    stop
	    Sound.GBCharge:
			TNT1 A 6 A_PlaySoundEx("weapon/gbcharge","Weapon",0)
			TNT1 A 1 A_JumpIfInventory("WeaponCharge",1,"Sound.GBCharge")
			stop
	}
}

actor BaseMM8BDMWep : BaseMM8BDMWep0
{
	Inventory.ForbiddenTo "CustWepClassBase"
	+INVENTORY.RESTRICTABSOLUTELY
}

See Also


Creating Weapons

BaseMM8BDMCustWep