SetMarineWeapon

From ZDoom Wiki

Jump to: navigation, search

void SetMarineWeapon(tid, weapon);

Usage

Sets a Scripted Marine's weapon on the fly. Choices defined in zdefs.acs are as follows:

  MARINEWEAPON_Dummy //no weapon
  MARINEWEAPON_Fist
  MARINEWEAPON_BerserkFist
  MARINEWEAPON_Chainsaw
  MARINEWEAPON_Pistol
  MARINEWEAPON_Shotgun
  MARINEWEAPON_SuperShotgun
  MARINEWEAPON_Chaingun
  MARINEWEAPON_RocketLauncher
  MARINEWEAPON_PlasmaRifle
  MARINEWEAPON_Railgun
  MARINEWEAPON_BFG

Note in the case of rocket marines they are not immune to splash damage, so you may want to knock up their health a bit with SetActorProperty since they'll probably kill themselves pretty quickly otherwise.

Examples

  // Switch the marine(s) with TID 10 to attack with a Chainsaw.
  SetMarineWeapon(10, MARINEWEAPON_Chainsaw);
Personal tools