hstring - GameRevision/GWLP-R GitHub Wiki

Naming

htring stands for hashstring indicating it can contain hashes. Strings in the gw.dat are referenced by string IDs. A string’s ID is the same for all languages.

Affiliation

Part of GuildWars protocol packets.

Structure

type field description
ushort StringLength length of the following string. it counts the number of wchars not the number of bytes.
wchar[StringLength] StringData this can be either a string ID (with key for encoded strings) or plain text see remarks1. This may also contain additional strings to fill in variables such as %str1%.

Remarks

1 Structure for plain text (header and terminator count towards stringLength):

type field description
ushort Header1 value: 0×0108
ushort Header2 value: 0×0107
wchar[] PlainText zero termination optional, not recommended
ushort Terminator value: 0×001
⚠️ **GitHub.com Fallback** ⚠️