Oops! I guess I based it off of someone else' weapon that had an item name that seemed like it should've been different.ChronoSeth wrote:"Jump target [x] not found in [y]" means that the state label which A_Jump is trying to enter is unavaliable. There is no "OtherBarrel" state in your weapon definition (you seem to have gotten the state and item parameters mixed up).
I really should have figured this out sooner.
Code: Select all
actor SideBySide : Weapon 30311
{
Weapon.SelectionOrder 2
Weapon.Slotnumber 3
Weapon.AmmoUse 1
Weapon.AmmoUse2 2
Weapon.AmmoGive 8
Weapon.AmmoType "ShotgunShell"
Weapon.AmmoType2 "ShotgunShell"
Inventory.Icon "DOU1A0"
Inventory.PickupMessage "Double-Barreled Shotgun"
Obituary "o% was completely opened in half by k%'s double-barrel."
+INVENTORY.UNTOSSABLE
States
{
Ready:
DBLE A 1 A_WeaponReady
Loop
Deselect:
DBLE A 0 A_TakeInventory("OtherBarrel", 1)
DBLE A 1 A_Lower
Loop
Select:
DBLE A 1 A_Raise
Loop
Fire:
DBLE A 1 A_JumpIfInventory("OtherBarrel",1,"RightBarrel")
DBLE A 0 A_playSound ("weapons/shotgundischarge")
DBLE K 3 Bright A_FireBullets (3.3, 3.3, 10, 6, "BulletPuff")
DBLE L 3 Bright A_Light1
DBLE A 3 A_GiveInventory("OtherBarrel", 1)
Goto Ready
RightBarrel:
DBLE A 0 A_playSound ("weapons/shotgundischarge")
DBLE N 9 Bright A_FireBullets (3.3, 3.3, 10, 6, "BulletPuff")
DBLE N 3 Bright A_Light1
DBLE A 3
DBLE C 6 A_TakeInventory("OtherBarrel", 1)
DBLE DEFM 5
DBLE GH 5
DBLE A 5 A_Refire
Goto Ready
AltFire:
DBLE A 3 A_JumpIfInventory("OtherBarrel",1,"RightBarrel")
DBLE A 0 A_Recoil(2)
DBLE A 0 A_GunFlash
DBLE A 0 A_playSound ("weapons/shotgundischarge")
DBLE A 1 A_playSound ("weapons/shotgundischarge")
DBLE A 7 A_FireBullets (5.4, 5.4, 21, 6, "BulletPuff")
DBLE B 6
DBLE C 6 A_ResetReloadCounter
DBLE DEFM 5
DBLE GH 5
DBLE A 5 A_Refire
Goto Ready
Flash:
DBLE I 4 Bright A_Light1
DBLE J 3 Bright A_Light2
Goto LightDone
Spawn:
SGN2 A -1
Stop
}
}
I changed the coding. I'm not getting the error anymore, but it isn't changing state for some reason, along with not preventing the player from firing both barrels when only one should be loaded.
Actually, what's the code for the Zblood sawn off? I might be able to learn how to do what I'm attempting with that as a reference.
