- script woelimit HIDDEN_NPC,{
end;
OnPCLoadMapEvent:
.@rid = playerattached();
if ( !compare(strcharinfo(PC_MAP), "g_cas") || !agitcheck() ) end;
getguildmember getcharid(CHAR_ID_GUILD), 1;
getguildmember getcharid(CHAR_ID_GUILD), 2;
.@count = 0;
for ( .@i = 0; .@i < $@guildmembercount; .@i++ ) {
if (attachrid($@guildmemberaid[.@i])) {
if( compare(strcharinfo(PC_MAP), "g_cas") ) .@count++;
}
}
if ( .@rid )
attachrid(.@rid);
else
detachrid;
if(.@count > .max){
message strcharinfo(0), "WARNING: Max of "+.max+" members can simultaneously join the WOE.";
warp "SavePoint",0,0;
}
end;
OnInit:
.max = 25;
end;
}
try this