Class BaseVehicle
Assembly: SlipeServer.dll
Syntax
public class BaseVehicle : SharedVehicle
Constructors
|
Improve this Doc
View Source
BaseVehicle(VehicleModel, Vector3, Vector3, String, Int32, Int32)
Create a vehicle using all createVehicle arguments
Declaration
protected BaseVehicle(VehicleModel model, Vector3 position, Vector3 rotation, string numberplate = "", int variant1 = 1, int variant2 = 1)
Parameters
Properties
|
Improve this Doc
View Source
Controler
Get the player controlling the vehicle in the drivers seat
Declaration
public Player Controler { get; }
Property Value
|
Improve this Doc
View Source
IdleRespawnDelay
Set the respawn delay in milliseconds
Declaration
public int IdleRespawnDelay { set; }
Property Value
|
Improve this Doc
View Source
Occupants
Get a dictionary of players occupying this vehicle
Declaration
public Dictionary<Seat, Player> Occupants { get; }
Property Value
|
Improve this Doc
View Source
RespawnDelay
Set the respawn delay of this vehicle in milliseconds
Declaration
public int RespawnDelay { set; }
Property Value
|
Improve this Doc
View Source
RespawnEnabled
Set to true to have the vehicle respawn if it gets blown up
Declaration
public bool RespawnEnabled { set; }
Property Value
|
Improve this Doc
View Source
RespawnPosition
Get and set the respawn position
Declaration
public Vector3 RespawnPosition { get; set; }
Property Value
|
Improve this Doc
View Source
RespawnRotation
Get and set the respawn rotation
Declaration
public Vector3 RespawnRotation { get; set; }
Property Value
|
Improve this Doc
View Source
Sirens
The sirens of this vehicle
Declaration
public Sirens Sirens { get; set; }
Property Value
|
Improve this Doc
View Source
Variant
Get and set the integers reprsenting the current variant. Check wiki for more info
Declaration
public Tuple<int, int> Variant { get; set; }
Property Value
Methods
|
Improve this Doc
View Source
Blow(Boolean)
Declaration
public bool Blow(bool explode = true)
Parameters
Type |
Name |
Description |
Boolean |
explode |
|
Returns
|
Improve this Doc
View Source
GetOccupant(Seat)
This function gets the player sitting/trying to enter this vehicle.
Declaration
public Player GetOccupant(Seat seat = Seat.FrontLeft)
Parameters
Type |
Name |
Description |
Seat |
seat |
|
Returns
|
Improve this Doc
View Source
ResetExplosionTime()
Resets the vehicle explosion time. This is the point in time at which the vehicle last exploded: at this time plus the vehicle's respawn delay, the vehicle is respawned. You can use this function to prevent the vehicle from respawning.
Declaration
public bool ResetExplosionTime()
Returns
|
Improve this Doc
View Source
ResetIdleTime()
Resets the vehicle idle time
Declaration
public bool ResetIdleTime()
Returns
|
Improve this Doc
View Source
Respawn()
Declaration
Returns
|
Improve this Doc
View Source
Spawn(Vector3)
Spawns the vehicle at a different position
Declaration
public bool Spawn(Vector3 position)
Parameters
Type |
Name |
Description |
Vector3 |
position |
|
Returns
|
Improve this Doc
View Source
Spawn(Vector3, Vector3)
Spawns the vehicle at a different position and rotation
Declaration
public bool Spawn(Vector3 position, Vector3 rotation)
Parameters
Returns
Events
|
Improve this Doc
View Source
OnCollisionShapeHit
Declaration
public event BaseVehicle.OnCollisionShapeHitHandler OnCollisionShapeHit
Event Type
|
Improve this Doc
View Source
OnCollisionShapeLeave
Declaration
public event BaseVehicle.OnCollisionShapeLeaveHandler OnCollisionShapeLeave
Event Type
|
Improve this Doc
View Source
OnDamage
Declaration
public event BaseVehicle.OnDamageHandler OnDamage
Event Type
|
Improve this Doc
View Source
OnEnter
Declaration
public event BaseVehicle.OnEnterHandler OnEnter
Event Type
|
Improve this Doc
View Source
OnExit
Declaration
public event BaseVehicle.OnExitHandler OnExit
Event Type
|
Improve this Doc
View Source
OnExplode
Declaration
public event BaseVehicle.OnExplodeHandler OnExplode
Event Type
|
Improve this Doc
View Source
OnRespawn
Declaration
public event BaseVehicle.OnRespawnHandler OnRespawn
Event Type
|
Improve this Doc
View Source
OnStartEnter
Declaration
public event BaseVehicle.OnStartEnterHandler OnStartEnter
Event Type
|
Improve this Doc
View Source
OnStartExit
Declaration
public event BaseVehicle.OnStartExitHandler OnStartExit
Event Type
Extension Methods