From 4c368d67748a0dd5b050bc700db0dffb52532cdb Mon Sep 17 00:00:00 2001 From: Vortrex <3858226+VortrexFTW@users.noreply.github.com> Date: Wed, 28 Apr 2021 21:28:24 -0500 Subject: [PATCH] Convert cash give/take amounts to int --- scripts/server/native.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/server/native.js b/scripts/server/native.js index ac66e4e6..14a9d64a 100644 --- a/scripts/server/native.js +++ b/scripts/server/native.js @@ -211,21 +211,21 @@ function getPlayerArmour(client) { // =========================================================================== function setPlayerCash(client, amount) { - getPlayerCurrentSubAccount(client).cash = amount; + getPlayerCurrentSubAccount(client).cash = toInteger(amount); updatePlayerCash(client); } // =========================================================================== function givePlayerCash(client, amount) { - getPlayerCurrentSubAccount(client).cash = getPlayerCurrentSubAccount(client).cash + amount; + getPlayerCurrentSubAccount(client).cash = getPlayerCurrentSubAccount(client).cash + toInteger(amount); updatePlayerCash(client); } // =========================================================================== function takePlayerCash(client, amount) { - getPlayerCurrentSubAccount(client).cash = getPlayerCurrentSubAccount(client).cash - amount; + getPlayerCurrentSubAccount(client).cash = getPlayerCurrentSubAccount(client).cash - toInteger(amount); updatePlayerCash(client); }