[HELP]CreateVehicle per /command

Wichtiger Hinweis: Bitte ändert nicht manuell die Schriftfarbe auf schwarz sondern belasst es bei der Standardeinstellung. Somit tragt ihr dazu bei dass euer Text auch bei Verwendung unseren dunklen Forenstils noch lesbar ist!

Tipp: Ihr wollt längere Codeausschnitte oder Logfiles bereitstellen? Benutzt unseren eigenen PasteBin-Dienst Link

  • new admincar1;
    new admincar2;
    new admincar3;
    new admincar4;
    new admincar5;
    new admincar6;
    new admincar7;
    new admincar8;
    new admincar9;
    new admincar10;
    new admincar11;
    new admincar12;
    new admincar13;
    new admincar14;
    new admincar15;
    new admincar16;
    new admincar17;
    new admincar18;
    new admincar19;
    new admincar20;
    new admincar21;
    new admincar22;
    new admincar23;
    new admincar24;
    new admincar25;
    new admincar26;

    if(strcmp("/cars",cmdtext,true) == 0)
    {
    if(Spieler[playerid][AdminLevel] >=4)
    {
    admincar1 = CreateVehicle(548,-3189.94677734,-398.26336670,8.66822243,84.00000000,-1,-1,5000000); //Cargobob
    admincar2 = CreateVehicle(548,-3193.58227539,-362.08023071,8.67556190,84.00000000,-1,-1,5000000); //Cargobob
    admincar3 = CreateVehicle(425,-3208.81884766,-299.21569824,7.86816978,0.00000000,-1,-1,5000000); //Hunter
    admincar4 = CreateVehicle(425,-3190.76831055,-298.61666870,7.86816978,0.00000000,-1,-1,5000000); //Hunter
    admincar5 = CreateVehicle(425,-3175.49389648,-301.93511963,7.86092758,0.00000000,-1,-1,5000000); //Hunter
    admincar6 = CreateVehicle(563,-3175.66552734,-271.69061279,7.55365181,0.00000000,-1,-1,5000000); //Raindance
    admincar7 = CreateVehicle(563,-3196.69531250,-273.57095337,7.54640961,0.00000000,-1,-1,5000000); //Raindance
    admincar8 = CreateVehicle(520,-3204.15625000,-337.68557739,7.83249569,0.00000000,-1,-1,5000000); //Hydra
    admincar9 = CreateVehicle(520,-3184.11328125,-337.55117798,7.83249569,0.00000000,-1,-1,5000000); //Hydra
    admincar10 = CreateVehicle(520,-3233.33056641,-393.97613525,7.49779415,0.00000000,-1,-1,5000000); //Hydra
    admincar11 = CreateVehicle(520,-3253.36279297,-393.87722778,7.49779415,0.00000000,-1,-1,5000000); //Hydra
    admincar12 = CreateVehicle(520,-3246.11425781,-364.34652710,7.49045467,0.00000000,-1,-1,5000000); //Hydra
    admincar13 = CreateVehicle(520,-3236.38549805,-343.18249512,7.49779415,0.00000000,-1,-1,5000000); //Hydra
    admincar14 = CreateVehicle(520,-3256.95654297,-342.07318115,7.49779415,0.00000000,-1,-1,5000000);//Hydra
    admincar15 = CreateVehicle(563,-3235.47607422,-299.52172852,7.21170807,0.00000000,-1,-1,5000000); //Raindance
    admincar16 = CreateVehicle(563,-3257.52490234,-299.70050049,7.21170807,0.00000000,-1,-1,5000000); //Raindance
    admincar17 = CreateVehicle(425,-3221.14086914,-268.36840820,7.46973228,0.00000000,-1,-1,5000000); //Hunter
    admincar18 = CreateVehicle(425,-3241.45581055,-270.15014648,7.53346825,0.00000000,-1,-1,5000000); //Hunter
    admincar19 = CreateVehicle(432,-3268.69726562,-265.63397217,6.90468597,0.00000000,-1,-1,5000000); //Rhino
    admincar20 = CreateVehicle(432,-3257.74291992,-265.54229736,6.90468597,0.00000000,-1,-1,5000000); //Rhino
    admincar21 = CreateVehicle(432,-3257.09985352,-280.14529419,6.90468597,0.00000000,-1,-1,5000000); //Rhino
    admincar22 = CreateVehicle(432,-3268.63110352,-280.08282471,6.90468597,0.00000000,-1,-1,5000000); //Rhino
    admincar23 = CreateVehicle(432,-3240.32055664,-322.61145020,6.89744377,0.00000000,-1,-1,5000000); //Rhino
    admincar24 = CreateVehicle(432,-3255.36547852,-322.65408325,6.89744377,0.00000000,-1,-1,5000000);//Rhino
    admincar25 = CreateVehicle(432,-3194.71801758,-317.72760010,7.23214531,0.00000000,-1,-1,5000000); //Rhino
    admincar26 = CreateVehicle(432,-3214.79003906,-319.42227173,7.23938751,0.00000000,-1,-1,5000000); //Rhino
    }
    return 1;
    }


    Erros:

    gamemodes\BJ.pwn(3247) : warning 204: symbol is assigned a value that is never used: "admincar1"
    gamemodes\BJ.pwn(3256) : warning 204: symbol is assigned a value that is never used: "admincar10"
    gamemodes\BJ.pwn(3257) : warning 204: symbol is assigned a value that is never used: "admincar11"
    gamemodes\BJ.pwn(3258) : warning 204: symbol is assigned a value that is never used: "admincar12"
    gamemodes\BJ.pwn(3259) : warning 204: symbol is assigned a value that is never used: "admincar13"
    gamemodes\BJ.pwn(3260) : warning 204: symbol is assigned a value that is never used: "admincar14"
    gamemodes\BJ.pwn(3261) : warning 204: symbol is assigned a value that is never used: "admincar15"
    gamemodes\BJ.pwn(3262) : warning 204: symbol is assigned a value that is never used: "admincar16"
    gamemodes\BJ.pwn(3263) : warning 204: symbol is assigned a value that is never used: "admincar17"
    gamemodes\BJ.pwn(3264) : warning 204: symbol is assigned a value that is never used: "admincar18"
    gamemodes\BJ.pwn(3265) : warning 204: symbol is assigned a value that is never used: "admincar19"
    gamemodes\BJ.pwn(3248) : warning 204: symbol is assigned a value that is never used: "admincar2"
    gamemodes\BJ.pwn(3266) : warning 204: symbol is assigned a value that is never used: "admincar20"
    gamemodes\BJ.pwn(3267) : warning 204: symbol is assigned a value that is never used: "admincar21"
    gamemodes\BJ.pwn(3268) : warning 204: symbol is assigned a value that is never used: "admincar22"
    gamemodes\BJ.pwn(3269) : warning 204: symbol is assigned a value that is never used: "admincar23"
    gamemodes\BJ.pwn(3270) : warning 204: symbol is assigned a value that is never used: "admincar24"
    gamemodes\BJ.pwn(3271) : warning 204: symbol is assigned a value that is never used: "admincar25"
    gamemodes\BJ.pwn(3272) : warning 204: symbol is assigned a value that is never used: "admincar26"
    gamemodes\BJ.pwn(3249) : warning 204: symbol is assigned a value that is never used: "admincar3"
    gamemodes\BJ.pwn(3250) : warning 204: symbol is assigned a value that is never used: "admincar4"
    gamemodes\BJ.pwn(3251) : warning 204: symbol is assigned a value that is never used: "admincar5"
    gamemodes\BJ.pwn(3252) : warning 204: symbol is assigned a value that is never used: "admincar6"
    gamemodes\BJ.pwn(3253) : warning 204: symbol is assigned a value that is never used: "admincar7"
    gamemodes\BJ.pwn(3254) : warning 204: symbol is assigned a value that is never used: "admincar8"
    gamemodes\BJ.pwn(3255) : warning 204: symbol is assigned a value that is never used: "admincar9"


    Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase


    26 Warnings.


    Könnt ihr mir bitte helfen?
    Wollte per Command cars spawnen^^


    mfg jecK_s

  • Aus welchem Grund definierst du die eigentlich? WIllst du damit später nochwas machen?


    Sonst kannst du ja einfach CreateVehicle nehmen ohne eine definition vorher

    Die deutsche Rechtschreibung ist Freeware, sprich du darfst sie kostenlos nutzen...
    Sie ist aber nicht Open Source, somit darfst du sie nicht verändern oder in veränderter Form veröffentlichen!


  • wollte noch das hier machen

    if(strcmp("/caroff",cmdtext,true) == 0)
    {
    DestroyVehicle(admincar1);
    ...DestroyVehicle(admincar26);
    return 1;
    }


    Edit:
    Bin dumm,sry ^^ :pinch:
    da gehen ja die erros weg :P


    /closed

  • Dann mach den Befehl auch noch dann sollten die Warns weg sein ;)

    Die deutsche Rechtschreibung ist Freeware, sprich du darfst sie kostenlos nutzen...
    Sie ist aber nicht Open Source, somit darfst du sie nicht verändern oder in veränderter Form veröffentlichen!