Difference between revisions of "LOCINFO"

From OdaWiki
(Created page with "LOCINFO is a text lump designed to place names on areas of the map, similar to Quakeworld .loc files or the ZDaemon SECTINFO lump format. It is designed to be parsed with Hex...")
 
Line 1: Line 1:
 
LOCINFO is a text lump designed to place names on areas of the map, similar to Quakeworld .loc files or the ZDaemon SECTINFO lump format.  It is designed to be parsed with Hexen 2's script parser and thus follows similar syntactic conventions to MAPINFO.
 
LOCINFO is a text lump designed to place names on areas of the map, similar to Quakeworld .loc files or the ZDaemon SECTINFO lump format.  It is designed to be parsed with Hexen 2's script parser and thus follows similar syntactic conventions to MAPINFO.
 +
 +
== Definitions ==
 +
 +
All definitions should be on a single line.  All location definitions consist of the location type, the location name, and all parameters for that location.
  
 
'''map <maplump>'''
 
'''map <maplump>'''
Line 5: Line 9:
 
This definition is considered a header for other definitions, which designates which map lump in the WAD they apply to.
 
This definition is considered a header for other definitions, which designates which map lump in the WAD they apply to.
  
'''point <x> <y> <z> <location>'''
+
'''point <location> <x> <y> <z>'''
  
 
This designates an x, y and z location on the map as a specific location.
 
This designates an x, y and z location on the map as a specific location.
  
'''rect <x1> <y1> <x2> <y2> <location>'''
+
'''rect <location> <x1> <y1> <x2> <y2>'''
  
 
This designates an area of the map as a specific location with one corner point at x1, y1 and the other corner point at x2, y2.
 
This designates an area of the map as a specific location with one corner point at x1, y1 and the other corner point at x2, y2.
  
'''circle <x> <y> <radius> <location>'''
+
'''circle <location> <x> <y> <radius>'''
 +
 
 +
This designates an area of the map as a specific location with the center point at x, y and a radius.  Note that this is a true circular radius, not a square one.
 +
 
 +
'''shape <location> <x1> <y1> <x2> <y2> <x3> <y3> [...]
 +
 
 +
''This location type is not implemented yet.  More specifically, it is not yet decided if shapes that cross themselves will follow the even-odd rule or non-zero rule.''
  
This designates an area of the map as a specific location with the center point at x, y and a radiusNote that this is a circular radius, not a square one.
+
An arbitrary closed shape with at least three points at x1, y1, x2, y2 and x3, y3More points can be added, up to a limit of ''(undecided)''.
  
 
== Determining location ==
 
== Determining location ==
  
 
For a particular map definition, any location that has an area or volume to it is checked in order, and the first match 'wins'.  If no area or volume-based locations match, then the distance from the given location is measured between all point locations.  If there are no point locations, no location is returned.
 
For a particular map definition, any location that has an area or volume to it is checked in order, and the first match 'wins'.  If no area or volume-based locations match, then the distance from the given location is measured between all point locations.  If there are no point locations, no location is returned.

Revision as of 22:24, 24 November 2012

LOCINFO is a text lump designed to place names on areas of the map, similar to Quakeworld .loc files or the ZDaemon SECTINFO lump format. It is designed to be parsed with Hexen 2's script parser and thus follows similar syntactic conventions to MAPINFO.

Definitions

All definitions should be on a single line. All location definitions consist of the location type, the location name, and all parameters for that location.

map <maplump>

This definition is considered a header for other definitions, which designates which map lump in the WAD they apply to.

point <location> <x> <y> <z>

This designates an x, y and z location on the map as a specific location.

rect <location> <x1> <y1> <x2> <y2>

This designates an area of the map as a specific location with one corner point at x1, y1 and the other corner point at x2, y2.

circle <location> <x> <y> <radius>

This designates an area of the map as a specific location with the center point at x, y and a radius. Note that this is a true circular radius, not a square one.

shape <location> <x1> <y1> <x2> <y2> <x3> <y3> [...]

This location type is not implemented yet. More specifically, it is not yet decided if shapes that cross themselves will follow the even-odd rule or non-zero rule.

An arbitrary closed shape with at least three points at x1, y1, x2, y2 and x3, y3. More points can be added, up to a limit of (undecided).

Determining location

For a particular map definition, any location that has an area or volume to it is checked in order, and the first match 'wins'. If no area or volume-based locations match, then the distance from the given location is measured between all point locations. If there are no point locations, no location is returned.