[DUDA/AYUDA]Que Pasa Con Esto ?
#1

FilterScript
PHP код:
/*############################################################################*/
/*                                                                                                        */
/*                                      Creado por Micaela_Dia                                                            */
/*                                                                                                        */
/*################### - CONSERVA LOS CREDITOS - ##############################*/
//  comandos: /mision - /infomision
#include <a_samp>
#include <zcmd>
new RutaAvion;
new 
Text3D:AVION_3D_INFO[MAX_VEHICLES],AVIONCARTEL;
new 
ObjetoAvion[MAX_VEHICLES], CartelTimer[MAX_PLAYERS];
forward FuncionesA(playerid);
forward F_AVION_CARTEL(playerid);
forward F_AVION_CARTEL2(playerid);
forward F_AVION_CARTEL3(playerid);
forward F_AVION_CARTEL4(playerid);
forward F_AVION_CARTEL5(playerid);
forward SetRaceCheckpoint(playerid,target,next);
public 
OnGameModeInit()
{
        print(
"/////////// = ///////////////////////////// = /////////////////////////");
        print(
"MMMM             MMMM          44444          2222222       @@@@@@@@   ");
        print(
"M:::M           M:::M         4::::4        2::::::::2     @::::::::@  ");
        print(
"M::::M         M::::M        4::4::4      2:::2 2 2:::2   @::@@@@@@::@ ");
        print(
"M::MM::M     M::MM::M      4::4 4::4    2:::2      2:::2 @::@   @@ @::@");
        print(
"M::M M::M   M::M M::M     4::4  4::4   22222       2:::2 @::@ @    @::@");
        print(
"M::M  M::M M::M  M::M    4::4   4::4              2:::2  @::@      @::@");
        print(
"M::M   M::M::M   M::M   4::4    4::4             2:::2   @::@  @@@@@::@");
        print(
"M::M    M:::M    M::M  4::4444444::44444       2:::2     @::@ @    @::@");
        print(
"M::M     M:M     M::M 4::::::::::::::::4     2:::2       @::@ @    @::@");
        print(
"M::M      M      M::M4444444444444444444   2:::2         @::@  @@@@@::@");
        print(
"M::M             M::M           4::4     2:::2222222222  @::@@@@@@@::@ ");
        print(
"M::M             M::M           4::4    2:::::::::::::2   @:::::::::@  ");
        print(
"MMMM             MMMM           4444   2222222222222222    @@@@@@@@@   ");
        print(
"//////////////  AVION PUBLICITARIO POR M42@  //////////////////////////");
        
AVIONCARTEL AddStaticVehicleEx(5931914.4635, -2522.880615.514558.23780115);
        
AVION_3D_INFOAVIONCARTEL ] = Create3DTextLabel(" [!] USE {FF99FF}\n/mision",0xFFFFFFFF0.00.00.060.00);
    
Attach3DTextLabelToVehicleAVION_3D_INFOAVIONCARTEL ] , AVIONCARTEL0.00.02.0);
        return 
1;
}
public 
OnPlayerExitVehicle(playeridvehicleid)
{
        
F_AVION_CARTEL5(playerid);
        
DisablePlayerRaceCheckpoint(playerid);
        return 
1;
}
public 
OnVehicleDeath(vehicleidkillerid)
{
        
AVION_3D_INFOAVIONCARTEL ] = Create3DTextLabel(" [!] USE {FF99FF}\n/mision",0xFFFFFFFF0.00.00.060.00);
    
Attach3DTextLabelToVehicleAVION_3D_INFOAVIONCARTEL ] , AVIONCARTEL0.00.02.0);
        return 
