コード例 #1
0
    public void ShowLevel(int index)
    {
        MapInfoAsset info = m_Maps[index];

        m_MapTitle.text           = info.m_ShortName;
        m_MapDesc.text            = info.m_Description;
        m_MapPreviewImage.texture = info.m_Preview;

        m_MapPreviewPanel.SetActive(true);
    }
コード例 #2
0
    public void PlayLevel(int index)
    {
        // Activate the selected level
        MapInfoAsset info = m_Maps[index];

        MapList.ActiveMap = MapList.m_MapList[info.m_MapIndex];

        // Reset game variables
        GameSession.Instance = new GameSession();

        // Start the game
        SceneManager.LoadScene("L_Game");
    }