Skip to content

Commit

Permalink
Release 2023-01-30
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Jan 30, 2023
1 parent 2452e3f commit e95e926
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 44 deletions.
18 changes: 5 additions & 13 deletions docs-gen/native-entity.def.lua
Original file line number Diff line number Diff line change
Expand Up @@ -1738,9 +1738,7 @@ function N_0x9ebc85ed0fffe51c(entity, toggle, keepPhysics) end
function SetEntityCollision_2(entity, toggle, keepPhysics) end


--- ```
--- Returns the model hash from the entity
--- ```
--- Returns the model hash from an entity.
--- @usage local hash = GetEntityModel(PlayerPedId())
---
--- if hash == `mp_m_freemode_01` then
Expand Down Expand Up @@ -1821,13 +1819,9 @@ function N_0xa80ae305e0a3044f(entity, toggle) end
function SetEntityAlwaysPrerender(entity, toggle) end


--- ```
--- Makes the specified entity (ped, vehicle or object) persistent. Persistent entities will not automatically be removed by the engine.
--- p1 has no effect when either its on or off
--- maybe a quick disassembly will tell us what it does
--- p2 has no effect when either its on or off
--- maybe a quick disassembly will tell us what it does
--- ```
--- Assigns an existing entity to be owned by the current script. If the entity was not owned by a script yet, this also means the entity will remain persistent until released.
---
--- Note that this is not needed right after creating an entity as a script-created entity will automatically be assigned.
---
--- @hash [0xAD738C3085FE7E11](https://docs.fivem.net/natives/?_0xAD738C3085FE7E11)
--- @param entity Entity
Expand All @@ -1838,9 +1832,7 @@ function SetEntityAlwaysPrerender(entity, toggle) end
function SetEntityAsMissionEntity(entity, p1, p2) end


--- ```
--- Deletes the specified entity, then sets the handle pointed to by the pointer to NULL.
--- ```
--- Deletes the specified entity, and invalidates the passed handle (i.e. in/out argument).
---
--- @hash [0xAE3CBE5BF394C9C9](https://docs.fivem.net/natives/?_0xAE3CBE5BF394C9C9)
--- @param entity Entity (Entity*)
Expand Down
18 changes: 7 additions & 11 deletions docs-gen/native-player.def.lua
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,14 @@
function N_0x0032a6dba562c518() end


--- Set the model for a specific Player. Be aware that this will destroy the current Ped for the Player and create a new one, any reference to the old ped should be reset
--- Make sure to request the model first and wait until it has loaded.
--- @usage local model = 'a_f_m_beach_01'
--- Set the model for a specific Player. Note that this will destroy the current Ped for the Player and create a new one, any reference to the old ped will be invalid after calling this.
---
--- As per usual, make sure to request the model first and wait until it has loaded.
--- @usage local model = `a_f_m_beach_01`
--- if IsModelInCdimage(model) and IsModelValid(model) then
--- RequestModel(model)
--- while not HasModelLoaded(model) do
--- Citizen.Wait(0)
--- Wait(0)
--- end
--- SetPlayerModel(PlayerId(), model)
--- SetModelAsNoLongerNeeded(model)
Expand Down Expand Up @@ -952,10 +953,7 @@ function SetPlayerStealthPerceptionModifier(player, value) end
function IsPlayerRidingTrain(player) end


--- ```
--- This returns YOUR 'identity' as a Player type.
--- Always returns 0 in story mode.
--- ```
--- Returns the player index for the local player.
---
--- @hash [0x4F8644AF03D0E0D6](https://docs.fivem.net/natives/?_0x4F8644AF03D0E0D6)
---
Expand Down Expand Up @@ -2834,9 +2832,7 @@ function SpecialAbilityDeactivate(player) end
function HasPlayerBeenSpottedInStolenVehicle(player) end


--- ```
--- Returns current player ped
--- ```
--- Returns the entity handle for the local player ped. Note that this entity handle will change after using commands such as SET_PLAYER_MODEL.
---
--- @hash [0xD80958FC74E988A6](https://docs.fivem.net/natives/?_0xD80958FC74E988A6)
---
Expand Down
25 changes: 15 additions & 10 deletions docs-gen/native-streaming.def.lua
Original file line number Diff line number Diff line change
Expand Up @@ -1052,20 +1052,27 @@ function N_0x95a7dabddbb78ae7(iplName1, iplName2) end
function StopPlayerSwitch() end


--- ```
--- Request a model to be loaded into memory.
--- ```
---
--- Request a model (archetype) to be loaded for use by the current script. Use SET_MODEL_AS_NO_LONGER_NEEDED when done using the model in script.
--- @usage local modelHash = `adder`
--- RequestModel(modelHash)
--- while not HasModelLoaded(modelHash) do
--- Wait(0)
--- end
---
--- -- omitted: creating a vehicle
---
--- -- when done using the model
--- SetModelAsNoLongerNeeded(modelHash
--- @hash [0x963D27A58DF860AC](https://docs.fivem.net/natives/?_0x963D27A58DF860AC)
--- @param model Hash
--- @return void
--- @overload fun(model: Hash): void
function RequestModel(model) end


--- ```
--- Checks if the specified model has loaded into memory.
--- ```
--- Returns whether the specified model (archetype) is currently loaded.
---
--- Note that this will return 'true' even if the model has been requested and loaded by something other than the current script, if you're intending to actually use the model in a later frame, you should call REQUEST_MODEL anyway.
---
--- @hash [0x98A4EB5D89A0C952](https://docs.fivem.net/natives/?_0x98A4EB5D89A0C952)
--- @param model Hash
Expand Down Expand Up @@ -1779,9 +1786,7 @@ function N_0xdfa80cb25d0a19b3() end
function SetInteriorActive(interiorID, toggle) end


--- ```
--- Unloads model from memory
--- ```
--- Releases the script ownership assigned by REQUEST_MODEL. This command should be used when done using a specific model hash in script.
---
--- @hash [0xE532F5D78798DAAB](https://docs.fivem.net/natives/?_0xE532F5D78798DAAB)
--- @param model Hash
Expand Down
13 changes: 3 additions & 10 deletions docs-gen/native-vehicle.def.lua
Original file line number Diff line number Diff line change
Expand Up @@ -9414,8 +9414,8 @@ function N_0xaf03011701811146(vehicle, entity) end
--- @usage local ModelHash = `adder` -- Use Compile-time hashes to get the hash of this model
--- if not IsModelInCdimage(ModelHash) then return end
--- RequestModel(ModelHash) -- Request the model
--- while not HasModelLoaded(ModelHash) do -- Waits for the model to load with a check so it does not get stuck in an infinite loop
--- Citizen.Wait(10)
--- while not HasModelLoaded(ModelHash) do -- Waits for the model to load
--- Wait(0)
--- end
--- local MyPed = PlayerPedId()
--- local Vehicle = CreateVehicle(ModelHash, GetEntityCoords(MyPed), GetEntityHeading(MyPed), true, false) -- Spawns a networked vehicle on your current coords
Expand Down Expand Up @@ -9562,14 +9562,7 @@ function N_0xb0ad1238a709b1a2(vehicle) end
function IsVehicleOnAllWheels(vehicle) end


--- ```
--- Returns model name of vehicle in all caps. Needs to be displayed through localizing text natives to get proper display name.
--- -----------------------------------------------------------------------------------------------------------------------------------------
--- While often the case, this does not simply return the model name of the vehicle (which could be hashed to return the model hash). Variations of the same vehicle may also use the same display name.
--- -----------------------------------------------------------------------------------------------------------------------------------------
--- Returns "CARNOTFOUND" if the hash doesn't match a vehicle hash.
--- Using HUD::_GET_LABEL_TEXT, you can get the localized name.
--- ```
--- Returns the display name/text label (`gameName` in `vehicles.meta`) for the specified vehicle model.
---
--- @hash [0xB215AAC32D25D019](https://docs.fivem.net/natives/?_0xB215AAC32D25D019)
--- @param modelHash Hash
Expand Down

0 comments on commit e95e926

Please sign in to comment.