Use game namespace and new const

This commit is contained in:
Vortrex
2021-11-16 02:00:54 -06:00
parent b8ee6efcd6
commit 2e753b4d87
12 changed files with 249 additions and 239 deletions

View File

@@ -48,7 +48,7 @@ function updatePlayerNameTag(clientName, characterName, colour, paused, ping) {
playerPaused[clientName] = paused;
playerPing[clientName] = ping;
if(gta.game == GAME_GTA_IV) {
if(game.game == VRR_GAME_GTA_IV) {
let client = getPlayerFromParams(clientName);
if(client != false) {
if(client.player != null) {
@@ -81,7 +81,7 @@ function drawNametag(x, y, health, armour, text, ping, alpha, distance, colour,
// Health Bar
if(getMultiplayerMod() == VRR_MPMOD_GTAC) {
if(gta.game == GAME_GTA_III) {
if(game.game == VRR_GAME_GTA_III) {
// Mickey Hamfists is ridiculously tall. Raise the nametag for him a bit
if(skin == 109) {
y -= 20;
@@ -207,7 +207,7 @@ function getClientFromPlayer(player) {
// ===========================================================================
function processNameTagRendering(event) {
//if(gta.game >= GAME_GTA_IV) {
//if(game.game >= GAME_GTA_IV) {
// return false;
//}