Registration count
#1

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 ?
Reply
#2

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.
Reply
#3

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)
Reply
#4

Yes, create a file named AccountsNumber.ini by hand. Then, also by hand, write inside: AccNo="NumberOfAccounts"
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)