Minalien.com
My brain makes things explode.
My brain makes things explode.
Mar 21st
Tutorial Description
In the last tutorial, we finished getting Direct3D set up, implemented a timer system to allow us to calculate the time between each frame, and set up the framework that will grant us access to our game without interfering with the core engine. In this tutorial, we are going to implement a reusable Scene Object class, which will be the parent for all future classes that we wish to enable in a scene manager. The scope of this tutorial series makes a full-fledged instance management system overkill, so we will not be building one in here. However, as this tutorial series will act as the base for future tutorials that will implement a scene manager, I am going to implement the scene object class here.
Downloads
Binary Only (18.8KB)
Full VS2010 Project Dir (28.4KB)
Starting Words
I just wanted to point out that this tutorial series borrows a lot of the structure of Jonathan Harbour’s Advanced2D game engine, from the book “Advanced 2D Game Development“. While I certainly believe it to be a wonderful book, and an excellent starting point for beginners (in fact, the reason for me borrowing the format for his engine is because I find the method well-suited for beginners), I find that I have a lot of personal quirks with Jonathan’s methods and programming habits, and there are a number of inconsistencies in it. Furthermore, there are some topics that are covered in the book that just aren’t well-suited for beginners, and can cause things to be a bit confusing and convoluted. In this tutorial series, I don’t plan to implement three-dimensional rendering, which he does cover briefly, and have no intention of including game scripting, though several more advanced tutorials will cover these aspects at a later date (read: when I stop being lazy). Anybody looking at learning to program two-dimensional games with DirectX and C++ should look into the book, but should remember that there will always be better ways to implement certain systems than what is shown to you in a book – or an online tutorial. Anybody that wants to gain a solid understanding and truly grasp the depth of these programming systems is highly encouraged to look up information on any subjects that they are unfamiliar with. I strongly recommend Safari Books Online – I read a lot of books there, and it’s certainly helped me improve myself. Advanced 2D Game Development is available on SBO, as well.
Notice: This tutorial continues from where “C++/D3D Pong Tutorial 02” article left off. Please read it if you have not already.
Mar 16th
Well, I haven’t exactly blogged much of anything in the past couple weeks, mostly because I’ve been side-tracked with a couple projects, such as the new website for the Keyboard-Failure IRC network (http://www.kbfail.net- or point your IRC client of choice to irc://irc.kbfail.net). You can see the new theme (which I think is a major improvement over the pink-background, black-text spawned by the lack of any desire to work to give KBFail a real theme/system. What can I say? We’re all lazy.) by going to the development page: http://minalien.dynalias.net/kbfail/. Guess when I get around to working on it, I’m going to install the newest Release Candidate of SMF for development/testing of the new site, and I’ll probably get around to rebuilding my old mod to integrate Alex Gorbatchev’s SyntaxHighlighter (which I use on this blog) sometime soon, too. Gods, I wish SMF were object-oriented. :P
It seems that I do actually have somebody paying attention to the Direct3D Pong tutorial series I’ve been writing. I kind of shrugged off doing much more work on the project because I didn’t think anybody was bothering to read it, but a recent tweet shows me that there is at least one person reading it. That, for me, is plenty – so @Ogreman, you can look forward to the next tutorial in the series to come along (hopefully) by the end of this weekend.
I’ve been going through some.. personal issues. Anybody familiar with my past will probably know what I’m talking about, so I’ll just kinda leave the details at that. Suffice to say that life is a pain in the ass, but I’m (uncharacteristically) looking toward the brighter side of things and moving forward with life. On the lighter side of things, my plans to visit Erin in Phoenix are going through, so I’ll be blissfully free of work and hanging out with a friend. I’ve been acting very out-of-character for me, recently. I mean, social activity? Something seriously has to be wrong with me. I think I broke my head. D:
Recently renewed my subscription to Safari Books Online – I pay for the $40-ish unlimited subscription, but they’ve got a $20-ish (monthly) ten-books-per-month plan. Very useful, and I highly recommend it for anybody who deals with technology on a hobby basis. Large collection of full books on there, ready for you to read on your computer at home, or even in mobile-optimized forms on your iPhone or (if you’re one of the cool kids, like me) Android or other smartphone. Anyway, I’ve been reading up and studying for the CCNA certifications, which I’m hoping I will be able to take on-base without first going through the “NCO” courses. In the worst case scenario, I’ll just find somewhere closeby off-base, probably in Los Angeles, to take it on my own. They’ve got a full collection of Cisco networking books, programming (including game programming) books for a large selection of languages (Obj-C, C, C++, C#, Ruby, Java, HTML/XHTML, PHP, ASP.NET.. you name it, it’s there). For those who can afford it and will use it, it’s much cheaper than buying each of the books separately, and much more legal (and less of a pain in the ass for searching) than downloading the books on your favorite torrent client.
Feb 20th
I’ve been looking at Box2D a lot recently, mostly because Torque 2D (Torque Game Builder’s replacement) is going to be using it. It’s a damn good, and powerful, two-dimensional physics engine -- it’s what powered Crayon Physics, and several similar physics-oriented games. Box2D is a pretty beautiful thing, from what I’ve looked at, and it’s been ported to a lot of systems. Recently, I found a Torque Game Builder integration for it, and figured I’d look into it. Currently, it’s integrated into the Torque Game Builder editor, and still allows for the use of the standard TGB physics (you cannot have both Box2D and TGB physics on the same object, however). The system comes in the form of a class that needs to be set on the Scene itself, and behaviors that you add to objects. The system uses the object’s convex collision polygon, as well.
Video
Screenshots of the Pyramid Test
Stacked Pyramid
Tumbling Pyramid
TGB/Box2D Integration Links
Torque Game Builder 1.7.4
Box2D implementation
Feb 18th
Well, Aliens vs Predator was finally released two days ago, and I hadn’t noticed. Started downloading it the night it was released, rather than the day. Anyway, started playing it last night, and this morning, and I’m loving the game. The demo wasn’t all that great, I’ll admit, but that’s mostly because Free-For-All in the AVP setting is pointless. To really enjoy the game, you need a Team Free-For-All, with each team being one of the three races in-game (Xenomorph, Predator, or Human). Although I have to say, playing as a Human/Marine in the multi-player game modes is very masochistic. Think about it – as a human, you lack the badassery of the Predators, which includes vision modes specifically designed to help hunt humans and Xenomorphs (believe me, in the dark multi-player levels, Xenomorphs are hard as fuck to spot, harder yet to kill, and don’t even think about catching one if they decide to sprint away), you lack the cloaking, so you’re easy as hell to spot, no matter where you are (again, the Predators can spot all humans with one visor mode, and the Xenomorphs (aliens, for anybody who hasn’t figured that out yet) can track you by “scent” – which, in gameplay terms, is an outline showing where you are. Unlike the Predator’s visors, though, Xenomorphs can see you even through walls), and if you aren’t with a group of friends – well, count yourself among the dead. Because that’s really the only opportune time to kill either of the opposing races – if they start to take out one of your buddies.
Playing as the Xenomorphs, in multi-player especially, but single-player as well, can get disorienting fast. You see, Xenomorphs can run on walls, and can jump from one wall to another. And they’re fucking fast. If I, as a Xenomorph, get injured and need a quick escape, I hold my sprint key and just fucking run. There’s no way that either a Predator or a Human will be able to catch up to me – especially if I’m switching between walls, ceilings, and floor, and jumping from surface to surface. But, as I said, this has the disadvantage of being severely disorienting, however incredibly bad-ass it may be.
Playing as the Predators is amazingly fun, especially in the multi-player games. While you can be seen by humans when your cloak is engaged, they’re usually twitchy as hell and won’t spot you well in the shadows. Xenomorphs still have their scent-tracking thing, and will spot you just as well as they’d spot a human, but you’ve got auto-tracking, shoulder-mounted badassery in the form of a laser gun that is fast enough to track them, provided they don’t jump behind a wall or into a vent. You’ve also got proximity mines, and a few other useful tools, and no player will be too happy when, out of nowhere, in spite of their vigilance, they’re blasted from behind by a laser cannon from a creature they can barely play. But hey, if they’re masochistic enough to play as humans in multi-player, that’s their own damn fault. Who wants to play a pathetic human when you can play incredibly-advanced alien hunters (I guess that human’s aren’t the toughest prey anymore) or incredibly-deadly alien beasts, anyway?
In short, if you have the chance to buy it, whether it’s for PC (where I play), XBOX 360, or some other platform, I highly recommend it. If you do get it on PC, don’t be a puss – buy it over Steam, not at a store, and hit me up for a game.
Feb 16th
Well, I’ve come to the conclusion that I need to stop being lazy and get some work done on the OS X port of Waxy’s Sushi Party. So, for the next couple of nights, I am going to start working my ass off to get an early prototype ready.
This means a lot of playing the game, taking notes, and fucking around with Torque Game Builder for me, and nightly development blog entries for the whole.. two or three of you who read my blog. Yeah, so, enjoy. >.>