Add some IV support

This commit is contained in:
Vortrex
2021-02-20 20:09:07 -06:00
parent a48cdd3e72
commit d501e00092
6 changed files with 39 additions and 20 deletions

View File

@@ -311,7 +311,9 @@ addNetworkHandler("ag.removeFromVehicle", function() {
// ---------------------------------------------------------------------------
function processEvent(event, deltaTime) {
gta.clearMessages();
if(gta.game != GAME_GTA_IV) {
gta.clearMessages();
}
if(localPlayer != null) {
if(isSpawned) {
@@ -436,7 +438,7 @@ addEventHandler("OnDrawnHUD", function (event) {
}
}
if(renderLabels) {
if(renderLabels && gta.game != GAME_GTA_IV) {
processLabelRendering();
}

View File

@@ -36,6 +36,15 @@ addNetworkHandler("ag.nametag", function(clientName, characterName, colour, paus
playerColours[clientName] = colour;
playerPaused[clientName] = paused;
playerPing[clientName] = ping;
if(gta.game == GAME_GTA_IV) {
let client = getPlayerFromParams(clientName);
if(client != false) {
if(client.player != null) {
client.player.setNametag(characterName, colour);
}
}
}
});
// -------------------------------------------------------------------------