Game Development Community

Suggestions for beginner please

by Aaron Shumaker · in General Discussion · 12/26/2004 (5:11 am) · 4 replies

Well, I deleted my post so that I could repost in the public forum as you suggested, but it appears that the post has already been moved. I had copied it to the clipboard, but lost it in the process of trying to figure out what was going on. I'm pretty sleepy right now, but I'll make another futile attempt.

Me and my bro are going to make a sim of the classic game of marbles. Initially nothing more than shooting a marble into a ring of marbles and trying to knock a bunch out of a circle. The impression I got from reading some of the documentation is that one should be able to make a game without editin the source code, but it appears in this case I will need to implement physics of a marble as a class in the engine.

I made a copy of the wheeled vehicle header and implementation files and renamed the class and files as a Marble class, and changed the racing demo scripts to use the marble class. Of course this is nothing more than a name change, but I'm trying to piece by piece replace wheeled vehicle specific code with marble specific code. I figure some of the physics and properties of a tire can be used for a marble.

(I got a little distracted though, when I discovered how to set the tire friction levels and engine power levels so that my buggy could pop some awsome wheelies. LOL)

warpy in IRC chat suggested a better solution would be to use the Open Dynamics Engine (ODE). I'm afraid though that the time required to integrate ODE into the game, learn that engine in addition to the torque engine, and then creating a ODE marble may be more trouble than just implementing a marble class.

If anyone who has experience along these lines could provide suggestions, it would be apperciated.

#1
12/26/2004 (5:11 am)
I think this will get a much better response from the Torque Public Section of the forums.
#2
12/26/2004 (8:46 am)
My suggestion would be to make a class similar to Item. Thy physics of Item are simple enough to easily understand, yet have enough complexity to do whatever you need marbles to do. I am using a modified Item class now for a rolling ball, and it has been working perfectly.

You can use the function applyImpulse to give the items some movement and test it out.

Good luck!
#3
12/26/2004 (5:15 pm)
Hi Aaron,

Sounds like an excellent first project. It's very smart to start with a fairly simple game design.

Did you read the chapter in our docs discussing what we did with MarbleBlast?

That chapter answers your question pretty much directly. :) The marble in MarbleBlast is derived straight from ShapeBase. Josh is basically correct too... if you go this route, the Marble class will end-up looking somewhat similar to Item, in that it's a lightweight extension of ShapeBase.

You could use ODE, but your instincts are correct, it'd be a bit overkill. At least, get your prototype up and running with simple custom physics, and then if you want to get fancy you can work on doing neater physics stuff later.

Hope you have fun learning the engine! We like to say that making games is the funnest game in the world. (Though, it can certainly be frustrating at times, especially when you're just starting out. :)
#4
12/26/2004 (7:30 pm)
Thanks alot, Josh and Josh, lol.