FivePD API
EntityWrappers/PedWrapper

FPedTasks

Represents the tasks of a FPed.

Methods

AchieveHeading

Invokes the "ped.Task.AchieveHeading" native.

Parameters

NameTypeDescription
headingfloatThe heading.
timeoutintThe timeout.

AimAt

Invokes the "ped.Task.AimAt" native.

Parameters

NameTypeDescription
targetVector3The target.
durationintThe duration.

Arrest

Invokes the "ped.Task.Arrest" native.

Parameters

NameTypeDescription
pedPedThe ped.

ChaseWithGroundVehicle

Invokes the "ped.Task.ChaseWithGroundVehicle" native.

Parameters

NameTypeDescription
targetEntityThe target.

ChaseWithHelicopter

Invokes the "ped.Task.ChaseWithHelicopter" native.

Parameters

NameTypeDescription
targetEntityThe target.
offsetVector3The offset.

ChaseWithPlane

Invokes the "ped.Task.ChaseWithPlane" native.

Parameters

NameTypeDescription
targetEntityThe target.
offsetVector3The offset.

ChatTo

Invokes the "ped.Task.ChatTo" native.

Parameters

NameTypeDescription
pedPedThe ped.

ClearAll

Invokes the "ped.Task.ClearAll" native.

ClearAllImmediately

Invokes the "ped.Task.ClearAllImmediately" native.

ClearAnimation

Invokes the "ped.Task.ClearAnimation" native.

Parameters

NameTypeDescription
animSetstringThe anim set.
animNamestringThe anim name.

ClearLookAt

Invokes the "ped.Task.ClearLookAt" native.

ClearSecondary

Invokes the "ped.Task.ClearSecondary" native.

Climb

Invokes the "ped.Task.Climb" native.

ClimbLadder

Invokes the "ped.Task.ClimbLadder" native.

Cower

Invokes the "ped.Task.Cower" native.

Parameters

NameTypeDescription
durationintThe duration.

CruiseWithVehicle

Invokes the "ped.Task.CruiseWithVehicle" native.

Parameters

NameTypeDescription
vehicleVehicleThe vehicle.
speedfloatThe speed.
drivingstyleintThe drivingstyle.

DriveTo

Invokes the "ped.Task.DriveTo" native.

Parameters

NameTypeDescription
vehicleVehicleThe vehicle to drive.
targetVector3The location to drive to.
radiusfloatThe radius.
speedfloatThe speed.
drivingStyleintThe driving style flag.

EnterAnyVehicle

Invokes the "ped.Task.EnterAnyVehicle" native.

Parameters

NameTypeDescription
seatFVehicleSeatThe seat.
timeoutintThe timeout.
speedfloatThe speed.
flagintThe flag.

EnterVehicle

Invokes the "ped.Task.EnterVehicle" native.

Parameters

NameTypeDescription
vehicleVehicleThe vehicle.
seatFVehicleSeatThe seat.
timeoutintThe timeout.
speedfloatThe speed.
flagintThe flag.

FightAgainst

Invokes the "ped.Task.FightAgainst" native.

Parameters

NameTypeDescription
targetPedThe target.
durationintThe duration.

FightAgainstHatedTargets

Invokes the "ped.Task.FightAgainstHatedTargets" native.

Parameters

NameTypeDescription
radiusfloatThe radius.
durationintThe duration.

FleeFrom

Invokes the "ped.Task.FleeFrom" native.

Parameters

NameTypeDescription
positionVector3The position.
durationintThe duration.

FollowPointRoute

Invokes the "ped.Task.FollowPointRoute" native.

Parameters

NameTypeDescription
pointsIEnumerable<Vector3>The points.

FollowToOffsetFromEntity

Invokes the "ped.Task.FollowToOffsetFromEntity" native.

Parameters

NameTypeDescription
targetEntityThe target.
offsetVector3The offset.
movementSpeedfloatThe movementSpeed.
timeoutintThe timeout.
stoppingRangefloatThe stoppingRange.
persistFollowingboolThe persistFollowing.

GoTo

Invokes the "ped.Task.GoTo" native.

Parameters

NameTypeDescription
targetEntityThe target.

GoTo

Invokes the "ped.Task.GoTo" native.

Parameters

NameTypeDescription
targetEntityThe target.
offsetVector3The offset.
timeoutintThe timeout.

GoTo

Invokes the "ped.Task.GoTo" native.

Parameters

NameTypeDescription
positionVector3The position.
ignorePathsboolThe ignorePaths.
timeoutintThe timeout.

GuardCurrentPosition

Invokes the "ped.Task.GuardCurrentPosition" native.

HandsUp

Invokes the "ped.Task.HandsUp" native.

Parameters

NameTypeDescription
durationintThe duration.

Jump

Invokes the "ped.Task.Jump" native.

LeaveVehicle

Invokes the "ped.Task.LeaveVehicle" native.

Parameters

NameTypeDescription
flagsFLeaveVehicleFlagsThe flags.

LeaveVehicle

Invokes the "ped.Task.LeaveVehicle" native.

Parameters

NameTypeDescription
vehicleVehicleThe vehicle.
flagsFLeaveVehicleFlagsThe flags.

LeaveVehicle

Invokes the "ped.Task.LeaveVehicle" native.

Parameters

