API:SPoint
From STNE Wiki
(Difference between revisions)
(Added Functions) |
|||
| Line 15: | Line 15: | ||
!Description | !Description | ||
!Return | !Return | ||
| + | |- | ||
| + | |FromString | ||
| + | |String | ||
| + | |Creates a new SPoint from a String Value, e.g. "155|155" | ||
| + | |Returns a SPoint on success | ||
| + | |- | ||
| + | |op_Equality | ||
| + | |SPoint,SPoint | ||
| + | |Tests if the Paramaters are identic | ||
| + | |If the Test passes, it returns True (Boolean), otherwise False | ||
| + | |- | ||
| + | |op_Inequality | ||
| + | |SPoint,SPoint | ||
| + | |Inversion of op_Equality, tests on differencesf | ||
| + | |If there are differences, Return True (Boolean), otherwise False | ||
| + | |- | ||
| + | |RectangleDiff | ||
| + | |SPoint | ||
| + | |Calculates the distance to the given Point by adding the X and Y Difference. | ||
| + | |Returns the Distance as an Integer | ||
|} | |} | ||
Revision as of 19:59, 25 January 2021
| Scripting Portal | Contents | API Reference | Index |
|---|
The SPoint structure represents a Coordinate in a 2-dimensional-grid.
It is defined with a X-Coordinate and a Y-Coordinate, both as Integers.
Example:
Var point As New SPoint(5,5);
It has also a few Functions and Properties.
| Function | Parameter | Description | Return |
|---|---|---|---|
| FromString | String | 155" | Returns a SPoint on success |
| op_Equality | SPoint,SPoint | Tests if the Paramaters are identic | If the Test passes, it returns True (Boolean), otherwise False |
| op_Inequality | SPoint,SPoint | Inversion of op_Equality, tests on differencesf | If there are differences, Return True (Boolean), otherwise False |
| RectangleDiff | SPoint | Calculates the distance to the given Point by adding the X and Y Difference. | Returns the Distance as an Integer |