示例#1
0
                public new void Enter(IemStateManager.StateManager sm)
                {
                    TargetPracticeStateManager gsm = (TargetPracticeStateManager)sm;

                    List <ReactiveTarget> targets = IemUtils.FindComponentsNearToLocation <ReactiveTarget>(gsm.location, 50);

                    foreach (var target in targets)
                    {
                        target.SetFlag(BaseEntity.Flags.On, false);
                    }

                    gsm.eg.EndGame();

                    double totalTime = 0;

                    foreach (TPGameLevel level in gsm.eg.gamelevels)
                    {
                        totalTime += level.LevelTime();
                    }

                    IemUI.CreateGameBanner(gsm.eg.player, "Game is complete! - your time was "
                                           + IemUtils.GetTimeFromSeconds(totalTime) + " seconds");


                    IemUI.Confirm(gsm.eg.player, "Game completed!\nreturn to the map",
                                  "Back",
                                  gsm.eg.backToTheMap);
                }