Little "format" and "dini" help
#4

Quote:
Originally Posted by Lorenc_
Посмотреть сообщение
Reading sometimes dosent work really well on dini, suggesting some new file reading, creating systems like, y_ini, mysql, BUD - blazing user database, there the ones which are good.

By the way on a second notice did you ban the player with the reason
Код:
 Reason=Wasn't given a reason
or you just edited and said that the reason aint showing upon there?

I think you can close files and open them with dini, do so there..
I made a ban command according with params: without params2, the reason would be: "Wasn't given a reason".
Thx at all. Maybe Im gonna try y_ini or any other system of these, since you're not the first one told me to do it xP

Quote:
Originally Posted by Gavibro
Посмотреть сообщение
From what I see,BannedBy,Date,Time and Reason are strings,so you need to use dini_Get
pawn Код:
if(PlayerInfo[playerid][Banned] == 1)
    {
       PlayerInfo[playerid][BannedBy] = dini_Get(file,"BannedBy");
       PlayerInfo[playerid][Date] = dini_Get(file,"Date");
       PlayerInfo[playerid][Time] = dini_Get(file,"Time");
       PlayerInfo[playerid][Reason] = dini_Get(file,"Reason");
       new admin[128], data[128], time[128], reason[128];
       format(admin,sizeof(admin),"You have been banned by the adminstrator %s",PlayerInfo[playerid][BannedBy]);
       format(data,sizeof(data),"Date which you have been banned: %s",PlayerInfo[playerid][Date]);
       format(time,sizeof(time),"Time which you have been banned: %s",PlayerInfo[playerid][Time]);
       format(reason,sizeof(reason),"Reason by the which you have been banned: %s",PlayerInfo[playerid][Reason]);
       SendClientMessage(playerid, vermelho, "____________________________");
       SendClientMessage(playerid, vermelho, admin);
       SendClientMessage(playerid, vermelho, data);
       SendClientMessage(playerid, vermelho, time);
       SendClientMessage(playerid, vermelho, reason);
       SendClientMessage(playerid, vermelho, "* Your ban haven't over yet *");
       SendClientMessage(playerid, vermelho, "____________________________");
       Kick(playerid);

    }
Thank you, did work.
Reply


Messages In This Thread
Little "format" and "dini" help - by blackwave - 28.12.2010, 02:14
Re: Little "format" and "dini" help - by Lorenc_ - 28.12.2010, 02:38
Re: Little "format" and "dini" help - by Gavibro - 28.12.2010, 03:20
Re: Little "format" and "dini" help - by blackwave - 28.12.2010, 11:28

Forum Jump:


Users browsing this thread: 2 Guest(s)