Posts: 62
Threads: 20
Joined: Nov 2013
C:\Documents and Settings\aa\My Documents\Downloads\Current Online Italy Mafia\gamemodes\IMV6.pwn(4626) : error 017: undefined symbol "MAX_GATES"
C:\Documents and Settings\aa\My Documents\Downloads\Current Online Italy Mafia\gamemodes\IMV6.pwn(4637) : error 017: undefined symbol "GateInfo"
C:\Documents and Settings\aa\My Documents\Downloads\Current Online Italy Mafia\gamemodes\IMV6.pwn(4637) : warning 215: expression has no effect
C:\Documents and Settings\aa\My Documents\Downloads\Current Online Italy Mafia\gamemodes\IMV6.pwn(4637) : error 001: expected token: ";", but found "]"
C:\Documents and Settings\aa\My Documents\Downloads\Current Online Italy Mafia\gamemodes\IMV6.pwn(4637) : error 029: invalid expression, assumed zero
C:\Documents and Settings\aa\My Documents\Downloads\Current Online Italy Mafia\gamemodes\IMV6.pwn(4637) : fatal error 107: too many error messages on one line
Posts: 422
Threads: 107
Joined: Sep 2013
Reputation:
0
Show us the lines of your errors
Posts: 62
Threads: 20
Joined: Nov 2013
stock LoadGates()
{
new file[64];
for(new t=0; t<=MAX_GATES; t++)
{
format(file,sizeof(file),"gates/gate%d.txt",t);
new Float: X, Float: Y, Float: Z;
X = dini_Float(file,"floatx");
Y = dini_Float(file,"floaty");
Z = dini_Float(file,"floatz");
new F = dini_Int(file,"factionid");
new GID = dini_Int(file,"gateid");
if(dini_Exists(file))
{
GateInfo[t][gModel] = 976;
GateInfo[t][gFaction] = F;
GateInfo[t][gCX] = X;
GateInfo[t][gCY] = Y;
GateInfo[t][gCZ] = Z;
GateInfo[t][gSpeed] = 5;
new string[256];
format(string, sizeof(string), ".::Gate %d::.\nCmd: /fgate\nFaction Owner: %d",t,GateInfo[t][gFaction]);
GateInfo[GID][gGate] = CreateDynamicObject(976, X, Y, Z-1, 0, 0, dini_Float(file,"facingangle"));
GateInfo[t][gText] = CreateDynamic3DTextLabel(string, 0xFFFFFFFF, GateInfo[t][gCX], GateInfo[t][gCY], GateInfo[t][gCZ], 10);
GateInfo[t][gStatus] = 0;
}
}
print("Gates loaded successfully.");
return 1;
}
Posts: 185
Threads: 23
Joined: Jan 2013
Reputation:
0
Did you declare the enum&new of GateInfo? (enum _x { ... }; new GateInfo[MAX_GATES][_x]; )
Did you declare how much is MAX_GATES? (#define MAX_GATES .. || new MAX_GATES = ..; )
Posts: 62
Threads: 20
Joined: Nov 2013
i didn't Understand what u say
,Can u Fix the error which in code plz ,thanks
Posts: 62
Threads: 20
Joined: Nov 2013
C:\Documents and Settings\aa\My Documents\Downloads\Current Online Italy Mafia\gamemodes\IMV6.pwn(6293) : error 029: invalid expression, assumed zero
C:\Documents and Settings\aa\My Documents\Downloads\Current Online Italy Mafia\gamemodes\IMV6.pwn(6293 -- 6294) : error 029: invalid expression, assumed zero
C:\Documents and Settings\aa\My Documents\Downloads\Current Online Italy Mafia\gamemodes\IMV6.pwn(6294 -- 6295) : error 029: invalid expression, assumed zero
C:\Documents and Settings\aa\My Documents\Downloads\Current Online Italy Mafia\gamemodes\IMV6.pwn(6294 -- 6295) : fatal error 107: too many error messages on one line
Codes
if(newkeys & 2 && IsPlayerInAnyVehicle(playerid))
{
new i = playerid;
for(new h=0; h<=MAX_GATES; h++)
{
if(IsPlayerInRangeOfPoint(i, 20.0, GateInfo[h][gCX], GateInfo[h][gCY], GateInfo[h][gCZ]))
{
OnPlayerCommandText(playerid, "/gate");
}
}
}*/
if(newkeys & 2 && IsPlayerInAnyVehicle(playerid))
{
new i = playerid;
for(new g; g < sizeof(Gates); g++)
{
if(IsPlayerInRangeOfPoint(i, 20.0, Gates[g][closeX],Gates[g][closeY],Gates[g][closeZ]) || IsPlayerInRangeOfPoint(i, 20.0, Gates[g][openX],Gates[g][openY],Gates[g][openZ]))
{
OnPlayerCommandText(playerid, "/gate");
}
}
}
Posts: 62
Threads: 20
Joined: Nov 2013
As u know i am Newbie Scripter
but the codes here
if(newkeys & 2 && IsPlayerInAnyVehicle(playerid))
{
new i = playerid;
for(new h=0; h<=MAX_GATES; h++)
{
if(IsPlayerInRangeOfPoint(i, 20.0, GateInfo[h][gCX], GateInfo[h][gCY], GateInfo[h][gCZ]))
{
OnPlayerCommandText(playerid, "/gate");
}
}
}*/ {Code number 6293}
if(newkeys & 2 && IsPlayerInAnyVehicle(playerid)) {Code Number 6294}
{
new i = playerid;
for(new g; g < sizeof(Gates); g++)
{
if(IsPlayerInRangeOfPoint(i, 20.0, Gates[g][closeX],Gates[g][closeY],Gates[g][closeZ]) || IsPlayerInRangeOfPoint(i, 20.0, Gates[g][openX],Gates[g][openY],Gates[g][openZ]))
{
OnPlayerCommandText(playerid, "/gate");
}
}
}
Posts: 2,368
Threads: 27
Joined: Jun 2010
Reputation:
0
Please use [pawn] your code here [/pawn] before posting any code. I still can't get your code, where is the problem at?