Difference between revisions of "Thing"

From DoomWiki.org

[unchecked revision][unchecked revision]
(THINGS lump)
(more uses)
Line 1: Line 1:
'''Things''' represent [[player]]s, [[monster]]s, [[pick-up]]s, and [[projectile]]s. Inside the game, these are known as actors.  
+
'''Things''' represent [[player]]s, [[monster]]s, [[pick-up]]s, and [[projectile]]s. Inside the game, these are known as actors. They also represent obstacles, certain decorations, player start positions and teleport landing sites.
  
 
DoomEd numbers are the numbers used in the editor to represent an actor. When the map is loaded, an actor that corresponds to that number will be spawned at the location of that map thing. Although many actors have DoomEd numbers, not all of them do. For instance, a blue key card has a DoomEd number, but a rocket flying through the air does not.
 
DoomEd numbers are the numbers used in the editor to represent an actor. When the map is loaded, an actor that corresponds to that number will be spawned at the location of that map thing. Although many actors have DoomEd numbers, not all of them do. For instance, a blue key card has a DoomEd number, but a rocket flying through the air does not.

Revision as of 17:03, 18 January 2005

Things represent players, monsters, pick-ups, and projectiles. Inside the game, these are known as actors. They also represent obstacles, certain decorations, player start positions and teleport landing sites.

DoomEd numbers are the numbers used in the editor to represent an actor. When the map is loaded, an actor that corresponds to that number will be spawned at the location of that map thing. Although many actors have DoomEd numbers, not all of them do. For instance, a blue key card has a DoomEd number, but a rocket flying through the air does not.

THINGS lump

Doom level format

Level thing data is stored in the THINGS lump.

Offset Size (bytes) Description
0 2 X position
2 2 Y position
4 2 Angle facing
6 2 DoomEd thing type
8 2 Flags

Flags

bit hex description
0 0x0001 Thing is on skill levels 1 & 2
1 0x0002 Thing is on skill level 3
2 0x0004 Thing is on skill levels 4 & 5
3 0x0008 Thing is deaf
4 0x0010 Thing is not in single player

Boom flags

Boom adds the flags:

bit hex description
5 0x0020 Thing is not in deathmatch
6 0x0040 Thing is not in coop
7 0x0080 Friendly monster

ZDoom editing

Spawn numbers are the numbers used by specials such as Thing Spawn to spawn actors in the game once the user has started playing the map. Although DoomEd numbers and spawn numbers both describe actors, they are not interchangeable—you must not use a spawn number on a map thing, and you must not use a DoomEd number for instance as a Thing_Spawn parameter.

Actor Names are the actual names each actor has internally (to test these you may want to try out the summon console command). These are used with the functions SpawnSpot and Spawn which allow you to spawn any actor available with Thing_Spawn and also all other actors (though some actors aren't meant to be spawned) such as cameras, scenery or whatever you might require.

If you create a new actor with the DECORATE lump, you can specify both the spawn number (SpawnNum), and the DoomEd number (DoomEdNum). The name you give the new DECORATE item is also its actor name, so you can also spawn it using that.

THINGS structure

Offset Size (bytes) Description
0 2 Thing id (tid)
2 2 X position
4 2 Y position
6 2 Starting height
8 2 Angle facing
10 2 DoomEd thing type
12 2 Flags (see below)
14 1 Hexen/ZDoom special type
15 1 Argument 1
16 1 Argument 2
17 1 Argument 3
18 1 Argument 4
19 1 Argument 5

Doom Format things are 10 bytes in size, while Hexen/ZDoom format things are 20 bytes in size.

Flags

bit hex description
00x0001Thing is on Skill levels 1 & 2
10x0002Thing is on Skill level 3
20x0004Thing is on Skill levels 4 & 5
30x0008Thing is Deaf
40x0010Thing is dormant until activated
80x0100Thing is in Single Player
90x0200Thing is in Co-Op
100x0400Thing is in Deathmatch
110x0800Thing is 25% translucent
120x1000Makes the thing invisible
130x2000Friendly monster
140x4000Thing stands still (only useful for specific Strife monsters or friendlies)

Strife

bit hex description
00x0001Thing is on Skill levels 1 & 2
10x0002Thing is on Skill level 3
20x0004Thing is on Skill levels 4 & 5
30x0008Thing stands still (only useful for specific Strife monsters)
40x0010Thing is not in Single player
50x0020Thing is Deaf
60x0040Friendly monster
80x0100Thing is 25% translucent
90x0200Makes the thing invisible
</td>