public static void CloseSplash() { introSC = new IntroScreen(); splashSC.Hide(); splashSC.Close(); introSC.ShowDialog(); }
public static void CloseEditor() { introSC = new IntroScreen(); editorSC.Hide(); editorSC.Close(); introSC.ShowDialog(); }
public virtual void TestPlayIntroWithFailingAudioDevice() { AddStep("hide notifications", () => notifications.Hide()); AddStep("restart sequence", () => { logo.FinishTransforms(); logo.IsTracking = false; IntroStack?.Expire(); Add(IntroStack = new OsuScreenStack { RelativeSizeAxes = Axes.Both, }); IntroStack.Push(intro = CreateScreen()); }); AddStep("trigger failure", () => { trackResetDelegate = Scheduler.AddDelayed(() => { intro.Beatmap.Value.Track.Seek(0); }, 0, true); }); AddUntilStep("wait for menu", () => intro.DidLoadMenu); if (IntroReliesOnTrack) { AddUntilStep("wait for notification", () => notifications.UnreadCount.Value == 1); } AddStep("uninstall delegate", () => trackResetDelegate?.Cancel()); }
public void Start() { Hardware hardware = new Hardware(800, 600, 24, false); IntroScreen intro = new IntroScreen(hardware, "sentece.txt"); MenuScreen menu = new MenuScreen(hardware); PlayerSelectScreen selectScreen = new PlayerSelectScreen(hardware); GameScreen game = new GameScreen(hardware); intro.Show(); do { menu.Show(); switch (menu.MenuOption) { case 0: game.Show(); break; case 1: selectScreen.Show(); break; case 2: game.Show(); break; case 3: exit = true; break; } } while (!exit); }
public static void Load() { Game.Player.Money = 0; Game.Player.WantedLevel = 0; Game.Player.Character.Weapons.RemoveAll(); if (HasSaveGame()) { string json = LoadPlayerData(); if (json != "") { PlayerJson playerJson = PlayerJson.FromJson(json); playerJson.Spawn(); } } else { Screen.FadeIn(500); if (Main.configSettings.Info_Intro_Screen) { IntroScreen intro = Script.InstantiateScript <IntroScreen>(); intro.Start(); } Notification.Show(NotificationIcon.Multiplayer, "GTAVOverride", "Mod has initialized!", "Mod has initialized a new savegame file, your progress will be saved from now on.", true, true); } loaded = true; lastSave = Game.GameTime; Debug.Log("Player loaded!"); }
public Gta5EyeTracking() { Debug.Log("Begin Initialize"); //Disposing _shutDownRequestedEvent = new ManualResetEvent(false); //Settings _settingsStorage = new SettingsStorage(); _settings = _settingsStorage.LoadSettings(); //Statistics var version = Assembly.GetExecutingAssembly().GetName().Version; var versionString = version.Major + "." + version.Minor + "." + version.Build; _googleAnalyticsApi = new GoogleAnalyticsApi("UA-68420530-1", _settings.UserGuid, "GTA V Eye Tracking Mod", "gta5eyetracking", versionString); //Gaze _tobiiTracker = new EyeTrackingHost(); //Menu _menuPool = new MenuPool(); _settingsMenu = new SettingsMenu(_menuPool, _settings); _introScreen = new IntroScreen(_menuPool, _settings); //Debug _debugGazeVisualization = new DefaultCrosshair(Color.FromArgb(220, 255, 0, 0), Color.FromArgb(220, 0, 255, 255)); _debugOutput = new DebugOutput(); //Hids _mouseEmulation = new MouseEmulation(); _controllerEmulation = new ControllerEmulation(); //Features _gameState = new GameState(_controllerEmulation, _menuPool); _animationHelper = new AnimationHelper(); _aiming = new Aiming(_settings, _animationHelper, _gameState); _extendedView = new ExtendedView(_settings, _gameState, _aiming, _debugOutput); _radialMenu = new RadialMenu(_controllerEmulation); //Window _foregroundWindowWatcher = new ForegroundWindowWatcher(); _foregroundWindowWatcher.ForegroundWindowChanged += ForegroundWindowWatcherOnForegroundWindowChanged; _isWindowForeground = _foregroundWindowWatcher.IsWindowForeground(); //General _gazeProjector = new GazeProjector(_settings); _controlsProcessor = new ControlsProcessor(_settings, _controllerEmulation, _aiming, _extendedView, _radialMenu, _settingsMenu, _gameState, _debugOutput); KeyDown += OnKeyDown; Tick += OnTick; Aborted += OnAborted; AppDomain.CurrentDomain.ProcessExit += AppDomainOnProcessExit; AppDomain.CurrentDomain.DomainUnload += AppDomainOnProcessExit; Debug.Log("End Initialize"); }
public LevelSetupState(LevelFSM stateMachine, LevelController controller) { _stateMachine = stateMachine; _playerSpawner = controller.PlayerSpawner; _gameSession = GameSession.Instance; _introScreen = controller.LevelHUD.IntroScreen; _playtimeScreen = controller.LevelHUD.PlaytimeScreen; }
static void Main(string[] args) { var player = new Player(); var intro = new IntroScreen(player); var nextScreen = intro.Run(); while (nextScreen != null) { nextScreen = nextScreen.Run(); } }
static void Main(string[] args) { var player = new Player(); var intro = new IntroScreen(player); var nextScreen = intro.Run(); while (nextScreen != null) { nextScreen = nextScreen.Run(); } }
static void Main(string[] args) { var player = new Player(); GameScreen nextScreen = new IntroScreen(); while (nextScreen != null) { nextScreen = nextScreen.Run(player.Context); } Console.WriteLine("The End!"); Console.ReadKey(); }
public UiSystem() { mBriefingScreen = new BriefingScreen(); mIntroScreen = new IntroScreen(); mShopScreen = new ShopScreen(); mSettingsScreen = new SettingsScreen(); mAdsScreen = new AdsScreen(); mGameScreen = new GameScreen(); mDebriefingWinScreen = new DebriefingWinScreen(); mDebriefingDefeatScreen = new DebriefingDefeatScreen(); HideAllScreens(); mScreenMode = eMode.NO_SCREEN; mProgressBar = GameObject.Find("FilledZone").GetComponent <RectTransform>(); }
void Start() { all.SetActive(false); #if UNITY_ANDROID siempreAtaja = false; #endif introScreen = GetComponent <IntroScreen> (); introScreen.OnIntroScreen(); ballsManager = GetComponent <BallsManager> (); ia = GetComponent <IA> (); resultsManager = GetComponent <ResultsManager> (); Events.OnShoot += OnShoot; m_VRInput.OnDown += OnDown; m_VRInput.OnUp += OnUp; Events.OnStartAgain += OnStartAgain; Events.Goal += Goal; }
public virtual void TestPlayIntro() { AddStep("restart sequence", () => { logo.FinishTransforms(); logo.IsTracking = false; IntroStack?.Expire(); Add(IntroStack = new OsuScreenStack { RelativeSizeAxes = Axes.Both, }); IntroStack.Push(intro = CreateScreen()); }); AddUntilStep("wait for menu", () => intro.DidLoadMenu); }
/// <summary> /// LoadContent will be called once per game and is the place to load /// all of your content. /// </summary> protected override void LoadContent() { GameContent.Initialize(Content); // Create a new SpriteBatch, which can be used to draw textures. _spriteBatch = new SpriteBatch(GraphicsDevice); _introScreen = new IntroScreen(this); _mainMenu = new TitleScreen(this); _credits = new CreditsScreen(this); _gameOver = new GameOverScreen(this); _options = new OptionsScreen(this); _loadscreen = new LoadScreen(this); _savescreen = new SaveScreen(this); _loadingScreen = new LoadingScreen(this); _howToPlay = new HowToPlay(this); GameStateManager.Parent = this; //System.Threading.ThreadPool.QueueUserWorkItem(LoadContentAsync); }
public void Initialize() { InputManager = new InputMapManager(this); InputManager.Add(new KeyboardInputMap(InputUnit.Keyboard, InputUnit.Mouse)); InputManager.Add(new GamePadInputMap(InputUnit.GamePads[0])); AudioUnit.Load("pulse_low_alt"); AudioUnit.Load("pulse_low"); AudioUnit.Load("pulse_mid"); AudioUnit.Load("pulse_high"); AudioUnit.Load("select"); AudioUnit.Load("refill"); AudioUnit.Load("bgm"); AudioUnit.Load("bgm1"); AudioUnit.Load("bgmboss"); AudioUnit.Load("boss_defeat"); ActiveScene = new IntroScreen(); }
public void Run() { // TO DO: Create a real Menu, instead of showing all the screens IntroScreen intro = new IntroScreen(); intro.Run(); MenuScreen menu = new MenuScreen(); do { menu.Run(); switch (menu.GetChosenOption()) { case MenuScreen.MenuOption.Game: Game g = new Game(menu.RetroLook); g.Run(); break; case MenuScreen.MenuOption.Help: HelpScreen help = new HelpScreen(menu.RetroLook); help.Run(); break; case MenuScreen.MenuOption.Credits: CreditsScreen credits = new CreditsScreen(menu.RetroLook); credits.Run(); break; case MenuScreen.MenuOption.Scores: HiScoresScreen hiScores = new HiScoresScreen(menu.RetroLook); hiScores.Run(); break; } } while (menu.GetChosenOption() != MenuScreen.MenuOption.Exit); }
protected virtual void ScreenChanged(IScreen current, IScreen newScreen) { switch (newScreen) { case IntroScreen intro: introScreen = intro; break; case MainMenu menu: menuScreen = menu; break; } if (newScreen is IOsuScreen newOsuScreen) { OverlayActivationMode.Value = newOsuScreen.InitialOverlayActivationMode; if (newOsuScreen.HideOverlaysOnEnter) { CloseAllOverlays(); } else { Toolbar.Show(); } if (newOsuScreen.AllowBackButton) { BackButton.Show(); } else { BackButton.Hide(); } } }
// Start is called before the first frame update void Start() { Cursor.visible = false; inst = this; StartCoroutine(IntroStep()); }
public void Start() { //TO DO Hardware hardware = new Hardware(SCREEN_WIDTH, SCREEN_HEIGHT, 24, false); IntroScreen intro = new IntroScreen(hardware); GameScreen game = new GameScreen(hardware); CreditsScreen credits = new CreditsScreen(hardware); PlayerSelectScreen playerSelect = new PlayerSelectScreen(hardware); ScoreBoardScreen scoreBoard; MainMenuScreen mainMenu = new MainMenuScreen(hardware); HelpScreen helpScreen = new HelpScreen(hardware); OptionsScreen optionsScreen = new OptionsScreen(hardware); intro.Show(); HordeModeScreen hordeMode; do { mainMenu.Show(); if (!mainMenu.GetExit()) { switch (mainMenu.GetChosenOption()) { case 1: playerSelect.Show(); game = new GameScreen(hardware); game.ChosenPlayer = playerSelect.ChosenPlayer(); game.Show(); break; case 2: if (lastGame != 0) { if (lastGame == 1) { playerSelect.Show(); game = new GameScreen(hardware); game.ChosenPlayer = playerSelect.ChosenPlayer(); game.Show(); } else { playerSelect.Show(); hordeMode = new HordeModeScreen(hardware); hordeMode.ChosenPlayer = playerSelect.ChosenPlayer(); hordeMode.Show(); } } break; case 3: playerSelect.Show(); hordeMode = new HordeModeScreen(hardware); hordeMode.ChosenPlayer = playerSelect.ChosenPlayer(); hordeMode.Show(); break; case 4: scoreBoard = new ScoreBoardScreen(hardware); scoreBoard.Show(); break; case 5: helpScreen.Show(); break; case 6: optionsScreen.Show(); break; case 7: credits.Show(); break; default: break; } } } while (!mainMenu.GetExit()); }
public Gta5EyeTracking() { Util.Log("Begin Initialize"); //Disposing _shutDownRequestedEvent = new ManualResetEvent(false); //Settings _settingsStorage = new SettingsStorage(); _settings = _settingsStorage.LoadSettings(); //Statistics var version = Assembly.GetExecutingAssembly().GetName().Version; var versionString = version.Major + "." + version.Minor + "." + version.Build; _googleAnalyticsApi = new GoogleAnalyticsApi("UA-68420530-1", _settings.UserGuid, "GTA V Eye Tracking Mod", "gta5eyetracking", versionString); //Gaze _aspectRatio = 1; _host = new EyeXHost(); _host.Start(); _lightlyFilteredGazePointDataProvider = _host.CreateGazePointDataStream(GazePointDataMode.LightlyFiltered); _lightlyFilteredGazePointDataProvider.Next += NewGazePoint; _lastGazeTime = DateTime.UtcNow; //Menu _menuPool = new MenuPool(); _settingsMenu = new SettingsMenu(_menuPool, _settings); _deadzoneEditor = new DeadzoneEditor(_settings, _settingsMenu); _settingsMenu.ShutDownRequested += SettingsMenuOnShutDownRequested; _introScreen = new IntroScreen(_menuPool, _settings); _introScreen.ShutDownRequested += SettingsMenuOnShutDownRequested; //Debug _debugGazeVisualization = new DotCrosshair(Color.FromArgb(220, 255, 0, 0), Color.FromArgb(220, 0, 255, 255)); _debugOutput = new DebugOutput(); //Hids _mouseEmulation = new MouseEmulation(); _controllerEmulation = new ControllerEmulation(); //Features _animationHelper = new AnimationHelper(); _aiming = new Aiming(_settings, _animationHelper); _freelook = new Freelook(_controllerEmulation, _mouseEmulation, _settings); _radialMenu = new RadialMenu(_controllerEmulation); _pedestrianInteraction = new PedestrianInteraction(_settings); //Window _foregroundWindowWatcher = new ForegroundWindowWatcher(); _foregroundWindowWatcher.ForegroundWindowChanged += ForegroundWindowWatcherOnForegroundWindowChanged; _isWindowForeground = _foregroundWindowWatcher.IsWindowForeground(); //General _gazeProjector = new GazeProjector(_settings); _controlsProcessor = new ControlsProcessor(_settings, _controllerEmulation, _aiming, _freelook, _radialMenu, _settingsMenu, _menuPool, _debugOutput); KeyDown += OnKeyDown; Tick += OnTick; Util.Log("End Initialize"); }
public Gta5EyeTracking() { Debug.Log("Begin Initialize"); //Disposing _shutDownRequestedEvent = new ManualResetEvent(false); //Settings _settingsStorage = new SettingsStorage(); _settings = _settingsStorage.LoadSettings(); //Statistics var version = Assembly.GetExecutingAssembly().GetName().Version; var versionString = version.Major + "." + version.Minor + "." + version.Build; _googleAnalyticsApi = new GoogleAnalyticsApi("UA-68420530-1", _settings.UserGuid, "GTA V Eye Tracking Mod", "gta5eyetracking", versionString); //Gaze _tobiiTracker = new TobiiInteractionEngineTracker(); //Menu _menuPool = new MenuPool(); _settingsMenu = new SettingsMenu(_menuPool, _settings); _introScreen = new IntroScreen(_menuPool, _settings); //Debug _debugGazeVisualization = new DefaultCrosshair(Color.FromArgb(220, 255, 0, 0), Color.FromArgb(220, 0, 255, 255)); _debugOutput = new DebugOutput(); //Hids _mouseEmulation = new MouseEmulation(); _controllerEmulation = new ControllerEmulation(); //Features _gameState = new GameState(_controllerEmulation, _menuPool); _animationHelper = new AnimationHelper(); _aiming = new Aiming(_settings, _animationHelper, _gameState); _extendedView = new ExtendedView(_settings, _gameState, _tobiiTracker, _aiming, _debugOutput); _radialMenu = new RadialMenu(_controllerEmulation, _tobiiTracker); //Window _foregroundWindowWatcher = new ForegroundWindowWatcher(); _foregroundWindowWatcher.ForegroundWindowChanged += ForegroundWindowWatcherOnForegroundWindowChanged; _isWindowForeground = _foregroundWindowWatcher.IsWindowForeground(); //General _gazeProjector = new GazeProjector(_settings); _controlsProcessor = new ControlsProcessor(_settings,_controllerEmulation,_aiming,_extendedView,_radialMenu,_settingsMenu, _gameState, _debugOutput); KeyDown += OnKeyDown; Tick += OnTick; Aborted += OnAborted; Debug.Log("End Initialize"); }
/// <summary> /// Allows the game to perform any initialization it needs to before starting to run. /// This is where it can query for any required services and load any non-graphic /// related content. Calling base.Initialize will enumerate through any components /// and initialize them as well. /// </summary> protected override void Initialize() { // set up the display window graphics.PreferredBackBufferWidth = 500; graphics.PreferredBackBufferHeight = 500; graphics.ApplyChanges(); // update the ViewportHeight and ViewportWidth constants so the screens know // how to draw themselves GameConstants.ViewportHeight = graphics.GraphicsDevice.Viewport.Height; GameConstants.ViewportWidth = graphics.GraphicsDevice.Viewport.Width; // display title in the window Window.Title = "Alien Attack"; // setup the state of the game currentGameState = GameConstants.GameState.Title; currentKeyboardState = Keyboard.GetState(); prevKeyBoardState = currentKeyboardState; // set up the screens titleScreen = new TitleScreen(); instructionScreen = new InstructionScreen(); highScoreScreen = new HighScoreScreen(); creditsScreen = new CreditsScreen(); introScreen = new IntroScreen(); readyScreen = new GetReadyScreen(); gameOverScreen = new GameOverScreen(); // set up the game objects gameCamera = new Camera(); player = new Player(); enemies = new Enemies(); map = new Map(); miniMap = new MiniMap(); skybox = new Skybox(); // set up the ingame displays score = new Score(); highScore = new HighScore(); // set up the soundtrack gameSongs = new GameSongs(); base.Initialize(); }
// Start is called before the first frame update private void Start() { intro = FindObjectOfType <IntroScreen>(); }
// Start is called before the first frame update void Awake() { roomNavigation = GetComponent <RoomNavigation>(); textInput = GetComponent <TextInput>(); interactableItems = GetComponent <InteractableItems>(); registerObjects = GetComponent <RegisterObjects>(); registerRooms = GetComponent <RegisterRooms>(); map = GetComponent <MiniMap>(); debugClass = GetComponent <DebugMode>(); additionalNarrations = GetComponent <AdditionalNarrations>(); npcTalk = GetComponent <NPCTalk>(); npcInteraction = GetComponent <NPCInteraction>(); demoScript = GetComponent <DemoScript>(); achievements = GetComponent <Achievements>(); combat = GetComponent <Combat>(); teleType = GetComponent <TeleType>(); introScreen = GetComponent <IntroScreen>(); GameObject.Find("MainScrollRect").GetComponent <ScrollRect>().verticalNormalizedPosition = 0.5f; //enterToContinue = false; //escToContinue = false; //toResumeEscToContinue = false; //exitPopUp = false; debugMode = false; secondQuestActive = false; currentActiveInput = "main"; ego.equippedWeapon = null; ego.equippedArmor = null; ego.equippedShield = null; ego.chosenAction = ""; ego.allStats[0].value = 100; ego.allStats[1].value = 100; ego.allStats[2].value = 100; ego.allStats[3].value = 0; ego.allStats[4].value = 1; ego.allStats[5].value = 0; ego.allStats[6].value = 4; ego.allStats[7].value = 0; ego.allStats[8].value = 1.5f; ego.allStats[9].value = 0; ego.allStats[10].value = 0; for (int i = 0; i < ego.allStats.Length; i++) { ego.allStats[i].effectValue = 0; } ego.activeEffects.Clear(); ego.defeatedBadGuys.Clear(); ego.blueCrystals = 0; ego.bankedCrystals = 0; ego.fightClubRank = 0; ego.fleeLocation = ""; ego.conversation = 0; ego.currentInit = 0; ego.displayAction = ""; ego.chosenAction = ""; ego.chosenItem = null; ego.chosenItem2 = null; ego.chosenTarget = null; ego.potionBelt.Clear(); //enterToContinueDialogue = false; //timeDelay = 1; sentences = new Queue <string>(); pauses = new Queue <int>(); //ego = Instantiate(ego); }