Jump to content
  • 0

Want Rocket Launcher to remain first weapon 5.


Gokuma

Question

Adding another explosive weapon 5 in decorate, it becomes the primary one you switch to first when you press 5.   I want the regular RL to come up first.  Any suggestions?

 

Current weapon code:



ACTOR CryoGrenade : DoomWeapon 2061
{
  Game Doom
  SpawnID 193
  Height 20
  Weapon.SelectionOrder 1100
  Weapon.SlotNumber 5
  Weapon.AmmoUse1 1
  Weapon.AmmoGive1 3
  Weapon.AmmoType1 "RocketAmmo"
  +WEAPON.MELEEWEAPON
  Inventory.PickupMessage "You got Cryogrenades!"
  Obituary "%o got chilled by %k.  Frosty!"
  States
  {
  Ready:
    PUNG B 1 A_WeaponReady
    Loop
  Deselect:
    PUNG B 1 A_Lower
    Loop
  Select:
    PUNG B 1 A_Raise
    Loop
  Fire:
    PUNG B 10
    PUNG A 10 A_FireCustomMissile("IceGrenade",0,1,0,0,0,0)
    Goto Ready
  AltFire:
    PUNG B 4
    PUNG C 4 A_Punch
    PUNG D 5
    PUNG C 4
    PUNG B 5 A_ReFire
    Goto Ready
  Spawn:
    SBBM G -1
    Stop
  }
}

Share this post


Link to post

2 answers to this question

Recommended Posts

  • 1

There is a weapon parameter called Weapon.SlotPriority. The default value of this is 32767 if not set. Lower values have higher priority (i.e. appear first in order), and higher numbers appear later. Thus, if you add the parameter

Weapon.SlotPriority 32768

to your weapon properties (or any decimal bigger than 32767 actually), it will appear after anything with a lower value in slot 5, including the original rocketlauncher with priority 32767. In the event of things with equal priority, it seems to select them based on last created ones from reading files (so the last created one will be chosen first).

Edited by 3saster

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
Answer this question...

×   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...