multi-dimensional arrays must be fully initialized
#1

Код:
new NumberNames[8][6] =
{
	{"ZERO"},
	{"ONE"},
	{"TWO"},
	{"THREE"},
	{"FOUR"},
	{"FIVE"},
	{"SIX"}
	
}; //error here
Wanna use it in this form:
Код:
new string[255]; format(string, sizeof(string), 
"0 is %s | 1 is %s | 2 is %s | 3 is %s | 4 is %s | 5 is %s | 6 is %s", 
NumberNames[0], NumberNames[1], NumberNames[2], NumberNames[3], NumberNames[4], NumberNames[5], NumberNames[6]);
Error : multi-dimensional arrays must be fully initialized, nevermind if ' { ' & ' } ' is there or not.

Thanks
Reply
#2

Try adding one more,
pawn Код:
{"SEVEN"}
or change this line:
pawn Код:
new NumberNames[8][6] =
to
pawn Код:
new NumberNames[7][6] =
I think it's because there is an empty place in array
Reply
#3

They all must be used for this to work. You're leaving the seventh one.
Reply
#4

Yeah you're both right thanks rep+
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)