Overhaul of "client" to "player"

This commit is contained in:
Vortrex
2020-12-29 04:26:15 -06:00
parent eeff21929c
commit 1c7532523c
34 changed files with 920 additions and 911 deletions

View File

@@ -145,7 +145,7 @@ function getPlayerVehicleSeat(client) {
// ---------------------------------------------------------------------------
function isPlayerSpawned(client) {
return client.player
return (client.player != null);
}
// ---------------------------------------------------------------------------
@@ -175,7 +175,11 @@ function getVehicleForNetworkEvent(vehicle) {
// ---------------------------------------------------------------------------
function deleteGameElement(element) {
destroyElement(element);
if(element != null) {
destroyElement(element);
return true;
}
return false;
}
// ---------------------------------------------------------------------------
@@ -184,4 +188,11 @@ function isPlayerInFrontVehicleSeat(client) {
return (getPlayerVehicleSeat(client) == 0 || getPlayerVehicleSeat(client) == 1);
}
// ---------------------------------------------------------------------------
function removePlayerFromVehicle(client) {
triggerNetworkEvent("ag.removeFromVehicle", client);
return true;
}
// ---------------------------------------------------------------------------