Struct VehicleSpawnInfo
Describes the data used to spawn (and respawn) a vehicle.
public readonly struct VehicleSpawnInfo : IEquatable<VehicleSpawnInfo>
- Implements
- Inherited Members
Constructors
VehicleSpawnInfo(int, Vector3, float, int, int, bool, int, TimeSpan)
Describes the data used to spawn (and respawn) a vehicle.
public VehicleSpawnInfo(int ModelId, Vector3 Position, float ZRotation, int PrimaryColor, int SecondaryColor, bool HasSiren, int Interior, TimeSpan RespawnDelay)
Parameters
ModelIdintThe vehicle model ID.
PositionVector3The world position where the vehicle should spawn.
ZRotationfloatThe Z-axis rotation in degrees.
PrimaryColorintThe primary color ID.
SecondaryColorintThe secondary color ID.
HasSirenboolA value indicating whether the vehicle has a siren.
InteriorintThe interior ID.
RespawnDelayTimeSpanThe respawn delay.
Properties
HasSiren
A value indicating whether the vehicle has a siren.
public bool HasSiren { get; init; }
Property Value
Interior
The interior ID.
public int Interior { get; init; }
Property Value
ModelId
The vehicle model ID.
public int ModelId { get; init; }
Property Value
Position
The world position where the vehicle should spawn.
public Vector3 Position { get; init; }
Property Value
PrimaryColor
The primary color ID.
public int PrimaryColor { get; init; }
Property Value
RespawnDelay
The respawn delay.
public TimeSpan RespawnDelay { get; init; }
Property Value
SecondaryColor
The secondary color ID.
public int SecondaryColor { get; init; }
Property Value
ZRotation
The Z-axis rotation in degrees.
public float ZRotation { get; init; }
Property Value
Methods
Deconstruct(out int, out Vector3, out float, out int, out int, out bool, out int, out TimeSpan)
public void Deconstruct(out int ModelId, out Vector3 Position, out float ZRotation, out int PrimaryColor, out int SecondaryColor, out bool HasSiren, out int Interior, out TimeSpan RespawnDelay)
Parameters
ModelIdintPositionVector3ZRotationfloatPrimaryColorintSecondaryColorintHasSirenboolInteriorintRespawnDelayTimeSpan
Equals(VehicleSpawnInfo)
public bool Equals(VehicleSpawnInfo other)
Parameters
otherVehicleSpawnInfo
Returns
Equals(object)
public override bool Equals(object obj)
Parameters
objobject
Returns
GetHashCode()
public override int GetHashCode()
Returns
ToString()
public override string ToString()
Returns
Operators
operator ==(VehicleSpawnInfo, VehicleSpawnInfo)
public static bool operator ==(VehicleSpawnInfo left, VehicleSpawnInfo right)
Parameters
leftVehicleSpawnInforightVehicleSpawnInfo
Returns
operator !=(VehicleSpawnInfo, VehicleSpawnInfo)
public static bool operator !=(VehicleSpawnInfo left, VehicleSpawnInfo right)
Parameters
leftVehicleSpawnInforightVehicleSpawnInfo