for(new i=0;i<MAX_PLAYERS;i++) if(GetPlayerInterior(playerid) == GetPlayerInterior(i)) { //if they are in same interior here }