IsPedBleeding: Difference between revisions
Jump to navigation
Jump to search
(Created page with "{{Client function}} __NOTOC__ {{New feature/item|3.0159|1.5.8|20935|This function gets the state of a player's or ped's bleeding effect.}} ==Syntax== <synt...") |
|||
Line 13: | Line 13: | ||
==Example== | ==Example== | ||
Example by Hydra | |||
<syntaxhighlight lang="lua"> | |||
function checkBleeding() | |||
if isPedBleeding(localPlayer) then | |||
outputChatBox("The ped is bleeding") | |||
else | |||
outputChatBox("The ped is not bleeding") | |||
end | |||
end | |||
addCommandHandler("cBleed", checkBleeding | |||
</syntaxhighlight> | |||
==Requirements== | ==Requirements== |
Revision as of 08:12, 1 September 2021
This function gets the state of a player's or ped's bleeding effect.
Syntax
bool isPedBleeding( ped thePed )
OOP Syntax Help! I don't understand this!
- Method: ped:isBleeding(...)
- Variable: .bleeding
- Counterpart: setPedBleeding
Required Arguments
- thePed: the player or ped whose bleeding effect state you want to get.
Returns
Returns true if the player or ped is bleeding, false otherwise.
Example
Example by Hydra
function checkBleeding() if isPedBleeding(localPlayer) then outputChatBox("The ped is bleeding") else outputChatBox("The ped is not bleeding") end end addCommandHandler("cBleed", checkBleeding
Requirements
This template will be deleted.
See Also
- canPedBeKnockedOffBike
- getPedAnalogControlState
- getPedAnimation
- getPedBonePosition
- getPedCameraRotation
- getPedControlState
- getPedMoveState
- getPedOxygenLevel
- getPedSimplestTask
- getPedTargetCollision
- getPedTargetEnd
- getPedTargetStart
- getPedTask
- getPedVoice
- getPedWeaponMuzzlePosition
- givePedWeapon
- isPedBleeding
- isPedDoingTask
- isPedReloadingWeapon
- isPedTargetingMarkerEnabled
- setAnalogControlState
- setPedAimTarget
- setPedAnalogControlState
- setPedBleeding
- setPedCameraRotation
- setPedCanBeKnockedOffBike
- setPedControlState
- setPedEnterVehicle
- setPedExitVehicle
- IsPedFootBloodEnabled
- setPedFootBloodEnabled
- setPedLookAt
- setPedOxygenLevel
- setPedTargetingMarkerEnabled
- setPedVoice
- Shared
- addPedClothes
- getPedClothes
- removePedClothes
- createPed
- getPedAmmoInClip
- getPedArmor
- getPedFightingStyle
- getPedOccupiedVehicle
- getPedOccupiedVehicleSeat
- getPedStat
- getPedTarget
- getPedTotalAmmo
- getPedWalkingStyle
- getPedWeapon
- getPedWeaponSlot
- getPedContactElement
- getValidPedModels
- isPedChoking
- isPedDead
- isPedDoingGangDriveby
- isPedDucked
- isPedHeadless
- isPedInVehicle
- isPedOnFire
- isPedOnGround
- isPedWearingJetpack
- killPed
- removePedFromVehicle
- setPedAnimation
- setPedAnimationProgress
- setPedAnimationSpeed
- setPedArmor
- setPedDoingGangDriveby
- setPedFightingStyle
- setPedHeadless
- setPedOnFire
- setPedStat
- setPedWalkingStyle
- setPedWeaponSlot
- warpPedIntoVehicle