Hilfe bei /givesfPass

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
  • Hier der Code


    if(strcmp(cmd, "/givesfpass", true) == 0)
    {
    if(PlayerInfo[playerid][pAdmin] < 4) return SendClientMessage(playerid, 0xFFFFFFFF, "Du hast nicht die Rechte!");
    new pID,sendername[MAX_PLAYER_NAME],giveplayer[MAX_PLAYER_NAME];
    if(sscanf(params,"u",pID))return SendClientMessage(playerid,-1," /givesfpass [playerid / Name]");
    if(IsPlayerConnected(pID))
    {
    GetPlayerName(playerid, sendername, sizeof(sendername));
    GetPlayerName(pID, giveplayer, sizeof(giveplayer));
    format(string, sizeof(string), "Sie haben %s den Führerschein gegeben.",pID);
    SendClientMessage(playerid, -1, string);
    format(string, sizeof(string), "Admin %s hat ihnen den Führerschein gegeben.",sendername);
    SendClientMessage(giveplayerid, -1, string);
    PlayerInfo[pID][pSFPass] = 1;
    return 1;
    }
    return 1;
    }



    Der Fehler:

  • if(strcmp(cmd, "/givesfpass", true) == 0)
    {
    if(PlayerInfo[playerid][pAdmin] < 4) return SendClientMessage(playerid, 0xFFFFFFFF, "Du hast nicht die Rechte!");
    new pID,sendernamed[MAX_PLAYER_NAME],giveplayerd[MAX_PLAYER_NAME];
    if(sscanf(params,"u",pID))return SendClientMessage(playerid,-1," /givesfpass [playerid / Name]");
    if(IsPlayerConnected(pID))
    {
    GetPlayerName(playerid, sendernamed, sizeof(sendernamed));
    GetPlayerName(pID, giveplayerd, sizeof(giveplayerd));
    format(string, sizeof(string), "Sie haben %s den Führerschein gegeben.",giveplayerid);
    SendClientMessage(playerid, -1, string);
    format(string, sizeof(string), "Admin %s hat ihnen den Führerschein gegeben.",sendernamed);
    SendClientMessage(giveplayerid, -1, string);
    PlayerInfo[pID][pSFPass] = 1;
    return 1;
    }
    return 1;
    }
    Versuch das mal, habe einfach "sendername" und "giveplayer" umbenannt in "sendernamed" und "giveplayerid".


    /e
    Zeig die anderen Zeilen mal.

  • Also jetzt durch das einfügen des stocks ist es verkackt:


    Code
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(2931) : error 021: symbol already defined: "sscanf"C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8786) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8796) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8797) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8800) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8801) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8812) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8827) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8831) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8833) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8845) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8848) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8851) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(13773) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(13894) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(14776) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(14781) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19056) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19078) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19132) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19150) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19158) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19192) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19196) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19199) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19229) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19235) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19245) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19248) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19286) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19299) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(22309) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(22386) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(22388) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(29558) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(30099) : warning 204: symbol is assigned a value that is never used: "para1"C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(30369) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(31187) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(35390) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(35393) : warning 219: local variable "sendername" shadows a variable at a preceding levelC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(35393) : warning 219: local variable "giveplayer" shadows a variable at a preceding levelC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(35394) : error 017: undefined symbol "params"C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(35406) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(35408) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(41832) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(42230) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(43237) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(46699) : warning 217: loose indentationC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(47817) : error 021: symbol already defined: "sscanf"C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(50365) : warning 219: local variable "GetName" shadows a variable at a preceding levelC:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(52152) : warning 203: symbol is never used: "LightsStatus"C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(52152) : warning 203: symbol is never used: "M_OnPlayerUpdate"Pawn compiler 3.2.3664	 	 	Copyright (c) 1997-2006, ITB CompuPhase
    
    
    3 Errors.
  • do.de - Domain-Offensive - Domains für alle und zu super Preisen
  • Hier, ein wenig zu viel



    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8785) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8795) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8796) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8799) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8800) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8811) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8826) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8830) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8832) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8844) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8847) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(8850) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(13772) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(13893) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(14775) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(14780) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19055) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19077) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19131) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19149) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19157) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19191) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19195) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19198) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19228) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19234) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19244) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19247) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19285) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(19298) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(22308) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(22385) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(22387) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(29557) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(30098) : warning 204: symbol is assigned a value that is never used: "para1"
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(30368) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(31186) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(35389) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(35393) : error 017: undefined symbol "params"
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(35405) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(35407) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(41831) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(42229) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(43236) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(46698) : warning 217: loose indentation
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(47816) : error 021: symbol already defined: "sscanf"
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(50364) : warning 219: local variable "GetName" shadows a variable at a preceding level
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(52151) : warning 203: symbol is never used: "LightsStatus"
    C:\Users\smail\Desktop\LG\German-Elite-Reallife\gamemodes\hd.pwn(52151) : warning 203: symbol is never used: "M_OnPlayerUpdate"
    Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase



    2 Errors.

  • Lade mal das Script in Pastebin.com hoch.
    Ich werde es dir dann schnell einrichten und Kommentare dazu schreiben, was ich gemacht habe, damit du es verstehst.