public void GenMostScore()
    {
        Object[] keys = Environment.RoomManager.GetRooms().values().toArray();

        Room[] Rooms=new Room[keys.length];int[]Scores=new int[keys.length];

        int row = 0;
        for (int a = 0; a < keys.length; a++)
        {
            Room Current = (Room) keys[a];
            if(Current!=null && Current.Score > 0)
            {
                Rooms[row] = Current;
                Scores[row++] = Current.Score;
                continue;
            }
        }

        int len = row;

        int t;Room t2;
        for (int i=0;i<len;i++)
        {
            for (int j=i;j>0&&Scores[j-1]<Scores[j];j--)
            {
                t=Scores[j];
                Scores[j]=Scores[j-1];
                Scores[j-1]=t;
                t2=Rooms[j];
                Rooms[j]=Rooms[j-1];
                Rooms[j-1]=t2;
            }
        }

        if(len>MAX_ROOMS)
        {
            len = MAX_ROOMS;
        }

        try{sleep(10000);}catch (Exception ex){}

        
        ServerMessage MsgRooms = Environment.RoomListing.GetScore();
        Environment.RoomListing.ScoreActived(false);
        Environment.InitPacket(451, MsgRooms);
        Environment.Append(0, MsgRooms);
        Environment.Append(Integer.toString(2), MsgRooms);
        Environment.Append(len, MsgRooms);
        for(int i = 0;i<len;i++)
        {
            Environment.RoomManager.SerializeRoom(MsgRooms,Rooms[i],0,Scores[i]);
        }
        Environment.Append(false, MsgRooms);
        Environment.RoomListing.ScoreActived(true);
    }