Template:EnemyStats2/doc

From Darkest Dungeon Wiki
Jump to navigation Jump to search
Template-info.svg Documentation

This template defines the Cargo table EnemyStats2, which stores attributes for Enemies in Darkest Dungeon II. This template itself does nothing except to define the table schema. Functionality is defined in the templates and modules below:

The following tables are linked to, or derived from, the main table in some way:

Schema

Note that when adding a new enemy to the table using Template:EnemyStats2/Add, an extra field, types must be provided which contains a space-separated list of all the enemy's types. However, those types are not stored in this table but in EnemyStats2Types.

Field Required? Notes
name Required Must be unique.
image Optional A full-sized image of the enemy.
icon Optional An icon used to display the enemy in tables.
article Required The enemy page. Required because a lot of times we will link to the enemy from other places, and there are often multiple enemies on one page. E.g. the Shambler Tentacle's article is Shambler (Darkest Dungeon II)#Shambler Tentacle.
boss Required yes or no. Whether the enemy has the boss tag and is immune from the effect of Murder Weapon, for example.
minion_of Optional If the enemy only appears in a specific boss fight, then it is a minion_of that boss. This does not correspond to any real in-game value. However it is useful for grouping enemies together when sorting and searching information on the wiki: we want to group all minions together with their bosses, and not with all regular enemies.
champion_of Optional Some enemies are champion versions of another enemy (e.g. Bullseye Barrett is the champion_of the Arbalist). Again, this has no meaning in the game. However it is useful for sorting enemies: we want champion enemies to be sorted after regular enemies.
region Optional If an enemy is restricted to a specific region. Currently the only allowed values are valley,sprawl,tangle,foetor,shroud,sluice,mountain. This is used to sort and search information on the wiki and doesn't correspond to any in-game value.
category Required Each enemy on the wiki must belong to some sort of category. As with the above attributes, this attribute only exists in order for us to sort and organise information on the wiki.

This is mostly used for Module:EnemyStats2/Table. When writing code for the table, I came upon a fundamental problem: how should we sort the enemies correctly? A few issues stood out:

  • Type doesn't work: Ghoul has no type but logically should belong with Gaunts. Likewise Gander is a Cadaver but logically belongs with Creature Den enemies. There are a lot of other instances.
  • Region doesn't work either: When sorting Confession bosses, logically we should group all Act 1 bosses together, then Act 2, then Act 3. And not all enemies have regions.
  • We could do some insane hybrid of all these attributes together, but that creates a sorting key that is unclear in many ways.

In the end I decided to create a new attribute called category for the purposes of sorting enemies. Each enemy should belong to one and only one category. Currently all categories are defined on Data:Enemies (Darkest Dungeon II), along with their sorting order. They should mostly make sense: gaunts, creature_den, obsession, shambler, etc...

This has the benefit that it is very explicit: each enemy should belong in a group somewhere, and category states that directly.

However, it has some downsides. The first one is that we must explicitly specify an extra value for each enemy—in particular, a value that has no real in-game meaning. And also category is a term used on the wiki to describe categories of articles; this is possibly a mistake that will create more issues in the long run, but for now I'll just say: let's cross that bridge when we get to it.

hp Optional Unspecified means the enemy is invulnerable.
speed Required
death_armor Required
bleed Optional Unspecified means the enemy is immune.
blight Optional Unspecified means the enemy is immune.
burn Optional Unspecified means the enemy is immune.
stun Optional Unspecified means the enemy is immune.
move Optional Unspecified means the enemy is immune.
debuff Optional Unspecified means the enemy is immune.
size Required
turns Required The number of turns the enemy takes per round, not counting free actions, etc...
permanent_conditions Optional Some enemies have certain conditions. For example, Death deals more damage to Bleed bleeding heroes as her health gets lower. A lot of enemies start with Dodge Dodge or Block Block tokens. And so on.