Bon un exemple tout con qui vient de Lstunt : les gstats.
new string[256];
new Float:timeout,Float:Visites,Float:txerror;
new txtimeout,totaltimeout,totalvisites,commandes,kicks;
if(dini_Exists(GeneralStats()))
if(dini_Isset(GeneralStats(),"TimeOut")) {
timeout = dini_Int(GeneralStats(),"TimeOut");
totaltimeout = floatround(timeout, floatround_round);
}
if(dini_Isset(GeneralStats(),"Visites")) {
Visites = dini_Int(GeneralStats(),"Visites");
totalvisites = floatround(Visites, floatround_round);
}
if(dini_Isset(GeneralStats(),"Commandes")) {
commandes = dini_Int(GeneralStats(),"Commandes");
}
if(dini_Isset(GeneralStats(),"Kicks")) {
kicks = dini_Int(GeneralStats(),"Kicks");
}
txerror = floatdiv(timeout,Visites)*100;
txtimeout = floatround(txerror, floatround_round);
format(string, sizeof(string), "Stats Lalu's Stunt : Taux de TimeOut: %d pour cent - Visites totales : %d - TimeOut totaux : %d - Commandes exécutées : %d, - Nombre de kicks : %d", txtimeout,totalvisites,totaltimeout,commandes,kicks);
SendClientMessage(playerid,COLOR_GREY,string);
PS : le code est pas super optimisé et il te manque une fonction pour le faire fonctionner, mais sur le principe il est complet pour avoir un aperçu.