Dreft Posted June 22, 2009 Share Posted June 22, 2009 How to make a variable "playervar" for all players, but for everyone with different value? In pawn i do this: new playervar[MAX_PLAYERS]; and then if i want to make playervar for player id 5 and 6 i do: playervar[5] = somenumber; playervar[6] = someothernumber; How to do something like this in Lua ? Link to comment
Gamesnert Posted June 22, 2009 Share Posted June 22, 2009 playervar={} -- This is your table/array... whatever... playervar[player1] = someVarOrMaybeAnotherTableHere playervar[player2] = someOtherVarOrMaybeYetAnotherTableHere Link to comment
Dreft Posted June 22, 2009 Author Share Posted June 22, 2009 works Oh how to create the same thing but just for boolean ? EDIT: Dont need it i thinked that i need to use bool:playervar when creating it, but now i see that i dont need Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now