Trouble on stopping an object at the right place

I’m trying to make the first roll of the game stop at the edge of the frame. But without success because even changing the speed it never stops on the right place.
code:


video reference
https://imgur.com/a/Er3Uu9Z

Thank you in advance.

Hi, probably I cannot really help you with your problem but I just wanted to let you know that the resolution of your screenshot is extremely low which makes it very difficult to read the events. Aside from that the description of your problem is not easy to understand.

What is the first roll? What do you mean by “edge of the frame”?

The only thing that stands out immediately despite the difficulty to read the events is that you have an event block with the “At the beginning of the scene”-condition that is not doing anything since there are no actions.

The problem will lie with the way you are stopping the reel. You’ll need some calculations to get the final position (usually in the form of round(position/sectionHeight) * sectionHeight), and your best bet will be to use a position tween to correct under or over runs of the reel.

If you need help with this, can you screen snip the events that stop the reel? And give the height (in pixels) of each block on a reel (i.e. the height of each coloured section on a reel)?

I you used the forum upload tool for the image :joy:

I just to do this just to test things, then when I export I will remove it.

I noticed that I don’t have any kind of alternative, I would guess that I would do it hand.
Here you have the project, better than than trying to simulate events from an image.

Ok, so supply the information and we’ll sort out a solution.

Thank you :grinning:

slot 1 x/y 236 97
slot 2 x/y 236 369
slot 3 x/y 236 641

size of the symbol is 284x272

And a screen shot of the events that stop the spinning reel?


Sorry, the events are in the green dashed screen

Try this, and see if it is smooth enough for you :

1 Like