NameTypeDescription
vehicleVehicleThe vehicle.
closeDoorboolThe closeDoor.

LookAt

Invokes the "ped.Task.LookAt" native.

Parameters

NameTypeDescription
targetEntityThe target.
durationintThe duration.

LookAt

Invokes the "ped.Task.LookAt" native.

Parameters

NameTypeDescription
positionVector3The position.
durationintThe duration.

ParachuteTo

Invokes the "ped.Task.ParachuteTo" native.

Parameters

NameTypeDescription
positionVector3The position.

ParkVehicle

Invokes the "ped.Task.ParkVehicle" native.

Parameters

NameTypeDescription
vehicleVehicleThe vehicle.
positionVector3The position.
headingfloatThe heading.
radiusfloatThe radius.
keepEngineOnboolThe keepEngineOn.

PlayAnimation

Invokes the "ped.Task.PlayAnimation" native.

Parameters

NameTypeDescription
animDictstringThe animDict.
animNamestringThe animName.

PlayAnimation

Invokes the "ped.Task.PlayAnimation" native.

Parameters

NameTypeDescription
animDictstringThe animDict.
animNamestringThe animName.
blendInSpeedfloatThe blendInSpeed.
durationintThe duration.
flagsFAnimationFlagsThe flags.

PlayAnimation

Invokes the "ped.Task.PlayAnimation" native.

Parameters

NameTypeDescription
animDictstringThe animDict.
animNamestringThe animName.
speedfloatThe speed.
durationintThe duration.
playbackRatefloatThe playbackRate.

PlayAnimation

Invokes the "ped.Task.PlayAnimation" native.

Parameters

NameTypeDescription
animDictstringThe animDict.
animNamestringThe animName.
blendInSpeedfloatThe blendInSpeed.
blendOutSpeedfloatThe blendOutSpeed.
durationintThe duration.
flagsFAnimationFlagsThe flags.
playbackRatefloatThe playbackRate.

PutAwayMobilePhone

Invokes the "ped.Task.PutAwayMobilePhone" native.

PutAwayParachute

Invokes the "ped.Task.PutAwayParachute" native.

ReactAndFlee

Invokes the "ped.Task.ReactAndFlee" native.

Parameters

NameTypeDescription
pedPedThe ped.

ReloadWeapon

Invokes the "ped.Task.ReloadWeapon" native.

RunTo

Invokes the "ped.Task.RunTo" native.

Parameters

NameTypeDescription
positionVector3The position.
ignorePathsboolThe ignorePaths.
timeoutintThe timeout.

ShootAt

Invokes the "ped.Task.ShootAt" native.

Parameters

NameTypeDescription
targetPedThe target.
durationintThe duration.
patternFFiringPatternThe pattern.

ShootAt

Invokes the "ped.Task.ShootAt" native.

Parameters

NameTypeDescription
positionVector3The position.
durationintThe duration.
patternFFiringPatternThe pattern.

ShuffleToNextVehicleSeat

Invokes the "ped.Task.ShuffleToNextVehicleSeat" native.

Parameters

NameTypeDescription
vehicleVehicleThe vehicle.

Skydive

Invokes the "ped.Task.Skydive" native.

SlideTo

Invokes the "ped.Task.ShuffleToNextVehicleSeat" native.

Parameters

NameTypeDescription
positionVector3The position.
headingfloatThe heading.

StandStill

Invokes the "ped.Task.StandStill" native.

Parameters

NameTypeDescription
durationintThe duration.

StartScenario

Invokes the "ped.Task.StartScenario" native.

Parameters

NameTypeDescription
namestringThe name.
positionVector3The position.

SwapWeapon

Invokes the "ped.Task.SwapWeapon" native.

TurnTo

Invokes the "ped.Task.TurnTo" native.

Parameters

NameTypeDescription
entityEntityThe to turn to.
durationintThe duration.

TurnTo

Invokes the "ped.Task.TurnTo" native.

Parameters

NameTypeDescription
positionVector3The to turn to.
durationintThe duration.

UseMobilePhone

Invokes the "ped.Task.UseMobilePhone" native.

UseMobilePhone

Invokes the "ped.Task.UseMobilePhone" native.

Parameters

NameTypeDescription
durationintThe duration.

UseParachute

Invokes the "ped.Task.UseParachute" native.

VehicleChase

Invokes the "ped.Task.VehicleChase" native.

Parameters

NameTypeDescription
targetPedThe target.

VehicleShootAtPed

Invokes the "ped.Task.VehicleShootAtPed" native.

Parameters

NameTypeDescription
targetPedThe target.

Wait

Invokes the "ped.Task.Wait" native.

Parameters

NameTypeDescription
durationintThe duration.

WanderAround

Invokes the "ped.Task.WanderAround" native.

WanderAround

Invokes the "ped.Task.WanderAround" native.

Parameters

NameTypeDescription
positionVector3The position.
radiusfloatThe radius.

WarpIntoVehicle

Invokes the "ped.Task.WarpIntoVehicle" native.

Parameters

NameTypeDescription
vehicleVehicleThe vehicle.
seatFVehicleSeatThe seat.

WarpOutOfVehicle

Invokes the "ped.Task.WarpOutOfVehicle" native.

Parameters

NameTypeDescription
vehicleVehicleThe vehicle.