protected override void AwakeInit()
 {
     dialogMode = DialogOKCancelMode.None;
     exitMode   = Exitmode.World;
     registrator.Add(
         new MessageRegistrationTuple {
         type = InstantMessageType.PuzzleBusy, handler = OnPuzzleBusy
     },
         new MessageRegistrationTuple {
         type = InstantMessageType.PuzzleCompleteProcessed, handler = OnPuzzleCompleteProcessed
     },
         new MessageRegistrationTuple {
         type = InstantMessageType.PuzzleWinImageStopped, handler = OnPuzzleWinImageStopped
     },
         new MessageRegistrationTuple {
         type = InstantMessageType.PuzzleSourceImageClosed, handler = OnPuzzleSourceImageClosed
     },
         new MessageRegistrationTuple {
         type = InstantMessageType.GUIBackButtonPressed, handler = OnGUIBackButtonPressed
     },
         new MessageRegistrationTuple {
         type = InstantMessageType.GUIWhiteCurtainFaded, handler = OnGUIWhiteCurtainFaded
     },
         new MessageRegistrationTuple {
         type = InstantMessageType.GUIViewButtonPressed, handler = OnGUIViewButtonPressed
     },
         new MessageRegistrationTuple {
         type = InstantMessageType.GUIRestartButtonPressed, handler = OnGUIRestartButtonPressed
     },
         new MessageRegistrationTuple {
         type = InstantMessageType.GUIMagicButtonPressed, handler = OnGUIMagicButtonPressed
     },
         new MessageRegistrationTuple {
         type = InstantMessageType.GUIOKButtonPressed, handler = OnGUIOKButtonPressed
     },
         new MessageRegistrationTuple {
         type = InstantMessageType.GUICancelButtonPressed, handler = OnGUICancelButtonPressed
     },
         new MessageRegistrationTuple {
         type = InstantMessageType.MusicTrackPlayed, handler = OnMusicTrackPlayed
     },
         new MessageRegistrationTuple {
         type = InstantMessageType.GUIRotoCoinsPressed, handler = OnGUIRotoCoinsPressed
     },
         new MessageRegistrationTuple {
         type = InstantMessageType.GUIRotoChipsPressed, handler = OnGUIRotoChipsPressed
     },
         new MessageRegistrationTuple {
         type = InstantMessageType.PuzzleAutostepAvailable, handler = OnPuzzleAutostepAvailable
     },
         new MessageRegistrationTuple {
         type = InstantMessageType.ShopBlurryScreenshotTaken, handler = OnShopBlurryScreenshotTaken
     }
         );
 }
        void OnPuzzleCompleteProcessed(object sender, InstantMessageArgs args)
        {
            exitMode = Exitmode.Victory;
            PuzzleCompleteStatus completeStatus = (PuzzleCompleteStatus)args.arg;

            GlobalManager.MStorage.GalleryLevel = completeStatus.descriptor.init.id;
            GlobalManager.MInstantMessage.DeliverMessage(InstantMessageType.PuzzleBusy, this, true);
            GlobalManager.MInstantMessage.DeliverMessage(InstantMessageType.BackgroundMusic, this, BackGroundMusicMode.Off);
            GlobalManager.MAudio.PlayMusicTrack(victoryMusicId, false);
            GlobalManager.MInstantMessage.DeliverMessage(InstantMessageType.PuzzleShowWinimage, this, completeStatus.firstTime ? victoryId : levelCompletedOnceAgainId);
        }
 void OnShopBlurryScreenshotTaken(object sender, InstantMessageArgs args)
 {
     exitMode = Exitmode.Shop;
     GlobalManager.MInstantMessage.DeliverMessage(InstantMessageType.GUIFadeWhiteCurtain, this);
 }