Include errors
#1

i got this Inculde and i wanted to add to my gm but when i did this a got these errors

Код:
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(3) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(7) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(25) : error 021: symbol already defined: "AddVehicleMissiles"
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(27) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(30) : error 021: symbol already defined: "GetVehiclePos"
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(31) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(33) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(36) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(39) : error 021: symbol already defined: "AttachObjectToVehicle"
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(42) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(44) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(48) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(51) : error 021: symbol already defined: "RemoveVehicleMissiles"
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(53) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(55) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(57) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(61) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(63) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(66) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(69) : error 021: symbol already defined: "IsVehicleHot"
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(71) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(72) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(74) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(90) : warning 219: local variable "Floatx" shadows a variable at a preceding level
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(102) : warning 213: tag mismatch
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(102) : warning 213: tag mismatch
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(102) : warning 213: tag mismatch
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(103) : error 017: undefined symbol "a"
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(105) : error 017: undefined symbol "a"
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(105) : warning 215: expression has no effect
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(106) : error 017: undefined symbol "z"
and this is the include
pawn Код:
#include a_samp

------------------------------------
native AddVehicleMissiles(vehicleid,Floatoffsetx,Floatoffsetz);
native RemoveVehicleMissiles(vehicleid);
native IsVehicleHot(vehicleid);
-------------------------------------

#define MISSILE_DETONATE_TIME 500       milliseconds
#define MISSILE_EXPLODE_TYPE 10
#define MISSILE_EXPLODE_RADIUS 10.0
#define MISSILE_SPEED 40.0
#define MISSILE_FIRE_KEY 1

new VehicleFire[MAX_VEHICLES];
new VehicleBomb[MAX_VEHICLES][2];
new VehicleSmok[MAX_VEHICLES][2];
new FloatVehicleOffsetX[MAX_VEHICLES];
new FloatVehicleOffsetZ[MAX_VEHICLES];

forward VM_OnPlayerKeyStateChange(playerid,newkeys);
forward VM_Explode(vehicleid,mode);
forward VM_OnVehicleFire(vehicleid,slot);

stock AddVehicleMissiles(vehicleid,Floatoffsetx,Floatoffsetz)
{
        if(!VehicleFire[vehicleid])
        {
                new Floatx,Floatu;
                GetVehiclePos(vehicleid,x,u,u);
                if(x != 0)
                {
                        if(!IsValidObject(VehicleBomb[vehicleid][1]))
                        {

                                VehicleBomb[vehicleid][0] = CreateObject(3790,0.0,0.0,0.0,0,0,0,300.0);
                                VehicleBomb[vehicleid][1] = CreateObject(3790,0.0,0.0,0.0,0,0,0,300.0);

                                AttachObjectToVehicle(VehicleBomb[vehicleid][0],vehicleid,offsetx,0,offsetz,0,0,270);
                                AttachObjectToVehicle(VehicleBomb[vehicleid][1],vehicleid,-offsetx,0,offsetz,0,0,270);

                                VehicleOffsetX[vehicleid] = offsetx;
                                VehicleOffsetZ[vehicleid] = offsetz;
                                return 1;
                        }
                }
        }
        return 0;
}

stock RemoveVehicleMissiles(vehicleid)
{
        if(!VehicleFire[vehicleid])
        {
                if(IsValidObject(VehicleBomb[vehicleid][1]))
                {
                        if(VehicleBomb[vehicleid][0])
                        {
                                DestroyObject(VehicleBomb[vehicleid][0]);
                                DestroyObject(VehicleBomb[vehicleid][1]);
                                return 1;
                        }
                        return DestroyObject(VehicleBomb[vehicleid][1]),1;
                }
        }
        return 0;
}

stock IsVehicleHot(vehicleid)
{
        if(IsValidObject(VehicleBomb[vehicleid][1]))
                return 1;

        return 0;
}


