- Joined
- Sep 20, 2015
- Messages
- 385
Hello. In my map there is an item that you can't buy 2 times. So i created a boolean variable that turns true when the item is bought for the first time. It works fine, but i have 10 players in the map so here is my question:
Witch option is better between create one variable for each player and create one array variable with n = number of players ?
To be more clear:
option 1
create 1 variable for each player in the game
P1itemb, P2itemb, P3itemb and so on
OR
option 2
create one array variable that contains all players
ItemB[player number]
so will be ItemB[0] = P1, ItemB[1] = P2 and so on
For better i mean, witch option dont make the game freeze for a shot time?
Thank you
Witch option is better between create one variable for each player and create one array variable with n = number of players ?
To be more clear:
option 1
create 1 variable for each player in the game
P1itemb, P2itemb, P3itemb and so on
OR
option 2
create one array variable that contains all players
ItemB[player number]
so will be ItemB[0] = P1, ItemB[1] = P2 and so on
For better i mean, witch option dont make the game freeze for a shot time?
Thank you