Example #1
0
    /// <summary>
    /// Updates the syncher
    /// </summary>
    void Update()
    {
        if (!Utilities.IsLevelLoaded())
        {
            return;
        }

        if (!m_initialised)
        {
            Initialise();
        }

        if (photonView.isMine)
        {
            m_networkedTimePassed = Time.time - m_startUpTime;
        }

        m_gameManager.TrySetTimePassed(m_networkedTimePassed);
        m_gameManager.TrySetState(m_networkedState);

        AdjustTimestamps();
    }