diff --git a/ENTITY/SetEntityHealth.md b/ENTITY/SetEntityHealth.md index 0300aed1a..4d5c34b53 100644 --- a/ENTITY/SetEntityHealth.md +++ b/ENTITY/SetEntityHealth.md @@ -8,17 +8,18 @@ ns: ENTITY void SET_ENTITY_HEALTH(Entity entity, int health); ``` -health >= 0 +When setting health for player ped entity types, the game clamps the health value to ensure it does not exceed the entity's maximum health. This maximum health can be retrieved by invoking [`GET_PED_MAX_HEALTH`](#_0x4700A416E8324EF3). -male ped ~= 100 - 200 +When setting health for non-player peds, the maximum health will be increased if the new health value exceeds the current maximum, ensuring that the changes take effect. -female ped ~= 0 - 100 +Default health value for peds is `200`. -``` -NativeDB Added Parameter 3: int p2 -``` +Applying this on other entities that are not players or peds won't clamp the value. + +### Added parameters +* **inflictor**: The handle for the entity that caused the damage. ## Parameters -* **entity**: -* **health**: +* **entity**: The entity handle. +* **health**: The health we should set this entity to. diff --git a/PED/IsPedInjured.md b/PED/IsPedInjured.md index 0fbbd39c3..9f770a810 100644 --- a/PED/IsPedInjured.md +++ b/PED/IsPedInjured.md @@ -8,12 +8,20 @@ ns: PED BOOL IS_PED_INJURED(Ped ped); ``` -``` -Gets a value indicating whether this ped's health is below its injured threshold. -The default threshold is 100. -``` +Indicates whether this ped's health is below its injured threshold. +The default threshold is 100, these are stored in the `pedhealth.meta` file located in `common:\data\` + +### Below are some of the values + +| InjuredHealthThreshold | Name | +|------------------------|-----------| +| 100.000000 | Strong | +| 100.000000 | Average | +| 100.000000 | Weak | + ## Parameters -* **ped**: +* **ped**: The ped to check for injuries. ## Return value +A boolean representing whether the passed ped is injured or not. \ No newline at end of file diff --git a/PED/SetPedMaxHealth.md b/PED/SetPedMaxHealth.md index 256e3c335..36cb6c16c 100644 --- a/PED/SetPedMaxHealth.md +++ b/PED/SetPedMaxHealth.md @@ -8,12 +8,7 @@ ns: PED void SET_PED_MAX_HEALTH(Ped ped, int value); ``` -``` -sets the maximum health of a ped -I think it's never been used in any script -``` - ## Parameters -* **ped**: -* **value**: +* **ped**: The ped handle we're setting this for. +* **value**: The new max health.