Get rid of old death handling
This commit is contained in:
@@ -19,24 +19,27 @@ function processSync(event, deltaTime) {
|
|||||||
//}
|
//}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (localPlayer.health <= 0) {
|
|
||||||
if (!calledDeathEvent) {
|
if (calledDeathEvent == false) {
|
||||||
logToConsole(LOG_DEBUG, `Local player died`);
|
if (localPlayer.health <= 0) {
|
||||||
localPlayer.clearWeapons();
|
if (!calledDeathEvent) {
|
||||||
calledDeathEvent = true;
|
logToConsole(LOG_DEBUG, `Local player died`);
|
||||||
sendNetworkEventToServer("v.rp.playerDeath");
|
localPlayer.clearWeapons();
|
||||||
|
calledDeathEvent = true;
|
||||||
|
sendNetworkEventToServer("v.rp.playerDeath");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (localPlayer.health <= 0) {
|
//if (localPlayer.health <= 0) {
|
||||||
if (!calledDeathEvent) {
|
// if (!calledDeathEvent) {
|
||||||
logToConsole(LOG_DEBUG, `Local player died`);
|
// logToConsole(LOG_DEBUG, `Local player died`);
|
||||||
localPlayer.clearWeapons();
|
// localPlayer.clearWeapons();
|
||||||
calledDeathEvent = true;
|
// calledDeathEvent = true;
|
||||||
sendNetworkEventToServer("v.rp.playerDeath");
|
// sendNetworkEventToServer("v.rp.playerDeath");
|
||||||
}
|
// }
|
||||||
}
|
//}
|
||||||
|
|
||||||
if (streamingRadioElement) {
|
if (streamingRadioElement) {
|
||||||
//streamingRadio.volume = getStreamingRadioVolumeForPosition(streamingRadio.position);
|
//streamingRadio.volume = getStreamingRadioVolumeForPosition(streamingRadio.position);
|
||||||
|
|||||||
Reference in New Issue
Block a user