Editing
EDF thing reference
(section)
From Eternity Wiki
Jump to navigation
Jump to search
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
====States==== *'''firstdecoratestate''' :Sets the first frame in a sequential list of dummy frames that use the internal Decorate-style defined '''states''' of this actor for [[EDF delta structures|framedelta]] compatibility. It's not required unless the intention is to make the Decorate states of this thing accessible from other thing types. Default games' (Doom, Heretic) thing types use externalized frames for all thing types, for compatibility. *'''states''' {{see|DECORATE state syntax}} :Default = nothing :Defines frames using [http://zdoom.org/wiki/DECORATE DECORATE]-style state definitions. This means it won't be necessary to define separate [[frame]] blocks for each individual frame. See the DECORATE reference at the ZDoom wiki for documentation on its syntax. Using the '''states''' field instead of any of the ones below results in more concise text, but also the newly created frames won't be accessible from outside (other thingtypes, Dehacked patches or delta structures), unless you use the '''firstdecoratestate''' field as well. Like normally, [[List of codepointers|codepointers]] may or may not be preceded by '''A_'''. The DECORATE code has to be implemented via a heredoc: a text string that spans on multiple lines. Unlike a regular string which uses quotation marks, the heredoc is marked by @" and "@ respectively. Example on an imp-like monster (the '=' sign is optional): states = @" Spawn: TROO AB 10 A_Look loop See: TROO AABBCCDD 3 A_Chase loop Pain: TROO H 2 TROO H 2 A_Pain goto See Melee: Missile: TROO EF 8 A_FaceTarget TROO G 6 A_TroopAttack goto See Death: TROO I 8 TROO J 8 A_Scream TROO K 6 TROO L 6 A_Fall TROO M -1 stop XDeath: TROO N 5 TROO O 5 A_XScream TROO P 5 TROO Q 5 A_Fall TROO RST 5 TROO U -1 stop Raise: TROO ML 8 TROO KJI 6 goto See "@ :A "fast" flag is now allowed between the tics and action function of DECORATE states (along with the pre-existing "bright" flag) which determines if that state halves its "tics" value when the game is in -fast or Nightmare skill. Example (from demon's states): states @" See: SARG AABBCCDD 2 fast A_Chase loop Melee: SARG EF 8 fast A_FaceTarget SARG G 8 fast A_SargAttack goto See Pain: SARG H 2 fast SARG H 2 fast A_Pain goto See "@ *'''spawnstate''' :Default = S_NULL :Sets the frame which a thing starts in when it is spawned. Monsters generally use this frame to stand still and look for targets. If the object is supposed to have any dynamic purpose or be visible, do not leave the '''spawnstate''' at S_NULL. *'''seestate''' :Default = S_NULL :Sets the frame which a monster will jump to when it sees or hears a target during a [[Look]] (monster standing unawakened) check. If an object is alive and has a seestate, it is considered ''sentient'' by certain game mechanics. *'''painstate''' :Default = S_NULL :Sets the frame a thing may randomly enter when it has been injured. If set to S_NULL, the creature will be removed instantly from the game if the random check succeeds. *'''dmg_painstates''' :Default = (nothing) :This is a list of one or more damagetype/frame pairs, enclosed in braces. For example: dmg_painstates { Fire, S_HPLAY_FPAIN1, Lava, S_HPLAY_LPAIN1 } makes the actor go to frame S_HPLAY_FPAIN1 when damaged by fire, or to S_HPLAY_LPAIN1 when harmed by lava. It defaults to its '''painstate''' if the damage is of another nature. The damage type of an actor is set up through the '''mod''' field. *'''dmg_painstates.add''' *'''dmg_painstates.remove''' :Can be used for derived actor types, who can have more or fewer specialized pain states than their ancestors. ''Dmg_painstates.add'' has the same format as ''dmg_painstates'', but ''dmg_painstates.remove'' only lists the damagetypes. For example: dmg_painstates.remove { Fire, lava } makes them get hurt normally from fire or lava, without going to special pain states. *'''meleestate''' :Default = S_NULL :If this frame is not S_NULL, monsters will have a slightly lower range attack probability and when they are within about 64 units of their target, they will enter this frame to perform a melee attack. *'''missilestate''' :Default = S_NULL :If this frame is not S_NULL, monsters chasing a target will randomly enter it to perform a missile attack. *'''deathstate''' :Default = S_NULL :When a thing dies normally, it will enter this state. If the state is S_NULL, the thing will disappear forever. *'''dmg_deathstates''' *'''dmg_deathstates.add''' *'''dmg_deathstates.remove''' :Defaults = (nothing) :These three properties work similar to ''dmg_painstates*'', in that they allow the object to enter special frames depending on the damage type suffered, but if they die. The formats are the same. *'''xdeathstate''' :Default = S_NULL :If a thing dies by taking enough damage that its health is equal to its negated spawnhealth value (or negated 0.5 spawnhealth value in Heretic), it will enter this frame instead of its deathstate. If this frame is S_NULL, the thing will always die normally. *'''raisestate''' :Default = S_NULL :If this frame is not S_NULL, a creature running [[VileChase]] codepointers can perform a resurrection on this actor. When this occurs, the actor will enter this frame along with being restored. *'''healstate''' (since Feb 21 2016) :Default = S_NULL :Sets the frame to jump to if, during a [[VileChase]] frame, the thing encounters a corpse and raises it. If not set (or set to S_NULL), it will actually default to S_VILE_HEAL1, same as in Doom. *'''crashstate''' :Default = S_NULL :When a thing with this state dies and then subsequently hits the ground, it will enter this state. If this state S_NULL, it is not used. *'''activestate''' :Default = S_NULL :State to enter when triggered by the '''Thing_Activate''' parameterized special. *'''inactivestate''' :Default = S_NULL :State to enter when triggered by the '''Thing_Deactivate''' parameterized special.
Summary:
Please note that all contributions to Eternity Wiki are considered to be released under the GNU Free Documentation License 1.2 (see
Eternity Wiki:Copyrights
for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource.
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Navigation menu
Page actions
Page
Discussion
Read
Edit
History
Page actions
Page
Discussion
More
Tools
Personal tools
Not logged in
Talk
Contributions
Log in
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Search
Tools
What links here
Related changes
Special pages
Page information