Registration count - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Registration count (
/showthread.php?tid=432361)
Registration count -
Zex Tan - 22.04.2013
Hello, how can I increase a players Registration ID, like:
Player A registered with an account with its registration number 0001.
Then,
Player B registered with an account with its number 0002.
How can I do that ?
AW: Registration count -
HurtLocker - 22.04.2013
This is what I have in my /register command to do this:
pawn Код:
format(AccFile, sizeof(AccFile), "/users/AccountsNumber.ini", AccFile);
ac=dini_Int(AccFile, "AccNo");
ac++;
dini_IntSet(AccFile, "AccNo", ac);
format(str, sizeof(str), "{03FF20}%s [%d] {5293FA}has just registered. It's the number {03FF20}%d {5293FA}account created in this server!", name, playerid, ac);
SendClientMessageToAll(1, str);
So, create a .ini file yourself and add inside the string "AccNo" by hand.
Re: AW: Registration count -
Zex Tan - 22.04.2013
Quote:
Originally Posted by HurtLocker
This is what I have in my /register command to do this:
pawn Код:
format(AccFile, sizeof(AccFile), "/users/AccountsNumber.ini", AccFile); ac=dini_Int(AccFile, "AccNo"); ac++; dini_IntSet(AccFile, "AccNo", ac); format(str, sizeof(str), "{03FF20}%s [%d] {5293FA}has just registered. It's the number {03FF20}%d {5293FA}account created in this server!", name, playerid, ac); SendClientMessageToAll(1, str);
So, create a dini file yourself and add inside the string "AccNo" by hand.
|
Do I need to create a new file ? Sorry... Can't really understand some codes. (Haven't script for months)
AW: Registration count -
HurtLocker - 22.04.2013
Yes, create a file named AccountsNumber.ini by hand. Then, also by hand, write inside: AccNo="NumberOfAccounts"