Hi, guys.
I've only programmed with Irrlicht a few times. Not a really experienced Irrlicht programmer. Just got a problem.
One of my client asked me to write a 3d roulette program, I suppose they're probably running an online casino or something. Anyways, that's not my concern, I just want to do my job.
I guess it wouldn't be that hard just to have a roulette spinning and put a ball down there and let it roll. And leave the collision detection to Irrlicht. The thing is, my client ask for the ability to control the result (dirty bastards). That means they want to control who wins at the end. I told them if they want to make this in real 3D, then everything is calculated at run-time, which includes where the little ball is gonna stop, too. They said they don't really care how I do it as long as I get the job done.
So, is it possible to do this? or is there any other work around?
Please give me some advice, thanks guys.
need help with 3d roulette
Devil, I deal with clients like this all the time.
THEY DONT WANT 'REAL' 3D. When they say 3D, they mean ONLY the graphic rendering. They are not talking about physics in any way. You could make the spin an animation and they'd be fine with it. (If you're going to deal with clients, you need to be able to understand when they use buzzwords and what those words mean to THEM and not to you.)
Your best approach is probably just that, set it as an animation where the ball bounces and rolls in its own animation space.
Then you have an animation for the wheel where it turns around then slows down to a stop.
When you put them together, it looks like the ball is spinning and bouncing and stopping on top of the wheel.
In this way you can change the orientation of the wheel before it spins so that it will stop at the place on the wheel that you want it to. (which is basically what Rambus stated)
To make things a little more elegant, you can even have several animations of the ball (with slightly different bounces) as long as the animation ends in the same place and spins as the same rate as the wheel.
THEY DONT WANT 'REAL' 3D. When they say 3D, they mean ONLY the graphic rendering. They are not talking about physics in any way. You could make the spin an animation and they'd be fine with it. (If you're going to deal with clients, you need to be able to understand when they use buzzwords and what those words mean to THEM and not to you.)
Your best approach is probably just that, set it as an animation where the ball bounces and rolls in its own animation space.
Then you have an animation for the wheel where it turns around then slows down to a stop.
When you put them together, it looks like the ball is spinning and bouncing and stopping on top of the wheel.
In this way you can change the orientation of the wheel before it spins so that it will stop at the place on the wheel that you want it to. (which is basically what Rambus stated)
To make things a little more elegant, you can even have several animations of the ball (with slightly different bounces) as long as the animation ends in the same place and spins as the same rate as the wheel.
a screen cap is worth 0x100000 DWORDS