Szerző Téma: PPC Fegyver  (Megtekintve 1067 alkalommal)

PPC Fegyver
« Dátum: 2012. március 04. - 20:11:59 »
0 Show voters
Sziasztok!
Olyasmira lenne szükségem h ppc modba rendõröknek lehessen fegyvere.már engedélyeztem a ppc server settings inc -be.Csak azt nem tudom hogy le kell -e compliezni a modot ahoz h az includek menjenek mert nem mentek.megpróbáltam am lecompliezni de akkor ezt a hibát írta:
 
E:\\SAMP\\samp03dsvr_R2_win32\\pawno\\include\\PPC_DefLoads.inc(21) : error 001: expected token: \"}\", but found \"{\"
E:\\SAMP\\samp03dsvr_R2_win32\\pawno\\include\\PPC_DefLoads.inc(35) : error 055: start of function body without function header
E:\\SAMP\\samp03dsvr_R2_win32\\pawno\\include\\PPC_DefLoads.inc(53) : error 055: start of function body without function header
E:\\SAMP\\samp03dsvr_R2_win32\\pawno\\include\\PPC_DefLoads.inc(68) : error 055: start of function body without function header
E:\\SAMP\\samp03dsvr_R2_win32\\pawno\\include\\PPC_DefLoads.inc(71) : error 055: start of function body without function header
E:\\SAMP\\samp03dsvr_R2_win32\\pawno\\include\\PPC_DefLoads.inc(84) : error 055: start of function body without function header
E:\\SAMP\\samp03dsvr_R2_win32\\pawno\\include\\PPC_DefLoads.inc(89) : error 055: start of function body without function header
E:\\SAMP\\samp03dsvr_R2_win32\\pawno\\include\\PPC_DefLoads.inc(93) : error 055: start of function body without function header
E:\\SAMP\\samp03dsvr_R2_win32\\pawno\\include\\PPC_DefLoads.inc(104) : error 010: invalid function or declaration
E:\\SAMP\\samp03dsvr_R2_win32\\pawno\\include\\PPC_Common.inc(137) : warning 203: symbol is never used: \"text\"
E:\\SAMP\\samp03dsvr_R2_win32\\pawno\\include\\PPC_Common.inc(137) : warning 203: symbol is never used: \"command\"
E:\\SAMP\\samp03dsvr_R2_win32\\pawno\\include\\PPC_PlayerCommands.inc(410) : warning 217: loose indentation
Pawn compiler 3.2.3664           Copyright (c) 1997-2006, ITB CompuPhase
 
