LIB format

From ENIGMA

Jump to: navigation, search

LIB is the Game Maker Library format introduced in GM 5.0. LateralGM supports it, as well as a greatly compressed alternative, LGL format.

LIBs can be edited with a Library Maker, provided that the Lib ID is 1000 or greater (this is to prevent the user from editing the official libs. If you still desire to view/edit the official libs, simply alter it with a hex editor to make the Lib ID to some number >= 1000). Interestingly, official libs all use the value 1 for Lib ID.

For notes on how to read this format, and other information, please see Format info.

Lookup Tables

Action Kinds
ID Name
0 Normal
1 Begin Group
2 End Group
3 Else
4 Exit
5 Repeat
6 Variable
7 Code
8 -Placeholder
9 -Separator
10 -Label

The Order column in the table below indicates the order that the entries would be expected to appear in a user-friendly dropdown.

Argument Types
Order Name ID
1 Expression 0
2 String 1
3 Both 2
4 Boolean 3
5 Menu 4
6 Color 13
7 Font String 15
8 Sprite 5
9 Sound 6
10 Background 7
11 Path 8
12 Script 9
13 Object 10
14 Room 11
15 Font 12
16 Timeline 14
Execution Types
ID Name Description
0 Nothing Function Name and Code remain empty (0, 0)
1 Function Function Name is filled. Code remains empty (0)
2 Code Code is filled. Function Name remains empty (0)

Documentation

GM version needed for the following info[1]
Length of Tab Caption { Tab Caption }
Lib ID (if ID < 1000, this file is protected as official)
Length of Author { Author }
Lib Version
(double) is the "Last Changed:" time - fractional days since 1899-12-30
Length of Info { Info }
Length of Initialization Code { Initialization Code }
Advanced
Number of actions (changes to a different number in official libs.)
Number of actions again
{
 GM version needed for the following info[1]
 Length of Name { Name }
 Action Id
 Image size { Image Data (bmp format) }
 Hidden
 Advanced
 <520+> Registered only
 Length of Description { Description }
 Length of List Text { List Text }
 Length of Hint Text { Hint Text }
 Kind[2] (0-10)
 Interface Kind (0=Normal, 1=None, 2=Arrows, 5=Code, 6=Text)
 Question
 Apply to
 Relative
 Argument Count
 Number of Arguments (always 8)
 {
  Length of Argument Caption { Argument Caption }
  Argument Type[3] (0-15)
  Length of Default Argument Value { Default Argument Value }
  Length of Menu { Menu }
 }
 Execution Type[4] (0-2)
 Length of Function Name[4] { Functon Name }
 Length of Code[4] { Code }
}
  1. 1.0 1.1 500 for GM5.0 through 5.2. 520 for GM5.3 or later.
  2. See Action Kinds above
  3. See Argument Types above
  4. 4.0 4.1 4.2 See Execution Types above
Personal tools
Namespaces
Variants
Actions
Navigation
ENIGMA
Other
Toolbox