Problema con Vehiculos
#4

Quote:
Originally Posted by ranslsad
Посмотреть сообщение
Es un sistema dinamico de puertas.
Creo que el error puede estar ahi.

pawn Код:
//**********************************************************************
        for(new i = 0; i <MAX_PUERTAS; i++) //Puertas Dinamicas
        {
            if(IsPlayerInRangeOfPoint(playerid,2.0,Puerta[i][PEnterX],Puerta[i][PEnterY],Puerta[i][PEnterZ]))
            {
                if(IsPlayerInAnyVehicle(playerid)) return 0;
                if(Puerta[i][PCerrado] == 1) return SendClientMessage(playerid, COLOR_RED, "La puerta esta cerrada.");
                SetPlayerVirtualWorld(playerid, Puerta[i][PExitVW]);
                SetPlayerPos(playerid, Puerta[i][PExitX], Puerta[i][PExitY], Puerta[i][PExitZ]);
                SetPlayerInterior(playerid, Puerta[i][PExitInt]);
                return 1;
            }
            if(IsPlayerInRangeOfPoint(playerid,2.0,Puerta[i][PExitX],Puerta[i][PExitY],Puerta[i][PExitZ]))
            {
                if(IsPlayerInAnyVehicle(playerid)) return 0;
                if(Puerta[i][PCerrado] == 1) return SendClientMessage(playerid, COLOR_RED, "La puerta esta cerrada.");
                SetPlayerVirtualWorld(playerid, Puerta[i][PEnterVW]);
                SetPlayerPos(playerid, Puerta[i][PEnterX], Puerta[i][PEnterY], Puerta[i][PEnterZ]);
                SetPlayerInterior(playerid, Puerta[i][PEnterInt]);
                return 1;
            }
        }
Greetings

Ranslsad
pawn Код:
if(IsPlayerInRangeOfPoint(playerid,2.0,Puerta[i][PEnterX],Puerta[i][PEnterY],Puerta[i][PEnterZ]))
            {
                new playerState = GetPlayerState(playerid);
                if(playerState == PLAYER_STATE_ONFOOT)
                {
                    if(IsPlayerInAnyVehicle(playerid)) return 0;
                    if(Puerta[i][PCerrado] == 1) return SendClientMessage(playerid, COLOR_RED, "La puerta esta cerrada.");
                    SetPlayerVirtualWorld(playerid, Puerta[i][PExitVW]);
                    SetPlayerPos(playerid, Puerta[i][PExitX], Puerta[i][PExitY], Puerta[i][PExitZ]);
                    SetPlayerInterior(playerid, Puerta[i][PExitInt]);
                    return 1;
                }else SendClientMessage(playerid, COLOR_RED, "Esta puerta es solo para personas a pie");
            }
Reply


Messages In This Thread
Problema con Vehiculos - by ranslsad - 30.12.2014, 18:52
Respuesta: Problema con Vehiculos - by jotajeda - 30.12.2014, 19:18
Re: Problema con Vehiculos - by ranslsad - 30.12.2014, 19:21
Respuesta: Re: Problema con Vehiculos - by jotajeda - 30.12.2014, 19:30
Re: Problema con Vehiculos - by ranslsad - 30.12.2014, 19:39
Respuesta: Re: Problema con Vehiculos - by jotajeda - 30.12.2014, 19:46
Re: Problema con Vehiculos - by ranslsad - 30.12.2014, 20:01
Respuesta: Problema con Vehiculos - by ranslsad - 18.02.2015, 11:21
Respuesta: Problema con Vehiculos - by jotajeda - 18.02.2015, 17:12
Respuesta: Problema con Vehiculos - by ranslsad - 18.02.2015, 20:03

Forum Jump:


Users browsing this thread: 1 Guest(s)