Game Development Community

dev|Pro Game Development Curriculum

Plan for David "FenrirWolf" Grace

by Fenrir Wolf · 06/01/2004 (3:07 pm) · 4 comments

What I did this weekend...

1. Created the new official Giant Robot Monster title screen. Here, take a look:

www.gapingwolf.com/torque/grm_title.jpg
1. Learned that the MountedImage code is replicated in both the Player.cc and in ShapeBase.cc. Not sure why this is so, but I figured this out when modifying the engine to support the "firstpersononly" flag for mounted images. (The datablock values were already there, but the actual logic for the rendering routines weren't.) This isn't entirely working correctly, as you can see here. It still shows up on multiplayer models, making me suspect that the flag isn't being propagated to all of the client objects properly.

www.gapingwolf.com/torque/grm_ss1.jpg
2. Got a glimpse of how the network syncing code works. I wanted to add the ability for objects to shake when they get damaged. This meant not only adding the necessary rendering stuff in ShapeInstance, but I also had to modify ShapeBase to keep the client and server objects syncronized. (Since the client only cared about the animations, while the server only wanted to know how much of the effect to apply.)

www.gapingwolf.com/torque/grm_ss3.jpg
3. Figured out stateTransisions work, and a basic idea of how to put together mounted image states.

4. Implemented a very simple melee system. (It only casts a single ray out from the eye, and anything that intersects it hits. So, no wide-swing damage -- dunno yet how to work around this.)

5. Added explosions back into Shapebase, so that they can be called now for any generic object. (Currently, all I've got is a console-exposed "blowup()" method on ShapeBase that lets you destroy an object any time you want.) Also fixed some odd, bogus code that was causing explosions not to start properly on the client. I heard mention on the boards that spawning explosions outside of the projectile class causes Torque to crash in multiplayer, but I tested this out with two clients/one server and couldn't replicate it.

www.gapingwolf.com/torque/grm_ss2.jpg
6. Modified the crosshair so an object's health and name shows up when you hilight it. I might take this out in the future if I decide to implement visible damage. (ie: Buildings start to sag as you beat them up.)

7. Put together some simple test buildings. They're very simple, just some boxes with a single texture applied to them, plus four internal bones to animate the sagging that occurs when you destroy them. The result looks pretty cool.

8. Tried to add blend animations for the punching (for the 3rd person views), but PlayThread doesn't seem to want to play a single-fire animation sequence more than once. Not sure what's going on here yet, though I did some code tracing. Everything seems to fire off properly, but the animation doesn't actually show up.

All in all, a very eventful three-day weekend. I've got a short video of the game in action, so you can see how the shaking and explosions work. I think it looks pretty keen, but I am biased. :)

Short GIANT ROBOT MONSTER play demonstration (900k)

Hope you enjoy! (PS: Normally your fists don't do that much damage, but I jacked it up in order to test the smoke/debris effects. Yes, I went a bit overboard!)

#1
06/01/2004 (10:45 pm)
Hey, just watched your video. That's pretty cool!

You might want to consider putting the light pack in there. I think it would make stuff look a LOT more real. Also, ground transforms would probably help your walk cycle look better.

playThread should work - you might have to reset the thread, though, when you start it up again.

Good luck getting everything else solved. :)
#2
06/01/2004 (11:40 pm)
David,

Did you get my email?

Joe
#3
06/02/2004 (9:25 am)
@Joe: Yes I did! Thank you, I was eager to see how the files were put together. I heard in some thread on here you guys didn't use SORT:: and simply carefully placed the polys in such a way as to get around alpha-sorting issues.

@Ben: Thanks for the compliments... I spent most of the weekend working on this. A lot of the art is temporary, like the animated fists, buildings, and so on. I'm just more concerned about getting things into the game and working, I will go back and clean them up afterwards. And yes, the Lighting Pack is enabled in that video, but I didn't put it to any good use. :)

I'll give PlayThread another shot, but my experience is that once it fires an animation (that isn't cyclic), it won't start it again. Even if I do something like, %player.stopThread(1) and then %player.playThread(1, "anim"). Not sure what's going on here...
#4
09/21/2004 (6:45 am)
To deal with the playThread problem, call the stopThread function ( eg. %player.stopThread(1); ) when the animation is finised. However don't call the next playThread function directly after the stopThread function, you've got to leave a bit of time between the two or else it won't work. This fourm thread may help: http://www.garagegames.com/mg/forums/result.thread.php?qt=18577