Skip to main content

PedData


Namespace: FivePD.API.Utils#
File: Source/Utils/PedData.cs#

You can use this class to create PedData instances, which can be used to set the ped's data. (using SetPedData())


Fields#

FirstName#

Type:string

The first name of the ped;

LastName#

Type:string

The last name of the ped.

Warrant#

Type:string

The name of the warrant (if there is any, otherwise null).

DriverLicense#

Type:License

License object.

Example#

Ped ped;...var data = await ped.GetData(); // using the extension methodvar driversLicense = data.DriverLicense;
string expirationStr = driversLicense.Expiration; // eg. 10/3/2020PedData.License.Status status = driversLicense.LicenseStatus; // can be: Valid, Expired, Revoked, Suspended

HuntingLicense#

Type:License

License object.

Example#

Ped ped;...var data = await ped.GetData(); // using the extension methodvar huntingLicense = data.HuntingLicense;
string expirationStr = huntingLicense.Expiration; // eg. 10/3/2020PedData.License.Status status = huntingLicense.LicenseStatus; // can be: Valid, Expired, Revoked, Suspended

FishingLicense#

Type:License

License object.

Example#

Ped ped;...var data = await ped.GetData(); // using the extension methodvar fishingLicense = data.FishingLicense;
string expirationStr = fishingLicense.Expiration; // eg. 10/3/2020PedData.License.Status status = fishingLicense.LicenseStatus; // can be: Valid, Expired, Revoked, Suspended

WeaponLicense#

Type:License

License object.

Example#

Ped ped;...var data = await ped.GetData(); // using the extension methodvar weaponLicense = data.WeaponLicense;
string expirationStr = weaponLicense.Expiration; // eg. 10/3/2020PedData.License.Status status = weaponLicense.LicenseStatus; // can be: Valid, Expired, Revoked, Suspended

DateOfBirth#

Type:string

If you ever set this, you must use the following format: mm/dd/yyyy.

BloodAlcoholLevel#

Type:double

Blood alcohol level.

UsedDrugs#

Type:bool[]

NOTE: If you ever set the value of this field, it must always have 3 elements.

  • 0 indexed (first) elem indicates meth
  • 1 indexed elem indicates coke
  • 2 indexed elem indicated cannabis

Gender#

Type:Gender

The gender of the ped.

Age#

Type:int

The age of the ped (can be calculated from the DateOfBirth).

Address#

Type:string

The home address of the ped.

Items#

Type:List<Item>

A list of items that the ped currently possesses (NOTE: These items will shop up when you search the ped).

Violations#

Type:List<Violation>

A list of violations that the ped has committed.