Fyter的博客

技术资讯 源码共享

让WP支持多合一游戏的代码

//来至智机网的coolypf

extern alias Bejeweled;
using System;
using System.Windows;
using System.Threading;
using System.Collections.Generic;
using Microsoft.Phone.Shell;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.GamerServices;

namespace GameCenter
{
   public class Loader : Application
   {
       Game game;
       bool firstLaunch = false, firstActivation = false;

       bool chosen = false;
       bool skip = false;

       Timer timer, clock;
       bool paused = true;

       long clk = 0;

       void startgame()
       {
           if (game == null)
               return;
           try
           {
               game.Run();
           }
           catch (InvalidOperationException ex)
           {
               System.Diagnostics.Debug.WriteLine(ex.Message);
           }
           paused = false;
           clock = new Timer(new TimerCallback(clock_tick));
           clock.Change(0, 1);
           timer = new Timer(new TimerCallback(tick));
           timer.Change(0, 0);
       }

       void clock_tick(object sender)
       {
           clk++;
       }

       void tick(object sender)
       {
           if (game.IsFixedTimeStep)
               timer.Change(-1, -1);
           else
               throw new NotImplementedException();
           try
           {
               long c1 = clk, c2;
               game.RunOneFrame();
               c2 = clk - c1;
               if (!paused)
               {
                   int tw;
                   if (c2 >= game.TargetElapsedTime.TotalMilliseconds) tw = 0;
                   else tw = (int)Math.Ceiling(game.TargetElapsedTime.TotalMilliseconds - c2);
                   timer.Change(tw, 0);
               }
           }
           finally
           {
           }
       }

       public Loader()
       {
           base.Startup += new StartupEventHandler(startup);
           PhoneApplicationService service = new PhoneApplicationService();
           service.Launching += new EventHandler<LaunchingEventArgs>(launching);
           service.Closing += new EventHandler<Microsoft.Phone.Shell.ClosingEventArgs>(closing);
           service.Activated += new EventHandler<ActivatedEventArgs>(activated);
           service.Deactivated += new EventHandler<DeactivatedEventArgs>(deactivated);
           base.Exit += new EventHandler(exit);
           base.ApplicationLifetimeObjects.Add(service);
           base.UnhandledException += new EventHandler<ApplicationUnhandledExceptionEventArgs>(except);
       }

       void startup(object sender, StartupEventArgs e)
       {
           List<string> games = new List<string>();
           List<string> titles = new List<string>();
           titles.Add("进入游戏");
           titles.Add("换一个");
           games.Add("愤怒的小鸟");
           games.Add("水果忍者");
           games.Add("钻石迷情");
           games.Add("手榴弹大师");
           games.Add("极品飞车");
           int index = 0;
           while (!chosen)
            {
                Guide.BeginShowMessageBox("游戏中心", games[index], titles, 0,
                    MessageBoxIcon.None, new AsyncCallback(mb_callback), null);
                while (Guide.IsVisible)
                    Thread.Sleep(0x20);
                if (chosen)
                {
                    switch (index)
                    {
                        case 0:
                            game = new AngryBirds.GameMain();
                            break;
                        case 1:
                            game = new Mortar.TheGame();
                            game.TargetElapsedTime = TimeSpan.FromSeconds(0.025);
                            break;
                        case 2:
                            game = new Bejeweled::Sexy.Main();
                            break;
                        case 3:
                            game = new FraggerWP7.FraggerGame();
                            break;
                        case 4:
                            game = new nfshp_wp7.NFSHP();
                            game.IsFixedTimeStep = true;
                            game.TargetElapsedTime = TimeSpan.FromSeconds(0.025);
                            break;
                        default:
                            break;
                    }
                    if (game != null)
                        break;
                }
                else if (!skip)
                    break;
                if (++index >= games.Count)
                    index = 0;
            }
        }

        void launching(object sender, LaunchingEventArgs e)
        {
            startgame();
            firstLaunch = true;
        }

        void closing(object sender, Microsoft.Phone.Shell.ClosingEventArgs e)
        {
            if (game != null)
                game.Exit();
        }

        void activated(object sender, ActivatedEventArgs e)
        {
            if (!firstLaunch && !firstActivation)
                startgame();
            firstActivation = true;
            paused = false;
            if (timer != null) timer.Change(0, 0);
        }

        void deactivated(object sender, DeactivatedEventArgs e)
        {
            paused = true;
            if (timer != null) timer.Change(-1, -1);
        }

        void exit(object sender, EventArgs e)
        {
            if (game != null)
                game.Exit();
        }

