public void Reset()
    {
        m_Instance.transform.position = m_SpawnPoint.position;
        m_Instance.transform.rotation = m_SpawnPoint.rotation;

        m_Movement.SetDefaults();
        m_Shooting.SetDefaults();
        m_Health.SetDefaults();
    }
Exemple #2
0
    public void Respawn(Vector3 position, Vector3 rotation)
    {
        Health.SetDefaults();

        MoveToLocation(position);
        transform.rotation = Quaternion.Euler(rotation);

        _movement.SetDefaults();
        _movement.SetAudioSourceActive(true);
        _shooting.SetDefaults();
    }
Exemple #3
0
    // Used at the start of each round to put the tank into it's default state.
    public void Reset()
    {
        m_Movement.SetDefaults();
        m_Shooting.SetDefaults();
        m_Health.SetDefaults();

        if (m_Movement.hasAuthority)
        {
            m_Movement.m_Rigidbody.position = m_SpawnPoint.position;
            m_Movement.m_Rigidbody.rotation = m_SpawnPoint.rotation;
        }
    }
Exemple #4
0
    // Used at the start of each round to put the tank into it's default state.
    public void Reset()
    {
        m_Movement.SetDefaults();
        m_Shooting.SetDefaults();
        m_Health.SetDefaults();

        if (m_Movement.hasAuthority)
        {
            // TODO Reset the state of the movement's model
            //m_Movement.m_Rigidbody.position = m_SpawnPoint.position;
            //m_Movement.m_Rigidbody.rotation = m_SpawnPoint.rotation;
        }
    }