Ejemplo n.º 1
0
        public LongRunningAction Reboot(string toLevel)
        {
            Reboot reboot = new Reboot(this.Game, toLevel);

            ServiceHelper.AddComponent((IGameComponent)reboot);
            bool disposed = false;

            reboot.Disposed += (EventHandler <EventArgs>)((_, __) => disposed = true);
            return(new LongRunningAction((Func <float, float, bool>)((_, __) => disposed)));
        }
Ejemplo n.º 2
0
 public LongRunningAction Reboot(string toLevel)
 {
   Reboot reboot = new Reboot(this.Game, toLevel);
   ServiceHelper.AddComponent((IGameComponent) reboot);
   bool disposed = false;
   reboot.Disposed += (EventHandler<EventArgs>) ((_, __) => disposed = true);
   return new LongRunningAction((Func<float, float, bool>) ((_, __) => disposed));
 }