[Ayuda] Con IsPlayerInArea...
#1

Buenas a Todos, Estoy utilizando la funcion IsPlayerInArea, me funciona , todo bien, pero a veces me pone en el cliente el error Unknown, solamente en el cliente cierro el server y lo abro otra vez y no tira nada, vuelvo a cerrar el server otra vez y pasa lo mismo, algo debe esta mal en el scripts.

Que puede Ser? y Aclaro solo sucede cuando utilizo la funcion de IsPlayerInArea.

Aca dejo el el codigo ke utilizo:

Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
	if (strcmp("/comando", cmdtext, true, 10) == 0)
	{
	        if(!IsPlayerInArea(playerid, x, y,  x, y))
	        {
	     
	        }
                else
	        {
	     
	        }
		return 1;
	}
	return 0;
}
Код:
IsPlayerInArea(playerid, Float:minx, Float:maxx, Float:miny, Float:maxy)
{
    new Float:x, Float:y, Float:z;
    GetPlayerPos(playerid, x, y, z);
    if (x > minx && x < maxx && y > miny && y < maxy) return 1;
    return 0;
}
Desde Ya Muchas Gracias.
Reply
#2

Ya solucione.

Lo Puse en stock al IsPlayerInArea:

Код:
stock IsPlayerInArea(playerid, Float:minx, Float:maxx, Float:miny, Float:maxy)
{
    new Float:x, Float:y, Float:z;
    GetPlayerPos(playerid, x, y, z);
    if (x > minx && x < maxx && y > miny && y < maxy) return 1;
    return 0;
}
Gracias igual :P xD
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)