Variable value gets reset after a few screens during prototype

What i am trying to achieve

An input that a user can input or three buttons with set values that gets assigned to a variable, on submit, the value of the variable is used to calculate certain values, on the next screen, i need to show the value of the updated variables, making certain values dynamic.

Steps performed in the screens and prototype

Create a variable Total = 1000
Create a variable Remaining = 0
Create a variable fraction = 0
Create a variable ‘x’ = 0

Three buttons in one screen, button click sets variable to 200 300 500.
Submit button on press, set fraction to be (x / total) * 100 → set variable remaining to be total - x,

Next screen, I created an overlay that shows all the values of the variables (sometimes it breaks on this screen itself)

Next screen, Another page that shows some of the values, mainly x and fraction but here the values are reset to be 0 and 0 and breaks autolayout.

I have a redirect sort of button on the last screen above, on press and re running the steps does not result in any issues whatsoever. Its ONLY the first run of the prototype that the value of some variables gets reset.


Is this some Figma caching issues where the first run takes some extra effort to fully setup the variables (hence secondary runs without refreshing the page doesnt cause issues)?

Is there some step that I have potentially done that is causing this issue?

Is there limitation to variable prototyping?

As mentioned, this only happens during the first run of the prototype.

1 Like

@Aditya_Ratna_Shakya can you share a copy of the file (or even a screen recording that demonstrates what you’re looking for) with the work you’re describing? Having a bit of a difficult time fully visualizing this, and that would be helpful.