FivePD API
EntityWrappers/PedWrapper

FPedProperties

Represents the properties of a FPed, providing access to various ped attributes and behaviors.

Methods

CurrentVehicle

Gets the vehicle the ped is currently in, if any.

Returns

NameType
async Task<Vehicle>A task that resolves to the current vehicle, or null if not in a vehicle.

LastVehicle

Gets the last vehicle the ped was in.

Returns

NameType
async Task<Vehicle>A task that resolves to the last vehicle, or null if none.

SeatIndex

Gets the ped's current seat index in their vehicle.

Returns

NameType
async Task<FVehicleSeat>A task that resolves to the vehicle seat position.

VehicleTryingToEnter

Gets the vehicle the ped is attempting to enter.

Returns

NameType
async Task<Vehicle>A task that resolves to the target vehicle, or null if none.

VehicleWeapon

Gets the weapon hash of the ped's vehicle weapon.

Returns

NameType
async Task<FWeaponHash>A task that resolves to the weapon hash.

SetAccuracy

Sets the accuracy value for the ped, affecting their ability to hit targets.

Parameters

NameTypeDescription
valueintThe accuracy value to set.

SetAlwaysDiesOnLowHealth

Sets whether the ped should always die when their health is low.

Parameters

NameTypeDescription
valueboolTrue to make the ped die on low health, false otherwise.

SetAlwaysKeepTask

Sets whether the ped should always keep their current task.

Parameters

NameTypeDescription
valueboolTrue to make the ped keep their current task, false otherwise.

SetArmor

Sets the armor value for the ped.

Parameters

NameTypeDescription
valueintThe armor value to set.

SetArmorFloat

Sets the armor value for the ped as a float.

Parameters

NameTypeDescription
valuefloatThe armor value to set.

SetBlockPermanentEvents

Sets whether the ped should block permanent events.

Parameters

NameTypeDescription
valueboolTrue to block permanent events, false otherwise.

SetCanBeDraggedOutOfVehicle

Sets whether the ped can be dragged out of vehicles.

Parameters

NameTypeDescription
valueboolTrue to allow being dragged out, false otherwise.

SetCanBeKnockedOffBike

Sets whether the ped can be knocked off bikes.

Parameters

NameTypeDescription
valueboolTrue to allow being knocked off bikes, false otherwise.

SetCanBeShotInVehicle

Sets whether the ped can be shot while in a vehicle.

Parameters

NameTypeDescription
valueboolTrue to allow being shot in vehicles, false otherwise.

SetCanBeTargetted

Sets whether the ped can be targeted by other entities.

Parameters

NameTypeDescription
valueboolTrue to allow being targeted, false otherwise.

SetCanFlyThroughWindscreen

Sets whether the ped can fly through windscreens in collisions.

Parameters

NameTypeDescription
valueboolTrue to allow flying through windscreens, false otherwise.

SetCanPlayGestures

Sets whether the ped can perform gesture animations.

Parameters

NameTypeDescription
valueboolTrue to allow gesture animations, false otherwise.

SetCanRagdoll

Sets the "CanRagdoll" property of the ped.

Parameters

NameTypeDescription
valueboolValue.

SetCanSufferCriticalHits

Sets the "CanSufferCriticalHits" property of the ped.

Parameters

NameTypeDescription
valueboolValue.

SetCanSwitchWeapons

Sets the "CanSwitchWeapons" property of the ped.

Parameters

NameTypeDescription
valueboolValue.

SetCanWearHelmet

Sets the "CanWearHelmet" property of the ped.

Parameters

NameTypeDescription
valueboolValue.

SetCanWrithe

Sets the "CanWrithe" property of the ped.

Parameters

NameTypeDescription
valueboolValue.

SetDiesInstantlyInWater

Sets the "DiesInstantlyInWater" property of the ped.

Parameters

NameTypeDescription
valueboolValue.

SetDrivingSpeed

Sets the "DrivingSpeed" property of the ped.

Parameters

NameTypeDescription
valuefloatValue.

SetDrivingStyle

Sets the "DrivingStyle" property of the ped.

Parameters

NameTypeDescription
valueFDrivingStyleValue.

SetDropsWeaponsOnDeath

Sets the "DropsWeaponsOnDeath" property of the ped.

Parameters

NameTypeDescription
valueboolValue.

SetDrownsInSinkingVehicle

