C:\Documents and Settings\Eigenaar\Bureaublad\LVRPG\gamemodes\LSTW2Uv1.pwn(98) : error 052: multi-dimensional arrays must be fully initialized Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 1 Error.
new TeamInfo[ MAX_TEAMS ][ teaminfo ]= { { "Varrio Los Aztecas", AZTECAS_COLOR, 0, 0, 0, 0, 0}, { "Los Santos Vagos", VAGOS_COLOR, 0, 0, 0, 0, 0}, { "The Ballas Family", BALLAS_COLOR, 0, 0, 0, 0, 0}, { "Grove Street Familie", GROVE_COLOR, 0, 0, 0, 0, 0}, { "Los Santos Police Department", COPS_COLOR, 0, 0, 0, 0, 0} };code]
new TeamInfo[ MAX_TEAMS ][ teaminfo ]= {
{ "Varrio Los Aztecas", AZTECAS_COLOR, 0, 0, 0, 0, 0},
{ "Los Santos Vagos", VAGOS_COLOR, 0, 0, 0, 0, 0},
{ "The Ballas Family", BALLAS_COLOR, 0, 0, 0, 0, 0},
{ "Grove Street Familie", GROVE_COLOR, 0, 0, 0, 0, 0},
{ "Los Santos Police Department", COPS_COLOR, 0, 0, 0, 0, 0}
};
Originally Posted by //exora
Remove the comma from the last line in the array.
pawn Код:
|
C:\Documents and Settings\Eigenaar\Bureaublad\LVRPG\gamemodes\LSTW2Uv1.pwn(98) : error 052: multi-dimensional arrays must be fully initialized C:\Documents and Settings\Eigenaar\Bureaublad\LVRPG\gamemodes\LSTW2Uv1.pwn(103) : error 001: expected token: ";", but found "enum" Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 2 Errors.
#define MAX_TEAMS 5
#include <a_samp>
#define MAX_TEAMS 5
#define AZTECAS_COLOR 0x0066FFAA
#define VAGOS_COLOR 0x0066FFAA
#define BALLAS_COLOR 0x0066FFAA
#define GROVE_COLOR 0x0066FFAA
#define COPS_COLOR 0x0066FFAA
enum teaminfo
{
blabla[32],
teamcolor,
num1,
num2,
num3,
num4,
num5,
};
new TeamInfo[MAX_TEAMS][teaminfo] =
{
{ "Varrio Los Aztecas", AZTECAS_COLOR, 0, 0, 0, 0, 0}, // Team 1
{ "Los Santos Vagos", VAGOS_COLOR, 0, 0, 0, 0, 0}, // Team 2
{ "The Ballas Family", BALLAS_COLOR, 0, 0, 0, 0, 0}, // Team 3
{ "Grove Street Familie", GROVE_COLOR, 0, 0, 0, 0, 0}, // Team 4
{ "Los Santos Police Department", COPS_COLOR, 0, 0, 0, 0, 0} // Team 5
};
public OnFilterScriptInit()
{
print("\n");
for(new i; i < sizeof TeamInfo; i++)
{
printf(" %s | %x | %d | %d | %d | %d | %d |", TeamInfo[i][blabla], TeamInfo[i][teamcolor], TeamInfo[i][num1], TeamInfo[i][num2], TeamInfo[i][num3], TeamInfo[i][num4], TeamInfo[i][num5]);
}
print("\n");
return 1;
}
#define MAX_TEAMS 6
// : error 052: multi-dimensional arrays must be fully initialized