As a game developer, you'll be happy to know that Nokia's new N-Gage Series 60 game phone lets you easily develop 3D games. In fact, celebrated game designer John Romero used X-Forge, a 3D engine available for N- Gage, to create great graphics for the N-Gage version of Red Faction. Why should you care? Because Nokia designed N-Gage to be a game developer's mobile-platform device of choice. Wireless Elite columnist John Papageorge spoke with John Romero about designing 3D games for N-Gage. Find out what he discovered.
Will mobile phones soon bring game fans Doom-like satisfaction? Game designer John Romero thinks so. The outspoken game-development heavyweight bets gaming fans will be knocked out by the killer game action and cool 3D graphics on the mobile game adaptation of the classic shooter Red Faction. Romero's work on Red Faction for Nokia's new N-Gage Series 60 game phone revealed numerous tips and tricks for making compelling 3D games on mobile devices.
Romero formed Monkeystone Games in July 2001 with former Ion Storm colleagues Tom Hall and Stevie Case. The company develops and publishes interactive entertainment for mobile devices, PCs, and major video game consoles. Monkeystone's principles boast more than 50 years of combined experience in game creation, running from concept to market. They've helped create such mega-hits as Wolfenstein 3D, the Doom series, Rise of the Triad, Duke Nukem, Quake, Anachronox, and Age of Empires.
Monkeystone focuses on games for handheld devices including Pocket PC, Palm, mobile phones platforms including J2ME (Java 2 Platform, Micro Edition) and Qualcomm's BREW, Symbian devices, and Nintendo's Game Boy Advance. In fact, Monkeystone received praise for its Hyperspace Delivery Boy!, a unique action-puzzle game for the Pocket PC. The company plans to release more games for wireless platforms in 2003. Monkeystone's proven development process produces recognizable IP (intellectual property) in the form of game characters and attributes exportable into other forms of entertainment.
"[Monkeystone's] strengths come mainly from experience in creating games over the past 20+ years and the fact that we are proficient on just about every gaming platform that exists," says Romero. "The vast majority of our careers have been spent creating original IP as opposed to developing licensed titles, so we are strong in creativity."
3D with N-Gage
Romero believes that the N-Gage platform has shocked developers in the industry. "The game industry was not prepared, not prepared at all. Everyone thought that the mobile future was still a ways off, with everyone playing games on regular ol' cell phones," says Romero. "Nokia's announcement of the N-Gage showed everyone that wireless gaming was real, it was serious, and it was here now. I love the N-Gage for this reason: It quickly ushered in the age of wireless gaming because the 'Nintendo of Cellular' was behind the concept."
Romero says that N-Gage presents fewer challenges than developers might first think. In addition to featuring the most power in a cell phone today, Romero says N-Gage boasts: "[A] fast processor, plentiful RAM and storage memory, and a great-looking screen."
According to Romero, the secret to real 3D on N-Gage requires two fundamental game development ideas: streamlining and optimizing. "You can't go crazy with the polygons and textures like you can on the PC," he says. "But this gets your game down to its essence, its strengths. And 3D games are processor intensive, especially so for a cell phone, so we work mainly on speeding up the game."
Romero wants Red Faction fans to know that his team implemented most of the weapons, 12 of the levels, and many of the enemies. "The Bluetooth death match is something that I've never experienced before, so that's exciting," says Romero.
By all signs, the N-Gage Red Faction adaptation should rock just as hard as the original PC version.
X-Forge
Romero wears his opinions on his sleeve and doesn't suffer fools lightly; therefore, pay attention when he insists that X-Forge, designed by Finland's Fathammer, surpassed his expectation for 3D graphics. "X-Forge is a very sophisticated 3D engine, and it's very powerful," says Romero. Because of the features set, Romero admits that it took time to learn all it could accomplish, but he adds that the studying was well worth it.
Romero generously offers this tip to game developers: "With X-Forge, it's easy to add special effects to your models, like we did with the flaming exhaust from our rockets," says Romero. First, he says, he loaded images into thingamajig (an X-Forge tool), which became the particles. "Once you have those images, through the texture panel you can load these files into thingamajig, and set them to different types of blending modes (we used additive) in the blending panel," he says.
According to Romero, because the hardware can't support hundreds of particles, he dropped the emission rate in the emitter 2 panel, capped the maximum particle amount, and also set the maximum lifetime. "In the launch panel the velocity was set to a negative value along the x-axis, which in our case shoots particles back towards the player," he says. "The two remaining variables to be set are damping and z rotation, which can be found in the damping and sprite panels, respectively. The damping values slow the particle's momentum based on particle age, and z-rotation spins the sprite two- dimensionally. This particle system was then referenced in 3D Studio Max using a helper node, which was parented to our rocket geometry."
Important tip: With X-Forge, do as much work as you can in 3D Studio Max. The X-Forge engine likes using 3D Studio Max data much better than if you hand code new objects into the game.
Romero praises Fathammer's support, "But since they're in Finland there's a nine-hour time difference for us here in Texas, so if you need an answer immediately, prepare to stay up until 1 a.m. onward. That's probably the only weakness I can muster. It's really amazing what this engine can do on the N- Gage."
As for the N-Gage, Romero's only real criticism concerns the location of the MMC chip; however, he adds, "I really think it's a great device."
Mobile game development tips
Romero believes that game design experience on the PC platform helps when creating games for mobile devices. "A fair amount of [game] experience really helps you to stay away from dead-end designs and making bad decisions," he says. "Knowing how to squeeze a lot of fun out of almost nothing is pretty important in this space, as the limitations of mobile devices require very small games. For instance, most J2ME games are 64 KB or less."
If there's a single important trick or tip in mobile gaming development, Romero says you should boil everything down to the minimum work necessary to perform the task. For example, he says not to create an engine to implement a menu system. "Just blast it in there and finish it already," he says. "Move on to other things. Get your game done."
Romero believes that developing a game using a PC proves far different than getting the game running on the actual mobile device. "If you don't have your Symbian build process down pat, it can take several hours just to get your game compiling and able to transfer to the device," he says. "The Symbian build process is pretty complicated. Also, if you create a SIS file for your game and it's over 2 MB, forget making it an SIS because it's too big for the N-Gage to unpack [at the time of this writing]. Use the USB cable to transfer your game files manually to the MMC instead."
Romero says that if you use Internet or Bluetooth networking, you must include the line xfcUseNetwork(1); in your xfcAppInit() method. The (undocumented) code segment below proves crucial:
Listing 1. Include xfcUseNetwork;
INT32 xfcAppInit()
{
// init default core features
xfcUseDefaults();
// init networking
xfcUseNetwork(1);
// Create an instance of the application class
RedFaction::create();
return 0;
}
Another X-Forge tip, according to Romero: store your game's global data in your GameFlowManager class. Make it your central repository for things you
want to get at quickly. When you ::create an instance of a class, always pass the pointer to your GameFlowManager and store it for later use, Romero suggests.
To implement a class for triggers that the player would walk into and trigger a game event, you must walk through a collision list to see what kind of trigger the player hit, said Romero. Here's the code that figures it out:
Listing 2. Collision list walk-through
void RFTriggers:

{
if (mCollisionInfoList != NULL)
{
XFeCollisionInfo *collisionInfo =
mCollisionInfoList->getFirstNode();
while (collisionInfo != NULL)
{
// Figure out what we collided with
XFeCollisionInfo *nextCollisionInfo =
collisionInfo->getNextSibling();
// Figure out what we collided with
XFeNode *node =
mGameGraph->getNode(collisionInfo->mObjectId);
INT32 nodeType = node->getType();
switch( type )
{
//---------------------
// LEVEL END TRIGGER
//---------------------
case LEVELEND_TYPE:
if ( nodeType == PLAYER_TYPE )
((Player*)node)->setLevelFinished( 1 );
break;
}
collisionInfo = nextCollisionInfo;
}
}
}
Predicting the future
What does the future hold for mobile gaming? Hmmm. Romero admits it's hard to predict how the mobile game market will prevail in terms of multiplayer functionality and 3D capability. "I don't know," he says. "All I can do is my part in furthering 3D games on mobile devices and see where it goes. Incorporating the strengths of wireless are pretty important to developing this segment, I believe."