1;
}
public 
SetRaceCheckpoint(playerid,target,next)
{
        if(
RutaAvion == 1)
        {
                
SetPlayerRaceCheckpoint(playerid,31695.85, -2493.3625.47,   1090.16, -2388.7655.68,   10);
        }
        else if(
RutaAvion == 2)
        {
            
SetPlayerRaceCheckpoint(playerid,31090.16, -2388.7655.68,   959.30, -2168.9055.68,   10);
        }
        else if(
RutaAvion == 3)
        {
            
SetPlayerRaceCheckpoint(playerid,3959.30, -2168.9055.68,   892.61, -1873.0355.68,   10);
        }
        else if(
RutaAvion == 4)
        {
            
SetPlayerRaceCheckpoint(playerid,3892.61, -1873.0355.68,   365.09, -1942.2755.68,   10);
        }
        else if(
RutaAvion == 5)
        {
                
SetPlayerRaceCheckpoint(playerid,3365.09, -1942.2755.68,   151.80, -1964.9055.68,   10);
        }
        else if(
RutaAvion == 6)
        {
                
SetPlayerRaceCheckpoint(playerid,3151.80, -1964.9055.68,   93.18, -1573.9655.68,   10);
        }
        else if(
RutaAvion == 7)
        {
           
SetPlayerRaceCheckpoint(playerid,393.18, -1573.9655.68,    307.43, -1146.09141.36,   10);
        }
        else if(
RutaAvion == 8)
        {
                
SetPlayerRaceCheckpoint(playerid,3307.43, -1146.09141.36,   662.44, -885.83113.69,   10);
        }
        else if(
RutaAvion == 9)
        {
            
SetPlayerRaceCheckpoint(playerid,3662.44, -885.83113.69,   986.27, -684.10181.35,   10);
        }
        else if(
RutaAvion == 10)
        {
            
SetPlayerRaceCheckpoint(playerid,3986.27, -684.10181.35,   1295.26, -869.74100.50,     9);
        }
        else if(
RutaAvion == 11)
        {
            
SetPlayerRaceCheckpoint(playerid,31295.26, -869.74100.50,   1657.85, -994.75111.86,   10);
        }
        else if(
RutaAvion == 12)
        {
            
SetPlayerRaceCheckpoint(playerid,31657.85, -994.75111.86,   2038.30, -1074.2273.54,   10);
        }
        else if(
RutaAvion == 13)
        {
            
SetPlayerRaceCheckpoint(playerid,32038.30, -1074.2273.54,   2254.50, -1117.0787.69,   10);
        }
        else if(
RutaAvion == 14)
        {
            
SetPlayerRaceCheckpoint(playerid,32254.50, -1117.0787.69,    2666.29, -1100.89124.67,   10);
        }
        else if(
RutaAvion == 15)
        {
           
SetPlayerRaceCheckpoint(playerid,32666.29, -1100.89124.67,   2882.03, -647.1755.68,   10);
        }
        else if(
RutaAvion == 16)
        {
            
SetPlayerRaceCheckpoint(playerid,32882.03, -647.1755.68,   2919.02, -1273.3155.68,   10);
        }
        else if(
RutaAvion == 17)
        {
            
SetPlayerRaceCheckpoint(playerid,32919.02, -1273.3155.68,   2923.29, -1588.6955.68,   10);
        }
        else if(
RutaAvion == 18)
        {
            
SetPlayerRaceCheckpoint(playerid,32923.29, -1588.6955.68,   2926.39, -1877.1155.68,   10);
        }
        else if(
RutaAvion == 19)
        {
                
SetPlayerRaceCheckpoint(playerid,32926.39, -1877.1155.68,   2883.30, -2178.2155.68,   10);
        }
        else if(
RutaAvion == 20)
        {
                        
SetPlayerRaceCheckpoint(playerid,32883.30, -2178.2155.68,   2784.07, -2450.5269.41,   10);
        }
        else if(
RutaAvion == 21)
        {
                
SetPlayerRaceCheckpoint(playerid,32784.07, -2450.5269.41,   2510.15, -2659.0075.95,   10);
        }
        else if(
RutaAvion == 22)
        {
                
SetPlayerRaceCheckpoint(playerid,32510.15, -2659.0075.95,   2173.88, -2684.7678.06,   10);
        }
        else if(
RutaAvion == 23)
        {
                
SetPlayerRaceCheckpoint(playerid,32173.88, -2684.7678.06,   1856.02, -2496.1012.53,   10);
        }
        else if(
RutaAvion == 24)
        {
                
SetPlayerRaceCheckpoint(playerid,41856.02, -2496.1025.47,   0.0,0.0,0.0,   10);
        }
}
public 
FuncionesA(playerid)
{
        new 
message[288];
        
format(messagesizeof(message), "Dirigete al proximo Checkpoint"playerid);
        new 
targetnext;
        if(
RutaAvion == 1)
        {
                        
F_AVION_CARTEL(playerid);
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 2;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 2)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 3;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 3)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 4;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 4)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 5;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 5)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 6;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 6)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 7;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 7)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 8;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 8)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 9;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 9)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 10;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 10)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 11;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 11)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 12;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 12)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 13;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 13)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 14;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 14)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 15;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 15)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 16;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 16)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 17;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 17)
        {
                
GameTextForPlayer(playerid,message30003);
                
RutaAvion 18;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 18)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 19;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 19)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 20;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 20)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 21;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 21)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 22;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 22)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 23;
                
