- Home /
Updating ui not working in fixed update .But it works in update
StoreCurency.text = PlayerPrefs.GetInt(GameStrings.curency, 0).ToString();
these lines of code is working fine in an update method. But when I put the same line in fixed update with nothing else is changed then its not updating . I would like to know why
Answer by Breyyne · Jan 07 at 08:17 PM
Because FixedUpdate is part of the Physics Engine in Unity and not always in sync with the regular Update loop. You can try setting up a coroutine to be called from the FixedUpdate that after a WaitForEndOfFrame completes the UI update.
Your answer
Follow this Question
Related Questions
LateUpdate not working properly for UI Text rotation 0 Answers
Text MeshPro Input field insert integer? 1 Answer
How Can i store string variable through UI text that is confirmed by a button ? 0 Answers
Changing Toggle UI's value (Checked or Unchecked) 5 Answers
Is it unnecessary to use FixedUpdate for a non-physics game? 1 Answer