FixedUpdate
фактически используется только для физики, и вы не должны изменять его интервалы для того, что вы хотите сделать ...
скорее используйте Update
и Time.deltaTime
, если это возможно. Даже в FixedUpdate
рекомендуется использовать Time.deltaTime
(см. Time.fixedDeltaTime
)
В вашем случае, однако, для приращения точных временных шагов вы можете рассмотреть сопрограмму с WaitForSeconds
(или, возможно, WaitForSecondsRealtime
) типа
using System.Collections;
//...
private void Start()
{
StartCoroutine(RunTimer());
}
private IEnumerator RunTimer()
{
var time = 0f;
uiText.text = "Time: " + time.ToString("#.0##");
// looks scary but is okey in a coroutine as long as you yield somewhere inside
while(true)
{
// yield return makes the routine pause here
// allow Unity to render this frame
// and continue from here in the next frame
//
// WaitForSeconds .. does what the name says
yield return new WaitForSeconds(0.01f);
time += 0.01f;
uiText.text = "Time: " + time.ToString("#.0##");
}
}
![enter image description here](https://i.stack.imgur.com/wxcjp.gif)