Sets the "DrownsInSinkingVehicle" property of the ped.

Parameters

NameTypeDescription
valueboolValue.

SetDrownsInWater

Sets the "DrownsInWater" property of the ped.

Parameters

NameTypeDescription
valueboolValue.

SetFatalInjuryHealthThreshold

Sets the "FatalInjuryHealthThreshold" property of the ped.

Parameters

NameTypeDescription
valuefloatValue.

SetInjuryHealthThreshold

Sets the "InjuryHealthThreshold" property of the ped.

Parameters

NameTypeDescription
valuefloatValue.

SetIsDucking

Sets the "IsDucking" property of the ped.

Parameters

NameTypeDescription
valuefloatValue.

SetIsEnemy

Sets the "IsEnemy" property of the ped.

Parameters

NameTypeDescription
valuefloatValue.

SetIsPainAudioEnabled

Sets the "IsPainAudioEnabled" property of the ped.

Parameters

NameTypeDescription
valueboolValue.

SetIsPriorityTargetForEnemies

Sets the "IsPriorityTargetForEnemies" property of the ped.

Parameters

NameTypeDescription
valueboolValue.

SetMaxDrivingSpeed

Sets the "MaxDrivingSpeed" property of the ped.

Parameters

NameTypeDescription
valuefloatValue.

SetMoney

Sets the "Money" property of the ped.

Parameters

NameTypeDescription
valueintValue.

SetMovementAnimationSet

Sets the "MovementAnimationSet" property of the ped.

Parameters

NameTypeDescription
valuestringValue.

SetNeverLeavesGroup

Sets the "NeverLeavesGroup" property of the ped.

Parameters

NameTypeDescription
valueboolValue.

SetShootRate

Sets the "ShootRate" property of the ped.

Parameters

NameTypeDescription
valueintValue.

SetStaysInVehicleWhenJacked

Sets the "StaysInVehicleWhenJacked" property of the ped.

Parameters

NameTypeDescription
valueboolValue.

SetSweat

Sets the "Sweat" property of the ped.

Parameters

NameTypeDescription
valuefloatValue.

SetVehicleDrivingFlags

Sets the "VehicleDrivingFlags" property of the ped.

Parameters

NameTypeDescription
valueFVehicleDrivingFlagsValue.

SetVoice

Sets the "Voice" property of the ped.

Parameters

NameTypeDescription
valuestringValue.

SetWetnessHeight

Sets the "WetnessHeight" property of the ped.

Parameters

NameTypeDescription
valuefloatValue.

SetIntoVehicle

Places the ped into a specific vehicle seat.

Parameters

NameTypeDescription
vehicleVehicleThe vehicle to enter.
vehicleSeatFVehicleSeatThe seat position to use.

MarkAsNoLongerNeeded

Marks the ped as no longer needed, allowing it to be cleaned up by the game.

CreateBlip

Creates a blip on the map for this ped.

Parameters

NameTypeDescription
spriteFBlipSpriteThe sprite to use for the blip.
colorFBlipColorThe color to use for the blip.
textstringOptional text to display on the blip.

RemoveBlips

Removes all blips associated with this ped.

Properties

Accuracy

Gets the ped's accuracy value, affecting their ability to hit targets.

Type: Task<int>

Armor

Gets the ped's armor value as an integer.

Type: Task<int>

ArmorFloat

Gets the ped's armor value as a float.

Type: Task<float>

CanFlyThroughWindscreen

Gets a value indicating whether the ped can be ejected through the windscreen in vehicle collisions.

Type: Task<bool>

CanRagdoll

Gets the ped's armor value as a float.

Type: Task<bool>

CanSufferCriticalHits

Gets the ped's armor value as a float.

Type: Task<bool>

CanWrithe

Gets the ped's armor value as a float.

Type: Task<bool>

DropsWeaponsOnDeath

Gets the ped's armor value as a float.

Type: Task<bool>

FatalInjuryHealthThreshold

Gets the ped's armor value as a float.

Type: Task<float>

IsDead

Gets a value indicating whether the ped is dead.

Type: bool

IsInVehicle

Gets a value indicating whether the ped is in a vehicle.

Type: bool

InjuryHealthThreshold

Gets the health threshold at which the ped will be considered injured.

Type: Task<float>

IsAiming

Gets a value indicating whether the ped is currently aiming a weapon.

