[Pomoc] undefined simbol

Započeo yabb3, Oktobar 31, 2013, 02:32:37 PRE PODNE

prethodna tema - sledeća tema

0 članova i 2 gostiju pregledaju ovu temu.

Skipta koju koristim: Ravens LA:RP
Problem: imam errore neznam u cemu je problem

Deo koda:
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1189) : error 017: undefined symbol "PlayerOnFire"
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1198) : error 017: undefined symbol "Flame"
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1200) : error 017: undefined symbol "Flame"
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1235) : error 017: undefined symbol "PlayerOnFire"
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1263) : error 017: undefined symbol "Flame"
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1269) : error 017: undefined symbol "Flame"
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1273) : error 017: undefined symbol "Flame"
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1288) : error 017: undefined symbol "Flame"
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1325) : error 017: undefined symbol "Flame"
Pawn compiler 3.2.3664	 	 	Copyright (c) 1997-2006, ITB CompuPhase


9 Errors.


stock CanPlayerBurn(playerid, val = 0)
{
	if(CallRemoteFunction("CanBurn", "d", playerid) >= 0 && !IsPlayerInWater(playerid) && GetPlayerSkin(playerid) != 277 && GetPlayerSkin(playerid) != 278 && GetPlayerSkin(playerid) != 279 && ((!val && !PlayerOnFire[playerid]) || (val && PlayerOnFire[playerid]))) { return 1; }
	return 0;
}


new AaF_cache[MAX_PLAYERS] = { -1, ... };
new AaF_cacheTime[MAX_PLAYERS];

stock Aiming_at_Flame(playerid)
{
	if(gettime() - AaF_cacheTime[playerid] < 1)
  	{
  	    return AaF_cache[playerid];
 	}
 	AaF_cacheTime[playerid] = gettime();

	new id = -1;
	new Float:dis = 99999.99;
	new Float:dis2;
	new Float:px, Float:py, Float:pz;
	new Float:x, Float:y, Float:z, Float:a;
	GetXYInFrontOfPlayer(playerid, x, y, z, a, 1);
	z -= Z_DIFFERENCE;

	new Float:cx,Float:cy,Float:cz,Float:fx,Float:fy,Float:fz;
	GetPlayerCameraPos(playerid, cx, cy, cz);
	GetPlayerCameraFrontVector(playerid, fx, fy, fz);

	for(new i; i < MAX_PLAYERS; i++)
	{
	    if(IsPlayerConnected(i) && PlayerOnFire[i] && (IsInWaterCar(playerid) || HasExtinguisher(playerid) || GetPlayerWeapon(playerid) == 41 || Peeing(playerid)) && PlayerOnFire[i])
	    {
	        GetPlayerPos(i, px, py, pz);
	        if(!Peeing(playerid))
		 	{
	        	dis2 = DistanceCameraTargetToLocation(cx, cy, cz, px, py, pz, fx, fy, fz);
 			}
 			else
 			{
 			    if(IsPlayerInRangeOfPoint(playerid, ONFOOT_RADIUS, px, py, pz))
				{
	        		dis2 = 0.0;
				}
 			}
	        if(dis2 < dis)
	        {
				dis = dis2;
	    		id = i;
	    		if(Peeing(playerid))
	    		{
	    		    return id;
				}
			}
		}
	}
	if(id != -1) { return id-MAX_PLAYERS; }
	for(new i; i < MAX_FLAMES; i++)
	{
		if(Flame[i][Flame_Exists])
		{
		    if(IsInWaterCar(playerid) || HasExtinguisher(playerid) || GetPlayerWeapon(playerid) == 41 || Peeing(playerid))
		    {
		        if(!Peeing(playerid))
				{
					dis2 = DistanceCameraTargetToLocation(cx, cy, cz, Flame[i][Flame_pos][0], Flame[i][Flame_pos][1], Flame[i][Flame_pos][2]+Z_DIFFERENCE, fx, fy, fz);
				}
				else
				{
				    dis2 = GetDistanceBetweenPoints(x,y,z,Flame[i][Flame_pos][0],Flame[i][Flame_pos][1],Flame[i][Flame_pos][2]);
				}
				if((IsPlayerInAnyVehicle(playerid) && dis2 < CAR_RADIUS && dis2 < dis) || (!IsPlayerInAnyVehicle(playerid) && ((dis2 < ONFOOT_RADIUS && dis2 < dis))))
				{
				    dis = dis2;
				    id = i;
				}
			}
		}
	}
	if(id != -1)
	{
		if
		(
			(
				IsPlayerInAnyVehicle(playerid) && !IsPlayerInRangeOfPoint(playerid, 50, Flame[id][Flame_pos][0], Flame[id][Flame_pos][1], Flame[id][Flame_pos][2])
			)
			||
			(
				!IsPlayerInAnyVehicle(playerid)  && !IsPlayerInRangeOfPoint(playerid, 5, Flame[id][Flame_pos][0], Flame[id][Flame_pos][1], Flame[id][Flame_pos][2])
			)
		)
		{ id = -1; }
	}
	AaF_cache[playerid] = id;
	return id;
}


