This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
| prpl:getmousescreenposition [2016/12/02 23:33] – external edit 127.0.0.1 | prpl:getmousescreenposition [2025/02/14 14:57] (current) – external edit 127.0.0.1 | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | <- [[.: | + | <- [[.: |
| - | ===== | + | ===== |
| ^Arguments^Result^Notation^ | ^Arguments^Result^Notation^ | ||
| - | | | | [ - ] | | + | | | float float | [ - float float ] | |
| === Description === | === Description === | ||
| + | Return the relative (from 0 to 1) position of the mouse on the screen, (0,0) = left-bottom corner, (1,1) = top-right corner. | ||
| === Examples === | === Examples === | ||
| - | < | + | < |
| - | stack.Push(new Data(Input.mousePosition.y / Screen.height)); | + | GetMouseScreenPosition pop 0.5 gt if |
| - | + | #the mouse is in the right half of the screen | |
| + | endif | ||
| </ | </ | ||