Classes:Gauntlets

From ZDoom Wiki
Jump to navigation Jump to search
Note: Wait! Stop! You do not need to copy this actor's code into your project! Here's why:
  1. This actor is already defined in GZDoom, there's no reason to define it again.
  2. In fact, trying to define an actor with the same name will cause an error (because it already exists).
  3. If you want to make your own version of this actor, use inheritance.
  4. Definitions for existing actors are put on the wiki for reference purpose only.
Gauntlets of the necromancer
Actor type Weapon Game MiniHereticLogoIcon.png (Heretic)
DoomEd Number 2005 Class Name Gauntlets
Spawn ID 32 Identifier T_GAUNTLETS


Classes: InventoryWeaponGauntlets
 →GauntletsPowered

In Heretic, these are gauntlets worn by the player which fire green lightning while the attack button is held. The lightning damages enemies within melee range of the player, much like Doom's chainsaw weapon. When used with the Tome of Power, the lightning color changes to red and deals more damage.


DECORATE definition

ACTOR Gauntlets : Weapon
{
  +BLOODSPLATTER
  Weapon.SelectionOrder 2300
  +WEAPON.WIMPY_WEAPON
  +WEAPON.MELEEWEAPON
  Weapon.Kickback 0
  Weapon.YAdjust 15
  Weapon.UpSound "weapons/gauntletsactivate"
  Weapon.SisterWeapon "GauntletsPowered"
  Inventory.PickupMessage "$TXT_WPNGAUNTLETS"
  Tag "$TAG_GAUNTLETS"
  Obituary "$OB_MPGAUNTLETS"

  action native A_GauntletAttack(int power);

  States
  {
  Spawn:
    WGNT A -1
    Stop
  Ready:
    GAUN A 1 A_WeaponReady
    Loop
  Deselect:
    GAUN A 1 A_Lower
    Loop
  Select:
    GAUN A 1 A_Raise
    Loop
  Fire:
    GAUN B 4 A_PlayWeaponSound("weapons/gauntletsuse")
    GAUN C 4
  Hold:
    GAUN DEF 4 Bright A_GauntletAttack(0)
    GAUN C 4 A_ReFire
    GAUN B 4 A_Light0
    Goto Ready
  }
}