SetRaceCheckpoint(playerid,target,next);
        }
        else if(
RutaAvion == 23)
        {
                
GameTextForPlayer(playeridmessage30003);
                
RutaAvion 24;
                
SetRaceCheckpoint(playerid,target,next);
        }
}
public 
OnPlayerEnterRaceCheckpoint(playerid)
{
                
SetTimer("FuncionesA"10false);
        if(
RutaAvion == 24)
        {
                        
GameTextForPlayer(playerid"has terminado la ruta con exito\nganas ~g~$5000"30003);
                        
GivePlayerMoney(playerid5000);
                
DisablePlayerRaceCheckpoint(playerid);
                                
F_AVION_CARTEL5(playerid);
                
RutaAvion 0;
        }
}
public 
F_AVION_CARTEL(playerid)
{
        if(
GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
        {
                new 
Dodo GetPlayerVehicleID(playerid);
                
ObjetoAvion[Dodo] = CreateObject(1318810.010.010.0000);
                
SetObjectMaterialText(ObjetoAvion[Dodo], "Diviertete\n\n{FF0000}Con Amigos"0140"Tahoma"5010xFFFFFFFF0x005200,OBJECT_MATERIAL_TEXT_ALIGN_CENTER);
                
AttachObjectToVehicle(ObjetoAvion[Dodo], Dodo0.00, -13.00.95,  0.000.000.00);
                
CartelTimer[playerid] = SetTimerEx("F_AVION_CARTEL2"2000false"i"playerid);
                return 
1;
        }
        return 
1;
}
public 
F_AVION_CARTEL2(playerid)
{
        if(
GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
                {
                new 
Dodo GetPlayerVehicleID(playerid);
                
DestroyObject(Dodo);
                
CartelTimer[playerid] = SetTimerEx("F_AVION_CARTEL3"20false"i"playerid);
                return 
1;
        }
        return 
1;
}
public 
F_AVION_CARTEL3(playerid)
{
        if(
GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
        {
                new 
Dodo GetPlayerVehicleID(playerid);
                
ObjetoAvion[Dodo] = CreateObject(1318810.010.010.0000);
                
SetObjectMaterialText(ObjetoAvion[Dodo], "Jugando\n\n{FF0000}< SA-MP >\n{FFFF00}* 127.1.1.1:7777 *"0140"Arial"7010xFFFFFFFF0x005200,OBJECT_MATERIAL_TEXT_ALIGN_CENTER);
                
AttachObjectToVehicle(ObjetoAvion[Dodo], Dodo0.00, -13.00.95,  0.000.000.00);
                
CartelTimer[playerid] = SetTimerEx("F_AVION_CARTEL4"2000false"i"playerid);
                return 
1;
        }
        return 
1;
}
public 
F_AVION_CARTEL4(playerid)
{
        if(
GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
                {
                new 
Dodo GetPlayerVehicleID(playerid);
                
DestroyObject(Dodo);
                
CartelTimer[playerid] = SetTimerEx("F_AVION_CARTEL"20false"i"playerid);
                return 
1;
        }
        return 
1;
}
public 
F_AVION_CARTEL5(playerid)
{
        if(
GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
                {
                new 
Dodo GetPlayerVehicleID(playerid);
                
DestroyObject(Dodo);
                
KillTimer(CartelTimer[playerid]);
                
RutaAvion 0;
                
DisablePlayerRaceCheckpoint(playerid);
                return 
1;
        }
        return 
1;
}
zcmd(infomisionplayeridparams[])
{
        
ShowPlayerDialog(playerid,3451DIALOG_STYLE_MSGBOX"{FFFF00} INFORMACION DE MISION""\t{3CFF00} Sube al Avion y Recorre LS Haciendo Publicidad""aceptar""");
        return 
1;
}
zcmd(misionplayeridparams[])
{
                new 
targetnextvehicleid GetPlayerVehicleID(playerid);
                if(!
IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid0xFF2C00FF"no estas en un avion");
                {
        if(
GetVehicleModel(vehicleid) == 593)
                {
                        if(
RutaAvion == 0)
                        {
                                
RutaAvion 1;
                                
SendClientMessage(playerid0xFFFFFFAA"Para Comenzar el Empleo ve al Primer {FF0000}Checkpoint");
                                
SetRaceCheckpoint(playerid,target,next);
                                
Delete3DTextLabelAVION_3D_INFOAVIONCARTEL ] );
                                return 
1;
                        }
                        else if(
GetVehicleModel(vehicleid) == 593)
                        if(
RutaAvion == 1)
                        {
                                
RutaAvion 0;
                                
SendClientMessage(playerid0xFF2C00FF"has cancelado el trabajo");
                                
F_AVION_CARTEL5(playerid);
                                
DisablePlayerRaceCheckpoint(playerid);
                                return 
1;
                        }
                }
                return 
SendClientMessage(playerid0xFF2C00FF"este no es el avion publicitario");
        }

Errores (Solo Necesito La Solucion De Los 2 Errores, De Los loose indentation Ya Se Que Es.)
PHP код:
C:\Documents and Settings\Administrador\Escritorio\misiones.pwn(46) : warning 217loose indentation
C
:\Documents and Settings\Administrador\Escritorio\misiones.pwn(47) : warning 217loose indentation
C
:\Documents and Settings\Administrador\Escritorio\misiones.pwn(60) : warning 217loose indentation
C
:\Documents and Settings\Administrador\Escritorio\misiones.pwn(61) : warning 217loose indentation
C
:\Documents and Settings\Administrador\Escritorio\misiones.pwn(172) : warning 217loose indentation
C
:\Documents and Settings\Administrador\Escritorio\misiones.pwn(314) : warning 217loose indentation
C
:\Documents and Settings\Administrador\Escritorio\misiones.pwn(318) : warning 217loose indentation
C
:\Documents and Settings\Administrador\Escritorio\misiones.pwn(319) : warning 217loose indentation
C
:\Documents and Settings\Administrador\Escritorio\misiones.pwn(320) : warning 217loose indentation
C
:\Documents and Settings\Administrador\Escritorio\misiones.pwn(392) : error 025: function heading differs from prototype
C
:\Documents and Settings\Administrador\Escritorio\misiones.pwn(392 -- 399) : error 021symbol already defined"zcmd"
C:\Documents and Settings\Administrador\Escritorio\misiones.pwn(398) : warning 203symbol is never used"zcmd"
Pawn compiler 3.2.3664              Copyright (c1997-2006ITB CompuPhase
2 Errors

Lineas De Los Errores

PHP код:
zcmd(infomisionplayeridparams[])
{
        
ShowPlayerDialog(playerid,3451DIALOG_STYLE_MSGBOX"{FFFF00} INFORMACION DE MISION""\t{3CFF00} Sube al Avion y Recorre LS Haciendo Publicidad""aceptar""");
        return 
1;
}
zcmd(misionplayeridparams[])
{
                new 
targetnextvehicleid GetPlayerVehicleID(playerid);
                if(!
IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid0xFF2C00FF"no estas en un avion");
                {
        if(
GetVehicleModel(vehicleid) == 593)
                {
                        if(
RutaAvion == 0)
                        {
                                
RutaAvion 1;
                                
SendClientMessage(playerid0xFFFFFFAA"Para Comenzar el Empleo ve al Primer {FF0000}Checkpoint");
                                
SetRaceCheckpoint(playerid,target,next);
                                
Delete3DTextLabelAVION_3D_INFOAVIONCARTEL ] );
                                return 
1;
                        }
                        else if(
GetVehicleModel(vehicleid) == 593)
                        if(
RutaAvion == 1)
                        {
                                
RutaAvion 0;
                                
SendClientMessage(playerid0xFF2C00FF"has cancelado el trabajo");
                                
F_AVION_CARTEL5(playerid);
                                
DisablePlayerRaceCheckpoint(playerid);
                                return 
1;
                        }
                }
                return 
SendClientMessage(playerid0xFF2C00FF"este no es el avion publicitario");
        }

Ayuda, Gracias De Ante Mano.
Reply
#2

Mira esta linea:
pawn Код:
if(!IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, 0xFF2C00FF, "no estas en un avion");
{
Falta un else despuйs del if...
pawn Код:
if(!IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, 0xFF2C00FF, "no estas en un avion");

else /* <-------- AQUI */{ ...
Va en la segunda lнnea justo antes de la llave que abre ---> {
Reply
#3

Cambia ZCMD por command, quedarнa asн:

pawn Код:
command(infomision, playerid, params[]){
y haz lo mismo con las otras, saludos.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)