stock GetFlameSlot()
{
	for(new i = 0; i < MAX_FLAMES; i++)
	{
		if(!Flame[i][Flame_Exists]) { return i; }
	}
	return -1;
}


EDIT:
imam i ovo

new Flame[MAX_FLAMES][FlameInfo];
new ExtTimer[MAX_PLAYERS];
new PlayerOnFire[MAX_PLAYERS];
new PlayerOnFireTimer[MAX_PLAYERS];
new PlayerOnFireTimer2[MAX_PLAYERS];
new Float:PlayerOnFireHP[MAX_PLAYERS];
Poslednja Izmena: Oktobar 31, 2013, 02:33:51 PRE PODNE od TheDon


forum.sa-mp.com info:
Over 1000 posts.
Over 50 reputation.

Probaj u vrh samo:

new Flame;

new PlayerOnFire;


znaci ovo zameni sa time:

new Flame[MAX_FLAMES][FlameInfo];
new PlayerOnFire[MAX_PLAYERS];



Ako je to neka FS postavi je ovde, mozda nisi na dobro mesto ubacio fs.
Poslednja Izmena: Oktobar 31, 2013, 09:59:37 PRE PODNE od [X-3] Ralph

C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1193) : error 028: invalid subscript (not an array or too many subscripts): "PlayerOnFire"
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1193) : error 029: invalid expression, assumed zero
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1193) : error 028: invalid subscript (not an array or too many subscripts): "PlayerOnFire"
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1193) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright (c) 1997-2006, ITB CompuPhase


4 Errors.


stock CanPlayerBurn(playerid, val = 0)
{
	if(CallRemoteFunction("CanBurn", "d", playerid) >= 0 && !IsPlayerInWater(playerid) && GetPlayerSkin(playerid) != 277 && GetPlayerSkin(playerid) != 278 && GetPlayerSkin(playerid) != 279 && ((!val && !PlayerOnFire[playerid]) || (val && PlayerOnFire[playerid]))) { return 1; }
	return 0;
}


forum.sa-mp.com info:
Over 1000 posts.
Over 50 reputation.

Citat: [LG:RP]| Kris poslato Oktobar 31, 2013, 13:53:15 POSLE PODNE
new PlayerOnFlame[MAX_PLAYERS];


C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1194) : error 028: invalid subscript (not an array or too many subscripts): "PlayerOnFire"
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1194) : error 029: invalid expression, assumed zero
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1194) : error 028: invalid subscript (not an array or too many subscripts): "PlayerOnFire"
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1194) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright (c) 1997-2006, ITB CompuPhase


4 Errors.


iste errore kao i pre Pa POGLEDAJ MALO POGRESIO SAM UMESTO FIRE FLAME JEBEM GA
new PlayerOnFire[MAX_PLAYERS];
Poslednja Izmena: Oktobar 31, 2013, 14:14:52 POSLE PODNE od [LG:RP]| Kris


forum.sa-mp.com info:
Over 1000 posts.
Over 50 reputation.

Pa znam,ispravio sam ja odma ali dobijam ovo

C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1203) : error 028: invalid subscript (not an array or too many subscripts): "Flame"
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1203) : warning 215: expression has no effect
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1203) : error 001: expected token: ";", but found "]"
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1203) : error 029: invalid expression, assumed zero
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1203) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright (c) 1997-2006, ITB CompuPhase


4 Errors.


forum.sa-mp.com info:
Over 1000 posts.
Over 50 reputation.

Citat: [LG:RP]| Kris poslato Oktobar 31, 2013, 16:10:07 POSLE PODNE
new Flame[MAX_FLAMES][FlameInfo];


To sam vec imao evo sta dobijem

C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1072) : error 017: undefined symbol "FlameInfo"
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1072) : error 009: invalid array size (negative, zero or out of bounds)
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1203) : warning 213: tag mismatch
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1205) : warning 213: tag mismatch
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1205) : error 001: expected token: ",", but found "["
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1205) : warning 215: expression has no effect
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1205) : error 001: expected token: ";", but found "]"
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1205) : error 029: invalid expression, assumed zero
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1205) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright (c) 1997-2006, ITB CompuPhase


