racialtypes.2da is used to define the different races in the game.
Hardcoded Notes
NWN:EE unhardcoded a chunk of game engine things to do with races, especially around the free feat for Humans. See column information below.
The feats for favoured racial types for Ranger are hardcoded however so new races (and some existing ones like Oozes) cannot be selected.
There may be other changes to stats and abilities hardcoded to specific lines, these need thoroughly testing however (a number of racial feats may be "fake feats" and the information hardcoded to a specific line instead).
The players races are meant to be only ever entries 0 through 6 (Dwarf, Elf, Gnome, Halfing, Half Elf, Half Orc and Human). If you allow players to be other races the game may not treat them equally - the main thing seems to be the voiced conjuration sounds in spells.2da which are not used if you are racial type 7 or above.
There is a limit to the amount of racial types, 254. 255 is RACIAL_TYPE_INVALID.
Also note the special line 28 "RACE_INVALID" - do not use this line! This appears to be used by the game internally (not in nwscript directly) at least in certain effect properties when determining if a race is invalid for the purposes of VersusRacialTypeEffect.
Halflings receive a hardcoded +1 attack bonus when using slings.
Animal Empathy is tied to lines 8 (RACIAL_TYPE_ANIMAL), 9 (RACIAL_TYPE_BEAST), and 19 (RACIAL_TYPE_MAGICAL_BEAST).
Cut Content Notes
There are 4 default lines dummied out as "DELETED". The only remains of them are the Abrev column. They are "Og", "On", "Oc" and "Ol". These are possibly simply "Outsider" but various alignments, since "Oe" is Outsider, and "e", "g", "c", "n" and "l" are all alignments (Evil, Good, Chaotic, Neutral and Lawful). As far as we're aware these lines contain absolutely no special coding in the engine.
Subraces
There is no direct subrace support in Neverwinter Nights but there is a script-settable/gettable Subrace text field the player can also edit in.
You can also do subraces (if scripted for support in some aspects) using additional racial type rows although you'd need to edit a fair chunk of spells which make assumptions on what is humanoid (for instance Charm Person). This also obviously doesn't allow favoured enemies to work correctly either. Additionally any hardcoded aspects of lines 0 - 6 would not apply to those races "subraces".
2da Contents
1.82.8169.20
2da Column Information
Column Name | Example | Valid Values | Description |
---|---|---|---|
ID (no actual name) | Row numbers for the benefit of human readers. The game engine ignores the value in this field, instead generating sequential row numbers as the file is read. It is good practice to keep the entries in this field sequentially numbered to avoid confusion. | ||
Label | Text | The name of the race for the benefit of human readers. Unused by the game. | |
Abrev | Text | The two-letter abbreviation for this race. Not used in the game as far as we know. | |
Name | TLK entry | A StringRef for the name of this race (capitalized). | |
ConverName | TLK entry | A StringRef for the adjective form of this race (capitalized). | |
ConverNameLower | TLK entry | A StringRef for the adjective form of this race in lowercase. | |
NamePlural | TLK entry | A StringRef for the name of members of this race (capitalized, plural). | |
Description | TLK entry | A StringRef for the description of this race (shown during character creation). | |
Appearance | appearance.2da line reference | The ID of the row in appearance.2da that defines the default appearance for members of this race. (In particular, this is the appearance given to player characters of this race during character creation.) | |
StrAdjust | Integer | The racial modifier to strength for members of this race. | |
DexAdjust | Integer | The racial modifier to dexterity for members of this race. | |
IntAdjust | Integer | The racial modifier to intelligence for members of this race. | |
ChaAdjust | Integer | The racial modifier to charisma for members of this race. | |
WisAdjust | Integer | The racial modifier to wisdom for members of this race. | |
ConAdjust | Integer | The racial modifier to constitution for members of this race. | |
Endurance | Ignored. This field contains remnants of a (pre-release) definition of the movement speeds of the playable races. However, by the time the game was released, race-based speed definitions were discarded in favor of creaturespeed.2da. | ||
Favored | classes.2da line reference | The ID of the row in classes.2da that defines the favored class of this race. | |
FeatsTable | 2da resref name | The name of the .2da file (without the extension) defining the racial feats gained from taking this race. Bioware used the naming format Note the feats listed here not always are functional just informational like Quick to Master. The unhardcoded columns allow some like Quick to Master to be retooled/changed now however. | |
Biography | TLK entry | A StringRef for the default biography of this race, which is the default description provided for player characters during character creation. | |
PlayerRace | 1 | 1 or 0 | 1 = playable race 0 = non-playable race Does not seem to affect the script command GetIsPlayableRacialType. |
Constant | Text | Ignored. The NWScript symbolic constant for this racial type. This is ignored by the game and is only for the reference of the human reader. | |
AGE | Integer | The default age for player characters of this race. | |
ToolsetDefaultClass | classes.2da line reference | The default class selected by the Toolset when creating a non-player character of this race. | |
CRModifier | 1 | Float value | Used for CR calculations in the toolset, which affect XP given for defeating monsters. |
NameGenTableA | dwarf elf gnome halfing halforc human | Resref of an LTR file minus the "f" or "m" | Unhardcoded random name generation file used for this race during PC character generation. From niv: "LTR files are relatively simple probability lists and letter lookup tables for various parts of the name. I can look into writing up some docs on it, but editing them comfortably will require more than a spec." These probably ommit the "f" and "m" part. So not sure if you can use "familiar" as an option here. Test and replace this line if you find you can (or can generate new ones). |
NameGenTableB | As above | As above. | Unhardcoded random name generation file used for this race during PC character generation. Half elves use this to have human and elf names available. |
ExtraFeatsAtFirstLevel | 1 | **** or Integer | If set it adds this many extra feats at first level - ie; human trait sets this to 1 |
ExtraSkillPointsPerLevel | 1 | **** or Integer | If set it adds this many extra skill points at each level up. ie; humans have this set to 1. |
FirstLevelSkillPointsMultiplier | 4 | Integer | The amount of skill points at first level are multiplied by this, for instance a 10 intelligence Human Cleric gets 4 * (2 + 1) = 12 skill points at level 1. A Half-Orc Cleric would get 4 * (2 + 0) = 8 skill points at level 1. You can set this to 0 to have level 1 characters not get any skill points. |
AbilitiesPointBuyNumber | 30 | Integer | Amount of points available for point buys. ruleset.2da contains some overarching options to do with this as well. |
NormalFeatEveryNthLevel | 3 | Integer | The amount of levels between normal feats. EG: 3 means you get a feat at level 1, 3, 6, 12, 15. 4 would mean 1, 4, 8, 12, 16. |
NumberNormalFeatsEveryNthLevel | 1 | Integer | Amount of feats gained when NormalFeatEveryNthLevel level occurs, plus level 1. |
SkillPointModifierAbility | INT | STR, DEX, CON, WIS, INT, CHA | 3 letter code for an ability modifier used to provide additional skill points on level up. If blanked (****) it will not provide any. If the column is missing it will default to INT. |