SA-MP Forums Archive
[BUG] Public - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: [BUG] Public (/showthread.php?tid=303976)



[BUG] Public - BigBaws - 16.12.2011

i need your help guys look i got this error i guess i added it in the correct place of stock's
check pic
Код:
stock PlayerToPoint(playerid,Float:radi, Float:px, Float:py, Float:pz)
{
    if(IsPlayerConnected(playerid))
	{
		new Float:x, Float:y, Float:z;
		new Float:ox, Float:oy, Float:oz;
		GetPlayerPos(playerid, ox, oy, oz);
		x = (ox -px);
		y = (oy -py);
		z = (oz -pz);
		if (((x < radi) && (x > -radi)) && ((y < radi) && (y > -radi)) && ((z < radi) && (z > -radi))) return 1;
	}
	return 0;
}



Re: [BUG] Public - MP2 - 16.12.2011

Just remove it, it's already defined.


Re : [BUG] Public - BigBaws - 16.12.2011

i will mroe explain , when i login ingame then i create an object then i will /deleteobj it wont deleted its tell me ig there are no object near me ... & thanks for an other answer


Re: [BUG] Public - BlackWolf120 - 16.12.2011

Check your script, are u sure it isnt defined twice?
Also show us how u use the stock in ur script.


Re : [BUG] Public - BigBaws - 16.12.2011

i removed it it working good , but the Object i cant remove it IG i can just create it but i cant destroy it i already made a DestroyObject(Objct[i]); in the /deltobjct
but arnt destroying it


Re : [BUG] Public - BigBaws - 16.12.2011




Re : [BUG] Public - BigBaws - 16.12.2011

Anyhelp please ...


Re: [BUG] Public - BlackWolf120 - 16.12.2011

please dont post screenshots but pawno code using /pawn tags

Also i dont see a script part where ure trying to destroy a certain object.
Post the right code part please so i can take a look at it


Re : [BUG] Public - BigBaws - 16.12.2011

if(strcmp(cmdtext, "/suptag", true)==0)
{
new count;
new frm[128];
for(new i = 0; i < MAX_TAGS; i++)
{
if(PlayerToPoint(playerid,2,TagInfo[i][tgX],TagInfo[i][tgY],TagInfo[i][tgZ]))
{
GetPlayerName(playerid, frm, MAX_PLAYER_NAME);
if (!strcmp(TagInfo[i][tgSprayer],frm))
{
DestroyObject(Spray[i]);
TagInfo[i][tgX] = 0;
TagInfo[i][tgY] = 0;
TagInfo[i][tgZ] = 0;
Spray[i] = INVALID_OBJECT_ID;
strmid(TagInfo[i][tgSprayer], " ", 0, 1);
Tag--;
count++;
}
}
}
format(frm, sizeof(frm), "* Vous aver nettoyй Votre Tag Grafitti qui est Sur le mure .", count);
SendClientMessage(playerid, PURPLE, frm);
format(frm, sizeof(frm), " vous avez Supprimer Votre %d tags", count);
SendClientMessage(playerid, GRAY, frm);
ApplyAnimation(playerid,"SPRAYCAN","spraycan_full" ,4.0,0,0,0,0,0,1);
return 1;
}
when i type this commande i cant Destry the Tag object & thanks for your answers


Re : [BUG] Public - BigBaws - 16.12.2011

any help & thanks al ot