private void UpdateToOrigin() { m_t -= DELTA_T; //Time.smoothDeltaTime; float delta_t = DELTA_T; //Time.smoothDeltaTime; if (m_t < 0) { delta_t += m_t; m_t = 0; m_is_arrived = true; } this.transform.localPosition -= MathCore.DerivSpline(m_t / FACTOR, TAN_ORIGIN, 0.7f) * delta_t * m_translation; }
private void UpdateToDestination() { m_t += DELTA_T; //Time.smoothDeltaTime; float delta_t = DELTA_T; //.smoothDeltaTime; if (m_t > FACTOR) { delta_t -= m_t - FACTOR; m_t = FACTOR; m_is_arrived = true; } this.transform.localPosition += MathCore.DerivSpline(m_t / FACTOR, TAN_ORIGIN, 0.7f) * delta_t * m_translation; }