Saving / Loading Bit-Flags
#1

Hello there, how to compress and save bit-flags variable, and how to unpress and load it? I dont really want to save / save/load 32 symbols everytime, so maybe there is way to compress it?
for example enum
Код:
enum flags:(<<= 1) {
    flag1= 1,
    flag2,
    flag3,
    flag4,
    flag5
};
new flags:array[MAX_PLAYERS];
Reply
#2

Just save / load the variable as integer, each variable can hold 32 bit flags
Reply
#3

Quote:
Originally Posted by Nero_3D
Посмотреть сообщение
Just save / load the variable as integer, each variable can hold 32 bit flags
oh, true, thanks you.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)