ball rolling example, no python used, fake stencil shadow

Here is a setup i made last night for a ball rolling game test.

WSAD to control the ball and space to jump.

There is even a funky fake shadow effect under the ball.

you can only jump if the ball is on the floor… you can only roll if it is on the floor.

When in the air I added some simple controls to give the physics a somewhat mario64ish feel.

the controls have 8 directions.

To roll the ball properly I had to make a floor material with a friction of 10, and the roll damp set to full on in the dynamic game buttons. for the movement I used the angV to the global X,Y,and Z directions. Avoid useing the roll and torque it makes the ball very hard to control.

the jumps are all done with linV, and the air controls are all done with force.

Enjoy :smiley:

Version 1

Version 2, 8 directions rather than 4

Version 3, Stencil shadow hack

Version 4, shadow fixed, nice looking scene

This Is Awsome!

Cool Blenderizer!
Glad you like it… You enthusiasm got me to get off my ass and add the other 4 directions, and to make the floor with a grid on it.

here is the file

ball is much more reponsive now…
To get the diagonal movement I just added a combination of directions in the motion actuator
so up and left, up and right, down left and down right where added.
I also added the 4 new diagonals to the jumping directions.

The airwalking was not changed because I used force and the BGE allows you to add 2 diffrent motion actuators together, where as when you use LinV you must only use 1 block with a combination of X and Y .

who knows I might make a few levels and a couple of bad guys

i dont know much about the BGE, but did you use python scripting or any other plugin?
how did you make it keep on roling?

This example is 100% python free.

In the motion actuator, I used the angV to make it roll and move in the desired direction

cool. i was wondering. can you use this same function for drifting

Sure just set up the condition you want it to drift in that direction instead of where I have the keys pressed .

if you remove the roll dampening from the dynamic buttons it will drift quite a bit more than what is happening, now automatically

Ok ,

This is pretty cool I got the shadow to somewhat stay on the floor and change its scale when the ball is in the air.

needs a bit more work but the basics are all there, I need to make it more elaborate so that the shadow is more responsive , and smoother moving.

Wow, I looked on the forum page and thought this was by some noob who was excited that they got a ball to roll, but this is really kool and looks far more than it sounds like!

Hi The Red Hand,

Glad you like it!
as for the N00b comment, I just added a quick screenshot and some nice FX, so it dont look too noobish :smiley: (Thanks! )

The new file here:

It never did look n00bish. The name of your thread was misleading…

Nice looking walls and stuff, they change, but how? Fancy Shaders?

hi The Red Hand,

It is a texture set to reflection…

Just make a material with a texture, and rather than telling it to map to the UV channel I told it to map it as a reflection:

It is a great feature we have! Great for glass effects.
TO get the rainbow effect I just made an image in GIMP with a transparent background, and use the filters>noise>hurl on the default settings, and saved it as an alpha masked PNG file.

BTW I am the one who felt it looked N00bish, I made the snapshot to help un-mislead people I fooled with my title :smiley:

have a good day :smiley:

Wow, GE is a little more than I thought it would be. I didn’t think there was much to do in the Materials tab.

Hmmm that shadow is complicated… Very clever - I looked at it and then I decided I couldn’t be bothered to figure out what all the logic bricks do…
Really liked the reflecty wall as well. I’ve been playing with Ashsid’s videotexture player in reflect mode… its a bit weird