Ejemplo n.º 1
0
    void Start( )
    {
        //Initiate data
        GameService.InitDocument( );

        //Show the start game screen
        StartGameScreen.SetActive(true);   // ON
        InstructionScreen.SetActive(false);
        Marketplace.SetActive(false);
        PauseScreen.SetActive(false);
        GameHUD.SetActive(false);
        GameInfoHUD.SetActive(false);

        BtnLive.SetActive(false);
        BtnShop.SetActive(false);

        //Set initial values
        SocialLevel   = 0;
        VerbalLevel   = 0;
        SkillLevel    = 0;
        HardwareLevel = 0;

        Followers        = 0;
        Viewers          = 0;
        Money            = 60.00f;
        StreamerName     = "";
        TotalStreamTime  = 16.0f;
        StartCash        = 0;
        GameMessageList  = new List <KeyValuePair <string, string> >( );
        PlayerOwnedGames = new List <Game>( );

        //Set game state
        CurrentGameState = GameState.MENU;
        bGameStarted     = false;
    }
Ejemplo n.º 2
0
 /// <summary>
 /// Show Game instructions
 /// </summary>
 public void ShowInstructions( )
 {
     StartGameScreen.SetActive(false);
     InstructionScreen.SetActive(true);
     PauseScreen.SetActive(false);
     GameHUD.SetActive(false);
     GameInfoHUD.SetActive(false);
 }
Ejemplo n.º 3
0
    /// <summary>
    /// Show Game instructions
    /// </summary>
    public void ShowStartScreen( )
    {
        StartGameScreen.SetActive(true);
        InstructionScreen.SetActive(false);
        Marketplace.SetActive(false);
        PauseScreen.SetActive(false);
        GameHUD.SetActive(false);
        GameInfoHUD.SetActive(false);

        CurrentGameState = GameState.MENU;
    }
Ejemplo n.º 4
0
    /// <summary>
    /// Pause / unpause the game
    /// </summary>
    public void PauseGame( )
    {
        bGamePaused = !bGamePaused;

        StartGameScreen.SetActive(false);
        InstructionScreen.SetActive(false);
        PauseScreen.SetActive(bGamePaused);
        GameHUD.SetActive(!bGamePaused);
        GameInfoHUD.SetActive(!bGamePaused);

        CurrentGameState = bGamePaused ? GameState.PAUSE : GameState.GAME;
    }
Ejemplo n.º 5
0
    /// <summary>
    /// Start game and go to game hud & screen
    /// </summary>
    public void StartGame( )
    {
        //show the game hud
        StartGameScreen.SetActive(false);
        InstructionScreen.SetActive(false);
        PauseScreen.SetActive(false);
        GameHUD.SetActive(true);     // ON
        GameInfoHUD.SetActive(true); // ON

        CurrentGameState = GameState.GAME;

        StartCoroutine(StartGameCallback( ));
    }
Ejemplo n.º 6
0
    private IEnumerator LateStart()
    {
        yield return(new WaitForSeconds(0.001f));

        MainGame.SetActive(false);
        GameHUD.SetActive(false);
        HeroTutorial.SetActive(false);
        HeroHUD.SetActive(false);
        for (int i = 0; i < HeroInstructions.Length - 1; ++i)
        {
            HeroInstructions[i].SetActive(false);
        }
        MechanicsList.SetActive(false);
        for (int i = 0; i < Mechanics.Length - 1; ++i)
        {
            Mechanics[i].SetActive(false);
        }
    }
Ejemplo n.º 7
0
 public void LeaveMarketplace( )
 {
     Marketplace.SetActive(false);
     GameHUD.SetActive(true);
     GameInfoHUD.SetActive(true);
 }