Kilgore's Mapper Guide: FOMAP File Structure
Kilgore's Mapper Guide | |
---|---|
A guide to using the mapper, a developer tool used to make encounter maps that can be added to the game, if they are good enough. Assembled by Reloaded's lead developer himself on the game's main forum, and copied here with minor edits. | |
Season | 2 |
Status | Being translated... |
Completion | 60% |
Authors | Kilgore |
This Chapter | FOMAP File Structure |
More Chapters | Title Page README Basic Commands Interface FOMAP File Structure Common Mistakes |
Notes | Need to add images |
FOnline maps are saved in .FOMAP format. This is a text format, so you can open and edit them with Notepad. In theory, you could create whole maps from scratch using a regular notepad, without running a mapper, but in practice only a real madman would do that. Nevertheless, making some edits in Notepad might be necessary.
Each fomap file consists of three sections: Headers, Tiles, and Objects.
Headers
[Header] - map header:
Version
MaxHexX - map width (hexes)
MaxHexY - map length (hexes)
WorkHexX - map width (actually used part)
WorkHexY - map length (actually used part)
ScriptModule - specifies the name of the script in which contains map initialization function
ScriptFunc - the name of the function executed when initializing the map
NoLogOut - if it equals 1, characters do not disappear after logging off (they are in (off) mode), and if it equals 0, characters disappear normally after the time defined in scripts / config.fos.
Time - time of day for the map. If equal to -1, map lighting will change over game time. If not, then the lighting will be permanent (useful for underground maps)
DayTime - specifies times for which map lighting are defined below (separated by a space)
DayColor0 - lighting color for the first time specified in "DayTime"
DayColor1 - lighting color for the second time specified in "DayTime"
DayColor2 - lighting color for the third time specified in "DayTime"
DayColor3 - lighting color for the fourth time specified in "DayTime"
- Header Section Example:
- [Header]
- Version 4
- MaxHexX 400
- MaxHexY 400
- WorkHexX 126
- WorkHexY 127
- ScriptModule fo2077_map_losthills
- ScriptFunc _MapInit
- NoLogOut 0
Time -1 - DayTime 300 600 1140 1380
- DayColor0 18 18 53
- DayColor1 128 128 128
- DayColor2 103 95 86
- DayColor3 51 40 29
Tiles
In this section, each single line defines the individual tiles on the map.
- Syntax:
- Tile type (tile/roof), X position, Y position, Tile path
- Tiles Section Example:
- [Tiles]
- Tile 104 96 art\tiles\stlflr01.frm
- Roof 104 96 art\tiles\stop005.frm
Objects
This section contains all map objects. By default, each object is defined by four lines:
- MapObjType - object type
- ProtoId - pid of the object
- MapX - X coordinate
- MapY - Y coordinate
Some objects have additional lines with properties.
- Objects Section Example:
- [Objects]
- MapObjType 2
- ProtoId 3853
- MapX 65
- Maps 94