From 628b725b4bcdb9770558cd4c4a1409a13b75be3c Mon Sep 17 00:00:00 2001 From: Vortrex <3858226+VortrexFTW@users.noreply.github.com> Date: Tue, 5 Jan 2021 01:25:24 -0600 Subject: [PATCH] Use island const in getIsland func --- scripts/server/utilities.js | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/scripts/server/utilities.js b/scripts/server/utilities.js index cf2cca70..515ddede 100644 --- a/scripts/server/utilities.js +++ b/scripts/server/utilities.js @@ -315,14 +315,16 @@ function getWeaponModelId(weaponId) { function getIsland(position) { if(getServerGame() == GAME_GTA_III) { if(position.x > 616) { - return 0; + return AG_ISLAND_PORTLAND; } else if(position.x < -283) { - return 2; + return AG_ISLAND_SHORESIDEVALE; } - return 1; + return AG_ISLAND_STAUNTON; } else { - return 0; + return AG_ISLAND_NONE; } + + //return gta.getIslandFromPosition(position); } // ---------------------------------------------------------------------------