6 Errors.


forum.sa-mp.com info:
Over 1000 posts.
Over 50 reputation.

u ovom stocku je problem sa erroriam

stock IsAtFlame(playerid)
{
	for(new i; i < MAX_FLAMES; i++)
	{

	    if(Flame[i][Flame_Exists])
		{
		    if(!IsPlayerInAnyVehicle(playerid) && (IsPlayerInRangeOfPoint(playerid, FLAME_ZONE, Flame[i][Flame_pos][0], Flame[i][Flame_pos][1], Flame[i][Flame_pos][2]+Z_DIFFERENCE) ||
												   IsPlayerInRangeOfPoint(playerid, FLAME_ZONE, Flame[i][Flame_pos][0], Flame[i][Flame_pos][1], Flame[i][Flame_pos][2]+Z_DIFFERENCE-1)))
		    {
				return 1;
			}
		}
	}
	return 0;
}


new Flame[MAX_FLAMES][FlameInfo];
new PlayerOnFlame[MAX_PLAYERS];
new PlayerOnFire[MAX_PLAYERS];




forum.sa-mp.com info:
Over 1000 posts.
Over 50 reputation.

stock IsAtFlame(playerid)
{
	for(new i; i < MAX_FLAMES; i++)
	{

	    if(Flame[i][Flame_Exists])
		{
		    if(!IsPlayerInAnyVehicle(playerid)) && (IsPlayerInRangeOfPoint(playerid, FLAME_ZONE, Flame[i][Flame_pos][0], Flame[i][Flame_pos][1], Flame[i][Flame_pos][2]+Z_DIFFERENCE)) ||
												   IsPlayerInRangeOfPoint(playerid, FLAME_ZONE, Flame[i][Flame_pos][0], Flame[i][Flame_pos][1], Flame[i][Flame_pos][2]+Z_DIFFERENCE-1))
		    {
				return 1;
			}
		}
	}
	return 0;
}

C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1073) : error 017: undefined symbol "FlameInfo"
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1073) : error 009: invalid array size (negative, zero or out of bounds)
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1203) : warning 213: tag mismatch
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1205) : error 029: invalid expression, assumed zero
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1205) : warning 213: tag mismatch
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1205) : error 001: expected token: ",", but found "["
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1205) : warning 215: expression has no effect
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1205) : error 001: expected token: ";", but found "]"
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1205) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright (c) 1997-2006, ITB CompuPhase


6 Errors.


Znaci ne verujem sta god da radim nece,evo pogledaj ti molim te evo ti i pawno i GM
http://speedy.sh/Xm3ET/Gamemodeandpawno.rar  ???


forum.sa-mp.com info:
Over 1000 posts.
Over 50 reputation.

Citat: TheDon poslato Oktobar 31, 2013, 20:41:43 POSLE PODNE
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1073) : error 017: undefined symbol "FlameInfo"
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1073) : error 009: invalid array size (negative, zero or out of bounds)
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1203) : warning 213: tag mismatch
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1205) : error 029: invalid expression, assumed zero
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1205) : warning 213: tag mismatch
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1205) : error 001: expected token: ",", but found "["
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1205) : warning 215: expression has no effect
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1205) : error 001: expected token: ";", but found "]"
C:\Users\Niko_Crawford\Desktop\ERP Test Version\gamemodes\larp.pwn(1205) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright (c) 1997-2006, ITB CompuPhase


6 Errors.


Znaci ne verujem sta god da radim nece,evo pogledaj ti molim te evo ti i pawno i GM
http://speedy.sh/Xm3ET/Gamemodeandpawno.rar  ???

Ako mozes na mediafire da uplodas ili tako negde, posto preko ovakvih sajtova skidas preko njihovog klijenta nekoga i skines jos 45154 reklamnih aplikacija.

Samo klikni na naslov pri samom vrhu videces "Download: Gamemodeandpawno.rar" 2.55mb ne treba ti nikakav klient


forum.sa-mp.com info:
Over 1000 posts.
Over 50 reputation.

Evo nasao sam gresku:

enum FlameInfo
{
	Flame_id,
	Flame_Exists,
	Float:Flame_pos[3],
	Smoke[5],
}
new Flame[MAX_FLAMES][FlameInfo];


znaci new Flame[MAX_FLAMES][FlameInfo]; stavi ispod enuma FlameInfo i to je to.

Hvala punoo,hvala na pomoci i volji svima


forum.sa-mp.com info:
Over 1000 posts.
Over 50 reputation.