ScreenToWorldCoordinates (Harvest)
From OxeyeWiki
(Difference between revisions)
| Line 1: | Line 1: | ||
{{HarvestMethod | {{HarvestMethod | ||
| | | | ||
| - | worldX, worldY | + | worldX, worldY == screenToWorldCoordinates(screenX, screenY) |
| | | | ||
Converts screen coordinates to world coordinates. | Converts screen coordinates to world coordinates. | ||
Revision as of 22:40, 1 December 2009
|
Converts screen coordinates to world coordinates. | |||||
| screenX | Number | The x coordinate of the current screen | |||
| screenY | Number | The y coordinate of the current screen | |||
| Parameter | Expected Type | Description | |||
| Returns | |||||
| {{{4}}} | |||||
Example
local x,y = harvest.screenToWorldCoordinates(mouseX, mouseY) harvest.spawnChargeBomb(x, y)