Difference between revisions of "Map Points"

From SphereWiki
Jump to: navigation, search
m (Added languagemenue)
Line 1: Line 1:
 +
{{Languages|Map_Points}}
 +
 
__FORCETOC__
 
__FORCETOC__
 
A map point is a specific location on a world map, defined by X, Y, Z and M coordinates. Map point references, such as ''P'' from the [[Characters|character]]/[[Items|item]] object and ''MAP(x,y,map)'' from the [[Server|server]] object can be used to access additional information about a map point such as what static items exist at the location. The following tables detail the various properties of map points in SphereServer:
 
A map point is a specific location on a world map, defined by X, Y, Z and M coordinates. Map point references, such as ''P'' from the [[Characters|character]]/[[Items|item]] object and ''MAP(x,y,map)'' from the [[Server|server]] object can be used to access additional information about a map point such as what static items exist at the location. The following tables detail the various properties of map points in SphereServer:

Revision as of 21:49, 26 November 2010

Help
Available languages


A map point is a specific location on a world map, defined by X, Y, Z and M coordinates. Map point references, such as P from the character/item object and MAP(x,y,map) from the server object can be used to access additional information about a map point such as what static items exist at the location. The following tables detail the various properties of map points in SphereServer:


References

References return pointers to other objects (e.g. the REGION reference allows you to access the region that contains the map point). These can either be accessed by using <REFNAME> to return the UID (1 for object types that don't have UIDs) of the object or 0 if it doesn't exist, or by using <REFNAME.KEY> where KEY is a valid property/function/reference for the REFNAME object. Click on the name for more detailed information such as usage and examples.

Name Read/Write Description
REGION R Gets the region that contains the map point.
ROOM R Gets the room that contains the map point.
SECTOR R Gets the sector that contains the map point.


Properties and Functions

Here is a list of all map point properties and functions. If a function is marked as readable then it can return a value when used as <KEY>. Click on the name for more detailed information such as usage and examples.

Name Read/Write Description
ISNEARTYPE type, distance, check_multis R Returns 1 if an item exists within distance tiles of the location whose TYPE matches a specified type.
M
MAP
R Gets the location's map number.
STATICS R Gets the number of static items at the location.
STATICS.n.ID R Gets the ID of the nth item at the location. (zero-based)
STATICS.n.COLOR R Gets the hue of the nth item at the location. (zero-based)
STATICS.n.Z R Gets the Z level of the nth item at the location. (zero-based)
STATICS.n.KEY R Gets the KEY property from the ITEMDEF of the nth item at the location. (zero-based)
TERRAIN R Gets the terrain's ID at the location.
TERRAIN.Z R Gets the terrain's Z level at the location.
TYPE R Gets the terrain's TYPE at the location.
X R Gets the X coordinate of the location.
Y R Gets the Y coordinate of the location.
Z R Gets the Z coordinate of the location.