Spin the wheel type game

Hi, im new to Unreall and wish to make a spin the wheel type game. I want the player to be able to spin the wheel and Get questions basen on where the wheel stopped.

I have tried to animate The material in BP but I need help with how I’m suppose to get the game to know where the wheel stopped or a better way to make it work.

Any help would be appreciated!

You need to do it in material? Not considering 3d at all?

Yea a 3D wheel would be much simpler.

You could do it mathematically by dividing up ranges of rotation into array slots,

but I think the easiest would be to add little overlap or collision volume components manually along the rim, and have another one stationary as the wheel marker, which would detect when one of those pins overlaps with it or stops overlapping. it could get their name and then access a map between the pin names and the questions or scores or other effects that each should cause.

You have to make sure collision is enabled on the cone. And make sure it is a type that will be overlapped by the collision boxes. So if the cone is a world static object make sure the collision boxes overlap world static objects. If you can’t get even a print string to fire off from an overlap then you have the settings messed up somewhere

ok, so i followed your tips and made the object rotate instead. I have also mad some boxes to detect collision with another Cone actor.

I’m having trouble getting the detection working. How can i go about this?

TY so much for your help! her are my screenshots.


256012-

I see your screenshot shows how to make the wheel spin but there’s nothing about handling the OnComponentBeginOverlap event. If that is absent, nothing will happen. If it is present, please show how you’ve implemented it.
Thanks :slight_smile:

I’m having some trouble with this. Should the overlapping occur in the “Wheel BP” or “Cone BP”?

This is what i have tried, but it don’t work they way it should.

Either the wheel or the cone can handle it but it is easier for me to think about it from the cone’s perspective. I would use componentbeginoverlap instead of actorbeginoverlap so that the event tells me which component just hit the cone, and we can choose what to do based on that. When you say your blueprint isnt working then do you mean the overlap event is not firing or the print strings are not printing or what? Have you tried putting a breakpoint on the event to see step by step what happens versus what you thought would happen?

Overlaps occur on both objects when one hits the other as far as I know. So just ha dle the overlap on the one that makes most sense to you.

Remember your collision channels need to be set up to match between both objects, object/collision type and channels of types it can overlap with. Also both objects need a component that has a collision primitive in it check the static mesh assets for both to make sure, although in the case of your wheel I am uncertain how it will go with the invisible collider components.

Make sure all the actors or components involved have their Generate Overlap Events checkbox ticked.

Everything works fine in the editor now. The wheel spins and a card is chosen based on the result of the spin. But somehow when i package the game my card animation don’t appear. The wheel spins, and then nothing.