diff options
Diffstat (limited to 'npc/commands/ucp.txt')
-rw-r--r-- | npc/commands/ucp.txt | 21 |
1 files changed, 13 insertions, 8 deletions
diff --git a/npc/commands/ucp.txt b/npc/commands/ucp.txt index a11d2e0c5..f632d8a1e 100644 --- a/npc/commands/ucp.txt +++ b/npc/commands/ucp.txt @@ -20,16 +20,18 @@ function script UserCtrlPanel { case 1: GameRules; break; case 2: GameNews; break; case 3: - if (@query) { - mesn; - mesc l("Anti flood protection is enabled. Request rejected."), 1; - next; - break; - } if (!validatepin()) break; - @query=1; - query_sql("SELECT email,logincount,last_ip FROM `login` WHERE account_id="+getcharid(3)+"' LIMIT 2", .@email$, .@lgc, .@ip$); + if (!@email$) { + query_sql("SELECT email,logincount,last_ip FROM `login` WHERE account_id="+getcharid(3)+"' LIMIT 2", .@email$, .@lgc, .@ip$); + @email$=.@email$; + @lgc=.@lgc; + @ip$=.@ip$; + } else { + .@email$=@email$; + .@lgc=@lgc; + .@ip$=@ip$; + } mes l("Char Name: @@", strcharinfo(0)); mes l("Party Name: @@", strcharinfo(1)); mes l("Guild Name: @@", strcharinfo(2)); @@ -43,6 +45,9 @@ function script UserCtrlPanel { mes l("Last IP: @@", .@ip$[0]); mes l("Total Logins: @@", .@lgc[0]); next; + if (@query) + break; + @query=1; query_sql("SELECT name,last_login,last_map,partner_id FROM `char` WHERE account_id="+getcharid(3)+"' LIMIT 9", .@name$, .@lastlogin$, .@map$, .@married); for (.@i = 1; .@i < getarraysize(.@name$); .@i++) { mesn .@name$[i-1]; |