Looking for tips on making a 3d "Breakout" protoype
by Blake Drolson · in Torque Game Engine · 07/21/2006 (7:04 pm) · 3 replies
Hi there everyone,
I am a veteran game coder, and I am fairly new to the torque engine. I am impressed with the engine and have been studying hard to try and really learn the codebase and scripting system (its BIG). I have completed the GPGT book and lessons, reviewed the starter scriptbases, skimmed over the c++ code base, and tried to read many of the online docs to try and make sense of it all. Now I feel I should dive in and start on a prototype, and since I wanted to see how torque handled making any type of game, I thought a 3d "breakout" prototype might be simple, fun, and also a challenge because the base engine might not handle everything out of the box.
So now what I am looking for are some tips on the "best" way to implement this prototype, in terms of where to make changes, in order to create the basic prototype I am thinking about. I am sold on making the game in script if I can, but I am comfortable with making changes to the C++ code as needed.
Basically, I see a ball rolling over a 3d terrain, with very little friction, a minimum velocity, and being confined inside a box on the groundplane. The ball can bounce over hills etc, but cannot leave the play area. At one end of this box would be the bricks that the player would try to have the ball smash into, at the other end would be an area the player could move a paddle around in that would deflect the ball back up at the bricks, with a bit of direction based on where it hit the paddle. If the ball goes hits the boundry behind the player they lose a life and a new ball is spawned until the game is over.
So questions that come to mind.....
1) How to implement the ball rolling around? Will this take a new c++ class, like wheeled vehicle? Can I do it in script?
2) How to implement the paddle? I dont want a player that walks, runs, etc. I want the paddle to face the same direction at all times. Do I just use a static 3d shape, and turn off animations? Can this be done completly from script?
3) What about the boundries? Should I use P zones? This seems scriptable, is it? I envision having a force field appear when the ball hits a boundry (zap!), I am thinking this is completly scriptable too.
Would love to hear where you think I might concentrate to make this prototype and any other thoughts you might have. Once I get the basics down, I could start having fun with power ups, particle effects, ramps, a jumping paddle, etc. Thanks in advance for any help offered.
Peace,
Blake
I am a veteran game coder, and I am fairly new to the torque engine. I am impressed with the engine and have been studying hard to try and really learn the codebase and scripting system (its BIG). I have completed the GPGT book and lessons, reviewed the starter scriptbases, skimmed over the c++ code base, and tried to read many of the online docs to try and make sense of it all. Now I feel I should dive in and start on a prototype, and since I wanted to see how torque handled making any type of game, I thought a 3d "breakout" prototype might be simple, fun, and also a challenge because the base engine might not handle everything out of the box.
So now what I am looking for are some tips on the "best" way to implement this prototype, in terms of where to make changes, in order to create the basic prototype I am thinking about. I am sold on making the game in script if I can, but I am comfortable with making changes to the C++ code as needed.
Basically, I see a ball rolling over a 3d terrain, with very little friction, a minimum velocity, and being confined inside a box on the groundplane. The ball can bounce over hills etc, but cannot leave the play area. At one end of this box would be the bricks that the player would try to have the ball smash into, at the other end would be an area the player could move a paddle around in that would deflect the ball back up at the bricks, with a bit of direction based on where it hit the paddle. If the ball goes hits the boundry behind the player they lose a life and a new ball is spawned until the game is over.
So questions that come to mind.....
1) How to implement the ball rolling around? Will this take a new c++ class, like wheeled vehicle? Can I do it in script?
2) How to implement the paddle? I dont want a player that walks, runs, etc. I want the paddle to face the same direction at all times. Do I just use a static 3d shape, and turn off animations? Can this be done completly from script?
3) What about the boundries? Should I use P zones? This seems scriptable, is it? I envision having a force field appear when the ball hits a boundry (zap!), I am thinking this is completly scriptable too.
Would love to hear where you think I might concentrate to make this prototype and any other thoughts you might have. Once I get the basics down, I could start having fun with power ups, particle effects, ramps, a jumping paddle, etc. Thanks in advance for any help offered.
Peace,
Blake
#2
I hope it is fun :).
07/22/2006 (2:54 pm)
Thanks for the feedback badguy, will look into doing my ball and paddle in the C++ code, and see if I cant do the rest in script.I hope it is fun :).
#3
07/22/2006 (9:14 pm)
For protyping anyways, you can probably use a player just fine and remove the keybinds for turning. Kork Pong 20XX 3D!
Torque Owner Badguy
but I would recommend c++ for the ball class like your wheeled vehicle idea.
you can utilize the scripts for callbacks to your paddle.
boundaries should be fun. I think the ball should handle it, just draw a cool looking explosive type patch when it hits the box.
so code that support into the ball class, and enable disable it on collision in the scripts if you like.
but honestly. some cool code should go into the paddle.
and it should be a c++ object as well :)
just my 2 cents of course. you could prolly drive the whole thing in the script if you wanted to.
but I dont think it would be as cool.
this idea sounds like fun :)