-
Notifications
You must be signed in to change notification settings - Fork 0
LEV
AzazelN28 edited this page May 29, 2020
·
1 revision
LEV are text files that contains level geometry data.
They should begin with a line specifying the version:
LEV 2.1
All the game files contains the following lines:
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# This file has been converted from AutoCAD file 'SECBASE'.
#
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
After that we have some other information:
LEVELNAME <levelName>
PALETTE <paletteFileName>
MUSIC <musicFileName>
PARALLAX <parallaxX> <parallaxY>
NOTE: I'm not sure if the MUSIC parameter is used because the game uses iMuse to render music depending on the game state.
Then we can find all the resources needed to render level geometry:
TEXTURES <numTextures>
# You can find as much entries as specified by numTextures
TEXTURE: <textureFileName>
And after textures we can find the level geometry: sectors, walls and vertices.
NUMSECTORS <numSectors>
SECTOR <sectorId>
NAME <sectorName>
AMBIENT <sectorLight>
FLOOR TEXTURE <textureId> <textureOffsetX> <textureOffsetY> <textureFlag>
FLOOR ALTITUDE <altitude>
CEILING TEXTURE <textureId> <textureOffsetX> <textureOffsetY> <textureFlag>
CEILING ALTITUDE <altitude>
# This is used in levels with water like SEWERS.LEV or TALAY.LEV and it is
# used to calculate the player view height when is in this sector.
SECOND ALTITUDE <altitude>
FLAGS <a> <b> <c>
LAYER <layer>
VERTICES <numVertices>
# You can find as much entries as specified by numVertices
X: <x> Z: <z>
WALLS <numWalls>
# You can find as much entries as specified by numWalls
WALL LEFT: <leftSectorId> RIGHT: <rightSectorId> MID: <middleTextureId> <middleTextureOffsetX> <middleTextureOffsetY> <midFlag> TOP: <topTextureId> <topTextureOffsetX> <topTextureOffsetY> <topFlag> BOT: <bottomTextureId> <bottomTextureOffsetX> <bottomTextureOffsetY> <bottomFlag> SIGN: <signVertexId> <signX> <signY> ADJOIN: <adjoinSectorId> MIRROR: <mirrorSectorId> WALK: <walkSectorId> FLAGS: <a> <b> <c> LIGHT: <light>
And that's it, this is all you need to know to create a new level or parse one.