9 Errors.

 
A def loads inc így néz ki nálnuk
[pawn]// Setup a custom type that holds all data about a load
enum TLoad
{
LoadName[50], // The name of the load
bool:Mafia, // Holds \"true\" if this load is wanted by the mafia
Float:PayPerUnit, // Holds the price for every meter to haul this type of load (this gets multiplied by the distance to calculate the payment)
PCV_Required, // This holds the vehicle-type the player needs to use this load (and automatically the player\'s class)
FromLocations[30], // This array holds all loading-points for this load
ToLocations[30] // This array holds all unloading-points for this load
}
new ALoads[][TLoad] =
{
// LoadName, MafiaLoad, PayPerUnit, VehicleNeeded, From-Locations, To-Locations
// Dummy Load (never used)
{\"Dummy\", false, 0.00, 0, {0}, {0}}, // LoadID 0
// Loads for ore trailer
{\"uj Fa\", false, 100.00, PCV_TruckerOreTrailer, {21, 22}, {68}} // LoadID 200000
{\"uj Kavics\", false, 100.00, PCV_TruckerOreTrailer, {1, 2, 3,}, {4, 5, 65}} // LoadID 30000
{\"uj Föld\", false, 100.00, PCV_TruckerOreTrailer, {65, 1}, {2, 3, 4, 5}} // LoadID 4141
{\"Homok\", false, 100.00, PCV_TruckerOreTrailer, {11}, {1, 2, 3}}, // LoadID 1
{\"Kavics\", false, 100.00, PCV_TruckerOreTrailer, {12}, {1, 2, 3, 4, 5}}, // LoadID 2
{\"Szikla\", false, 100.00, PCV_TruckerOreTrailer, {11}, {1, 2, 3, 4, 5}}, // LoadID 3
{\"Szén\", false, 100.00, PCV_TruckerOreTrailer, {12}, {6, 7, 8}}, // LoadID 4
{\"Érc\", false, 100.00, PCV_TruckerOreTrailer, {12}, {6, 9}}, // LoadID 5
{\"Faforgács\", false, 100.00, PCV_TruckerOreTrailer, {13}, {7, 10}}, // LoadID 6
{\"Trágya\", false, 100.00, PCV_TruckerOreTrailer, {10}, {14}}, // LoadID 7
{\"Föld\", false, 100.00, PCV_TruckerOreTrailer, {6, 15, 16}, {17, 18, 19}}, // LoadID 8
{\"Szemét\", false, 100.00, PCV_TruckerOreTrailer, {17, 19}, {6, 18, 20}}, // LoadID 9
{\"Gumikacsák\", false, 100.00, PCV_TruckerOreTrailer, {21, 22}, {18, 23, 24}}, // LoadID 10
// Loads for liquids trailer
    {\"uj Olaj\", false, 120.00, PCV_TruckerFluidsTrailer, {70, 8, 31}, {37, 32}} // LoadID 313131
    {\"uj Keverékbenzin\", false, 120.00, PCV_TruckerFluidsTrailer, {69, 8, 38}, {25, 26, 35, 46}} // LoadID 5555555555
    {\"uj Földgáz\", false, 120.00, PCV_TruckerFluidsTrailer, {32, 70, 27, 29, 33, 34}, {8, 28, 30, 32, 31, 38}}, // LoadID 61
    {\"uj Benzin\", true, 110.00, PCV_TruckerFluidsTrailer, {8, 25, 26}, {64, 28}}, //LoadID 60
{\"Benzin\", true, 100.00, PCV_TruckerFluidsTrailer, {8, 25, 26}, {27, 28, 29, 30, 31, 32, 33, 34}}, // LoadID 11
{\"Gázolaj\", true, 100.00, PCV_TruckerFluidsTrailer, {8, 25, 26}, {27, 28, 29, 30, 31, 32, 33, 34}}, // LoadID 12
{\"Nitrogén\", true, 100.00, PCV_TruckerFluidsTrailer, {8, 25, 26}, {35, 36}}, // LoadID 13
{\"Nyers Olaj\", false, 100.00, PCV_TruckerFluidsTrailer, {8, 25, 26}, {6}}, // LoadID 14
{\"Kenõolaj\", false, 100.00, PCV_TruckerFluidsTrailer, {37, 38}, {39, 40}}, // LoadID 15
{\"Tej\", false, 100.00, PCV_TruckerFluidsTrailer, {37}, {6, 15, 39, 40}}, // LoadID 16
{\"Sör\", false, 100.00, PCV_TruckerFluidsTrailer, {37}, {15, 40, 41}}, // LoadID 17
{\"Tengeri Víz\", false, 100.00, PCV_TruckerFluidsTrailer, {8, 25}, {6, 10, 14, 42}}, // LoadID 18
{\"Vegyes Anyagok\", false, 100.00, PCV_TruckerFluidsTrailer, {37, 38}, {21, 22}}, // LoadID 19
{\"Vegszerek\", false, 100.00, PCV_TruckerFluidsTrailer, {21, 22}, {43, 44, 45}}, // LoadID 20
{\"Ólomos Benzin\", true, 100.00, PCV_TruckerFluidsTrailer, {41}, {44, 46}}, // LoadID 21
{\"Keverék Benzin\", false, 100.00, PCV_TruckerFluidsTrailer, {37, 41}, {26, 39, 40}}, // LoadID 22
// Loads for cargo trailer
{\"uj Élelmiszer\", false, 100.00, PCV_TruckerCargoTrailer, {66, 23, 15}, {54, 52}} // LoadIs 3000222
{\"uj Üditõ\", false, 100.00, PCV_TruckerCargoTrailer, {15, 54, 55}, {66, 71, 67, 23}} // LoadID 3010000
{\"Élelmiszer\", false, 100.00, PCV_TruckerCargoTrailer, {7, 44, 47, 48}, {49, 50, 51, 52, 53}}, // LoadID 23
{\"Üdítõ\", false, 100.00, PCV_TruckerCargoTrailer, {15, 54, 55}, {49, 50, 51, 52, 53}}, // LoadID 24
{\"Luxus cikkek\", true, 100.00, PCV_TruckerCargoTrailer, {56}, {57, 58, 59, 60, 61}}, // LoadID 25
{\"Üveges Sör\", false, 100.00, PCV_TruckerCargoTrailer, {24, 55}, {47, 48, 50}}, // LoadID 26
{\"Elektrocika\", true, 100.00, PCV_TruckerCargoTrailer, {7, 24, 48}, {50, 51, 62, 63}}, // LoadID 27
{\"Sport Cuccok\", false, 100.00, PCV_TruckerCargoTrailer, {47, 48}, {50, 53, 57}}, // LoadID 28
{\"Tábla\", false, 100.00, PCV_TruckerCargoTrailer, {10}, {4, 7, 18, 22}}, // LoadID 29
{\"Bútorok\", false, 100.00, PCV_TruckerCargoTrailer, {4}, {1, 2, 3, 5}}, // LoadID 30
{\"Benzines Hordók\", false, 100.00, PCV_TruckerCargoTrailer, {21, 22}, {23, 43, 47}}, // LoadID 31
{\"Bála\", false, 100.00, PCV_TruckerCargoTrailer, {43}, {44, 49, 50, 51, 52, 53}}, // LoadID 32
{\"Hengerek\", false, 100.00, PCV_TruckerCargoTrailer, {14}, {9, 62}}, // LoadID 33
// Loads for cement truck
{\"Cement\", false, 100.00, PCV_TruckerCementTruck, {12}, {1, 2, 3, 4}}, // LoadID 34
// Loads for truckers without trailer
{\"Élelmiszer\", false, 100.60, PCV_TruckerNoTrailer, {7, 44, 47, 48}, {49, 50, 51, 52, 53}}, // LoadID 35
{\"Üditõ\", false, 100.60, PCV_TruckerNoTrailer, {15, 54, 55}, {49, 50, 51, 52, 53}}, // LoadID 36
{\"Üveges sör\", true, 100.60, PCV_TruckerNoTrailer, {56}, {57, 58, 59, 60, 61}}, // LoadID 37
{\"Luxus cikkek\", false, 100.60, PCV_TruckerNoTrailer, {24, 55}, {47, 48, 50}}, // LoadID 38
{\"Elektronika\", true, 100.60, PCV_TruckerNoTrailer, {7, 24, 48}, {50, 51, 62, 63}}, // LoadID 39
{\"Sport cuccok\", false, 100.60, PCV_TruckerNoTrailer, {47, 48}, {50, 53, 57}}, // LoadID 40
{\"Táblák\", false, 100.60, PCV_TruckerNoTrailer, {10}, {4, 7, 18, 22}}, // LoadID 41
{\"Bútorok\", false, 100.60, PCV_TruckerNoTrailer, {4}, {1, 2, 3, 5}}, // LoadID 42
{\"Állatok\", false, 100.60, PCV_TruckerNoTrailer, {21, 22}, {23, 43, 47}}, // LoadID 43
{\"Husok\", false, 100.60, PCV_TruckerNoTrailer, {43}, {44, 49, 50, 51, 52, 53}}, // LoadID 44
{\"Papír\", false, 100.60, PCV_TruckerNoTrailer, {14}, {9, 62}}, // LoadID 45
// Loads for pilots
{\"Tulsulyos\", false, 100.00, PCV_PilotPlane, {128, 129, 132, 133,}, {137, 138, 141}}, // LoadID 46
{\"Utasok\", false, 100.00, PCV_PilotPlane, {130, 131, 127, 134, 135,}, {136, 139, 140, 142}}, // LoadID 47
{\"Tulsulyos\", false, 100.00, PCV_PilotHelicopter, {128, 129, 132, 133,}, {137, 138, 141}}, // LoadID 48
// Dumperes munka
{\"salak\", false, 300.40, PCV_TruckerDumper, {1, 2, 3}, {4, 5,}}, // LoadID 34
{\"föld\", false, 300.40, PCV_TruckerDumper, {1, 2, 4,}, {65, 5, 3}}, //LoadID 124
// Loads for mafia
{\"Élelmiszer\", false, 100.50, PCV_MafiaVan, {7, 44, 47, 48}, {49, 50, 51, 52, 53}}, // LoadID 49
{\"Üditõk\", false, 100.50, PCV_MafiaVan, {15, 54, 55}, {49, 50, 51, 52, 53}}, // LoadID 50
{\"Üveges sör\", true, 100.50, PCV_MafiaVan, {56}, {57, 58, 59, 60, 61}}, // LoadID 51
{\"Luxus cikkek\", false, 100.50, PCV_MafiaVan, {24, 55}, {47, 48, 50}}, // LoadID 52
{\"Elektronika\", true, 100.50, PCV_MafiaVan, {7, 24, 48}, {50, 51, 62, 63}}, // LoadID 53
{\"Sport felszerelés\", false, 100.50, PCV_MafiaVan, {47, 48}, {50, 53, 57}}, // LoadID 54
{\"Táblák\", false, 100.50, PCV_MafiaVan, {10}, {4, 7, 18, 22}}, // LoadID 55
{\"Butorok\", false, 100.50, PCV_MafiaVan, {4}, {1, 2, 3, 5}}, // LoadID 56
{\"Állatok\", false, 100.50, PCV_MafiaVan, {21, 22}, {23, 43, 47}}, // LoadID 57
{\"Hús\", false, 100.50, PCV_MafiaVan, {43}, {44, 49, 50, 51, 52, 53}}, // LoadID 58
{\"Papír\", false, 100.50, PCV_MafiaVan, {14}, {9, 62}} // LoadID 59
};
// This function returns a string (array) that holds all ProductID\'s that are linked to a certain vehicletype (and player class)
stock Product_GetList(PCV_Needed, &NumProducts)
{
// Setup local variables
new ProductList[50];
// Loop through all products
for (new i; i < sizeof(ALoads); i++)
{
   // Check if there aren\'t 50 products found (and added to the ProductList) yet
   if (NumProducts < 50)
   {
      // Check if the current product has the same PCV_Needed
      if (ALoads[PCV_Required] == PCV_Needed)

      {


         // Add the ProductID to the ProductList


         ProductList[NumProducts] = i;


         // Increase the counter NumProducts


         NumProducts++;


      }


   }


}


// Return the ProductList


return ProductList;


}


// This function returns a random products for the given vehicletype (and player class)


stock Product_GetRandom(PCV_Needed)


{


// Setup local variables


new ProductList[50], NumProducts;


// Get the entire product-list for this vehicle and class, and also the amount of products


ProductList = Product_GetList(PCV_Needed, NumProducts);


// Get a random product from this list and return it


return ProductList[random(NumProducts)];


}


// This function returns a random startlocation from the given product (load)


stock Product_GetRandomStartLoc(ProductID)


{


// Setup local variables


new NumProducts;


// First find out how many valid start-locations there are in this product


for (new i; i < 30; i++)


{


   // If the product has a valid location in this index


   if (ALoads[ProductID][FromLocations]
!= 0)

       NumProducts++; // Count the number of valid start-locations


   else // A start-location with ID 0 has been found (dummy-location)


       break; // Stop counting


}


// Return the LocationID that\'s stored at a random index


return ALoads[ProductID][FromLocations][random(NumProducts)];


}


// This function returns a random endlocation from the given product (load)


stock Product_GetRandomEndLoc(ProductID)


{


// Setup local variables


new NumProducts;


// First find out how many valid end-locations there are in this product


for (new i; i < 30; i++)


{


   // If the product has a valid location in this index


   if (ALoads[ProductID][ToLocations]
!= 0)

       NumProducts++; // Count the number of valid end-locations


   else // An end-location with ID 0 has been found (dummy-location)


       break; // Stop counting


}


// Return the LocationID that\'s stored at a random index


return ALoads[ProductID][ToLocations][random(NumProducts)];


}


[/pawn]

 

SimplePortal 2.3.7 © 2008-2024, SimplePortal