Handle respawn for paintball (don't use normal death respawn)
This commit is contained in:
@@ -402,6 +402,9 @@ function onPlayerDeath(client, position) {
|
|||||||
fadeCamera(client, false, 1.0);
|
fadeCamera(client, false, 1.0);
|
||||||
}
|
}
|
||||||
setTimeout(function () {
|
setTimeout(function () {
|
||||||
|
if (isPlayerInPaintBall(client)) {
|
||||||
|
respawnPlayerForPaintBall(client);
|
||||||
|
} else {
|
||||||
if (getPlayerCurrentSubAccount(client).inJail) {
|
if (getPlayerCurrentSubAccount(client).inJail) {
|
||||||
let closestJail = getClosestPoliceStation(getPlayerPosition(client));
|
let closestJail = getClosestPoliceStation(getPlayerPosition(client));
|
||||||
despawnPlayer(client);
|
despawnPlayer(client);
|
||||||
@@ -450,6 +453,7 @@ function onPlayerDeath(client, position) {
|
|||||||
setPlayerControlState(client, true);
|
setPlayerControlState(client, true);
|
||||||
resetPlayerBlip(client);
|
resetPlayerBlip(client);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}, 2000);
|
}, 2000);
|
||||||
}, 1000);
|
}, 1000);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user