GetDoorPosition
Where a door stands, from the tables export.
Metres in the level’s space, the door’s place as the level file gives it (the same numbers the level
lists show). nil for a key the export does not know, and for every door when the server runs without the tables export
or with one older than the doors (re-run the exporter). The nearest-object functions are built on it.
Syntax
Section titled “Syntax”GetDoorPosition(key)| Parameter | Type | |
|---|---|---|
key |
string | the door’s level name |
Returns
Section titled “Returns”number, number, number - x, y, z; nil when unknown
Example
Section titled “Example”local x, y, z = GetDoorPosition(key)if x and IsPointInZone(castle, x, y, z) then return factionOf[pid] == "Blue" end -- the castle's doors are the Blue faction'sSee also
Section titled “See also”GetNearestDoor · GetLevelDoors · GetContainerPosition · GetWorldItemPosition · the Doors and containers group of the index
