Get2DAColumn(object, int)

From NWN Lexicon
Revision as of 20:50, 11 December 2021 by Jasperre (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search
Nwnee logo.jpg Note: This article documents Neverwinter Nights: Enhanced Edition new content or changes/updates/fixes to 1.69 functions. These are all listed under the category and patches pages.

Returns a column name in a specific 2da.

string Get2DAColumn(
    string s2DA,
    int nColumnIdx


The 2DA to check the column name of
The column index, starting at 0.


Returns the column name of s2DA at nColumnIdx index (starting at 0).

Returns "" if column nColumnIdx doesn't exist (at end).


The column names are made lowercase, so it will always return "label" never "LABEL" or "Label" - this is apparently how the game stores the names.

This can be useful for automatically parsing 2da files, both user and game engine, in larger queries automatically, especially in combination with Get2DARowCount.


This function was added in 1.86.8193.34 of NWN:EE.


See Also


Get2DAString Get2DARowCount