The date of birth.
#2

pawn Код:
new Dates[3][11];
new DateString[11]="04/02/1997";
split(DateString,Dates,'/');

new day = strval(Dates[0]);
new month = strval(Dates[1]);
new year = strval(Dates[2]);

if(day<1||day>31) SendClientMessage(playerid,0xFFFFFFFF,"Day can only be from 1 to 31");
if(month<1||month>12) SendClientMessage(playerid,0xFFFFFFFF,"Month can only be from 1 to 12");
if(year<1) SendClientMessage(playerid,0xFFFFFFFF,"Year can be less than 1");
It's a example how you can do it with dialogs or whatever you need. Just make DateString variable equal to inputtext.
Not tested, but it should work.
Reply


Messages In This Thread
The date of birth. - by budelis - 29.08.2011, 18:17
Re: The date of birth. - by Bumbis - 29.08.2011, 18:35
Re: The date of birth. - by budelis - 29.08.2011, 19:03
Re: The date of birth. - by Bumbis - 29.08.2011, 19:50
Re: The date of birth. - by AndreT - 29.08.2011, 20:01

Forum Jump:


Users browsing this thread: 3 Guest(s)