public VM_OnPlayerKeyStateChange(playerid,newkeys)
{
        if((newkeys & MISSILE_FIRE_KEY) == (MISSILE_FIRE_KEY))
        {
                new id = GetPlayerVehicleID(playerid);
                if(!VehicleFire[id])
                {
                        if(id)
                        {
                                if(IsValidObject(VehicleBomb[id][1]))
                                {
                                        new
                                        Floatx,
                                        Floaty,
                                        Floatz,
                                        Floata;


                                        VehicleFire[id] = 1;

                                        if(IsValidObject(VehicleBomb[id][0]))
                                        {
                                                DestroyObject(VehicleBomb[id][0]);

                                                GetVehiclePos(id,Floatx,Floaty,Floatz);
                                                GetVehicleZAngle(id,a);

                                                a += 270;
                                                z += VehicleOffsetZ[id];

                                                x += (VehicleOffsetX[id]  floatsin(-a, degrees));
                                                y += (VehicleOffsetX[id]  floatcos(-a, degrees));

                                                VehicleBomb[id][0] = CreateObject(3790,x,y,z,0,0,a,300.0);
                                                VehicleSmok[id][0] = CreateObject(18731,x,y,z-1.3,0,0,0,300.0);

                                                a += 90;

                                                x += (30  floatsin(-a, degrees));
                                                y += (30  floatcos(-a, degrees));

                                                MoveObject(VehicleBomb[id][0],x,y,z,MISSILE_SPEED);
                                                MoveObject(VehicleSmok[id][0],x,y,z-1.3,MISSILE_SPEED);

                                                SetTimerEx(VM_Explode,MISSILE_DETONATE_TIME,0,dd,id,0);
                                                VM_OnVehicleFire(id,0);
                                                return 1;
                                        }
                                        DestroyObject(VehicleBomb[id][1]);

                                        GetVehiclePos(id,x,y,z);
                                        GetVehicleZAngle(id,a);

                                        a += 90;
                                        z += VehicleOffsetZ[id];

                                        x += (VehicleOffsetX[id]  floatsin(-a, degrees));
                                        y += (VehicleOffsetX[id]  floatcos(-a, degrees));

                                        VehicleBomb[id][1] = CreateObject(3790,x,y,z,0,0,a+180,300.0);
                                        VehicleSmok[id][1] = CreateObject(18731,x,y,z-1.3,0,0,0,300.0);

                                        a += 270;

                                        x += (30  floatsin(-a, degrees));
                                        y += (30  floatcos(-a, degrees));

                                        MoveObject(VehicleBomb[id][1],x,y,z,MISSILE_SPEED);
                                        MoveObject(VehicleSmok[id][1],x,y,z-1.3,MISSILE_SPEED);

                                        SetTimerEx(VM_Explode,MISSILE_DETONATE_TIME,0,dd,id,1);
                                        VM_OnVehicleFire(id,1);
                                        return 1;
                                }
                        }
                        return 1;
                }
        }
        return 1;
}

public VM_Explode(vehicleid,mode)
{
        if(IsValidObject(VehicleBomb[vehicleid][mode]))
        {
                new
                Floatx,
                Floaty,
                Floatz;

                GetObjectPos(VehicleBomb[vehicleid][mode],x,y,z);
                CreateExplosion(x,y,z,MISSILE_EXPLODE_TYPE,MISSILE_EXPLODE_RADIUS);

                DestroyObject(VehicleBomb[vehicleid][mode]);
                DestroyObject(VehicleSmok[vehicleid][mode]);

                VehicleFire[vehicleid] = 0;
                return 1;
        }
        return 1;
}
can you help me with that
Reply
#2

Didn't watched , my mistake
Reply
#3

He has forwards already.

pawn Код:
#include a_samp
//changes into
#include <a_samp>


//later
milliseconds
//add "//" before to comment out
//milliseconds
Reply
#4

lol
#include a_samp == #include <a_samp>
Reply
#5

lol i didn't notice that
i did this but it still not working
pawn Код:
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(3) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(7) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(25) : error 021: symbol already defined: "AddVehicleMissiles"
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(27) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(30) : error 021: symbol already defined: "GetVehiclePos"
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(31) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(33) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(36) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(39) : error 021: symbol already defined: "AttachObjectToVehicle"
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(42) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(44) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(48) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(51) : error 021: symbol already defined: "RemoveVehicleMissiles"
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(53) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(55) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(57) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(61) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(63) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(66) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(69) : error 021: symbol already defined: "IsVehicleHot"
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(71) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(72) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(74) : error 010: invalid function or declaration
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(90) : warning 219: local variable "Floatx" shadows a variable at a preceding level
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(102) : warning 213: tag mismatch
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(102) : warning 213: tag mismatch
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(102) : warning 213: tag mismatch
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(103) : error 017: undefined symbol "a"
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(105) : error 017: undefined symbol "a"
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(105) : warning 215: expression has no effect
C:\Users\maher\Desktop\ahmad ghanayem\ълрйеъ\Iron-Players\pawno\include\VM.inc(106) : error 017: undefined symbol "z"
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)