Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

LMS > Overview > Message File (MSBT)

This file is identified by the magic number MsgStdBn. It contains text strings that are looked up by label. This page describes version 3 of the file format.

TypeDescription
LBL1Message labels
TXT2Message strings
ATR1Attributes
TSY1Text style

LBL1 Block

This block contains labels for the TXT2, ATR1 and TSY1 blocks.

TXT2 Block

This block contains the actual text strings.

OffsetSizeDescription
0x04Number of messages
0x44 per messageOffsets to message strings
Null-terminated message strings

A message string may contain control tags, which may for example change the style of the text. A control tag always starts with character 0xE, which is followed by:

OffsetSizeDescription
0x02Tag group id
0x22Tag index
0x42Size of parameters
0x6Parameters

Character 0xF may mark the end of a region that is affected by a control tag. This character always takes up exactly 6 bytes (including the 0xF character), regardless of the character encoding. This marker is almost never seen in official files.

All tags and their parameters are defined in the TGG2 block of the MSBP file.

Predefined Tags

Tag group 0 (called ‘System’) contains predefined tags, while all other tag groups are game-specific. The following tags are defined under tag group 0:

TagNameParameters
0Rubyrt (string)
1Fontface (string)
2Sizepercent (uint8), size (string)
3Colorr (int8), g (int8), b (int8), a (int8), name (string)
4PageBreakNone
5Referencemstxt (string), label (string), lang (string)

ATR1 Block

This block contains attributes for each message. The format of the attributes is game-specific, but may be declared in an MSBP file. Depending on the game, the attributes may contain offsets to strings that are stored behind the attribute table.

OffsetSizeDescription
0x04Number of attributes
0x44Bytes per attribute
0x8Attributes
Strings

TSY1 Block

If the TSY1 block is present, it contains a style index for each message.

OffsetSizeDescription
0x04 per messageStyle index in MSBP file