Falsches anwählen auf Spielerdatei.

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
  • Hallo,


    mit meinem /accban Befehl wird die Spielerdatei nicht beschrieben, aber eigentlich müsste sie es,
    was kann tun?

    format(banFormat,sizeof(banFormat),"Accounts/%s.ini",name,Grund);
    if(fexist(banFormat))
    {

    new File:banaccount = fopen(banFormat,io_write);
    fwrite(banaccount,"Banned=1\n");
    fclose(banaccount);


    }



    Danke im Voraus :)

  • Übersicht:

    PHP
    io_read      Reads from the file.
    io_write     Write in the file, or create the file. Erases all contents.
    io_readwrite Reads the file or creates it
    io_append    Appends (adds) to file, write-only. If the file does not exist, it is created


    Ich würde io_readwrite verwenden

  • Übersicht:

    PHP
    io_read      Reads from the file.
    io_write     Write in the file, or create the file. Erases all contents.
    io_readwrite Reads the file or creates it
    io_append    Appends (adds) to file, write-only. If the file does not exist, it is created


    Ich würde io_readwrite verwenden


    Allerdings wird das Banned in die Datei dann doppelt erstellt :(