LoadFraktion Stock umändern

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


    ich habe hier einen LoadFraction Stock. Dieser ist aber für das R7 Plugin.
    Ich suche gerade eine Funktion beim R39-3 die diese ersetzen kann.


    stock LoadFactions()
    {
    new query[400];
    for(new id; id < MAX_FACTIONS; id++) // Goes through all the slots, looking for the data
    {
    format(query, sizeof(query), "SELECT * FROM fractions WHERE fid = %d", id); // Selects all the information from the table
    mysql_pquery(handle, query);
    mysql_store_result();
    if(cache_affected_rows())
    if(mysql_fetch_row_format(query,"|")) // es geht um diese Funktion
    {
    sscanf(query, "p<|>e<is[64]ds[32]s[32]s[32]s[32]s[32]s[32]s[32]s[32]s[32]s[32]s[32]s[32]>",Factions[id]); // SSCANF seperates the data into the variables
    Total_Factions_Created++; // Counts the factions created
    }


    }
    printf("> %d factions have been loaded from the database.", Total_Factions_Created); // Prints out the information of how many factions created
    return 1;
    }