Swords of Glass people format

From ModdingWiki
Jump to: navigation, search
Swords of Glass people format
Format typeSaved game
Save locationsUnrestricted
Elements savedCharacter stats, items

The character data in Swords of Glass is stored in the People.dat file. The file is fixed-width and stores 20 characters. Only those characters with an Unused flag set to false (0) are active.


Data type Description
UINT8 X position The X position of the character in the dungeon.
UINT8 Y position The Y position of the character in the dungeon.
UINT8 Z position The Z position (floor) of the character in the dungeon.
UINT8 Strength Character's strength.
UINT8 Dexterity Character's dexterity.
UINT8 IQ Character's IQ.
UINT8 Class 1 - Warrior, 2 - Magician.
1 Byte Unknown ?
UINT8 Level Character's level.
INT16LE Max HP Maximum hit points. Game caps at 255.
INT16LE HP Current hit points. Game caps at 255.
INT16LE Dead flag 0 - Alive, -1 - Dead. Where a character dies, this flag is set to true (-1).
4 Bytes Unknown ?
INT16LE Unused flag 0 - Used, -1 - Unused. If this flag is true (-1), this character slot is unused.
Real Experience The character's experience.
Real Gold The character's gold.
1 Byte Unknown ?
12 Items See the Item structure.
UINT8[10] Max MP Maximum magic power for each level. Game caps at 99.
UINT8[10] MP Current magic power for each level. Game caps at 99.
UINT8[30] Spell flag 0 - No, 1 - Yes. Flags for which spells this character knows.
7 Bytes Unknown ?
UINT8 Name length Length of this character's name.
char[7] Name The character's name. Names are always 7 bytes, but you should only display the length of bytes read from the previous value.


Each player has 12 item slots. If the item id is zero, the slot is empty. Both empty and occupied slots are 15 bytes.

Data type Description
UINT8 Item id The id of the item found in the CNames.dat file. If zero, this slot is empty.
UINT8 Bonus The bonus to the item (like Sword +1). The game never goes about +9, but it accepts over-buffed items.
INT16LE Quantity/Durability For items like arrows, this holds the quantity, but for non-stackable items like a sword or armor, this is the durability of the item. It will break at 0. The game never has quantities greater than 9, but accepts them.
UINT8 Name length The length of the item's name. Always 0x0A.
char[10] Name The name of the item. You can create custom names since the game uses id for everything.


This save game format was reverse engineered by TheAlmightyGuru. If you find this information helpful in a project you're working on, please give credit where credit is due. (A link back to this wiki would be nice too!)