Jump to content
  • 0

GM Online list, exclude ADMINS


Question

Posted

Hello, I would like to ask for a request on how to remove all ADMINS (GM LVL 99) from the GM online list ?

this is the script im using: 

 

 

 
prontera,164,182,4 script Online GMs 611,{
mes "Staffs Online Lists : ^FF0000"+getarraysize( .GM_Name$ )+"^000000 Staffs";
mes "^0000FF_____________________________^000000";
for( set .@i,0; .@i < getarraysize( .GM_Name$ ) ; set .@i,.@i + 1 ){
getmapxy( .Map$,.x,.y,0,.GM_Name$[.@i] );
mes "[ Lv ^63D1F4"+.GM_Level[.@i]+"^000000 ] ^FF0000@ ^0000FF"+.GM_Name$[.@i]+"^000000";
mes "Location : ^0000FF"+.Map$+"^000000";
mes "^0000FF_____________________________^000000";
}
close;
 
OnInit:
set .MinGMLevel,1; // Min. GM Level to Show in Online Lists
end;
 
OnPCLoginEvent:
if( getgmlevel() < .MinGMLevel ) end;
set .GM_Name$[ getarraysize( .GM_Name$ ) ],strcharinfo(0);
set .GM_Level[ getarraysize( .GM_Level ) ],getgmlevel();
end;
 
OnPCLogoutEvent:
if( getgmlevel() < .MinGMLevel ) end;
for( set .@i,0; .@i < getarraysize( .GM_Name$ ) ; set .@i,.@i + 1 ){
if( strcharinfo(0) != .GM_Name$[.@i] ) continue;
deletearray .GM_Name$[.@i],1;
deletearray .GM_Level[.@i],1;
end;
}
end;
}



thanks !

1 answer to this question

Recommended Posts

Posted

Change both instances of...

if( getgmlevel() < .MinGMLevel ) end;

To...

if( getgmlevel() < .MinGMLevel || getgmlevel() >= 99 ) end;

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...