2 Fragen

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
  • 1. Frage: wie kann ich bei GF die Max Wanted lvl verändern ?
    2.Frage: wie mach ich dass man bei /frisk sieht ob der User eine Waffe bei sich hat ?
    hier /frisk befehl


    if(strcmp(cmd,"/frisk",true)==0)
    {
    if(IsPlayerConnected(playerid))
    {
    tmp = strtok(cmdtext, idx);
    if(!strlen(tmp))
    {
    SendClientMessage(playerid, COLOR_WHITE, "Benutze: /frisk [playerid/PartOfName]");
    return 1;
    }
    giveplayerid = ReturnUser(tmp);
    if(IsPlayerConnected(giveplayerid))
    {
    if(giveplayerid != INVALID_PLAYER_ID)
    {
    if (ProxDetectorS(8.0, playerid, giveplayerid))
    {
    if(giveplayerid == playerid) { SendClientMessage(playerid, COLOR_GREY, "You cannot Frisk yourself!"); return 1; }
    GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
    GetPlayerName(playerid, sendername, sizeof(sendername));
    new text1[20], text2[20], text3[20], text4[20], text5[20];
    if(PlayerInfo[giveplayerid][pDrugs] > 0) { text1 = "| Drugs."; } else { text1 = "| Empty Pocket."; }
    if(PlayerInfo[giveplayerid][pMats] > 0) { text2 = "| Materials."; } else { text2 = "| Empty Pocket."; }
    if(Fishes[giveplayerid][pWeight1] > 0 || Fishes[giveplayerid][pWeight2] > 0 || Fishes[giveplayerid][pWeight3] > 0 || Fishes[giveplayerid][pWeight4] > 0 || Fishes[giveplayerid][pWeight5] > 0) { text3 = "| Fishes."; } else { text3 = "| Empty Pocket."; }
    if(PlayerInfo[giveplayerid][pPhoneBook] > 0) { text4 = "| Phone Book."; } else { text4 = "| Empty Pocket."; }
    if(PlayerInfo[giveplayerid][pCDPlayer] > 0) { text5 = "| CD-Player."; } else { text5 = "| Empty Pocket."; }
    format(string, sizeof(string), "|__________ Items with %s __________|", giveplayer);
    SendClientMessage(playerid, COLOR_WHITE, string);
    format(string, sizeof(string), "%s.", text1);
    SendClientMessage(playerid, COLOR_GREY, string);
    format(string, sizeof(string), "%s.", text2);
    SendClientMessage(playerid, COLOR_GREY, string);
    format(string, sizeof(string), "%s.", text3);
    SendClientMessage(playerid, COLOR_GREY, string);
    format(string, sizeof(string), "%s.", text4);
    SendClientMessage(playerid, COLOR_GREY, string);
    format(string, sizeof(string), "%s.", text5);
    SendClientMessage(playerid, COLOR_GREY, string);
    format(string, sizeof(string), "* %s has frisked %s for any illegal items.", sendername ,giveplayer);
    ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
    }
    else
    {
    SendClientMessage(playerid, COLOR_GREY, " That player is not near you !");
    return 1;
    }
    }
    }
    else
    {
    SendClientMessage(playerid, COLOR_GREY, " That player is Offline !");
    return 1;
    }
    }
    return 1;
    }