Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- - script dualclientkicker -1,{
- OnPCLoadMapEvent:
- set .@charmap$, strcharinfo(3);
- if(!compare(.tmp$,.@charmap$)) end;
- set .@len, query_sql("SELECT DISTINCT `account_id` FROM `char` WHERE `account_id` IN "+
- "(SELECT `account_id` FROM `login` WHERE `last_mac` = "+
- "(SELECT `last_mac` FROM `login` WHERE `account_id`="+getcharid(3)+")) AND `online` <> 0;",.@a);
- if(.@len-1) {
- for(set(.@d,0);.@d<.@len;set(.@d,.@d+1)) {
- getmapxy(.@map$,.@x,.@y,0,rid2name(.@a[.@d]));
- if(.@charmap$==.@map$&&rid2name(.@a[.@d])!=strcharinfo(0)) {
- dispbottom "Dual Clients are not allowed in This Map.";
- warp "geffen",0,0;
- }
- }
- }
- end;
- OnInit:
- setarray .maps$ , "alberta", "gefg_cas01", "payg_cas01", "prtg_cas01";
- set .lens , getarraysize(.maps$) ;
- for(set(.a,0);.a<.lens;set(.a,.a+1)) {
- setmapflag .maps$[.a], mf_loadevent ;
- set .tmp$ ,.tmp$+.maps$[.a]+",";
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment