FivePD API
Interfaces

IVector3Service

Responsible for Vector3 related tasks.

Methods

GetRandomLocationAsync

Gets a random location offset from the specified entity with heading.

Parameters

NameTypeDescription
entityEntityThe entity.
offsetMinintThe minimum offset.
offsetMaxintThe maximum offset.

Returns

NameType
Task<Vector3>A serialized json with location and heading.

GetPointOnRoadSideAsync

Gets a random location on roadside with heading.

Parameters

NameTypeDescription
entityEntityThe entity.
offsetMinintThe minimum offset.
offsetMaxintThe maximum offset.

Returns

NameType
Task<Vector3WithHeading>A serialized json with location and heading.

GetPlayerForwardVectorAsync

Gets the forward vector of the specified player.

Parameters

NameTypeDescription
playerPlayerThe player whose forward vector is to be calculated.

Returns

NameType
Task<Vector3>A Vector3 representing the forward direction of the player.