Skip to content
This repository was archived by the owner on Jun 1, 2020. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docs/ClientAPI/modules/alt/classes/Player/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

| Property name | Type | Access | Inherited from | Description |
| -------------- | ----------- | -------- | -------- | ----------- |
| all | Array | get | | Replace <span style="color:orange">alt.players</span> since build 569 |
| name | string | get | | |
| scriptID | number | get | | |
| vehicle | Vehicle | get | | |
Expand Down
1 change: 1 addition & 0 deletions docs/ClientAPI/modules/alt/classes/Vehicle/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

| Property name | Type | Access | Inherited from | Description |
| -------------- | ----------- | -------- | -------- | ----------- |
| all | Array | get | | Replace <span style="color:orange">alt.vehicles</span> since build 569 |
| gear | number | get | | |
| rpm | number | get | | |
| scriptID | number | get | | |
Expand Down
14 changes: 11 additions & 3 deletions docs/ClientAPI/modules/alt/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@

| Property name | Type | Access | Description |
| -------------- | ----------- | -------- | ----------- |
| cursorPos | object | set, get | |
| players | Array | get | |
| vehicles | Array | get | |
| cursorPos | object | set, get | <span style="color:red;">Removed in Build 569</span> |
| players | Array | get | <span style="color:red;">Removed in Build 569</span> &#124; now alt.Player.all => [Player](docs/ClientAPI/modules/alt/classes/Player/index.md) |
| vehicles | Array | get | <span style="color:red;">Removed in Build 569</span> &#124; now alt.Vehicle.all => [Vehicle](docs/ClientAPI/modules/alt/classes/Vehicle/index.md) |


## Methods
Expand Down Expand Up @@ -190,4 +190,12 @@ function toggleGameControls(state: boolean);
function wait(waitTime: number);
```

* [getCursorPos](docs/ClientAPI/modules/alt/method_getCursorPos.md)
```js
function getCursorPos();
```

* [setCursorPos](docs/ClientAPI/modules/alt/method_setCursorPos.md)
```js
function setCursorPos(cursorPos: object);
```
7 changes: 7 additions & 0 deletions docs/ClientAPI/modules/alt/method_getCursorPos.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
## alt.getCursorPos

```js
function getCursorPos();
```

[filename](method_getCursorPos_m.md ':include')
10 changes: 10 additions & 0 deletions docs/ClientAPI/modules/alt/method_getCursorPos_m.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
## Example

```js
const cursorPosition = alt.getCursorPos();
alt.log(cursorPosition.x + " | " + cursorPosition.y);
```
Will print you your current cursor position

## References

7 changes: 7 additions & 0 deletions docs/ClientAPI/modules/alt/method_setCursorPos.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
## alt.setCursorPos

```js
function setCursorPos(cursorPos: object);
```

[filename](method_setCursorPos_m.md ':include')
10 changes: 10 additions & 0 deletions docs/ClientAPI/modules/alt/method_setCursorPos_m.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
## Example

```js
alt.setCursorPos({x: 1920/2, y: 1080/2});
```

Will set your cursor to midscreen if your playing in 1920x1080

## References

1 change: 1 addition & 0 deletions docs/ServerAPI/nodejs/modules/alt/classes/Player/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

| Property name | Type | Access | Inherited from | Description |
| -------------- | ----------- | -------- | -------- | ----------- |
| all | Array | get | | Replace <span style="color:orange">alt.players</span> since build 569 |
| health | number | get | | |
| name | string | set, get | | |
| ping | number | get | | |
Expand Down
1 change: 1 addition & 0 deletions docs/ServerAPI/nodejs/modules/alt/classes/Vehicle/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ new Vehicle(model: string, x: number, y: number, z: number, rx: number, ry: numb
| Property name | Type | Access | Inherited from | Description |
| -------------- | ----------- | -------- | -------- | ----------- |
| activeRadioStation | number | set, get | | |
| all | Array | get | | Replace <span style="color:orange">alt.vehicles</span> since build 569 |
| bodyAdditionalHealth | number | set, get | | |
| bodyHealth | number | set, get | | |
| customPrimaryColor | object | set, get | | |
Expand Down