-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(game/five): add ped prop collection natives
- Loading branch information
1 parent
7cc7add
commit 77c9445
Showing
3 changed files
with
97 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
--- | ||
ns: CFX | ||
apiset: client | ||
game: gta5 | ||
--- | ||
## GET_PED_PROP_COLLECTION_LOCAL_INDEX | ||
|
||
```c | ||
int GET_PED_PROP_COLLECTION_LOCAL_INDEX(Ped ped, int anchorPoint); | ||
``` | ||
|
||
An analogue to [GET_PED_PROP_INDEX](#_0x898CC20EA75BACD8) that returns collection local prop index (inside [GET_PED_PROP_COLLECTION_NAME](#_0x6B5653E4) collection) instead of the global prop index. | ||
|
||
## Parameters | ||
* **ped**: The target ped | ||
* **anchorPoint**: One of the anchor points from [SET_PED_PROP_INDEX](#_0x93376B65A266EB5F) | ||
|
||
## Return value | ||
Local drawable index of the drawable that is currently used in the given ped and component, or -1 if the ped does not have a prop at the specified anchor point |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
--- | ||
ns: CFX | ||
apiset: client | ||
game: gta5 | ||
--- | ||
## GET_PED_PROP_COLLECTION_NAME | ||
|
||
```c | ||
char* GET_PED_PROP_COLLECTION_NAME(Ped ped, int anchorPoint); | ||
``` | ||
|
||
An analogue to [GET_PED_PROP_INDEX](#_0x898CC20EA75BACD8) that returns collection name instead of the global drawable index. | ||
|
||
Should be used together with [GET_PED_PROP_COLLECTION_LOCAL_INDEX](#_0xCD420AD1). | ||
|
||
## Parameters | ||
* **ped**: The target ped | ||
* **anchorPoint**: One of the anchor points from [SET_PED_PROP_INDEX](#_0x93376B65A266EB5F) | ||
|
||
## Return value | ||
Collection name to which the current prop used in the given ped and anchor point belongs to. Returns null if Ped is not found, does not have a prop at the specified anchor point, or if the index is out of bounds. |