Creating simple breakable objects

From ZDoom Wiki
Jump to navigation Jump to search
Nuvolabomb.png Warning: The feature described on this page has been deprecated, and will no longer be supported or updated by the GZDoom developers. While some functionality may be retained for the purposes of backwards-compatibility, authors are strongly discouraged from utilizing this feature in future projects and to instead use the modern DECORATE format. Compatibility with future GZDoom versions is not guaranteed.

In addition to the normal commands that can be used with normal decoration items, there are a few more that can be added to make the scenery breakable in the old DECORATE format. Using this, you can recreate the destroyable trees that Hexen uses, and even add burn or freeze frames.

  • DeathFrames - Like frames, but gets played when the actor dies.
  • IceDeathFrames - Like DeathFrames, except it is used when the actor freezes to death.
  • BurnDeathFrames - Like DeathFrames, except it is used when the actor burns to death.
  • GenericIceDeath - Like IceDeathFrames, except you don't specify any frames here. The game will create a generic ice death for you.
  • BurnsAway - If you include this, then the thing disappears after it finishes the BurnDeathFrames animation. Otherwise, it stays at the last frame in the sequence.
  • DiesAway - Like BurnsAway, but it applies to normal DeathFrames instead.
  • DeathHeight - How tall the actor is after a normal death.
  • SolidOnDeath - Include this, and the actor will stick block you after it dies. Useful with DeathHeight.
  • BurnHeight - How tall the actor is after a burning death.
  • SolidOnBurn - Include this, and the actor will still block you after it burns to death. Useful with BurnHeight.
  • DeathSound - Sound the actor makes during a normal death.
  • BurnDeathSound - Sound the actor makes during a burning death.
  • Health - The actor's initial health.

An example follows (for use in Hexen.wad):

   breakable FooTree
   {
       Sprite TRDT
       Frames A
       DeathFrames "BCDEFG"
       GenericIceDeath
       BurnDeathFrames "H*I*J*K*L*M*N*OPQ"
       BurnDeathSound TreeExplode
       BurnHeight 20
       SolidOnBurn
       SolidOnDeath
       DeathHeight 20
       DeathSound BishopDeath
       Solid
       Radius 15
       Height 180
       Health 70
       Mass 700000
       NoBlood
       BurnsAway
   }