Type: Task<bool>

IsAimingFromCover

Gets a value indicating whether the ped is aiming while in cover.

Type: Task<bool>

IsAmbientSpeechEnabled

Gets a value indicating whether ambient speech is enabled for the ped.

Type: Task<bool>

IsAmbientSpeechplaying

Gets a value indicating whether the ped is currently playing ambient speech.

Type: Task<bool>

IsBeingJacked

Gets a value indicating whether the ped is currently being carjacked.

Type: Task<bool>

IsBeingStealthKilled

Gets a value indicating whether the ped is being stealth killed.

Type: Task<bool>

IsBeingStunned

Gets a value indicating whether the ped is being stunned.

Type: Task<bool>

IsClimbing

Gets a value indicating whether the ped is climbing.

Type: Task<bool>

IsCuffed

Gets a value indicating whether the ped is handcuffed.

Type: Task<bool>

IsDiving

Gets a value indicating whether the ped is diving.

Type: Task<bool>

IsDoingDriveBy

Gets a value indicating whether the ped is performing a drive-by shooting.

Type: Task<bool>

IsDucking

Gets a value indicating whether the ped is in a ducking stance.

Type: Task<bool>

IsFalling

Gets a value indicating whether the ped is falling.

Type: Task<bool>

IsFleeing

Gets a value indicating whether the ped is fleeing from a threat.

Type: Task<bool>

IsGettingIntoAVehicle

Gets a value indicating whether the ped is entering a vehicle.

Type: Task<bool>

IsGettingUp

Gets a value indicating whether the ped is getting up from the ground.

Type: Task<bool>

IsGoingIntoCover

Gets a value indicating whether the ped is moving to take cover.

Type: Task<bool>

IsHuman

Gets a value indicating whether the ped is a human (as opposed to an animal).

Type: Task<bool>

IsIdle

Gets a value indicating whether the ped is in an idle state.

Type: Task<bool>

IsInBoat

Gets a value indicating whether the ped is in a boat.

Type: Task<bool>

IsInCombat

Gets a value indicating whether the ped is engaged in combat.

Type: Task<bool>

IsInCoverFacingLeft

Gets a value indicating whether the ped is in cover and facing left.

Type: Task<bool>

IsInFlyingVehicle

Gets a value indicating whether the ped is in a flying vehicle.

Type: Task<bool>

IsInGroup

Gets a value indicating whether the ped is part of a group.

Type: Task<bool>

IsInHeli

Gets a value indicating whether the ped is in a helicopter.

Type: Task<bool>

IsInjured

Gets a value indicating whether the ped is injured.

Type: Task<bool>

IsInMeleeCombat

Gets a value indicating whether the ped is engaged in melee combat.

Type: Task<bool>

IsInParachuteFreeFall

Gets a value indicating whether the ped is in a parachute free fall.

Type: Task<bool>

IsInPlane

Gets a value indicating whether the ped is in a plane.

Type: Task<bool>

IsInPoliceVehicle

Gets a value indicating whether the ped is in a police vehicle.

Type: Task<bool>

IsInStealthMode

Gets a value indicating whether the ped is in stealth mode.

Type: Task<bool>

IsInSub

Gets a value indicating whether the ped is in a submarine.

Type: Task<bool>

IsInTaxi

Gets a value indicating whether the ped is in a taxi.

Type: Task<bool>

IsInTrain

Gets a value indicating whether the ped is in a train.

Type: Task<bool>

IsJacking

Gets a value indicating whether the ped is carjacking another vehicle.

Type: Task<bool>

IsJumping

Gets a value indicating whether the ped is jumping.

Type: Task<bool>

IsJumpingOutOfVehicle

Gets a value indicating whether the ped is jumping out of a vehicle.

Type: Task<bool>

IsOnBike

Gets a value indicating whether the ped is on a bike.

Type: Task<bool>

IsOnFoot

Gets a value indicating whether the ped is on foot.

Type: Task<bool>

IsPerformingStealthKill

Gets a value indicating whether the ped is performing a stealth kill.

Type: Task<bool>

IsPlantingBomb

Gets a value indicating whether the ped is planting a bomb.

Type: Task<bool>

IsPlayer

Gets a value indicating whether the ped is a player character.

Type: Task<bool>

IsProne

Gets a value indicating whether the ped is prone.

Type: Task<bool>

