How to create a rotary casino-ish effect?

I’m working on a game and I came across this effect, I would really like to know how its been made as I personally find it very smooth. If you know how please explain! Thank you. (game is not a casino game incase that came to thought, ofc i wont make something violating ToS)

(credits to @Arch_Mage for example)

1 Like

How you would do this EXACTLY is basically:

  1. Set the ClipsDescendants property of your frame (holder) to true
  2. Create a copy of the current text you have in the frame and move it up so it’s not visible
  3. Create two Tweens. Make it so that the first one moves the original text down out of the frame and the second one moves the cloned text down to the frame.
  4. After the tween is done, remove the original text.

Another way of doing this:

  1. Same as first way
  2. Skip
  3. Create two Tweens, the first tween moves the text down out of the frame, after the tween has ended, put the text above the frame and change it’s contents and use the second tween to move it down.
  4. Skip

Note that the first method looks better because it makes it look like there is actually a spinning cylinder with numbers on it.

1 Like

I see, but how will i do the math calculation to see if for example number starts with one but gets changed to nine, it would roll 8 times?

Ok so, this might or might not be a tricky one, but what I suggest you to do is:

  1. Retrieve the current amount, store it
  2. Write down the changed amount
  3. Deplete the current amount for the changed amount. If the current amount is bigger than the changed amount,note it down.
  4. Do a for loop on the number you calculated, and just roll the effect again and again!
1 Like