bodybag.2da is used to define the models used for when a creature or placeable dies/is destroyed.
Bodybags
Bodybags are used for placeables and creatures when there is inventory contents that needs to be placed on the ground.
The game even creates an invisible one when the creature is lootable.
Note that if some thing is not filled in the right 2da file, eg; a reference to an invalid line in bodybag.2da, it spawns placeables.2da line 13 (LootBag1).
The body bag created has basic PLC properties (no scripts etc. of course) with the tag "Body Bag".
Placeable Bodybags
You can change the "Treasure Model" for what is spawned when the placeable is destroyed by damage and has something to pick up.
These are really simple - you have two options:
Default bodybag or not? | Appearance used |
---|---|
Yes | Uses the default line 13 placeables.2da option as above since it seems to not use the placeables.2da "BodyBag" column at all |
No | The instance of the placeable has a Treasure Model set to a specific bodybag.2da line as per above screenshot |
Creature Bodybags
There are two relevant options in the creature properties:
- Leaves Lootable Corpse - This bypasses the bodybag setting. This can also be set by SetIsDestroyable.
- Treasure Model - If lootable flag is off, then it can be either Default or a option from this 2da.
Lootable flag? | Default bodybag or not? | Appearance used |
---|---|---|
No | Yes | appearance.2da Body_Bag ID, which links to a line in bodybag.2da |
No | No | A line in bodybag.2da set on the Creature properties as per above screenshot |
Yes | n/a | Uses placeable line 157 - InvisObj (model plc_u02.mdl) - to click on. |
2da Columns
Line 0 should be left alone since it acts like a special ID line for "Default".
Column Names | Example | Valid Values | Description and Notes |
---|---|---|---|
LABEL | Potion | Text | Human readable name of the bodybag. Not used by the toolset or game. |
Name | 66483 | TLK refrence | The name of the bodybag. Note that it has to be filled in or Bad Strref will appear in the toolset. |
Appearance | 194 | placeables.2da line reference | The appearance to use |
2da Contents
2DA V2.0 LABEL Name Appearance 0 default 6671 **** 1 Potion 66483 194 2 Scroll 66484 195 3 Treasure 66490 196 4 Body 66492 198 5 Bones 66493 199 6 Pouch 66494 200