Beiträge von Mister.Anonym

    Habe Ich grade schon gemacht und getestet geht trz nicht!


    Textdraw7[playerid] = CreatePlayerTextDraw(playerid, 243.162261, 234.500076, "Login/Register");
    PlayerTextDrawLetterSize(playerid, Textdraw7[playerid], 0.449999, 1.600000);
    PlayerTextDrawTextSize(playerid, Textdraw7[playerid], -69.341133, 205.916732);
    PlayerTextDrawAlignment(playerid, Textdraw7[playerid], 1);
    PlayerTextDrawColor(playerid, Textdraw7[playerid], 65535);
    PlayerTextDrawSetShadow(playerid, Textdraw7[playerid], 0);
    PlayerTextDrawSetOutline(playerid, Textdraw7[playerid], 1);
    PlayerTextDrawBackgroundColor(playerid, Textdraw7[playerid], -1061109505);
    PlayerTextDrawFont(playerid, Textdraw7[playerid], 2);
    PlayerTextDrawSetProportional(playerid, Textdraw7[playerid], 1);

    PlayerTextDrawSetSelectable(playerid, Textdraw7[playerid], 1);

    SelectTextDraw(playerid, 0xFFFFFFFF);

    danke bekomme aber diese warnings!


    C:\Users\Justin\Desktop\DayDream-Roleplay\gamemodes\DDRP.pwn(332) : warning 213: tag mismatch
    C:\Users\Justin\Desktop\DayDream-Roleplay\gamemodes\DDRP.pwn(332) : warning 213: tag mismatch
    C:\Users\Justin\Desktop\DayDream-Roleplay\gamemodes\DDRP.pwn(332) : warning 202: number of arguments does not match definition
    Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase



    3 Warnings.

    Meinst du so ?


    Textdraw7[playerid] = CreatePlayerTextDraw(playerid, 243.162261, 234.500076, "Login/Register");
    PlayerTextDrawLetterSize(playerid, Textdraw7[playerid], 0.449999, 1.600000);
    PlayerTextDrawTextSize(playerid, Textdraw7[playerid], -69.341133, 205.916732);
    PlayerTextDrawAlignment(playerid, Textdraw7[playerid], 1);
    PlayerTextDrawColor(playerid, Textdraw7[playerid], 65535);
    PlayerTextDrawSetShadow(playerid, Textdraw7[playerid], 0);
    PlayerTextDrawSetOutline(playerid, Textdraw7[playerid], 1);
    PlayerTextDrawBackgroundColor(playerid, Textdraw7[playerid], -1061109505);
    PlayerTextDrawFont(playerid, Textdraw7[playerid], 2);
    PlayerTextDrawSetProportional(playerid, Textdraw7[playerid], 1);

    TextDrawSetSelectable(Textdraw7[playerid], 1);

    Guten Abend Ich versuche schon seit Stunden meinen Textdraw anclickbar zumachen und halt mit meinen Login/Register System zu verbinden Ich hoffe es kann mir bitte jemand helfen Ich bin am verzweifeln. Ich poste mal alles nötige unten! Ich bin noch anfänger sry :D


    Mein Problem ist halt das Ich den Textdraw nicht anklicken kann und das der auch nicht weg geht wen Ich einfach auch so unten auf diesen Spawn buttons drücke.



    new Text:Textdraw0;
    new Text:Textdraw1;
    new Text:Textdraw2;
    new Text:Textdraw3;
    new Text:Textdraw4;
    new Text:Textdraw5;
    new Text:Textdraw6;
    new PlayerText:Textdraw7[MAX_PLAYERS]; Der soll anklickbar werden!


    public OnGameModeInit()
    {


    Textdraw0 = TextDrawCreate(59.159591, 110.000030, "usebox");
    TextDrawLetterSize(Textdraw0, 0.000000, 36.627773);
    TextDrawTextSize(Textdraw0, 585.993957, 0.000000);
    TextDrawAlignment(Textdraw0, 1);
    TextDrawColor(Textdraw0, 0);
    TextDrawUseBox(Textdraw0, true);
    TextDrawBoxColor(Textdraw0, 102);
    TextDrawSetShadow(Textdraw0, 0);
    TextDrawSetOutline(Textdraw0, 0);
    TextDrawFont(Textdraw0, 0);


    Textdraw1 = TextDrawCreate(440.409973, 186.083297, "LD_SPAC:white");
    TextDrawLetterSize(Textdraw1, 0.001402, -0.017500);
    TextDrawTextSize(Textdraw1, -240.819900, 121.916633);
    TextDrawAlignment(Textdraw1, 1);
    TextDrawColor(Textdraw1, -1061109505);
    TextDrawSetShadow(Textdraw1, 0);
    TextDrawSetOutline(Textdraw1, 0);
    TextDrawBackgroundColor(Textdraw1, -1061109505);
    TextDrawFont(Textdraw1, 4);


    Textdraw2 = TextDrawCreate(66.061508, 131.833389, "Tipp des Tages!");
    TextDrawLetterSize(Textdraw2, 0.449999, 1.600000);
    TextDrawAlignment(Textdraw2, 1);
    TextDrawColor(Textdraw2, -16776961);
    TextDrawSetShadow(Textdraw2, 0);
    TextDrawSetOutline(Textdraw2, 1);
    TextDrawBackgroundColor(Textdraw2, -1061109505);
    TextDrawFont(Textdraw2, 3);
    TextDrawSetProportional(Textdraw2, 1);


    Textdraw3 = TextDrawCreate(454.465637, 132.416656, "Tipp der Woche!");
    TextDrawLetterSize(Textdraw3, 0.449999, 1.600000);
    TextDrawAlignment(Textdraw3, 1);
    TextDrawColor(Textdraw3, 65413);
    TextDrawSetShadow(Textdraw3, 0);
    TextDrawSetOutline(Textdraw3, 1);
    TextDrawBackgroundColor(Textdraw3, -1061109505);
    TextDrawFont(Textdraw3, 3);
    TextDrawSetProportional(Textdraw3, 1);


    Textdraw4 = TextDrawCreate(220.205047, 366.916687, "DayDream-Roleplay");
    TextDrawLetterSize(Textdraw4, 0.449999, 1.600000);
    TextDrawAlignment(Textdraw4, 1);
    TextDrawColor(Textdraw4, 16711935);
    TextDrawSetShadow(Textdraw4, 0);
    TextDrawSetOutline(Textdraw4, 1);
    TextDrawBackgroundColor(Textdraw4, 65535);
    TextDrawFont(Textdraw4, 2);
    TextDrawSetProportional(Textdraw4, 1);


    Textdraw5 = TextDrawCreate(91.361633, 229.833343, "Test");
    TextDrawLetterSize(Textdraw5, 0.449999, 1.600000);
    TextDrawAlignment(Textdraw5, 1);
    TextDrawColor(Textdraw5, -1);
    TextDrawSetShadow(Textdraw5, 0);
    TextDrawSetOutline(Textdraw5, 1);
    TextDrawBackgroundColor(Textdraw5, 51);
    TextDrawFont(Textdraw5, 3);
    TextDrawSetProportional(Textdraw5, 1);


    Textdraw6 = TextDrawCreate(494.758514, 228.083343, "Test");
    TextDrawLetterSize(Textdraw6, 0.449999, 1.600000);
    TextDrawAlignment(Textdraw6, 1);
    TextDrawColor(Textdraw6, -1);
    TextDrawSetShadow(Textdraw6, 0);
    TextDrawSetOutline(Textdraw6, 1);
    TextDrawBackgroundColor(Textdraw6, 51);
    TextDrawFont(Textdraw6, 2);
    TextDrawSetProportional(Textdraw6, 1);
    }


    public OnPlayerConnect(playerid)
    {


    TextDrawSetSelectable(Textdraw7, 1);
    Textdraw7[playerid] = CreatePlayerTextDraw(playerid, 243.162261, 234.500076, "Login/Register");
    PlayerTextDrawLetterSize(playerid, Textdraw7[playerid], 0.449999, 1.600000);
    PlayerTextDrawTextSize(playerid, Textdraw7[playerid], -69.341133, 205.916732);
    PlayerTextDrawAlignment(playerid, Textdraw7[playerid], 1);
    PlayerTextDrawColor(playerid, Textdraw7[playerid], 65535);
    PlayerTextDrawSetShadow(playerid, Textdraw7[playerid], 0);
    PlayerTextDrawSetOutline(playerid, Textdraw7[playerid], 1);
    PlayerTextDrawBackgroundColor(playerid, Textdraw7[playerid], -1061109505);
    PlayerTextDrawFont(playerid, Textdraw7[playerid], 2);
    PlayerTextDrawSetProportional(playerid, Textdraw7[playerid], 1);



    TextDrawShowForPlayer(playerid,Textdraw0);
    TextDrawShowForPlayer(playerid,Textdraw1);
    TextDrawShowForPlayer(playerid,Textdraw2);
    TextDrawShowForPlayer(playerid,Textdraw3);
    TextDrawShowForPlayer(playerid,Textdraw4);
    TextDrawShowForPlayer(playerid,Textdraw5);
    TextDrawShowForPlayer(playerid,Textdraw6);
    PlayerTextDrawShow(playerid,Textdraw7[playerid]);


    }



    public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
    {
    if(dialogid==DIALOG_LOGIN)
    {
    if(response)
    {
    new name[MAX_PLAYER_NAME],query[128],passwort[35];
    GetPlayerName(playerid,name,sizeof(name));
    if(strlen(inputtext)>0)
    {
    mysql_escape_string(inputtext,passwort,dbhandle);
    format(query,sizeof(query),"SELECT * FROM spieler WHERE name='%s' AND password=MD5('%s')",name,passwort);
    mysql_function_query(dbhandle,query,true,"OnPasswordResponse","i",playerid);
    }
    else
    {
    //Keine Eingabe
    SendClientMessage(playerid,Rot,"Gibt bitte dein Passwort ein.");
    ShowPlayerDialog(playerid,DIALOG_LOGIN,DIALOG_STYLE_PASSWORD,"{0091FF}Login","{FFFFFF}Herzlich Willkommen zurück auf dem {00FF28}DayDream-Roleplay {FFFFFF}Server. \nDie {FF0037}Datenbank {FFFFFF}hat einen {FF0037}Account {FFFFFF}unter diesen namen gefunden! \nBitte geben Sie ihr {FF0037}Passwort {FFFFFF}ein.","Login","Abbrechen");
    }
    }
    else
    {
    Kick(playerid);
    }
    return 1;
    }
    if(dialogid==DIALOG_REGISTER)
    {
    if(response)
    {
    new name[MAX_PLAYER_NAME],query[128],passwort[35];
    GetPlayerName(playerid,name,sizeof(name));
    if(strlen(inputtext)>3)
    {
    //Registrierungsfunktion
    mysql_escape_string(inputtext,passwort,dbhandle);
    format(query,sizeof(query),"INSERT INTO spieler (name,password) VALUES ('%s',MD5('%s')) ",name,passwort);
    mysql_function_query(dbhandle,query,true,"OnPlayerRegister","i",playerid);
    SpawnPlayer(playerid);
    SetPlayerSkin(playerid,22);
    }
    else
    {
    //Kleiner als 4 Zeichen
    SendClientMessage(playerid,Rot,"Dein Passwort muss mindestens 4 Zeichen lang sein.");
    ShowPlayerDialog(playerid,DIALOG_REGISTER,DIALOG_STYLE_INPUT,"{0091FF}Registrierung","{FFFFFF}Herzlich Willkommen auf dem {00FF28}DayDream-Roleplay {FFFFFF}Server. \n Die {FF0037}Datenbank {FFFFFF}hat {FF0037}keinen Account {FFFFFF}unter diesen namen gefunden! \nBitte {FF0037}erstellen {FFFFFF}Sie sich einen {FF0037}Account!","Registrieren","Abbrechen");

    }
    }
    else
    {
    Kick(playerid);
    }
    return 1;
    }



    public OnUserCheck(playerid)
    {
    new num_rows,num_fields;
    cache_get_data(num_rows,num_fields,dbhandle);
    if(num_rows==0)
    {
    //Registrierung
    ShowPlayerDialog(playerid,DIALOG_REGISTER,DIALOG_STYLE_INPUT,"{0091FF}Registrierung","{FFFFFF}Herzlich Willkommen auf dem {00FF28}DayDream-Roleplay {FFFFFF}Server. \n Die {FF0037}Datenbank {FFFFFF}hat {FF0037}keinen Account {FFFFFF}unter diesen namen gefunden! \nBitte {FF0037}erstellen {FFFFFF}Sie sich einen {FF0037}Account!","Registrieren","Abbrechen");


    }
    else
    {
    //Login
    ShowPlayerDialog(playerid,DIALOG_LOGIN,DIALOG_STYLE_PASSWORD,"{0091FF}Login","{FFFFFF}Herzlich Willkommen zurück auf dem {00FF28}DayDream-Roleplay {FFFFFF}Server. \nDie {FF0037}Datenbank {FFFFFF}hat einen {FF0037}Account {FFFFFF}unter diesen namen gefunden! \nBitte geben Sie ihr {FF0037}Passwort {FFFFFF}ein.","Login","Abbrechen");
    }


    return 1;
    }


    public OnPasswordResponse(playerid)
    {
    new num_fields,num_rows;
    cache_get_data(num_rows,num_fields,dbhandle);
    if(num_rows==1)
    {
    //Passwort richtig
    sStats[playerid][sEingeloggt] = 1;
    sStats[playerid][sLevel] = cache_get_field_content_int(0,"Level",dbhandle);
    SetPlayerScore(playerid,sStats[playerid][sLevel]);
    sStats[playerid][sid] = cache_get_field_content_int(0,"id",dbhandle);
    SetPlayerMoney(playerid,cache_get_field_content_int(0,"Money",dbhandle));
    sStats[playerid][sAdmin] = cache_get_field_content_int(0,"Admin",dbhandle);
    sStats[playerid][sWanteds] = cache_get_field_content_int(0,"Wanteds",dbhandle);
    SetPlayerWantedLevel(playerid,sStats[playerid][sWanteds]);
    sStats[playerid][sTimeBan] = cache_get_field_content_int(0,"TimeBan",dbhandle);
    sStats[playerid][sWarning1] = cache_get_field_content_int(0,"Warning1",dbhandle);
    sStats[playerid][sWarning2] = cache_get_field_content_int(0,"Warning2",dbhandle);
    sStats[playerid][sWarning3] = cache_get_field_content_int(0,"Warning3",dbhandle);
    sStats[playerid][sMute] = cache_get_field_content_int(0,"Mute",dbhandle);
    sStats[playerid][sSkin] = cache_get_field_content_int(0,"Skin",dbhandle);
    sStats[playerid][sSupportsperre] = cache_get_field_content_int(0,"Supportsperre",dbhandle);
    SpawnPlayer(playerid);
    SetPlayerSkin(playerid,22);

    //Timeban
    if(gettime()<sStats[playerid][sTimeBan] && sStats[playerid][sTimeBan] > 0)
    {
    new string[128];
    new days,hours,mins;
    new wartezeit = sStats[playerid][sTimeBan];
    new restzeit= wartezeit -gettime();
    days = floatround(restzeit / 86400,floatround_floor);
    hours = restzeit - (days * 86400);
    hours = floatround(hours / 3600,floatround_floor);
    mins = restzeit - ( (days * 86400) + (hours * 3600) );
    mins = floatround(mins / 60,floatround_floor);
    format(string, sizeof(string), "Du bist noch für %d Minuten gebannt.(%d Stunden).",mins,hours);
    SendClientMessage(playerid, Rot,string);
    TogglePlayerControllable(playerid, false);
    savePlayer(playerid);
    Kick(playerid);
    return 1;
    }
    else
    {
    sStats[playerid][sTimeBan] = 0;
    }
    if(sStats[playerid][sLevel] == 999)
    {
    sStats[playerid][sLevel] = 2;
    return 1;
    }
    //Endmute
    if(sStats[playerid][sMute] == 1)
    {
    SetTimerEx("EndMute", 300956, false, "d", playerid);
    }
    else
    {
    sStats[playerid][sMute] = 0;
    }
    }
    else
    {
    //Passwort falsch
    SendClientMessage(playerid,Rot,"Das eingegebene Passwort ist falsch.");
    ShowPlayerDialog(playerid,DIALOG_LOGIN,DIALOG_STYLE_PASSWORD,"{0091FF}Login","{FFFFFF}Herzlich Willkommen zurück auf dem {00FF28}DayDream-Roleplay {FFFFFF}Server. \nDie {FF0037}Datenbank {FFFFFF}hat einen {FF0037}Account {FFFFFF}unter diesen namen gefunden! \nBitte geben Sie ihr {FF0037}Passwort {FFFFFF}ein.","Login","Abbrechen");
    }
    return 1;
    }



    public OnPlayerRegister(playerid)
    {
    sStats[playerid][sdb_id] = cache_insert_id(dbhandle);
    return 1;
    }


    public OnPlayerClickPlayerTextDraw(playerid, PlayerText:playertextid)
    {
    if(playertextid == Textdraw7[playerid])
    {
    SendClientMessage(playerid, 0xFFFFFFAA, "You clicked on a textdraw.");
    CancelSelectTextDraw(playerid);
    //Login/Register
    new name[MAX_PLAYER_NAME],query[128];
    GetPlayerName(playerid,name,sizeof(name));
    format(query,sizeof(query),"SELECT id FROM spieler WHERE name='%s'",name);
    mysql_function_query(dbhandle,query,true,"OnUserCheck","i",playerid);
    }
    return 1;
    }

    ok Danke :D so Ich habe das Jetzt so gemacht aber bekomme halt einen Error aber versteht nicht warum das so ist Ich bitte nochmal um hilfe!


    Der Error:


    undefined symbol "mysql_query"



    public OnPlayerClickPlayerTextDraw(playerid, PlayerText:playertextid)
    {
    if(playertextid==Textdraw7[playerid])
    {

    //Login/Register
    new name[MAX_PLAYER_NAME],query[128];
    GetPlayerName(playerid,name,sizeof(name));
    format(query,sizeof(query),"SELECT id FROM spieler WHERE name='%s'",name);
    mysql_query(dbhandle,query);


    }
    return 1;
    }

    Guten Tag, Ich habe mir grade ein Tutorial durchgelesen, Über Textdraws mit einen Programm erstellen und dann Als OnPlayerClick machen. Aber Der Hat nicht Alles gezeigt und Weil mein Login/Register System schon ein bischen weiter ausarbeitet ist, Weiß Ich nicht wie Das gehen Soll Ich poste mal unten Alles.


    //Textdraw
    new Text:Textdraw0;
    new Text:Textdraw1;
    new Text:Textdraw2;
    new Text:Textdraw3;
    new Text:Textdraw4;
    new Text:Textdraw5;
    new Text:Textdraw6;
    new PlayerText:Textdraw7[MAX_PLAYERS];



    public OnGameModeInit()
    {


    Textdraw0 = TextDrawCreate(59.159591, 110.000030, "usebox");
    TextDrawLetterSize(Textdraw0, 0.000000, 36.627773);
    TextDrawTextSize(Textdraw0, 585.993957, 0.000000);
    TextDrawAlignment(Textdraw0, 1);
    TextDrawColor(Textdraw0, 0);
    TextDrawUseBox(Textdraw0, true);
    TextDrawBoxColor(Textdraw0, 102);
    TextDrawSetShadow(Textdraw0, 0);
    TextDrawSetOutline(Textdraw0, 0);
    TextDrawFont(Textdraw0, 0);


    Textdraw1 = TextDrawCreate(440.409973, 186.083297, "LD_SPAC:white");
    TextDrawLetterSize(Textdraw1, 0.001402, -0.017500);
    TextDrawTextSize(Textdraw1, -240.819900, 121.916633);
    TextDrawAlignment(Textdraw1, 1);
    TextDrawColor(Textdraw1, -1061109505);
    TextDrawSetShadow(Textdraw1, 0);
    TextDrawSetOutline(Textdraw1, 0);
    TextDrawBackgroundColor(Textdraw1, -1061109505);
    TextDrawFont(Textdraw1, 4);


    Textdraw2 = TextDrawCreate(66.061508, 131.833389, "Tipp des Tages!");
    TextDrawLetterSize(Textdraw2, 0.449999, 1.600000);
    TextDrawAlignment(Textdraw2, 1);
    TextDrawColor(Textdraw2, -16776961);
    TextDrawSetShadow(Textdraw2, 0);
    TextDrawSetOutline(Textdraw2, 1);
    TextDrawBackgroundColor(Textdraw2, -1061109505);
    TextDrawFont(Textdraw2, 3);
    TextDrawSetProportional(Textdraw2, 1);


    Textdraw3 = TextDrawCreate(454.465637, 132.416656, "Tipp der Woche!");
    TextDrawLetterSize(Textdraw3, 0.449999, 1.600000);
    TextDrawAlignment(Textdraw3, 1);
    TextDrawColor(Textdraw3, 65413);
    TextDrawSetShadow(Textdraw3, 0);
    TextDrawSetOutline(Textdraw3, 1);
    TextDrawBackgroundColor(Textdraw3, -1061109505);
    TextDrawFont(Textdraw3, 3);
    TextDrawSetProportional(Textdraw3, 1);


    Textdraw4 = TextDrawCreate(220.205047, 366.916687, "DayDream-Roleplay");
    TextDrawLetterSize(Textdraw4, 0.449999, 1.600000);
    TextDrawAlignment(Textdraw4, 1);
    TextDrawColor(Textdraw4, 16711935);
    TextDrawSetShadow(Textdraw4, 0);
    TextDrawSetOutline(Textdraw4, 1);
    TextDrawBackgroundColor(Textdraw4, 65535);
    TextDrawFont(Textdraw4, 2);
    TextDrawSetProportional(Textdraw4, 1);


    Textdraw5 = TextDrawCreate(91.361633, 229.833343, "Test");
    TextDrawLetterSize(Textdraw5, 0.449999, 1.600000);
    TextDrawAlignment(Textdraw5, 1);
    TextDrawColor(Textdraw5, -1);
    TextDrawSetShadow(Textdraw5, 0);
    TextDrawSetOutline(Textdraw5, 1);
    TextDrawBackgroundColor(Textdraw5, 51);
    TextDrawFont(Textdraw5, 3);
    TextDrawSetProportional(Textdraw5, 1);


    Textdraw6 = TextDrawCreate(494.758514, 228.083343, "Test");
    TextDrawLetterSize(Textdraw6, 0.449999, 1.600000);
    TextDrawAlignment(Textdraw6, 1);
    TextDrawColor(Textdraw6, -1);
    TextDrawSetShadow(Textdraw6, 0);
    TextDrawSetOutline(Textdraw6, 1);
    TextDrawBackgroundColor(Textdraw6, 51);
    TextDrawFont(Textdraw6, 2);
    TextDrawSetProportional(Textdraw6, 1);


    EnableStuntBonusForAll(0);
    DisableInteriorEnterExits();


    AntiDeAMX();


    //Mysql
    dbhandle = mysql_connect(MYSQL_HOST,MYSQL_USER,MYSQL_DATA,MYSQL_PASS);
    if(mysql_errno() < 1)print("MySQL: Die Verbindung wurde erfolgreich hergestellt."),mysql_log(LOG_DEBUG); else print("MySQL: Die Verbindung zur MySQL Datenbank konnte nicht hergestellt werden | Der Server wird nun heruntergefahren."), SendRconCommand("exit");

    //Timer
    SetTimer("ChangeServerName", 1000, 1);
    SetTimer("mapname",3000,1);
    SetTimer("gamemode",3000,1);

    AddPlayerClass(0, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);
    return 1;
    }


    public OnPlayerConnect(playerid)
    {


    Textdraw7[playerid] = CreatePlayerTextDraw(playerid, 243.162261, 234.500076, "Login/Register");
    PlayerTextDrawLetterSize(playerid, Textdraw7[playerid], 0.449999, 1.600000);
    PlayerTextDrawTextSize(playerid, Textdraw7[playerid], -69.341133, 205.916732);
    PlayerTextDrawAlignment(playerid, Textdraw7[playerid], 1);
    PlayerTextDrawColor(playerid, Textdraw7[playerid], 65535);
    PlayerTextDrawSetShadow(playerid, Textdraw7[playerid], 0);
    PlayerTextDrawSetOutline(playerid, Textdraw7[playerid], 1);
    PlayerTextDrawBackgroundColor(playerid, Textdraw7[playerid], -1061109505);
    PlayerTextDrawFont(playerid, Textdraw7[playerid], 2);
    PlayerTextDrawSetProportional(playerid, Textdraw7[playerid], 1);

    TextDrawShowForPlayer(playerid,Textdraw0);
    TextDrawShowForPlayer(playerid,Textdraw1);
    TextDrawShowForPlayer(playerid,Textdraw2);
    TextDrawShowForPlayer(playerid,Textdraw3);
    TextDrawShowForPlayer(playerid,Textdraw4);
    TextDrawShowForPlayer(playerid,Textdraw5);
    TextDrawShowForPlayer(playerid,Textdraw6);
    PlayerTextDrawShow(playerid,Textdraw7[playerid]);


    SelectTextDraw(playerid, 0x00FF00FF);


    new nachricht[128];
    format(nachricht,sizeof(nachricht),"Du bist mit der ID %i verbunden.",playerid);
    SendClientMessage(playerid,Rot,nachricht);

    //Login/Register
    new name[MAX_PLAYER_NAME],query[128];
    GetPlayerName(playerid,name,sizeof(name));
    format(query,sizeof(query),"SELECT id FROM spieler WHERE name='%s'",name);
    mysql_function_query(dbhandle,query,true,"OnPlayerClickPlayerTextDraw","i",playerid);
    return 1;
    }



    public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
    {
    if(dialogid==DIALOG_LOGIN)
    {
    if(response)
    {
    new name[MAX_PLAYER_NAME],query[128],passwort[35];
    GetPlayerName(playerid,name,sizeof(name));
    if(strlen(inputtext)>0)
    {
    mysql_escape_string(inputtext,passwort,dbhandle);
    format(query,sizeof(query),"SELECT * FROM spieler WHERE name='%s' AND password=MD5('%s')",name,passwort);
    mysql_function_query(dbhandle,query,true,"OnPasswordResponse","i",playerid);
    }
    else
    {
    //Keine Eingabe
    SendClientMessage(playerid,Rot,"Gibt bitte dein Passwort ein.");
    ShowPlayerDialog(playerid,DIALOG_LOGIN,DIALOG_STYLE_PASSWORD,"Login","Herzlich Willkommen zurück auf dem Island-Roleplay Server. \nDie Datenbank hat einen Account unter diesen namen gefunden! \nBitte geben Sie ihr Passwort ein.","Login","Abbrechen");
    }
    }
    else
    {
    Kick(playerid);
    }
    return 1;
    }
    if(dialogid==DIALOG_REGISTER)
    {
    if(response)
    {
    new name[MAX_PLAYER_NAME],query[128],passwort[35];
    GetPlayerName(playerid,name,sizeof(name));
    if(strlen(inputtext)>3)
    {
    //Registrierungsfunktion
    mysql_escape_string(inputtext,passwort,dbhandle);
    format(query,sizeof(query),"INSERT INTO spieler (name,password) VALUES ('%s',MD5('%s')) ",name,passwort);
    mysql_function_query(dbhandle,query,true,"OnPlayerRegister","i",playerid);
    SpawnPlayer(playerid);
    SetPlayerSkin(playerid,22);
    }
    else
    {
    //Kleiner als 4 Zeichen
    SendClientMessage(playerid,Rot,"Dein Passwort muss mindestens 4 Zeichen lang sein.");
    ShowPlayerDialog(playerid,DIALOG_REGISTER,DIALOG_STYLE_INPUT,"Registrierung","Herzlich Willkommen auf dem Island-Roleplay Server. \n Die Datenbank hat keinen Account unter diesen namen gefunden! \nBitte erstellen Sie sich einen Account!","Registrieren","Abbrechen");
    }
    }
    else
    {
    Kick(playerid);
    }
    return 1;
    }



    public OnPasswordResponse(playerid)
    {
    new num_fields,num_rows;
    cache_get_data(num_rows,num_fields,dbhandle);
    if(num_rows==1)
    {
    //Passwort richtig
    sStats[playerid][sEingeloggt] = 1;
    sStats[playerid][sLevel] = cache_get_field_content_int(0,"Level",dbhandle);
    SetPlayerScore(playerid,sStats[playerid][sLevel]);
    sStats[playerid][sid] = cache_get_field_content_int(0,"id",dbhandle);
    SetPlayerMoney(playerid,cache_get_field_content_int(0,"Money",dbhandle));
    sStats[playerid][sAdmin] = cache_get_field_content_int(0,"Admin",dbhandle);
    sStats[playerid][sWanteds] = cache_get_field_content_int(0,"Wanteds",dbhandle);
    SetPlayerWantedLevel(playerid,sStats[playerid][sWanteds]);
    sStats[playerid][sTimeBan] = cache_get_field_content_int(0,"TimeBan",dbhandle);
    sStats[playerid][sWarning1] = cache_get_field_content_int(0,"Warning1",dbhandle);
    sStats[playerid][sWarning2] = cache_get_field_content_int(0,"Warning2",dbhandle);
    sStats[playerid][sWarning3] = cache_get_field_content_int(0,"Warning3",dbhandle);
    SpawnPlayer(playerid);
    SetPlayerSkin(playerid,22);

    //Timeban
    if(gettime()<sStats[playerid][sTimeBan] && sStats[playerid][sTimeBan] > 0)
    {
    new string[128];
    new days,hours,mins;
    new wartezeit = sStats[playerid][sTimeBan];
    new restzeit= wartezeit -gettime();
    days = floatround(restzeit / 86400,floatround_floor);
    hours = restzeit - (days * 86400);
    hours = floatround(hours / 3600,floatround_floor);
    mins = restzeit - ( (days * 86400) + (hours * 3600) );
    mins = floatround(mins / 60,floatround_floor);
    format(string, sizeof(string), "Du bist noch für %d Minuten gebannt.(%d Stunden).",mins,hours);
    SendClientMessage(playerid, Rot,string);
    TogglePlayerControllable(playerid, false);
    savePlayer(playerid);
    Kick(playerid);
    return 1;
    }
    else
    {
    sStats[playerid][sTimeBan] = 0;
    }
    if(sStats[playerid][sLevel] == 999)
    {
    sStats[playerid][sLevel] = 2;
    return 1;
    }
    }
    else
    {
    //Passwort falsch
    SendClientMessage(playerid,Rot,"Das eingegebene Passwort ist falsch.");
    ShowPlayerDialog(playerid,DIALOG_LOGIN,DIALOG_STYLE_PASSWORD,"Login","Herzlich Willkommen zurück auf dem Island-Roleplay Server. \nDie Datenbank hat einen Account unter diesen namen gefunden! \nBitte geben Sie ihr Passwort ein.","Login","Abbrechen");
    }
    return 1;
    }

    public OnPlayerClickPlayerTextDraw(playerid, PlayerText:playertextid)
    {
    if(playertextid==Textdraw7[playerid])
    {
    new num_rows,num_fields;
    cache_get_data(num_rows,num_fields,dbhandle);
    if(num_rows==0)
    {
    //Registrierung
    ShowPlayerDialog(playerid,DIALOG_REGISTER,DIALOG_STYLE_INPUT,"Registrierung","Herzlich Willkommen auf dem Island-Roleplay Server. \n Die Datenbank hat keinen Account unter diesen namen gefunden! \nBitte erstellen Sie sich einen Account!","Registrieren","Abbrechen");
    }
    else
    {
    //Login
    ShowPlayerDialog(playerid,DIALOG_LOGIN,DIALOG_STYLE_PASSWORD,"Login","Herzlich Willkommen zurück auf dem Island-Roleplay Server. \nDie Datenbank hat einen Account unter diesen namen gefunden! \nBitte geben Sie ihr Passwort ein.","Login","Abbrechen");
    }

    }


    return 1;
    }

    Hallo Ich möchte mit einen Selfmade script anfangen, Und Ich möchte fragen welche reihenfolge Die beste wäre? Also z.B. erst Mysql sachen oder so. Und weil ich noch Anfänger bin und mit den Selfmade dann das
    Scripten lernen will wollte Ich noch fragen Wie Ich das am besten lernen kann. Die grundkentnisse kenne Ich schon.

    Guten Abend Ich bitte um hilfe weil es werden bei mir sachen nicht gespeichert z.B. die Payday zeit und der Bank Pin und sowas könnt ihr mir bitte helfen??


    new string[1024];
    format(string, sizeof(string), "UPDATE accounts SET adminlevel='%d',geld='%d',level='%d',alt='%d',job='%d',tutorial='%d',skin='%d',geschlecht='%d',mitglied='%d',leiter='%d',mute='%d',haus='%d',hause='%d',perso='%d',spawn='%d',premium='%d',link='%d',eingeloggt='%d',premiumtage='%d',coins='%d' WHERE Name='%s'",
    sStats[playerid][sAdminlevel],sStats[playerid][sGeld], sStats[playerid][sLevel],sStats[playerid][sAlter],sStats[playerid][sJob],sStats[playerid][sTutorial],sStats[playerid][sSkin],sStats[playerid][sGeschlecht],sStats[playerid][sMitglied],sStats[playerid][sLeiter],sStats[playerid][sMute],sStats[playerid][sHaus],sStats[playerid][sHausE],
    sStats[playerid][sPersonalausweis],sStats[playerid][sSpawnChange],sStats[playerid][sPremium],sStats[playerid][sLink],sStats[playerid][sEingeloggt],sStats[playerid][sPremiumZeit],sStats[playerid][sKaufpunkte], GetName(playerid));
    mysql_query(string);


    format(string, sizeof(string), "UPDATE accounts SET guthaben='%d',vertrag='%d',akku='%d',gps='%d',nummer='%d',wanteds='%d',waffenschein='%d',telefonbuch='%d',jailed='%d',klingelton='%d',autoschein='%d',motorradschein='%d',anglerschein='%d',bootschein='%d',flugschein='%d',angel='%d',koeder='%d',kondom='%d',mp3player='%d' WHERE Name='%s'",
    sStats[playerid][sGuthaben], sStats[playerid][sVertrag],sStats[playerid][sAkku],sStats[playerid][sGPS],sStats[playerid][sNummer],sStats[playerid][sWanteds],sStats[playerid][sWaffenschein],sStats[playerid][sTelefonBuch],sStats[playerid][sJailed],sStats[playerid][sKlingelton],sStats[playerid][sAutoschein],
    sStats[playerid][sMotorradschein],sStats[playerid][sAnglerschein],sStats[playerid][sBootschein],sStats[playerid][sFlugschein],sStats[playerid][sAngel],sStats[playerid][sKoeder],sStats[playerid][sKondom],sStats[playerid][sMP3Player], GetName(playerid));
    mysql_query(string);


    format(string, sizeof(string), "UPDATE accounts SET 247rob='%d',preamie='%d',JailTime='%d',hotel='%d',arbeitslosengeld='%d',krankenver='%d',autover='%d',autos='%d',jobtime='%d',arztkosten='%d',mats='%d',spielstunden='%d',drogen='%d',betrunken='%d',geworbenvon='%s',quest='%d',geworbennach='%d',helm='%d' WHERE Name='%s'",
    sStats[playerid][s247Rob], sStats[playerid][sPreamie],sStats[playerid][sJailTime],sStats[playerid][sHotel],sStats[playerid][sArbeitslosengeld],sStats[playerid][sKrankenver],sStats[playerid][sAutover],sStats[playerid][sAutos],sStats[playerid][sJobTime],sStats[playerid][sArztkosten],sStats[playerid][sMats],
    sStats[playerid][sSpielstunden],sStats[playerid][sDrogen],sStats[playerid][sBetrunken],sStats[playerid][sGeworbenVon],sStats[playerid][sQuest],sStats[playerid][sGeworbenNach],sStats[playerid][sHelm], GetName(playerid));
    mysql_query(string);


    format(string, sizeof(string), "UPDATE accounts SET driftzeit='%d',pklingelton='%d',pklingeltonhat='%d',fraktion='%d',sonnenbrille='%d',bap='%d',mission='%d',missionzeit='%d',benzinkanister='%d',timeban='%d',konto='%d',truckschein='%d',warnungen='%d' WHERE Name='%s'",
    sStats[playerid][sDriftZeit],sStats[playerid][sPKlingelton],sStats[playerid][sPKlingeltonHat],sStats[playerid][sFraktion],sStats[playerid][sSonnenbrille],sStats[playerid][sbap],sStats[playerid][sMission],sStats[playerid][sMissionZeit],
    sStats[playerid][sBenzinkanister],sStats[playerid][sTimeBan],sStats[playerid][sKonto],sStats[playerid][sTruckschein],sStats[playerid][sWarns], GetName(playerid));
    mysql_query(string);


    format(string, sizeof(string), "UPDATE accounts SET pin='%d',karte='%d',mob='%d',supportsperre='%d',bankraub='%d',atmrob='%d',reisepass='%d',mieter='%d',paypoints='%d',krankheit='%d',drogensamen='%d',drogenduenger='%d',waffenscheinzeit='%d',pkills='%d',pdeaths='%d',pbpunkte='%d',pwaffe='%d' WHERE Name='%s'",
    sStats[playerid][sPin],sStats[playerid][sKarte],sStats[playerid][sMob],sStats[playerid][sSupportsperre],sStats[playerid][sBankRaub],sStats[playerid][sATMRob],sStats[playerid][sReisePass],sStats[playerid][sMieter],sStats[playerid][sPayPoints],sStats[playerid][sKrankheit],
    sStats[playerid][sDrogenSamen],sStats[playerid][sDrogenDuenger],sStats[playerid][sWaffenscheinZeit],sStats[playerid][sPkills],sStats[playerid][sPdeaths],sStats[playerid][sPpunkte],sStats[playerid][sPwaffe], GetName(playerid));
    mysql_query(string);


    format(string, sizeof(string), "UPDATE accounts SET drogenwartezeit='%d',drogenangebaut='%d',drogenzeit='%d',rank='%d',wohnwagen='%d',maske='%d',pfand='%d',tod='%d',bombe='%d',fisch='%d',detskill='%d',wa='%d',bizz='%d',ppayday='%d',dietrich='%d',gb='%d',krankheit='%d',exp='%d',fspawn='%d',lastonline='%d',handy='%d' WHERE Name='%s'",
    sStats[playerid][sDrogenWarteZeit],sStats[playerid][sDrogenZeit],sStats[playerid][sDrogenAngebaut],sStats[playerid][sRank],sStats[playerid][sWohnwagen],sStats[playerid][sMaske],sStats[playerid][sPfand],sStats[playerid][sTod],sStats[playerid][sBombe],sStats[playerid][sFisch],
    sStats[playerid][sDetSkill],sStats[playerid][sWA],sStats[playerid][sBizz],sStats[playerid][spPayday],sStats[playerid][sDietrich],sStats[playerid][sGB],sStats[playerid][sKrankheit],sStats[playerid][sErf],GetPVarInt(playerid, "FeuerSpawn"),sStats[playerid][sLastOnline],sStats[playerid][sHandy]/*,sStats[playerid][sDrogenDuenger]*/, GetName(playerid));
    mysql_query(string);
    return 1;