예제 #1
0
파일: User.cs 프로젝트: SandonV/OpenSMO
 public void stopscan()
 {
     mSongScanner = new SongScanner(this);
     if(mSongScanner.IsScanning())
     {
     mSongScanner.StopScan();
     }
     Scanning = false;
 }
예제 #2
0
파일: User.cs 프로젝트: SandonV/OpenSMO
        public void scan()
        {
            if (Scanning)
            {
            SendChatMessage("Scan already in progress");
            }
            else
            {
            if (CurrentRoom == null)
            {
                SendChatMessage("Scanning can not be done from the Lobby. Join a room and then run /scan");
            }
            else
            {
                MySql.Query("DELETE FROM userpacks where userid = '" + User_ID + "'");
                mainClass.SendChatAll("Scan Started for " + NameFormat()+" ", CurrentRoom);
                mSongScanner = new SongScanner(this);
                Scanning = true;
                Hashtable[] packs = MySql.Query("select packname, title, subtitle, artist, packidentifiertrans.packid, titletrans, subtitletrans, artisttrans from packsongstrans, packidentifiertrans, packs where packidentifiertrans.packsongid = packsongstrans.id and packidentifiertrans.packid = packs.id order by packname asc");
                mSongScanner.LoadSongs(packs);

                mSongScanner.SendNextSong();
            }
            }
        }