Overhaul of "client" to "player"
This commit is contained in:
@@ -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;
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
Reference in New Issue
Block a user