I have implemented a feature in my game where users can scroll horizontally between 5 pages. The third page is the middle one, so I want to set the starting page to the third page. However, the scrollbar’s value
keeps resetting to 0
.
Even if I set the value
to 0.5
in the Inspector and start the game, it reverts back to 0
after stopping the game. Restarting the Unity Editor or reloading the scene also causes the value
to reset to 0
. I would appreciate any advice on why this is happening and how to fix it.