It crash where the screenshot was made.
OK i will fix it by creating a Stock :
Code:
stock get_entities_near_origin(Float:origin[3],entitylist[],Float:radius)
{
new entitycount, index, entityid
while((entityid=engfunc(EngFunc_FindEntityInSphere,entityid,origin,radius))!=0)
{
for(index=0;index<entitycount;index++)
if(entityid==entitylist[index])
return entitycount
entitylist[entitycount]=entityid
entitycount+=1
}
return entitycount
}
You just need to create an array and use the stock like this :
Code:
new entitylist[512], victim
for(victim=0;victim<get_entities_near_origin(origin,entitylist,700.0);victim++)
{
// Make your code here !
}
Now, it's work fine ! No more bug !
Yeah !
__________________