Resource:Maplimits: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
mNo edit summary
 
(One intermediate revision by one other user not shown)
Line 15: Line 15:
When using maplimits in ones map, at least three points must be made.<br>
When using maplimits in ones map, at least three points must be made.<br>
<br>
<br>
Note that the sequence of points <b>matters</b>. For example, this would create a square shaped border:
Note that the sequence of points <b>matters</b>. Start in the bottom left corner and work counter-clockwise.
 
For example, this would create a square shaped border:
<syntaxhighlight lang="lua">
<syntaxhighlight lang="lua">
<point x="0" y="0" />
<point x="0" y="0" />
Line 30: Line 32:
<point x="1" y="0" />
<point x="1" y="0" />
</syntaxhighlight>
</syntaxhighlight>
[[ru:Resource:Maplimits]]

Latest revision as of 14:26, 16 May 2012

Map Limits is a resource that allows defining points in a .map file to border a map. A player outside the border area will lose health until he dies or returns to the game area.

Usage

Syntax:

<maplimit>
	<point x="" y="" />
	<point x="" y="" />
	<point x="" y="" />
</maplimit>

When using maplimits in ones map, at least three points must be made.

Note that the sequence of points matters. Start in the bottom left corner and work counter-clockwise.

For example, this would create a square shaped border:

<point x="0" y="0" />
<point x="1" y="0" />
<point x="1" y="1" />
<point x="0" y="1" />


While this would create two triangles:

<point x="0" y="0" />
<point x="1" y="1" />
<point x="0" y="1" />
<point x="1" y="0" />