2Warnungs wieso??

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
  • public OnPlayerCommandText(playerid, cmdtext[])
    {
    if (strcmp("/help", cmdtext, true, 10) == 0)
    {
    SendClientMessage(playerid,0xFFFFFFAA,"|_Server Hilfe_|");
    SendClientMessage(playerid,0x33AA33AA,"");
    SendClientMessage(playerid,0x33AA33AA,"");
    SendClientMessage(playerid,0x33AA33AA,"");
    SendClientMessage(playerid,0x33AA33AA,"");
    return 1;
    }
    if (strcmp("/game", cmdtext, true, 10) == 0)
    {
    SendClientMessage(playerid,0xFFFFFFAA,"|_Server Infomation_|");
    SendClientMessage(playerid,0x33AA33AA,"");
    SendClientMessage(playerid,0x33AA33AA,"");
    SendClientMessage(playerid,0x33AA33AA,"");
    SendClientMessage(playerid,0x33AA33AA,"");
    return 1;
    }
    return 0;
    }

  • 1. Wieso bei Server-Hilfe das hat eindeutig was mit dem Script zu tun ^^
    und versuchs mal so
    public OnPlayerCommandText(playerid, cmdtext[])
    {
    if (strcmp("/help", cmdtext, true, 10) == 0)
    {
    SendClientMessage(playerid,0xFFFFFFAA,"|_Server Hilfe_|");
    SendClientMessage(playerid,0x33AA33AA," ");
    SendClientMessage(playerid,0x33AA33AA," ");
    SendClientMessage(playerid,0x33AA33AA," ");
    SendClientMessage(playerid,0x33AA33AA," ");
    return 1;
    }
    if (strcmp("/game", cmdtext, true, 10) == 0)
    {
    SendClientMessage(playerid,0xFFFFFFAA,"|_Server Infomation_|");
    SendClientMessage(playerid,0x33AA33AA," ");
    SendClientMessage(playerid,0x33AA33AA," ");
    SendClientMessage(playerid,0x33AA33AA," ");
    SendClientMessage(playerid,0x33AA33AA," ");
    return 1;
    }
    return 0;
    }


    /edit mist Monte war schneller :P

  • http://sa-mp.de/index.php?go=tools&sub=errxplain


    Das hilft solche Themen zu vermeiden ;)


    Du hast nur an 2 Orten das ; vergessen


    public OnPlayerCommandText(playerid, cmdtext[])
    {
    if (strcmp("/help", cmdtext, true, 10) == 0)
    {
    SendClientMessage(playerid,0xFFFFFFAA,"|_Server Hilfe_|"); //Hier vergessen
    SendClientMessage(playerid,0x33AA33AA," ");
    SendClientMessage(playerid,0x33AA33AA," ");
    SendClientMessage(playerid,0x33AA33AA," ");
    SendClientMessage(playerid,0x33AA33AA," ");
    return 1;
    }
    if (strcmp("/game", cmdtext, true, 10) == 0)
    {
    SendClientMessage(playerid,0xFFFFFFAA,"|_Server Infomation_|"); //Hier vergessen
    SendClientMessage(playerid,0x33AA33AA," ");
    SendClientMessage(playerid,0x33AA33AA," ");
    SendClientMessage(playerid,0x33AA33AA," ");
    SendClientMessage(playerid,0x33AA33AA," ");
    return 1;
    }
    return 0;
    }

    Meine Werke


    Minecraft Signatur Buggt



    Sowas wie 10/10 gibt es nicht. Ausser bei Satan

  • der hat keine " ; " vergessen sonst wären es Errors schau mal genau hin


    Vorher:
    public OnPlayerCommandText(playerid, cmdtext[])
    {
    if (strcmp("/help", cmdtext, true, 10) == 0)
    {
    SendClientMessage(playerid,0xFFFFFFAA,"|_Server Hilfe_|");
    SendClientMessage(playerid,0x33AA33AA,"");
    SendClientMessage(playerid,0x33AA33AA,"");
    SendClientMessage(playerid,0x33AA33AA,"");
    SendClientMessage(playerid,0x33AA33AA,"");
    return 1;


    if (strcmp("/game", cmdtext, true, 10) == 0)
    {
    SendClientMessage(playerid,0xFFFFFFAA,"|_Server Infomation_|");
    SendClientMessage(playerid,0x33AA33AA,"");
    SendClientMessage(playerid,0x33AA33AA,"");
    SendClientMessage(playerid,0x33AA33AA,"");
    SendClientMessage(playerid,0x33AA33AA,"");
    return 1;
    }
    }
    return 0;
    }
    }


    Nachher:
    public OnPlayerCommandText(playerid, cmdtext[])
    {
    if (strcmp("/help", cmdtext, true, 10) == 0)
    {
    SendClientMessage(playerid,0xFFFFFFAA,"|_Server Hilfe_|");
    SendClientMessage(playerid,0x33AA33AA," ");
    SendClientMessage(playerid,0x33AA33AA," ");
    SendClientMessage(playerid,0x33AA33AA," ");
    SendClientMessage(playerid,0x33AA33AA," ");
    return 1;
    }
    if (strcmp("/game", cmdtext, true, 10) == 0)
    {
    SendClientMessage(playerid,0xFFFFFFAA,"|_Server Infomation_|");
    SendClientMessage(playerid,0x33AA33AA," ");
    SendClientMessage(playerid,0x33AA33AA," ");
    SendClientMessage(playerid,0x33AA33AA," ");
    SendClientMessage(playerid,0x33AA33AA," ");
    return 1;
    }
    return 0;
    }


    er hatte 1x die einrückung Falsch
    und 1x die Klammersetzung