Skip to content

Commit 3d34c58

Browse files
Release 2024-05-27
1 parent af3b5f8 commit 3d34c58

File tree

3 files changed

+151
-25
lines changed

3 files changed

+151
-25
lines changed

docs-gen/client-cfx.def.lua

Lines changed: 141 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -416,6 +416,16 @@ function SetTrainDoorOpenRatio(train, doorIndex, ratio) end
416416
function MumbleAddVoiceTargetPlayerByServerId(targetId, serverId) end
417417

418418

419+
--- Set the vehicle's roll bias. Only works on planes.
420+
---
421+
--- @hash [0x264B45DE](https://docs.fivem.net/natives/?_0x264B45DE)
422+
--- @param vehicle Vehicle
423+
--- @param value number (float)
424+
--- @return void
425+
--- @overload fun(vehicle: Vehicle, value: number): void
426+
function SetVehicleRollBias(vehicle, value) end
427+
428+
419429
--- Removes the specified voice channel from the user's voice targets.
420430
---
421431
--- Performs the opposite operation of [MUMBLE_ADD_VOICE_TARGET_CHANNEL](https://docs.fivem.net/natives/?_0x4D386C9E)
@@ -536,6 +546,16 @@ function SetInteriorPortalRoomFrom(interiorId, portalIndex, roomFrom) end
536546
function SetVehicleCurrentRpm(vehicle, rpm) end
537547

538548

549+
--- Set the vehicle's pitch bias. Only works on planes.
550+
---
551+
--- @hash [0x2A6CC9F2](https://docs.fivem.net/natives/?_0x2A6CC9F2)
552+
--- @param vehicle Vehicle
553+
--- @param value number (float)
554+
--- @return void
555+
--- @overload fun(vehicle: Vehicle, value: number): void
556+
function SetVehiclePitchBias(vehicle, value) end
557+
558+
539559
--- Disables autoswapping to another weapon when the current weapon runs out of ammo.
540560
---
541561
--- @hash [0x2A7B50E](https://docs.fivem.net/natives/?_0x2A7B50E)
@@ -775,7 +795,21 @@ function AddTextEntry(entryKey, entryText) end
775795
function MumbleIsPlayerTalking(player) end
776796

777797

778-
--- GetPlayerFromServerId
798+
--- Gets a local client's Player ID from its server ID counterpart, assuming the passed `serverId` exists on the client.
799+
---
800+
--- If no matching client is found, or an invalid value is passed over as the `serverId` native's parameter, the native result will be `-1`.
801+
---
802+
--- It's worth noting that this native method can only retrieve information about clients that are culled to the connected client.
803+
--- @usage --We will assume the serverId is '4' in this scenario and that it's a valid serverId.
804+
---
805+
--- -- Passing invalid Player IDs such as 'nil' or IDs that don't exist will result in playerId being -1.
806+
---
807+
--- local playerId = GetPlayerFromServerId(serverId);
808+
---
809+
--- -- If the resulting playerId is not invalid (not equal to -1)
810+
--- if playerId ~= -1 then
811+
--- -- Do our stuff on this player.
812+
--- end
779813
---
780814
--- @hash [0x344EA166](https://docs.fivem.net/natives/?_0x344EA166)
781815
--- @param serverId number (int)
@@ -1185,6 +1219,8 @@ function GetWeaponComponentDamageModifier(componentHash) end
11851219

11861220

11871221
--- Loads a minimap overlay from a GFx file in the current resource.
1222+
---
1223+
--- If you need to control the depth of overlay use [`ADD_MINIMAP_OVERLAY_WITH_DEPTH`](https://docs.fivem.net/natives/?_0xED0935B5).
11881224
---
11891225
--- @hash [0x4AFD2499](https://docs.fivem.net/natives/?_0x4AFD2499)
11901226
--- @param name string (char*)
@@ -1617,7 +1653,7 @@ function SetWaterQuadLevel(waterQuad, level) end
16171653
function MumbleSetAudioInputIntent(intentHash) end
16181654

16191655

1620-
--- A getter for [SET_WEAPON_ANIMATION_OVERRIDE](\_0x1055AC3A667F09D9).
1656+
--- A getter for [SET_WEAPON_ANIMATION_OVERRIDE](https://docs.fivem.net/natives/?_0x1055AC3A667F09D9).
16211657
--- @usage local weaponAnimation = GetWeaponAnimationOverride(PlayerPedId()
16221658
--- @hash [0x63ED2E7](https://docs.fivem.net/natives/?_0x63ED2E7)
16231659
--- @param ped Ped
@@ -2123,7 +2159,7 @@ function GetPedDecorations(ped) end
21232159
function GetVehicleLightMultiplier(vehicle) end
21242160

21252161

2126-
--- SetModelHeadlightConfiguration
2162+
--- **This native is deprecated and does nothing!**
21272163
---
21282164
--- @hash [0x7F6B8D75](https://docs.fivem.net/natives/?_0x7F6B8D75)
21292165
--- @param modelHash Hash
@@ -3148,6 +3184,15 @@ function GetWeaponComponentCameraHash(componentHash) end
31483184
function RegisterFontId(fontName) end
31493185

31503186

3187+
--- Sets the text font for the current text drawing command.
3188+
---
3189+
--- @hash [0xADA9255D](https://docs.fivem.net/natives/?_0xADA9255D)
3190+
--- @param fontId number (int)
3191+
--- @return void
3192+
--- @overload fun(fontId: number): void
3193+
function SetTextFontForCurrentCommand(fontId) end
3194+
3195+
31513196
--- Leaves cursor mode. This function supports SDK infrastructure and is not intended to be used directly from your code.
31523197
---
31533198
--- @hash [0xADECF19E](https://docs.fivem.net/natives/?_0xADECF19E)
@@ -3199,6 +3244,17 @@ function GetCalmingQuadDampening(waterQuad, calmingQuadDampening) end
31993244
function CreateRuntimeTextureFromDuiHandle(txd, txn, duiHandle) end
32003245

32013246

3247+
--- Allows the bypassing of default game behavior that prevents the use of [SET_PED_DRIVE_BY_CLIPSET_OVERRIDE](https://docs.fivem.net/natives/?_0xED34AB6C5CB36520) in certain scenarios to avoid clipping issues (e.g., when there is more than one Ped in a vehicle).
3248+
---
3249+
--- Note: This flag and the overridden clipset are not replicated values and require synchronization through user scripts. Additionally, current game behavior also restricts applying this clipset locally when in first-person mode and will require a temporary workaround.
3250+
---
3251+
--- @hash [0xB14F8EAD](https://docs.fivem.net/natives/?_0xB14F8EAD)
3252+
--- @param flag boolean
3253+
--- @return void
3254+
--- @overload fun(flag: boolean): void
3255+
function OverridePedsUseDefaultDriveByClipset(flag) end
3256+
3257+
32023258
--- Disables the editor runtime mode, changing game behavior to not track entity metadata.
32033259
--- This function supports SDK infrastructure and is not intended to be used directly from your code.
32043260
---
@@ -3229,6 +3285,42 @@ function GetWaterQuadCount() end
32293285
function SetVehicleWheelHealth(vehicle, wheelIndex, health) end
32303286

32313287

3288+
--- Purpose: The game's default values for these make shooting while traveling Left quite a bit slower than shooting while traveling right (This could be a game-balance thing?)
3289+
---
3290+
--- Default Min: -45 Degrees
3291+
--- Default Max: 135 Degrees
3292+
---
3293+
--- ```
3294+
--- \ ,- ~ ||~ - ,
3295+
--- , ' \ x x ' ,
3296+
--- ```
3297+
---
3298+
--- , \ x x x ,
3299+
--- , \ x x ,
3300+
--- , \ x x ,
3301+
--- , \ x ,
3302+
--- , \ x ,
3303+
--- , \ x x ,
3304+
--- , \ x ,
3305+
--- , , '
3306+
--- ' - , \_ \_ \_ , ' \\
3307+
---
3308+
--- If the transition angle is within the shaded portion (x), there will be no transition(Quicker)
3309+
--- The angle corresponds to where you are looking(North on the circle) vs. the heading of your Ped.
3310+
--- Note: For some reason,
3311+
---
3312+
--- You can set these values to whatever you'd like with this native, but keep in mind that the transitional spin is only clockwise for some reason.
3313+
---
3314+
--- I'd personally recommend something like -135/135
3315+
---
3316+
--- @hash [0xB300F03](https://docs.fivem.net/natives/?_0xB300F03)
3317+
--- @param min number (float)
3318+
--- @param max number (float)
3319+
--- @return void
3320+
--- @overload fun(min: number, max: number): void
3321+
function SetPedTurningThresholds(min, max) end
3322+
3323+
32323324
--- Sets the height of the vehicle's suspension.
32333325
--- This changes the same value set by Suspension in the mod shop.
32343326
--- Negatives values raise the car. Positive values lower the car.
@@ -3361,6 +3453,24 @@ function GetPedFaceFeature(ped, index) end
33613453
function SetVehicleFuelLevel(vehicle, level) end
33623454

33633455

3456+
--- Draw a glow sphere this frame. Up to 256 per single frame.
3457+
---
3458+
--- @hash [0xBD25EC89](https://docs.fivem.net/natives/?_0xBD25EC89)
3459+
--- @param posX number (float)
3460+
--- @param posY number (float)
3461+
--- @param posZ number (float)
3462+
--- @param radius number (float)
3463+
--- @param colorR number (int)
3464+
--- @param colorG number (int)
3465+
--- @param colorB number (int)
3466+
--- @param intensity number (float)
3467+
--- @param invert boolean
3468+
--- @param marker boolean
3469+
--- @return void
3470+
--- @overload fun(posX: number, posY: number, posZ: number, radius: number, colorR: number, colorG: number, colorB: number, intensity: number, invert: boolean, marker: boolean): void
3471+
function DrawGlowSphere(posX, posY, posZ, radius, colorR, colorG, colorB, intensity, invert, marker) end
3472+
3473+
33643474
--- Sets whether the wheel is powered.
33653475
--- On all wheel drive cars this works to change which wheels receive power, but if a car's fDriveBiasFront doesn't send power to that wheel, it won't get power anyway. This can be fixed by changing the fDriveBiasFront with SET_VEHICLE_HANDLING_FLOAT.
33663476
--- Max number of wheels can be retrieved with the native GET_VEHICLE_NUMBER_OF_WHEELS.
@@ -4232,6 +4342,15 @@ function GetPlayerStamina(playerId) end
42324342
function SetWaveQuadAmplitude(waveQuad, amplitude) end
42334343

42344344

4345+
--- Returns the world position the pointer is hovering on the pause map.
4346+
---
4347+
--- @hash [0xE5AF7A82](https://docs.fivem.net/natives/?_0xE5AF7A82)
4348+
---
4349+
--- @return Vector3
4350+
--- @overload fun(): Vector3
4351+
function GetPauseMapPointerWorldPosition() end
4352+
4353+
42354354
--- Toggles whether the usage of [ADD_ROPE](https://docs.fivem.net/natives/?_0xE832D760399EB220) should create an underlying CNetworkRopeWorldStateData. By default this is set to false.
42364355
---
42374356
--- @hash [0xE62FC73](https://docs.fivem.net/natives/?_0xE62FC73)
@@ -4474,6 +4593,16 @@ function SetVehicleSteeringScale(vehicle, scale) end
44744593
function DrawRectRotated(x, y, width, height, rotation, r, g, b, a) end
44754594

44764595

4596+
--- Loads a minimap overlay from a GFx file in the current resource.
4597+
---
4598+
--- @hash [0xED0935B5](https://docs.fivem.net/natives/?_0xED0935B5)
4599+
--- @param name string (char*)
4600+
--- @param depth number (int)
4601+
--- @return number
4602+
--- @overload fun(name: string, depth: number): number
4603+
function AddMinimapOverlayWithDepth(name, depth) end
4604+
4605+
44774606
--- GetVehicleNumberOfWheels
44784607
---
44794608
--- @hash [0xEDF4B0FC](https://docs.fivem.net/natives/?_0xEDF4B0FC)
@@ -4494,6 +4623,15 @@ function GetVehicleNumberOfWheels(vehicle) end
44944623
function GetEntityIndexFromMapdata(mapdata, entity) end
44954624

44964625

4626+
--- Activates built-in timecycle editing tool.
4627+
---
4628+
--- @hash [0xEEB9B76A](https://docs.fivem.net/natives/?_0xEEB9B76A)
4629+
---
4630+
--- @return void
4631+
--- @overload fun(): void
4632+
function ActivateTimecycleEditor() end
4633+
4634+
44974635
--- See [SET_SCRIPT_GFX_ALIGN](https://docs.fivem.net/natives/?_0xB8A850F20A067EB6) for details about how gfx align works.
44984636
---
44994637
--- @hash [0xEED219F2](https://docs.fivem.net/natives/?_0xEED219F2)

docs-gen/server-cfx.def.lua

Lines changed: 9 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -489,15 +489,6 @@ function GetPlayerIdentifier(playerSrc, identifier) end
489489
function LoadPlayerCommerceDataExt(playerSrc) end
490490

491491

492-
--- NetworkGetVoiceProximityOverride
493-
---
494-
--- @hash [0x7A6462F4](https://docs.fivem.net/natives/?_0x7A6462F4)
495-
--- @param playerSrc string (char*)
496-
--- @return Vector3
497-
--- @overload fun(playerSrc: string): Vector3
498-
function NetworkGetVoiceProximityOverride(playerSrc) end
499-
500-
501492
--- ```
502493
--- Gets the amount of time player has spent evading the cops.
503494
--- Counter starts and increments only when cops are chasing the player.
@@ -793,19 +784,6 @@ function HasVehicleBeenDamagedByBullets(vehicle) end
793784
function DropPlayer(playerSrc, reason) end
794785

795786

796-
--- Used for freemode (online) characters.
797-
---
798-
--- **This is the server-side RPC native equivalent of the client native [\_SET_PED_HAIR_COLOR](?\_0x4CFFC65454C93A49).**
799-
---
800-
--- @hash [0xBB43F090](https://docs.fivem.net/natives/?_0xBB43F090)
801-
--- @param ped Ped
802-
--- @param colorID number (int)
803-
--- @param highlightColorID number (int)
804-
--- @return void
805-
--- @overload fun(ped: Ped, colorID: number, highlightColorID: number): void
806-
function SetPedHairColor(ped, colorID, highlightColorID) end
807-
808-
809787
--- Requests whether or not the commerce data for the specified player has loaded.
810788
---
811789
--- @hash [0xBEFE93F4](https://docs.fivem.net/natives/?_0xBEFE93F4)
@@ -1087,4 +1065,13 @@ function GetPlayerPing(playerSrc) end
10871065
--- @overload fun(playerSrc: string): number
10881066
function GetNumPlayerIdentifiers(playerSrc) end
10891067

1068+
1069+
--- NetworkGetVoiceProximityOverrideForPlayer
1070+
---
1071+
--- @hash [0xFFEEF513](https://docs.fivem.net/natives/?_0xFFEEF513)
1072+
--- @param playerSrc string (char*)
1073+
--- @return Vector3
1074+
--- @overload fun(playerSrc: string): Vector3
1075+
function NetworkGetVoiceProximityOverrideForPlayer(playerSrc) end
1076+
10901077

docs-gen/shared-cfx.def.lua

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -351,6 +351,7 @@ function IsAceAllowed(object) end
351351
--- * 2699
352352
--- * 2802
353353
--- * 2944
354+
--- * 3095
354355
--- * RedM
355356
--- * 1311
356357
--- * 1355

0 commit comments

Comments
 (0)