PlaySound() public static method

public static PlaySound ( SoundType type ) : void
type SoundType
return void
示例#1
0
        public void Init_Properties()
        {
            Width  = 320;
            Height = 240 + 25;

            Cursor.Hide();


            //pBack.Left = 0;
            //pBack.Top = 0;
            //pBack.Width = pBack.Image.Width;
            //pBack.Height = pBack.Image.Height;

            pMain.Image  = new Bitmap(320, 240);
            pMain.Left   = 0;
            pMain.Top    = 0;
            pMain.Width  = pMain.Image.Width;
            pMain.Height = pMain.Image.Height;


            Left = SystemInformation.PrimaryMonitorSize.Width / 2 - this.Width / 2;
            Top  = SystemInformation.PrimaryMonitorSize.Height / 2 - this.Height / 2;

            Media.PlaySound(Media.SoundType.ST_level2);
        }
示例#2
0
        public void Init_Properties()
        {
            Width  = 320;
            Height = 240 + 40 + flowPanel_gameInfo.Height;

            //Cursor.Hide();

            pMain.Image = new Bitmap(320, 240);

            /*pMain.Left = 0;
             * pMain.Top = 0;
             * pMain.Width = pMain.Image.Width;
             * pMain.Height = pMain.Image.Height;*/

            Left = SystemInformation.PrimaryMonitorSize.Width / 2 - this.Width / 2;
            Top  = SystemInformation.PrimaryMonitorSize.Height / 2 - this.Height / 2;

            Media.PlaySound(Media.SoundType.ST_level2);
        }