Skip to content

Commit

Permalink
Add Z_persistentMoney check
Browse files Browse the repository at this point in the history
  • Loading branch information
AirwavesMan committed Jan 26, 2021
1 parent f22bab4 commit 7ab5867
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions spawn/main.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -167,9 +167,9 @@ if (class_selection && !_isPZombie) then {
default {0};
};

_wealth = player getVariable ["cashMoney",0];
_wealth = _player getVariable [(["cashMoney","globalMoney"] select Z_persistentMoney),0];
if (_wealth < _coins) then {
player setVariable ["cashMoney",(_wealth + _coins),true];
player setVariable [(["cashMoney","globalMoney"] select Z_persistentMoney),(_wealth + _coins),true];
};
};

Expand Down

0 comments on commit 7ab5867

Please sign in to comment.