Beiträge von MrReece

    Hey, hab paar warnings und co... Kann mir das jemand so verschieben mit den lücken und co das das ins normale GF Passt?
    Und Aktion Key auf STRG Pls.


    LG



    public OnPlayerStateChange(playerid, newstate, oldstate)
    {
    if (newstate==PLAYER_STATE_DRIVER)
    {
    if (GetVehicleModel(GetPlayerVehicleID(playerid)) == 525)
    {
    IsTowTrucker[playerid]=1;
    TowTruckers++;
    SendClientMessage(playerid,0xFFFF00AA,"You can use the ACTION KEY to Tow cars");
    }
    else
    {
    if (TowTruckers>0)
    {
    SendClientMessage(playerid,0xFFFF00AA,"If you have a problem with your car, use /TowMe to call a TowTruker");
    }
    }
    }
    if ((newstate==PLAYER_STATE_ONFOOT)&&(IsTowTrucker[playerid]==1))
    {
    IsTowTrucker[playerid]=0;
    TowTruckers--;
    }
    if ((newstate==PLAYER_STATE_PASSENGER)&&(TowTruckers>0))
    {
    SendClientMessage(playerid,0xFFFF00AA,"If you have a problem with your car, use /TowMe to call a TowTruker");
    }
    return 1;
    }
    //------------------------------------------------------------------------------------------------------
    public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
    {
    if ((newkeys==KEY_ACTION)&&(IsPlayerInAnyVehicle(playerid))&&(GetPlayerState(playerid)==PLAYER_STATE_DRIVER))
    {
    if (GetVehicleModel(GetPlayerVehicleID(playerid)) == 525)
    {
    SendClientMessage(playerid,0xFFFF00AA,"trying to tow a car");
    new Float:pX,Float:pY,Float:pZ;
    GetPlayerPos(playerid,pX,pY,pZ);
    new Float:vX,Float:vY,Float:vZ;
    new Found=0;
    new vid=0;
    while((vid<MAX_VEHICLES)&&(!Found))
    {
    vid++;
    GetVehiclePos(vid,vX,vY,vZ);
    if ((floatabs(pX-vX)<7.0)&&(floatabs(pY-vY)<7.0)&&(floatabs(pZ-vZ)<7.0)&&(vid!=GetPlayerVehicleID(playerid)))
    {
    Found=1;
    if (IsTrailerAttachedToVehicle(GetPlayerVehicleID(playerid)))
    {
    DetachTrailerFromVehicle(GetPlayerVehicleID(playerid));
    }
    AttachTrailerToVehicle(vid,GetPlayerVehicleID(playerid));
    SendClientMessage(playerid,0xFFFF00AA,"Car towed!");
    }
    }
    if (!Found)
    {
    SendClientMessage(playerid,0xFFFF00AA,"There is no car in range.");
    }
    }
    }
    }
    //------------------------------------------------------------------------------------------------------
    public OnPlayerDisconnect(playerid)
    {
    if (IsTowTrucker[playerid]==1)
    {
    IsTowTrucker[playerid]=0;
    TowTruckers--;
    }
    return 1;
    }
    //------------------------------------------------------------------------------------------------------
    public OnPlayerCommandText(playerid,cmdtext[])
    {
    if (strcmp(cmdtext, "/TowMe", true)==0)
    {
    if (TowTruckers==0)
    {
    SendClientMessage(playerid,0xFFFF00AA,"Sorry there isn't any TowTrucker Available at the moment");
    return 1;
    }
    SendClientMessage(playerid,0xFFFF00AA,"TowTruckers has been told of your situation, just wait.");
    SendClientMessage(playerid,0xFFFF00AA,"REMEMBER: Your car can't be towed if you are sitting as the driver");
    new pName[MAX_PLAYER_NAME];
    new msg[256];
    format(msg,sizeof(msg),"*** %s (id:%d) Need to be Towed ***",pName,playerid);
    GetPlayerName(playerid,pName,sizeof(pName));
    for (new i=0;i<MAX_PLAYERS;i++)
    {
    if (IsTowTrucker[i]==1)
    {
    SendClientMessage(i,0xFFFF00AA,msg);
    }
    }
    return 1;
    }
    return 0;
    }


    else if (PlayerToPoint(10.0, i, 1684.6958,-1078.4027,23.8984))
    {
    if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pLeader] == 1)
    {
    SetObjectRot (gate6,0.000000,0.000000,269.818847);
    SetTimer("GateClose", 5000, 0);
    }
    }

    ... error 017: undefined symbol "playerid"

    Hey, hab ein prob mit der schranke, lässt sich nicht öffnen

    New:
    new gate6;
    Object:


    gate6 = CreateObject(968, 1682.002075, -1083.908203, 23.743521, 0.0000, 268.8998, 270.0000);


    Bei Close:
    SetObjectRot (gate6,0.000000,89.000000,269.818847,4);


    if (strcmp(cmdtext, "/opengate", true)==0)
    {
    if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pLeader] == 1)
    {
    if (PlayerToPoint(10,playerid,1684.6958,-1078.4027,23.8984))
    {
    SetObjectRot (gate6,0.000000,0.000000,269.818847,4);
    SendClientMessage(playerid, COLOR_GREEN, "Gate is open, it will close automatically in 5 seconds !");
    SetTimer("GateClose", 5000, 0);
    }
    return 1;
    }
    ....


    Könnt ihr mir vllt noch sagen wie ich mache das Jeder die schranke öffnen kann?


    Und wie man das mit timern macht das wenn man davor steht das das aufgeht.


    LG

    public deliver()
    {
    new string[200];
    for(new playerid=0;playerid<MAX_PLAYERS;playerid++)
    {
    if(PlayerToPoint(3.0,playerid,2063.2549,-1584.8943,13.4809) || PlayerToPoint(3.0,playerid,2235.2610,-1170.7758,1029.7969))
    {
    if(WatchingTV[playerid] == 1)
    {
    SendClientMessage(playerid, COLOR_GRAD1, "Du kannst keinen Materialien verkaufen, während du TV schaust !");
    return 1;
    }
    if(MatsHolding[playerid] > 0)
    {
    new payout = (50)*(MatsHolding[playerid]);
    format(string, sizeof(string), "* The Factory gave you %d Materials for your %d Materials Packages.", payout, MatsHolding[playerid]);
    SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
    PlayerInfo[playerid][pMats] += payout;
    MatsHolding[playerid] = 0;
    }
    else
    {
    SendClientMessage(playerid, COLOR_GREY, " You don't have any Materials Packages !");
    return 1;
    }
    }
    else
    {
    SendClientMessage(playerid, COLOR_GREY, " You are not at the Materials Factory in Los Santos !");
    return 1;
    }
    }
    else
    {
    SendClientMessage(playerid, COLOR_GREY, " Invalid Materials Name !");
    return 1;
    }
    }
    return 1;
    }
    }


    (1702) : error 029: invalid expression, assumed zero
    (1704) : error 017: undefined symbol "playerid"
    (1708) : error 010: invalid function or declaration

    Hey leute, hab ne frage: und Zwar:


    Wenn jemand sich bei mir aufm server registriert oder einloggt bekomme ich einen Moneywarn. Wie kann ich das machen das ich das beim einloggen/registrieren nicht mehr sehe?

    Hey hab mal was gemacht bekomme errors wegen PlayerToPoint....


    Ist das überhaupt so umsetzbar oder muss ich dann jedenjob einzeln machen also bei /joinjob halt die auflistung.
    Dann einzelnen begriff /joinjob Car jacker.... oder geht das auf diesem wege?



    if(strcmp(cmd, "/joinjob", true) == 0)
    {
    if(IsPlayerConnected(playerid))
    {
    if(PlayerInfo[playerid][pJob] == 0 || PlayerToPoint(4.0, playerid,363.2375,176.2490,1008.3828)
    {
    if(PlayerInfo[playerid][pLeader] != 12)
    {
    if(gTeam[playerid] == 1 || gTeam[playerid] == 2 || gTeam[playerid] == 4 || gTeam[playerid] == 11)
    {
    SendClientMessage(playerid, COLOR_GREY, " You must be a Civilian (Not Wanted) or a Family Member to get a Job !");
    return 1;
    }
    }
    new x_nr[256];
    x_nr = strtok(cmdtext, idx);
    if(!strlen(x_nr))
    {
    SendClientMessage(playerid, COLOR_LIGHTRED, "|____________________ Jobcenter ____________________|");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "| Locomotiv Driver Car Dealer");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "| Lawyer Boxer");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "| Whore Bus Driver");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "| Drugs Dealer Paperboy");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "| Car Jacker Trucker");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "| Car Mechanic Detectiv");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "| Bodyguard Stuntman");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "| Arms Dealer Pilot");
    SendClientMessage(playerid, COLOR_LIGHTRED, "Help: /joinjob [job]"); SendClientMessage(playerid, COLOR_LIGHTRED, "|____________________ Jobcenter ____________________|");
    return 1;
    }
    if(strcmp(x_nr,"Locomotiv Driver",true) == 0 && GetPlayerState(playerid) == 1 && PlayerToPoint(3.0, playerid,363.2375,176.2490,1008.3828))
    {
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You are about to become a Locomotiv Driver and get a 5 hour Contract.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You have to forfill this Contract first, if you want to Quit the job later.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* If you are sure to become a Locomotiv Driver, type /accept job.");
    GettingJob[playerid] = 1;
    return 1;
    }
    else if(strcmp(x_nr,"Lawyer",true) == 0 && GetPlayerState(playerid) == 1 && PlayerToPoint(3.0, playerid,363.2375,176.2490,1008.3828))
    {
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You are about to become a Whore and get a 5 hour Contract.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You have to forfill this Contract first, if you want to Quit the job later.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* If you are sure to become a Whore, type /accept job.");
    GettingJob[playerid] = 2;
    return 1;
    }
    else if(strcmp(x_nr,"Whore",true) == 0 && GetPlayerState(playerid) == 1 && PlayerToPoint(3.0, playerid,363.2375,176.2490,1008.3828))
    {
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You are about to become a Whore and get a 5 hour Contract.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You have to forfill this Contract first, if you want to Quit the job later.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* If you are sure to become a Whore, type /accept job.");
    GettingJob[playerid] = 3;
    return 1;
    }
    else if(strcmp(x_nr,"Drugs Dealer",true) == 0 && GetPlayerState(playerid) == 1 && PlayerToPoint(3.0, playerid,363.2375,176.2490,1008.3828))
    {
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You are about to become a Drugs Dealer and get a 5 hour Contract.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You have to forfill this Contract first, if you want to Quit the job later.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* If you are sure to become a Drugs Dealer, type /accept job.");
    GettingJob[playerid] = 4;
    return 1;
    }
    else if(strcmp(x_nr,"Car Jacker",true) == 0 && GetPlayerState(playerid) == 1 && PlayerToPoint(3.0, playerid,363.2375,176.2490,1008.3828))
    {
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You are about to become a Car Jacker and get a 5 hour Contract.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You have to forfill this Contract first, if you want to Quit the job later.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* If you are sure to become a Car Jacker, type /accept job.");
    GettingJob[playerid] = 5;
    return 1;
    }
    else if(strcmp(x_nr,"Car Mechanic",true) == 0 && GetPlayerState(playerid) == 1 && PlayerToPoint(3.0, playerid,363.2375,176.2490,1008.3828))
    {
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You are about to become a Car Mechanic and get a 5 hour Contract.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You have to forfill this Contract first, if you want to Quit the job later.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* If you are sure to become a Car Mechanic, type /accept job.");
    GettingJob[playerid] = 7;
    return 1;
    }
    else if(strcmp(x_nr,"Bodyguard",true) == 0 && GetPlayerState(playerid) == 1 && PlayerToPoint(3.0, playerid,363.2375,176.2490,1008.3828))
    {
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You are about to become a Bodyguard and get a 5 hour Contract.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You have to forfill this Contract first, if you want to Quit the job later.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* If you are sure to become a Bodyguard, type /accept job.");
    GettingJob[playerid] = 8;
    return 1;
    }
    else if(strcmp(x_nr,"Arms Dealer",true) == 0 && GetPlayerState(playerid) == 1 && PlayerToPoint(3.0, playerid,363.2375,176.2490,1008.3828))
    {
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You are about to become a Arms Dealer and get a 5 hour Contract.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You have to forfill this Contract first, if you want to Quit the job later.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* If you are sure to become a Arms Dealer, type /accept job.");
    GettingJob[playerid] = 9;
    return 1;
    }
    else if(strcmp(x_nr,"Car Dealer",true) == 0 && GetPlayerState(playerid) == 1 && PlayerToPoint(3.0, playerid,363.2375,176.2490,1008.3828))
    {
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You are about to become a Car Dealer and get a 5 hour Contract.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You have to forfill this Contract first, if you want to Quit the job later.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* If you are sure to become a Car Dealer, type /accept job.");
    GettingJob[playerid] = 10;
    return 1;
    }
    else if(strcmp(x_nr,"Boxer",true) == 0 && GetPlayerState(playerid) == 1 && PlayerToPoint(3.0, playerid,363.2375,176.2490,1008.3828))
    {
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You are about to become a Boxer and get a 5 hour Contract.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You have to forfill this Contract first, if you want to Quit the job later.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* If you are sure to become a Boxer, type /accept job.");
    GettingJob[playerid] = 12;
    return 1;
    }
    else if(strcmp(x_nr,"Bus Driver",true) == 0 && GetPlayerState(playerid) == 1 && PlayerToPoint(3.0, playerid,363.2375,176.2490,1008.3828))
    {
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You are about to become a Bus Driver and get a 5 hour Contract.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You have to forfill this Contract first, if you want to Quit the job later.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* If you are sure to become a Bus Driver, type /accept job.");
    GettingJob[playerid] = 14;
    return 1;
    else if(strcmp(x_nr,"Paperboy",true) == 0 && GetPlayerState(playerid) == 1 && PlayerToPoint(3.0, playerid,363.2375,176.2490,1008.3828))
    {
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You are about to become a Paperboy and get a 5 hour Contract.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You have to forfill this Contract first, if you want to Quit the job later.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* If you are sure to become a Paperboy, type /accept job.");
    GettingJob[playerid] = 15;
    return 1;
    }
    else if (strcmp(x_nr,"Trucker",true) == 0 && GetPlayerState(playerid) == 1 && PlayerToPoint(3.0, playerid,363.2375,176.2490,1008.3828))
    {
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You are about to become a Trucker and get a 5 hour Contract.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* You have to forfill this Contract first, if you want to Quit the job later.");
    SendClientMessage(playerid, COLOR_LIGHTBLUE, "* If you are sure to become a Trucker, type /accept job.");
    GettingJob[playerid] = 16;
    return 1;
    }
    else
    {
    SendClientMessage(playerid, COLOR_GREY, " You are not even near a place to get a Job !");
    }
    }
    else
    {
    SendClientMessage(playerid, COLOR_GREY, " You already have a Job, use /quitjob first !");
    }
    }
    return 1;
    }

    Hey, ich hab ein problem
    und zwar wenn ich Tazeranimation habe geht das ja aber ich seh nur wenn andere am boden liegen und wenn ich getazert bin stehe ich bei mir aber bei den andere nicht.


    Wie mach ich das das ich die Animation selber sehe?

    Hey Leute,
    würde gerne auf nem ausgewählten Punkt auf der Karte einen Befehl machen /job - Dann kommen halt die Jobs aufgelistet und dann wenn man /job carjacker macht das dann da steht /accept job und wenn man das tut das man ihn hat.


    Könnte mir bitte jemand die richtung weisen?


    Danke

    Hey hab mal ne frage:


    http://pastebin.com/f39fe3174


    Hab Im Mom paar Errors:
    Wegen Price oder so.
    Man Sollte per /materials - Automatisch 10 Pakete kaufen ( Ohne auswahl von 1-10 )


    Und Noch ein "Wunsch" Kann mir das jemand so anfertigen das wenn ich an nem PlayerToPoint bin ohne cmd die Packete gegen Mats austausche?


    Danke im vorraus!