DaUr3
1
The title is kind of ambiguous but I don’t know how else to phrase this. Basically, I am generating some currency that will be shared among teams.
There will be 2 teams and each team will have a pool of currency that they can use. I am just wondering how to separate these 2 pools.
This question is still very vague, but let’s see where this gets you. To store a currency, you just create an int.
int currency = 0;
To create multiple currencies for 2 (or more) teams, you should create an array.
int[] currencies = new int[2];
Then each team will access it by using their ‘identifier’, which is 0 or 1, depending on the team. (or 2,3,4 etc if you have more teams).
int team = 0;
int myTeamCurrency = currencies[team];