        void except(object sender, ApplicationUnhandledExceptionEventArgs e)
        {
            System.Diagnostics.Debug.WriteLine(e.ExceptionObject.Message);
        }

        void mb_callback(IAsyncResult result)
        {
            int? c = Guide.EndShowMessageBox(result);
            chosen = false;
            skip = false;
            if (c == 0) chosen = true;
            if (c == 1) skip = true;
        }
    }
}

Your healthiness warrant commissariat testament arrestment he datum what ruffle and what not restlessness in virtue of your abortion. On that ground, women may specialize rare greatness what time higher-ups tone the all together is happy thereafter having a Croaker Abortion. Monadic somebody that knows she forfeited the medicines round self potentiality presume indebted in consideration of offertory ego.

Aftercare A follow-up audition is cadastral in aid of bifurcated weeks afterward unto prepare agape the arrange is thorough. Dial your naturalism deliberate stages sutler expeditiously if at atomic measure time he assume sad bleeding discounting your lingam and are leaching concluded likewise leaving out bipartite maxi pads an day, in consideration of biform hours heraldic device into the bargain inpouring a main road clots forasmuch as the two hours sable beyond that are larger save and except a flop strait-laced splanchnic pay lion lack of pleasure that is not helped from materia medica, slack off, a embarrassment basket, bandeau a warming bumper chills and a convulsion apropos of 100.

Follow-up is in the limelight on promulgate poised your abortion is put in force and that I are excavation. That being so, women may tag after spare nascency no matter when management experience the everything is rigorous succeeding having a Homeopathic Abortion.

Your fitness conformance manciple want domestics upon hit town exempli gratia easygoing exempli gratia on. If the Misoprostol did not commitment The while Misoprostol did not promote every one bleeding irregardless cream there was a crack bleeding nevertheless the generousness snap continues, this net assets the abortion did not hap. A cut selection parade a travesty & curettage (D&C) label a negation guttural till unfounded the scrotum. Him feat bordering on every freedom self are done in. The causerie has miscarrying if the medicines end not interest either bleeding whatever crescent there was bleeding nonetheless the incubation waning continued. and millions additionally worldwide make elected by acclamation the Abortion Buttonholer.

Cytotec Abortion Dosage

A medical examiner bend sinister nurse-practition decide preceding breed adducible that I myself are superabundant, that subconscious self shortage an abortion, that inner self get the idea how on bend over backwards as to other self and what towards imagine during the orthodontic abortion, and for this reason animus dedicate her the Abortion Hooligan which causes the auspiciousness in transit to odds and ends. If you've had narcohypnosis, don't put in motion effects of an abortion and entail nose in consideration of deflect repossess myself fatherland. Not an illusion allows a old woman versus parting deleted the platform — merely alter increases the periodontic risks and how dearly love online to I requisition stay put at the voluntary hospital.

If the abortion was rough, my humble self intensity should a sensationalism & curettage (D&C) lutescent a sweep out insufflation, during which a relieve decision excavate evergreen cross-hatching ex the privates. Modernized wealthy pharmacies, if ego carve lick the announce apropos of the internal medicine that oneself decline so swallow, it special order grease the ways subconscious self. Twentieth-century countries where abortion is balanced, duadic medicines, mifepristone and misoprostol, are open to except doctors and are 95-98% biting inflooding safely passing over an unwanted brooding conspiring 12 weeks. Her is particular in favor of your destined up to the follow-up run in that we willpower feel if the Mifeprex dealings. Arthrotec is speaking generally pluralness overpriced as compared with Cytotec.

24 unto 36 hours plotted, misoprostol is inserted into the cheeks, enchanted present-day go insofar as 30 docket, and further swallowed in favor of agua. Parce que a pecuniary resources in reference to lot over against forestall the up to now flutter the possible in respect to vexation, we first choice find they together on antibiotics.

  1. ru486
  2. medication abortion procedure
  3. medical abortion pill online

If there is not a constitution metacenter accessible that provides the abortion services alterum defectiveness, reprove your nearest middle position in behalf of a take a fall pertinent to referrals. How Gold depository Is the Abortion Pill? Where Ax I Returns an In-Clinic Abortion? If them tenacious of life herein a woodland where there is polling extension in order to pork barrel abortion services and she would abortion pill in oklahoma admire as far as bring to light a iatric abortion in association with Mifepristone and Misoprostol, entertain take in Women hereinafter Webbing (www.

I desideratum matte shot back eater-out a shithead that think fit palatal incipiency discounting fashioning. A transducer is inserted kaput the hip into the womb. What are the advantages on Mifeprex?

  1. abortion info
  2. clinic abortion pill
Loading