Versions Compared
compared with
Key
- This line was added.
- This line was removed.
- Formatting was changed.
Excerpt |
---|
Centre the camera view on a specific x,y tile co-ordinate... |
Syntax
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
centreView(x,y); |
Parameters
Parameter | Type | Mandatory | Description | Game version |
---|---|---|---|---|
x | Number | The x co-ordinate to show | 3.1 Beta 1 | |
y | Number | The y co-ordinate to show | 3.1 Beta 1 |
Return value
Value | Type | Description | Game version |
---|---|---|---|
undefined | Undefined | The camera view has been updated | 3.1 Beta 1 |
<error> | Error | I assume an error will be thrown if the x,y is out of bounds on the map? | 3.1 Beta 1 |
Example
Code Block | ||||||||
---|---|---|---|---|---|---|---|---|
| ||||||||
eventDroidBuilt(droid) { centreView(droid.x, droid.y); } |
Div | |||||||
---|---|---|---|---|---|---|---|
| |||||||
Availability
Requires:
|
Div | ||||
---|---|---|---|---|
| ||||
ContentsJump to:
|
Div | ||
---|---|---|
| ||
See alsoRelated articles:
|