Re-Volt File StructureFilesCoordinate SystemBasic Data Types3D StructuresMesh file (.prm)World file (.w)Mesh (.w)TexAnimation (.w)Frame (.w)PolygonVertexVectorUVBigCube (.w)NCP (.w)Polyhedron (.ncp)Plane (.ncp)Lookup Grid (.ncp)Env List (.w)Bounding Box (.w)Mirror file (.rim)Mirror Entry (.rim)Level File StructuresPosition Node File (.pan)Node (.pan)Instances (.fin)Instance (.fin)Sources
Levels are similar to “Instances”. They consist of two files:
level.w, which is similar to
instance.prm. It contains the “look” of the level.
level.ncp, which is similar to
instance.ncp (but not equal). Contains the “feel” (What you cannot see but drive on).
The positive X-Axis goes to the right, Y downwards and Z forwards.
rvfloat is a 32-bit floating point number,
rvshort a 16-bit integer and goes from -32768 to 32767, and
rvlong a 32-bit floating point number. (Both
rvlong are signed unless explicit marked as unsigned)
type is a bit field with the following values:
|Bit-#||Value||Purpose in .w||Purpose in .prm|
|bit 0||0x001||Polygon is quadratic||Polygon is quadratic|
|bit 1||0x002||Polygon is double-sided||Polygon is double-sided|
|bit 2||0x004||is translucent||is translucent|
|bit 8||0x100||0: Alpha, 1: Additive transmarency||0: Alpha, 1: Additive transmarency|
|bit 10||0x400||unused||Disable EnvMapping|
|bit 11||0x800||Enable EnvMapping||pickup.m: sparkles|
texture is the number of the texture page (0=levela.bmp, 1=levelb.bmp, …). If set to -1, the object won't have any texture.
vertex_indices is a list of three or four indices for the list in the mesh structure. If the polygon is not double-sided, the vertices have to be given in clockwise order. (if you look at it from its “behind”, the points will be ordered ccw, and the poly is invisible)
Position nodes don't consist of much. There is the number of nodes, the ID of the node the track starts with, the total length of the track and a list of Nodes. There is a maximum number of 1024 nodes (limit is hardcoded).
The nodes from the Pos. node file are very straightforward. There is a regular vector for its position, a float for the distance to the finish line and two lists of 4 longs that give you the IDs of the previous and next IDs of the nodes the current node is connected to. There is a maximum of 4 links (limit due to file definition). If there is no link, the value(s) are