10.05.2011, 19:15
OK - I've got this dynamic /aplace command, and basically, there's something that is annoying me really much.
The compiler error:
pawn Код:
if(dialogid == 2)
{
if(response)
{
switch(listitem)
{
case 0:
{
new Float:X,Float:Y,Float:Z;
GetPlayerPos(playerid,X,Y,Z);
new p = editingplace[playerid]; // Line 3510
PlaceInfo[p][plOutX] = X;
PlaceInfo[p][plOutY] = Y;
PlaceInfo[p][plOutZ] = Z;
DestroyPickup(PlaceInfo[p][plPick]);
Delete3DTextLabel(PlaceInfo[p][plLabel]);
PlaceInfo[p][plPick] = CreatePickup(1318,28,PlaceInfo[p][plOutX],PlaceInfo[p][plOutY],PlaceInfo[p][plOutZ]);
new string[256];
format(string,sizeof(string),"%s\nID: %i",PlaceInfo[p][plText],p);
PlaceInfo[p][plLabel] = Create3DTextLabel(string,COLOR_YELLOW,PlaceInfo[p][plOutX],PlaceInfo[p][plOutY],PlaceInfo[p][plOutZ]+0.7,10.0,0,0);
OnPropUpdate();
SendClientMessage(playerid,COLOR_WHITE,"[Place] You have moved the entrance.");
}
case 1:
{
new Float:X,Float:Y,Float:Z;
GetPlayerPos(playerid,X,Y,Z);
new p = editingplace[playerid];
PlaceInfo[p][plIntX] = X;
PlaceInfo[p][plIntY] = Y;
PlaceInfo[p][plIntZ] = Z;
PlaceInfo[p][plInt] = GetPlayerInterior(playerid);
OnPropUpdate();
SendClientMessage(playerid,COLOR_WHITE,"[Place] You have moved the exit.");
}
case 2:
{
ShowPlayerDialog(playerid,3,DIALOG_STYLE_INPUT,"Place Text","Please enter what text you would like to appear on the place.","Ok","Cancel");
}
}
}
}
Код:
C:\Users\rodi\Desktop\Hakam\Universal Roleplay 0.3b [bak]\U-RP\gamemodes\u-rp.pwn(3510) : error 017: undefined symbol "editingplace" C:\Users\rodi\Desktop\Hakam\Universal Roleplay 0.3b [bak]\U-RP\gamemodes\u-rp.pwn(3510) : warning 215: expression has no effect C:\Users\rodi\Desktop\Hakam\Universal Roleplay 0.3b [bak]\U-RP\gamemodes\u-rp.pwn(3510) : error 001: expected token: ";", but found "]" C:\Users\rodi\Desktop\Hakam\Universal Roleplay 0.3b [bak]\U-RP\gamemodes\u-rp.pwn(3510) : error 029: invalid expression, assumed zero C:\Users\rodi\Desktop\Hakam\Universal Roleplay 0.3b [bak]\U-RP\gamemodes\u-rp.pwn(3510) : fatal error 107: too many error messages on one line Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 4 Errors.