This commit is contained in:
Luke committed 2023-06-04 15:15:21 +02:00
1 parent 3cebaf7fa5
commit b5eba8423f
229 files changed
+6238 -10690

No files matched your search

+26
View File
@@ -0,0 +1,26 @@
# Usage
When calling exports to add options, the input is an array of tables with the following properties.
- label: `string` Display text.
- name?: `string` Used as an identifier to remove the option.
- icon?: `string` Name of a [Font Awesome](https://fontawesome.com/icons) icon.
- iconColor?: `string`
- distance?: `number`
- bones?: `string` | `string[]`
- A bone name or array of bone names (refer to [GetEntityBoneIndexByName](https://docs.fivem.net/natives/?_0xFB71170B7E76ACBA)).
- groups?: `string` | `string[]` | `table<string, number>`
- A group, array of groups, or pairs of groups-grades required to show the option.
- Groups are framework dependent, and may refer to jobs, gangs, etc.
- items?: `string` | `string[]` | `table<string, number>`
- An item, array of items, or pairs of items-count required to show the option.
- Items are framework dependent.
- anyItem?: `boolean`
- Only require a single item from the items table to exist.
- canInteract?: `function(entity, distance, coords, name, bone)`
- Do not use this function to "return true". Options will always display if this is undefined.
- onSelect?: `function(data)`
- export?: `string`
- event?: `string`
- serverEvent?: `string`
- command?: `string`