IsReloading

Gets a value indicating whether the ped is reloading their weapon.

Type: Task<bool>

IsRunning

Gets a value indicating whether the ped is running.

Type: Task<bool>

IsScriptedSpeechplaying

Gets a value indicating whether the ped is playing scripted speech.

Type: Task<bool>

IsShooting

Gets a value indicating whether the ped is shooting.

Type: Task<bool>

IsSprinting

Gets a value indicating whether the ped is sprinting.

Type: Task<bool>

IsStopped

Gets a value indicating whether the ped is stopped.

Type: Task<bool>

IsSwimming

Gets a value indicating whether the ped is swimming.

Type: Task<bool>

IsSwimmingUnderWater

Gets a value indicating whether the ped is swimming underwater.

Type: Task<bool>

IsTryingToEnterALockedVehicle

Gets a value indicating whether the ped is attempting to enter a locked vehicle.

Type: Task<bool>

IsVaulting

Gets a value indicating whether the ped is vaulting over an obstacle.

Type: Task<bool>

IsWalking

Gets a value indicating whether the ped is walking.

Type: Task<bool>

IsWearingHelmet

Gets a value indicating whether the ped is wearing a helmet.

Type: Task<bool>

Money

Gets the amount of money the ped is carrying.

Type: Task<int>

Sweat

Gets the ped's sweat level.

Type: Task<float>

WasKilledByStealth

Gets a value indicating whether the ped was killed by a stealth attack.

Type: Task<bool>

WasKilledByTakedown

Gets a value indicating whether the ped was killed by a takedown.

Type: Task<bool>

On this page

MethodsCurrentVehicleLastVehicleSeatIndexVehicleTryingToEnterVehicleWeaponSetAccuracySetAlwaysDiesOnLowHealthSetAlwaysKeepTaskSetArmorSetArmorFloatSetBlockPermanentEventsSetCanBeDraggedOutOfVehicleSetCanBeKnockedOffBikeSetCanBeShotInVehicleSetCanBeTargettedSetCanFlyThroughWindscreenSetCanPlayGesturesSetCanRagdollSetCanSufferCriticalHitsSetCanSwitchWeaponsSetCanWearHelmetSetCanWritheSetDiesInstantlyInWaterSetDrivingSpeedSetDrivingStyleSetDropsWeaponsOnDeathSetDrownsInSinkingVehicleSetDrownsInWaterSetFatalInjuryHealthThresholdSetInjuryHealthThresholdSetIsDuckingSetIsEnemySetIsPainAudioEnabledSetIsPriorityTargetForEnemiesSetMaxDrivingSpeedSetMoneySetMovementAnimationSetSetNeverLeavesGroupSetShootRateSetStaysInVehicleWhenJackedSetSweatSetVehicleDrivingFlagsSetVoiceSetWetnessHeightSetIntoVehicleMarkAsNoLongerNeededCreateBlipRemoveBlipsPropertiesAccuracyArmorArmorFloatCanFlyThroughWindscreenCanRagdollCanSufferCriticalHitsCanWritheDropsWeaponsOnDeathFatalInjuryHealthThresholdIsDeadIsInVehicleInjuryHealthThresholdIsAimingIsAimingFromCoverIsAmbientSpeechEnabledIsAmbientSpeechplayingIsBeingJackedIsBeingStealthKilledIsBeingStunnedIsClimbingIsCuffedIsDivingIsDoingDriveByIsDuckingIsFallingIsFleeingIsGettingIntoAVehicleIsGettingUpIsGoingIntoCoverIsHumanIsIdleIsInBoatIsInCombatIsInCoverFacingLeftIsInFlyingVehicleIsInGroupIsInHeliIsInjuredIsInMeleeCombatIsInParachuteFreeFallIsInPlaneIsInPoliceVehicleIsInStealthModeIsInSubIsInTaxiIsInTrainIsJackingIsJumpingIsJumpingOutOfVehicleIsOnBikeIsOnFootIsPerformingStealthKillIsPlantingBombIsPlayerIsProneIsReloadingIsRunningIsScriptedSpeechplayingIsShootingIsSprintingIsStoppedIsSwimmingIsSwimmingUnderWaterIsTryingToEnterALockedVehicleIsVaultingIsWalkingIsWearingHelmetMoneySweatWasKilledByStealthWasKilledByTakedown