Метод | Описание | |
---|---|---|
AddVehicleToDatabase ( int ownerId, FactionEnums faction, string model, float parkX, float parkY, float parkZ, float parkRotX, float parkRotY, float parkRotZ, string plateText, int plateStyle, int color1, int color2 ) : int |
Creates a new vehicle into the database Used for debugging purposes only!
|
|
DoesVehicleHandleHaveRPVehicle ( NetHandle vehicle ) : bool |
Checks whether a vehicle has a RPVehicle object So basically if a vehicle is spawned with a command, this will return false
|
|
GenerateUnusedLicensePlate ( ) : string |
Generates an unused license plate for civilian vehicle
|
|
GetNearestVehicle ( Vector3 position ) : GTA_RP.Vehicles.RPVehicle |
Gets nearest vehicle
|
|
GetVehicleForCharacter ( Character character ) : GTA_RP.Vehicles.RPVehicle |
Return the vehicle that the character is currently using
|
|
GetVehicleForHandle ( NetHandle vehicle ) : GTA_RP.Vehicles.RPVehicle | ||
GetVehicleWithId ( int id ) : GTA_RP.Vehicles.RPVehicle |
Returns a vehicle with id
|
|
GetVehiclesForCharacter ( Character character ) : List |
Gets all vehicles that the player owns
|
|
InitializeVehicleManager ( ) : void |
Loads all vehicles from the database and adds them to the array
|
|
LockVehicle ( Client client ) : void |
Locks/Unlocks the most nearby vehicle if possible
|
|
LockVehicleWithId ( Character character, int id ) : void | ||
ParkVehicle ( Character character, int vehicleId ) : void |
Parks a vehicle with selected id
|
|
PurchasePark ( Character character, GTA_RP.Vehicles.RPVehicle vehicle ) : void |
Purchases a parking spot
|
|
SendUpdatedVehicleToClient ( Character character, int vehicleId, string licensePlateText, bool spawned ) : void |
Sends a message to client that updates his HUD to include a new vehicle
|
|
SpawnVehicleForCharacter ( Character character, int vehicleId ) : void |
Spawns a vehicle for player with certain id
|
|
SubscribeToVehicleDestroyedEvent ( OnVehicleDestroyedDelegate delegateMethod ) : void |
Subscribes a delegate to vehicle destroyed event
|
|
SubscribeToVehicleEnterEvent ( OnVehicleEnteredDelegate delegateMethod ) : void |
Subscribes a delegate to enter vehicle event
|
|
SubscribeToVehicleEnterEvent ( OnVehicleEnteredDelegateCharacter delegateMethod ) : void | ||
SubscribeToVehicleExitEvent ( OnVehicleExitedDelegate delegateMethod ) : void |
Subscribes a delegate to exit vehicle event
|
|
SubscribeToVehicleExitEvent ( OnVehicleExitedDelegateCharacter delegateMethod ) : void | ||
TryExitVehicleShop ( Character character, int id ) : void |
Character attempts to exit a vehicle shop
|
|
TryPurchasePark ( Character character, int vehicleId ) : void |
Attempts to purchase a parking spot for a vehicle
|
|
TryPurchaseVehicle ( Character character, int id, string model, int color1, int color2 ) : void |
Tries to purchase a vehicle for client Is called from event handler
|
|
UnsubscribeFromVehicleDestroyedEvent ( OnVehicleDestroyedDelegate delegateMethod ) : void |
Unsubscribes from vehicle destroyed event
|
|
UnsubscribeFromVehicleEnterEvent ( OnVehicleEnteredDelegate delegateMethod ) : void |
Unsubscribes from enter vehicle event
|
|
UnsubscribeFromVehicleEnterEvent ( OnVehicleEnteredDelegateCharacter delegateMethod ) : void | ||
UnsubscribeFromVehicleExitEvent ( OnVehicleExitedDelegate delegateMethod ) : void |
Unsubscribes from exit vehicle event
|
|
UnsubscribeFromVehicleExitEvent ( OnVehicleExitedDelegateCharacter delegateMethod ) : void | ||
VehicleDestroyedEvent ( NetHandle vehicle ) : void |
Announce destruction of vehicle to subscribers
|
|
VehicleEnterEvent ( Client client, NetHandle vehicle, int seat ) : void |
Announce player entering vehicle to subscribers
|
|
VehicleExitEvent ( Client client, NetHandle vehicle, int seat ) : void |
Announce player exiting vehicle to subscribers
|
|
VehicleManager ( ) : System.Collections.Generic |
Метод | Описание | |
---|---|---|
AddVehicleToManager ( int id, int ownerId, FactionEnums faction, string model, float parkX, float parkY, float parkZ, float parkRotX, float parkRotY, float parkRotZ, string plateText, int color1, int color2 ) : void |
Adds a vehicle into the vehicle manager
|
|
CreateVehicleShop ( int id, Vector3 entrance, Vector3 exit, Vector3 exitRot, Vector3 cameraPos, Vector3 cameraRot, Vector3 charPos, Vector3 vehiclePos, Vector3 vehicleRot ) : void |
Creates a new vehicle shop
|
|
DoesVehicleExistWithLicensePlate ( String licensePlate ) : Boolean |
Checks if vehicle exists with the given license plate
|
|
GenerateRandomString ( int length ) : String |
Generates a random string with given length
|
|
GetVehicleShopWithId ( int id ) : GTA_RP.Vehicles.VehicleShop |
Gets vehicle shop with certain id
|
|
HasVehicles ( ) : Boolean |
Checks whether any vehicles exist
|
|
InitializeVehicleInsertId ( ) : void |
Initializes the vehicle insert ID
|
|
InitializeVehicleShops ( ) : void |
Initializes vehicle shops
|
|
IsCharacterInVehicle ( Character character, GTA_RP.Vehicles.RPVehicle vehicle ) : bool |
Checks if character is in given vehicle
|
|
RunVehicleDestroyedEvents ( NetHandle vehicle ) : void |
Runs all subscriber methods for vehicle destroyed event
|
|
RunVehicleEnterEvents ( Client client, NetHandle vehicle, int seat ) : void |
Runs all subscriber methods for enter vehicle event
|
|
RunVehicleExitEvents ( Client client, NetHandle vehicle, int seat ) : void |
Runs all subscriber methods for exit vehicle event
|
|
SendVehicleLockedMessage ( Client client, Boolean locked ) : void |
Informs player whether vehicles was locked or unlocked
|
|
SetParkingSpotForVehicle ( GTA_RP.Vehicles.RPVehicle vehicle, Vector3 spot, Vector3 spotRot ) : void |
Set's new parking spot for vehicle
|
public AddVehicleToDatabase ( int ownerId, FactionEnums faction, string model, float parkX, float parkY, float parkZ, float parkRotX, float parkRotY, float parkRotZ, string plateText, int plateStyle, int color1, int color2 ) : int | ||
ownerId | int | Id of the owning character |
faction | FactionEnums | Id of the faction if exists, 0 if civilian |
model | string | Vehicle model |
parkX | float | Vehicle park X position |
parkY | float | Vehicle park Y position |
parkZ | float | Vehicle park Z position |
parkRotX | float | Vehicle park X rotation |
parkRotY | float | Vehicle park Y rotation |
parkRotZ | float | Vehicle park Z rotation |
plateText | string | Text of the license plate |
plateStyle | int | Style of the license plate |
color1 | int | Primary color of the vehicle |
color2 | int | Secondary color of the vehicle |
Результат | int |
public DoesVehicleHandleHaveRPVehicle ( NetHandle vehicle ) : bool | ||
vehicle | NetHandle | Vehicle handle |
Результат | bool |
public GenerateUnusedLicensePlate ( ) : string | ||
Результат | string |
public GetNearestVehicle ( Vector3 position ) : GTA_RP.Vehicles.RPVehicle | ||
position | Vector3 | Position for which to get the nearest vehicle |
Результат | GTA_RP.Vehicles.RPVehicle |
public GetVehicleForCharacter ( Character character ) : GTA_RP.Vehicles.RPVehicle | ||
character | Character | Character |
Результат | GTA_RP.Vehicles.RPVehicle |
public GetVehicleForHandle ( NetHandle vehicle ) : GTA_RP.Vehicles.RPVehicle | ||
vehicle | NetHandle | |
Результат | GTA_RP.Vehicles.RPVehicle |
public GetVehicleWithId ( int id ) : GTA_RP.Vehicles.RPVehicle | ||
id | int | Vehicle id |
Результат | GTA_RP.Vehicles.RPVehicle |
public GetVehiclesForCharacter ( Character character ) : List |
||
character | Character | Character |
Результат | List |
public InitializeVehicleManager ( ) : void | ||
Результат | void |
public LockVehicle ( Client client ) : void | ||
client | Client | |
Результат | void |
public LockVehicleWithId ( Character character, int id ) : void | ||
character | Character | |
id | int | |
Результат | void |
public ParkVehicle ( Character character, int vehicleId ) : void | ||
character | Character | |
vehicleId | int | Vehicle id |
Результат | void |
public PurchasePark ( Character character, GTA_RP.Vehicles.RPVehicle vehicle ) : void | ||
character | Character | Character who is buying |
vehicle | GTA_RP.Vehicles.RPVehicle | Vehicle for which the parking spot is being bought for |
Результат | void |
public SendUpdatedVehicleToClient ( Character character, int vehicleId, string licensePlateText, bool spawned ) : void | ||
character | Character | Character to whose client to send |
vehicleId | int | Id of the new vehicle |
licensePlateText | string | Text of the vehicle's license plate |
spawned | bool | Is vehicle spawned |
Результат | void |
public SpawnVehicleForCharacter ( Character character, int vehicleId ) : void | ||
character | Character | |
vehicleId | int | Vehicle id |
Результат | void |
public SubscribeToVehicleDestroyedEvent ( OnVehicleDestroyedDelegate delegateMethod ) : void | ||
delegateMethod | OnVehicleDestroyedDelegate | Delegate |
Результат | void |
public SubscribeToVehicleEnterEvent ( OnVehicleEnteredDelegate delegateMethod ) : void | ||
delegateMethod | OnVehicleEnteredDelegate | Delegate |
Результат | void |
public SubscribeToVehicleEnterEvent ( OnVehicleEnteredDelegateCharacter delegateMethod ) : void | ||
delegateMethod | OnVehicleEnteredDelegateCharacter | |
Результат | void |
public SubscribeToVehicleExitEvent ( OnVehicleExitedDelegate delegateMethod ) : void | ||
delegateMethod | OnVehicleExitedDelegate | Delegate |
Результат | void |
public SubscribeToVehicleExitEvent ( OnVehicleExitedDelegateCharacter delegateMethod ) : void | ||
delegateMethod | OnVehicleExitedDelegateCharacter | |
Результат | void |
public TryExitVehicleShop ( Character character, int id ) : void | ||
character | Character | |
id | int | Shop id |
Результат | void |
public TryPurchasePark ( Character character, int vehicleId ) : void | ||
character | Character | |
vehicleId | int | |
Результат | void |
public TryPurchaseVehicle ( Character character, int id, string model, int color1, int color2 ) : void | ||
character | Character | |
id | int | |
model | string | Vehicle model |
color1 | int | Vehicle color 1 |
color2 | int | Vehicle color 2 |
Результат | void |
public UnsubscribeFromVehicleDestroyedEvent ( OnVehicleDestroyedDelegate delegateMethod ) : void | ||
delegateMethod | OnVehicleDestroyedDelegate | Delegate |
Результат | void |
public UnsubscribeFromVehicleEnterEvent ( OnVehicleEnteredDelegate delegateMethod ) : void | ||
delegateMethod | OnVehicleEnteredDelegate | Delegate |
Результат | void |
public UnsubscribeFromVehicleEnterEvent ( OnVehicleEnteredDelegateCharacter delegateMethod ) : void | ||
delegateMethod | OnVehicleEnteredDelegateCharacter | |
Результат | void |
public UnsubscribeFromVehicleExitEvent ( OnVehicleExitedDelegate delegateMethod ) : void | ||
delegateMethod | OnVehicleExitedDelegate | Delegate |
Результат | void |
public UnsubscribeFromVehicleExitEvent ( OnVehicleExitedDelegateCharacter delegateMethod ) : void | ||
delegateMethod | OnVehicleExitedDelegateCharacter | |
Результат | void |
public VehicleDestroyedEvent ( NetHandle vehicle ) : void | ||
vehicle | NetHandle | Vehicle handle |
Результат | void |
public VehicleEnterEvent ( Client client, NetHandle vehicle, int seat ) : void | ||
client | Client | Client who entered vehicle |
vehicle | NetHandle | Vehicle that client entered into |
seat | int | |
Результат | void |
public VehicleExitEvent ( Client client, NetHandle vehicle, int seat ) : void | ||
client | Client | Client who exited vehicle |
vehicle | NetHandle | Vehicle from which client exited |
seat | int | |
Результат | void |
public VehicleManager ( ) : System.Collections.Generic | ||
Результат | System.Collections.Generic |