Aaaah, so his question was: "How do I check which map was entered?". I see...
rqueen, your script wont work, because .@mapname$ doesn't have a value.
Try this:
OnPCLoadMapEvent:
if (strcharinfo(3) == "bat_room" && query_sql("SELECT login.account_id FROM login LEFT JOIN `char` ON login.account_id=`char`.account_id WHERE login.last_ip=(SELECT last_ip FROM login WHERE account_id="+getcharid(3)+") AND `char`.online=1", .@account_id) > 5)
{
dispbottom "You exceeded the maximum accounts allowed in this area.";
warp "new_pront",156,177;
}
end;