Beispiel #1
0
        public GUIPlayer(
            Simulator simulator,
            Dictionary<TurretType, bool> availableTurrets,
            Dictionary<string, LevelDescriptor> levelsDescriptors,
            Color color,
            string representation,
            InputType inputType)
        {
            Simulator = simulator;

            SelectedCelestialBodyAnimation = new SelectedCelestialBodyAnimation(Simulator);

            Cursor = new SpaceshipCursor(Simulator.Scene, Vector3.Zero, 2, VisualPriorities.Default.PlayerCursor, color, representation, true);
            Crosshair = new Cursor(Simulator.Scene, Vector3.Zero, 2, VisualPriorities.Default.PlayerCursor, "crosshairRailGun", false);
            TurretMenu = new TurretMenu(Simulator, VisualPriorities.Default.TurretMenu, color, inputType);
            CelestialBodyMenu = new CelestialBodyMenu(Simulator, VisualPriorities.Default.CelestialBodyMenu, color, inputType);

            FinalSolutionPreview = new FinalSolutionPreview(Simulator);

            CelestialBodyMenu.AvailableTurrets = availableTurrets;
            CelestialBodyMenu.Initialize();

            WorldMenu = new WorldMenu(Simulator, VisualPriorities.Default.CelestialBodyMenu, levelsDescriptors, color);
            NewGameMenu = new NewGameMenu(Simulator, VisualPriorities.Default.CelestialBodyMenu, color);

            PowerUpInputMode = false;
            PowerUpFinalSolution = false;
        }
        public ProtagonistsAnimation(Simulator simulator, Mothership mothership)
        {
            Simulator = simulator;
            Mothership = mothership;

            Protagonist = new SpaceshipCursor(simulator.Scene, new Vector3(-200, -600, 0), 5, VisualPriorities.Cutscenes.IntroProtagonist, new Color(95, 71, 255), "Cursor1", true);
            Wife = new SpaceshipCursor(Simulator.Scene, new Vector3(-200, -600, 0), 5, VisualPriorities.Cutscenes.IntroWife, new Color(255, 0, 136), "Cursor2", true);

            Protagonist.FadeIn();
            Wife.FadeIn();

            ProtagonistText = new ManualTextBubble(Simulator.Scene, new Text("I must warn the\n\nother colonies!", @"Pixelite") { SizeX = 2 }, Protagonist.Position, VisualPriorities.Cutscenes.IntroProtagonist - 0.00001) { Alpha = 0 };

            State = ProtagonistState.None;

            TimeBeforeArrival = IntroCutscene.Timing["ProtagonistIn"];
            TimeBeforeAbduction = TimeBeforeArrival + 20000;
            TimeBeforeGoGetHelp = TimeBeforeAbduction + 4000;
            TimeBeforeFireAgainAtMothership = TimeBeforeGoGetHelp + 2000;
            TimeBeforeGoInCenter = TimeBeforeFireAgainAtMothership + 18000;
            TimeBeforeWarnColonies = TimeBeforeGoInCenter + 20000;
            TimeBeforeTeleport = TimeBeforeWarnColonies + 10000;


            PathArrivalProtagonist = GetPathArrivalProtagonist();
            PathArrivalWife = GetPathArrivalWife();

            TimeOnPathProtaAndWife = 0;
        }
        public GUIPausePlayer(Simulator simulator, SimPlayer innerPlayer)
        {
            Simulator = simulator;

            InnerPlayer = innerPlayer;

            Cursor = new SpaceshipCursor(Simulator.Scene, Vector3.Zero, 2, VisualPriorities.Default.PlayerPanelCursor, InnerPlayer.Color, InnerPlayer.ImageName, false);
        }