Jump to content

Trying to add the Iron Crossbow from Hexxen into Doom 2


Recommended Posts

So I am having an issue with trying to add the Iron Crossbow from Hexxen into Doom 2. I know this is an odd thing to do, but the reason I am trying to do this is because I am making a mapset based off Berserk and I wanted more a medieval theme. I'm am up for literally any suggestions. 

 

To clarify I did have it working in game and was able to shoot it and such but now it is giving me this error and I'm not even sure how to fix it to be honest. It won't let me launch the game at all, so here's the error followed by the actual decorate info. If there's anything else required to help with this please just let me know and I will provide what I can. 

 

The Error: 

Script error, "Berserk.wad:DECORATE" line 5:
'@property@inventory.amount' is an unknown actor property

 

The Decorate Info:

ACTOR IronBoltAmmo 12398
{
  Game Doom
  SpawnID 11
  Inventory.Amount 8
  Inventory.MaxAmount 50
  Ammo.BackpackAmount 6
  Ammo.BackpackMaxAmount 100
  Inventory.Icon "AMM1BOLT"
  States
  {
  Spawn:
    AMM1 A -1 
    Stop
  }
}

ACTOR IronBoltQuiverAmmo 12399 
{
  Game Doom
  SpawnID 12
  Inventory.pickupmessage "Quiver of Bolts"
  Inventory.Amount 15
  
  States
  {
  Spawn:
    AMM1 B -1 
    Stop
  }
}

ACTOR IronXBow : Weapon 12400
{
  Game Doom
  SpawnID 27
  Weapon.slotnumber 3
  Weapon.SelectionOrder 1800
  Weapon.AmmoUse 1
  Weapon.AmmoGive 16
  Weapon.AmmoType "IronBoltAmmo"
  Weapon.SisterWeapon "IronXBowPowered"
  Weapon.YAdjust 15
  Inventory.pickupmessage "Iron Crossbow"
  +WEAPON.NOALERT
  Obituary "%o was punctured by %k's Crossbow"
  
  States
  {
  Spawn:
    XBOW Z -1
    Stop
  Ready:
    XBOW A 1 A_WeaponReady
    Loop
  Deselect:
    XBOW A 1 A_Lower
    Loop
  Select:
    XBOW A 1 A_Raise
    Loop
  Fire:
    XBOW B 1 A_PlaySound("BowString")
    XBOW B 0 A_FireCustomMissile ("Ironbolt", 0)
    XBOW B 5 A_FireCustomMissile ("IronboltPain", 0, 0)
    XBOW CDEFG 4
    XBOW A 5 A_ReFire
    goto Ready
  }
}

ACTOR IronXBowPowered : IronXBow 12401
{
  Game Doom
  SpawnID 27
  Weapon.SelectionOrder 1800
  Weapon.AmmoUse 1
  Weapon.AmmoGive 16
  Weapon.AmmoType "IronBoltAmmo"
  Weapon.SisterWeapon "IronXBow"
  Weapon.YAdjust 15
  Inventory.pickupmessage "Iron Crossbow" // "ETHEREAL CROSSBOW"
  +WEAPON.POWERED_UP
  +WEAPON.NOALERT
  Obituary "%o should know that %k's is not a licensed acupuncturist"
  
  States
  {
  Fire:
    XBOW B 1 A_TakeInventory("IronBoltAmmo", 1)
  Hold:
    XBOW H 1 A_PlaySound("BowString")
    XBOW H 0 A_FireCustomMissile ("Ironbolt", 0, 0)
    XBOW H 3 A_FireCustomMissile ("IronboltPain", 0, 0)
    XBOW IJA 4
    XBOW A 1 A_ReFire
    goto Ready
  }
}

actor Ironbolt : FastProjectile 
{
  height 1
  radius 1
  damage (random(4,13)*9)
  speed 36
  seesound "misc/shot"
  deathsound "misc/shotx"
  PROJECTILE
  -ACTIVATEIMPACT 
  -ACTIVATEPCROSS
  +THRUGHOST
  +DONTREFLECT
  +NOEXTREMEDEATH
  scale 0.5
  
  states
  {
  Spawn:
    XBLT A -1
  Death:
    XBLT A 160
  XDeath:
    XBLT A 4
    stop
  }
}

actor IronboltPain : FastProjectile 
{
  height 1
  radius 1
  damage 0
  speed 36
  seesound "misc/shot"
  deathsound "misc/shotx"
  PROJECTILE
  -ACTIVATEIMPACT 
  -ACTIVATEPCROSS
  +THRUGHOST
  +DONTREFLECT
  +NOEXTREMEDEATH
  +RIPPER
  scale 0.5
  
  states
  {
  Spawn:
    TNT1 A 8
  Death:
    TNT1 A 0
    stop
  }
}

Share this post


Link to post

I think you need to have your new ammo class inherit from Ammo class, like so:

ACTOR IronBoltAmmo : Ammo 12398
{
  Game Doom
  SpawnID 11
  Inventory.Amount 8
  Inventory.MaxAmount 50
  Ammo.BackpackAmount 6
  Ammo.BackpackMaxAmount 100
  Inventory.Icon "AMM1BOLT"
  States
  {
  Spawn:
    AMM1 A -1 
    Stop
  }
}

 

Your other ammo class can inherit from this one or Ammo.

Edited by Rifleman

Share this post


Link to post

Yes, the first actor named 'IronBoltAmmo' is in fact simple actor. If you want it to behave like a Ammo, and be treated like an Ammo, you have to inherit it from ammo.

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...