Game Development Community

dev|Pro Game Development Curriculum

TGEA on OSX: 1.8 Out of the box impressions.

by Charlie Sibbach · 01/30/2009 (11:15 am) · 11 comments

My team just released the first demo of our game to the potential publisher on Tuesday, which is a major milestone for us. We're probably only 50% done out of the total workload, but it's been a big 50%, and knowing we'll have a publisher would make that second 50% go a lot quicker.

In any case, the game is based on TGE 1.5.0 (although it originally started on 1.3.?, and has been through two merge cycles already), and recently we've found that the performance of the game in a Windows debug build is attrocious, even though the Linux and OSX debug builds run great on similar hardware. I've been depending on that "Release Build" to be my final ace in the hole- we make it work OK in Debug, and we'll have a safety margin by going to Release. Given how much stuff is in the game right now, if we're already having performance issues, within a few more weeks it would be unplayable, let alone if it was completed.

Now, the engine has been modified quite a bit- but mainly in the vehicle physics, and support for a lot more weapons. It actually seems to be particle effects that are killing it; but our weapons are designed to be little more than blasts of particles, so having fewer of them is not an answer (especially given that it only takes two guns firing right now to drive the latency of a local game over the edge). But I can't rule out the possibility that it was something we did to the engine, somewhere along the line, possibly years ago, that laid the roots of what we're seeing now. Since I've heard that TGEA is supposed to be much more optimized throughout than TGE (which we'll get to in a second), and because my artists would wet themselves for shader support, we're considering a port to TGEA before we move forward with completing the game. It's probably going to set us back quite a while, as problem #1 is that we really don't know what we've changed (alot, here and there, poke and prod), and what GG has changed, and in particular, improved, in TGEA. So the plan, as it stands, is to take all the script code and put it on a fresh TGEA build, fire it up, and fix the first thing that breaks. Wash, rinse, repeat, until we are back to parity.

So, to determine if this is even worthwhile to attempt, I've bought, downloaded, and installed the new TGEA 1.8 for OSX. I'm using a 2.1Ghz Macbook Pro, Core 2 duo, with whatever graphics card they shipped with a year and a half ago. With TGE, it's been speedy, quick, and bulletproof- it's still a relatively high-end machine, damn it! First things first, I tried the "Build All Projects.command" script, which after reading the docs for a few minutes, seemed like a good idea, and it errored out without doing anything. Oh well, says I, it probably doesn't need to do anything on a fresh copy.

So, with bated breath, I fired up the T3D demo- let's see what this sucker can do. And.... I waited. It took nearly 30 seconds to fire up, and in the meantime, there was no loading screens, no splashes, just an empty white window up until when the main menu loaded. Well, it has a lot of DSOs to compile first time (subsequent restarts have not noticeably changed). On the main menu, it's already apparent something is not right in Mudville, the cursor is moving choppy. I entered the game directly. It took about a minute to load the game, after hanging on the end of "Loading Objects" for quite some time (Subsequent restarts have helped this, but mainly because the scene lighting is cached). And into the game I went. At a full 20fps. With a single player in the game. With a single DIF tower in the game and a few rocks. At 800x600 resolution. Moving around is pretty painful; the fps varies from 20 to 60, depending on if I'm looking at the tower or not, but even at 60 fps the movement and game is choppy to the point it's hard to play. The spaceman model is nice, they've included the jetpack mod by default, which is nice. But the rocket launcher you're carrying has no animation, which makes me sad. It ejects a nice, big, fat shell, but is otherwise pretty unimpressive. But what really boggles my mind is the thought, "The TGE 1.5 Stronghold demo looks BETTER than this!" There is just really nothing in this demo that captures the eye. But given as it seems to be a new demo level, I'm giving it a pass.

I escaped from the game, and went into the options, clicked Fullscreen, and turned the resolution up to 1440x900. There was no confirmation when I clicked apply; the button was pretty nonresponsive. It took me a while to get the game to actually change it's resolution, coming in and out of the dialog. Eventually, I got a full-screen window, with a nice titlebar and the menubar intact. Well, I expected that, I read somewhere that there are "fullscreen bugs" on OSX. Fortunately, it didn't seem to drop the framerate appreciably.

I dropped out of T3D, and went to see the other demos. The Stronghold demo looks, well, like the Stronghold demo. Yeah! The kicker was the "Forge" demo, which to date has refused to start and run. I just get a white window, and have to eventually force quit because it grabs my mouse. And then I went to work, where I'm writing this, to sit and ponder.

Without turning this into a rant, I have to wonder what's going on here. Everything I've seen so far has been a regression on my box. To say that I am let down is an understatement; I'm just short of devastated. Here I am, saving up my pennies for T3D for my next project once this one is out of the pipeline, and TGEA runs like this? T3D isn't even going to run on my computer at this rate, and it's only a year and a half old! This performance, along with the apparent lack of Linux support (Does anybody know how Hothead did this for Penny Arcade? Please let me know!) I'm having a real hard time justifying any further outlay of money on this product. Is this just Mac version 1 woes? What has been other people's experience? It's seriously making me reconsider the platform for my next project. Mac and Linux support are very important to me and my dev team; one of the primary reasons we went with TGE in the first place (a decision we've been very happy with to date), and the lack of those things in TSE and TGEA has pained me to no end. Is there a magic setting that I'm missing here?

GG, I'm waiting for 1.8.1. Please, please, please, prove to me that this is just version 1 blues.

P.S.: Rant time. This new project structure is baffling to me, because it extends and enhances one thing I thought was the stupidest part of TGE's layout- the idea of developing multiple games from the same codebase. Seriously now, WHO DOES THIS? I really can't fathom the logic in this; who's so hard up for hard drive that they can't keep two copies of the whole thing lying around? Who is out there making two games so similar that it even makes sense to share the codebase between them? About the only resource and code that my current project is going to share with my next project is the Advanced Camera, and probably not even that, because the camera is on the hitlist for things to fix/change in this game. Do you toolmakers out there, or the people putting together demos/cinematics/whatever, do this alot? Are they really that big of an audience that the whole engine should be structured around it?

Also, where's the Windows version of the tools in the Mac release? One of the brilliant parts of TGE has been that by tossing it into Subversion, I've been able to check out the same project on all three platforms, compile it, run it, and not change a damn thing, and even have all three versions of the DeleteDSOs scripts. The only thing I've had to do was keep the individual project files/make files up to date when I add new source files. I guess this new system will handle that nicely (supposedly; the script would have to work, which I'm not at all sure it does); but I've changed/modified at least as many core engine files as I have added new ones.

OK, I'm done. I'll check it out again after work. Maybe it will work better this time; I've trashed it on the internet and lowered it's self-esteem to the point it's going to work harder... One hopes.

About the author

Recent Blogs

• PeerConnection
• GuiLineCtrl

#1
01/30/2009 (12:46 pm)
Quote:
I've been depending on that "Release Build" to be my final ace in the hole- we make it work OK in Debug, and we'll have a safety margin by going to Release. Given how much stuff is in the game right now, if we're already having performance issues, within a few more weeks it would be unplayable, let alone if it was completed.
This is a terrible idea. You are making a huge number of very false assumptions. Compilers don't work like this...performance differences between debug and release are like comparing apples and some fruit nobody's ever even heard of. Adding objects to a mission in debug will produce a non-linear performance drop, which will be completely different than the much-closer-to-linear behavior of a release build.

It is not possible to get any kind of useful performance numbers (fps, profiling, memory usage) in a debug build.

Quote:
Rant time. This new project structure is baffling to me, because it extends and enhances one thing I thought was the stupidest part of TGE's layout- the idea of developing multiple games from the same codebase. Seriously now, WHO DOES THIS? I really can't fathom the logic in this
SVN externals/vendor branch
#2
01/30/2009 (1:06 pm)
I wouldn't be so quick to assume your Mac has a decent video card. It seems to me that Apple likes to put pretty shoddy video cards in their machines. I wouldn't be surprised (based on some quick searches) if the card in your Macbook is an Intel card or a very low end nVidia card.

The Penny Arcade games are made with TGE, as far as I know.

The default demo also has a MegaTerrain in it, which is almost certainly impacting the performance you're seeing. Delete three of them to get a more accurate comparison between a default TGE mission and the TGEA 1.8 mission.

I think you misunderstand the reasoning behind the new folder structure. There is now a "source" folder in each project folder. The idea being you put game-specific code into this folder, and make as few changes to the regular engine code as possible (unless of course the change is good for any of your projects). This separation IMO is a great thing. It's also pretty easy to safely ignore, if you only have one project.
#3
01/30/2009 (1:30 pm)
Quote:First things first, I tried the "Build All Projects.command" script

There is no buildAllProjects.command script, so I have no clue what you're running. Did you mean generateAllProjects.command?

Quote:errored out without doing anything.
The generateAllProjects.command script will fail unless you have PHP5, which came with Leopard. Are you still on Tiger? Tiger isn't supported.

Quote:I read somewhere that there are "fullscreen bugs" on OSX
Fullscreen was not supported on OS X in 1.8.0. It is supported in 1.8.1

Quote:Rant time. This new project structure is baffling to me, because it extends and enhances one thing I thought was the stupidest part of TGE's layout- the idea of developing multiple games from the same codebase. Seriously now, WHO DOES THIS? I really can't fathom the logic in this

Internally we've done things both ways, developing games on separate codebases and developing games on the same codebase. We've found that having games on separate codebases was a nightmare and cost us literally months because the different codebases would have some bugs fixed, others introduced, differing functionality and so on. Having our games on the same codebase has been a much smoother process and greatly increased productivity. So, to answer your question, we do it, because it saves us time, money, and effort, and results in more stable games.

You also describe a number of graphics issues, but provide no information about what graphics card you have or what OS version you are running. This information would be very helpful.
#4
01/30/2009 (4:47 pm)
Quote:
Rant time. This new project structure is baffling to me, because it extends and enhances one thing I thought was the stupidest part of TGE's layout- the idea of developing multiple games from the same codebase. Seriously now, WHO DOES THIS? I really can't fathom the logic in this

It's actually hard to fathom not seeing the logic in this. Most game studios tend to focus on certain genres of games, and games within a genre tend to share a lot of the same core features. So you manage your game engine code in one place, and you keep your game specific code separate from the engine code.

If you're developing completely unrelated games then it makes sense to keep separate engine code bases, but it's simple enough to just copy the entire directory structure without needing a tool to do it for you.
#5
01/30/2009 (5:09 pm)
Quote:One of the brilliant parts of TGE has been that by tossing it into Subversion, I've been able to check out the same project on all three platforms, compile it, run it, and not change a damn thing, and even have all three versions of the DeleteDSOs scripts. The only thing I've had to do was keep the individual project files/make files up to date when I add new source files.

What he said.

That is exactly how I used to do things too. It's A Real Shame that capability was jettisoned...
#6
01/30/2009 (6:49 pm)
What capability was jettisoned? He just described precisely how all of our internal games are set up, and how the engine is developed. So I'm a bit lost on why you can no longer do that.
#7
01/30/2009 (7:55 pm)
Alex, I didn't really mean to come off as sounding so bitter, and in some cases I was misinformed. For your reference, I'm using a Macbook Pro 2.16 GHz, with the ATI RadeonX1600 128mb, and yes, I'm running 10.4 still. And yes, I did mean the generateAllProjects.command script; I wrote while on break at work, and didn't have it in front of me to reference. And yes, going back to look at the requirements for the engine, my computer is underpowered. Given the relative age of my hardware (it was a high-end unit at the time!) and the flawless performance with TGE, I really didn't expect the requirements to have increased so much. The potential audience for a TGEA game must be much more limited than for TGE. And as a final bit of crow to eat, looking through it again, I do see the windows project files, I just can't find the related scripts (generateAllProjects.bat, for instance), so I suppose that the cross-platform development capabilities are not totally gone, but just need to be "augmented" a bit.

Pat, thank you for pointing this out and relieving my ignorance. While the idea that the release build is faster than the debug is true, I didn't realize that the debug build degrades non linearly, which does indeed make direct comparisons a tad meaningless. However, it also means that should I have been able to make it run quickly in debug, there's definately nothing to be lost in going to release build.

As to the rant about multiple games on the same codebase, I suppose it does come down to usage. This is my third project on TGE, and each of the past projects has been so vastly different from each other that maintaining any sort of common codebase between them was nonsensical for my use case. Each one had a wide variety of custom code, community resources and bugfixes, that basically made them mutually incompatible even if I had tried to share the engine.

Last, since you're in the thread, I just want to say Thank You to Alex- your contributions to this engine and community have been awesome, and I hope I haven't cheesed you off.
#8
01/30/2009 (8:33 pm)
Quote:Macbook Pro 2.16 GHz, with the ATI RadeonX1600 128mb
There was a bug on 10.5.6 that would cause the X1600 to lockup when rendering water, but that's been fixed in 1.8.1. However, we definitely require 10.5. Apple fixed a ton of driver bugs between 10.4 and 10.5, and we don't have the time to work around them to support 10.4 We barely have time to work around the issues with the 10.5 drivers :).

Oh, and my main dev machine at home is a 2.2Ghz MacBook Pro with a GeForce 8600 128MB, and 1.8.1 generally gets reasonable framerates.

Quote:I just can't find the related scripts (generateAllProjects.bat, for instance)
Really now? That is an issue. I'll look into what the packaging system is removing and hopefully the 1.8.1 update will contain those files on both OSs. Oh, and 1.8.1 also contains DeleteDSOs.command and DeletePrefs.command shell scripts.

Quote:This is my third project on TGE, and each of the past projects has been so vastly different from each other that maintaining any sort of common codebase between them was nonsensical for my use case
This is what we thought internally. Then we started hitting the same bug. Again, and again, and again. Repeat for many bugs. And features. And missing features. And then developers moving between games. As said, it really was a nightmare. I was porting all four of our internal games simultaneously, and I think that wound up being its own little hell because of the differences between the codebases. Certainly there are cases where it may not be the best approach, but if you maintain a clear separation between "This code is for my game" and "This code is for the engine" (very difficult with TGEA, I'll admit) there can be substantial wins.

Actually, I'm tempted to do a blog on how we structure our games internally and what the dev process is like on them.

Quote:I hope I haven't cheesed you off.
No worries. Your blog may have come off as a bit bitter, but your follow up post contains a lot of good and well expressed feedback, which is quite appreciated.
#9
01/31/2009 (8:32 am)
@Alex:
Quote:What capability was jettisoned? He just described precisely how all of our internal games are set up, and how the engine is developed. So I'm a bit lost on why you can no longer do that.

Perhaps I misunderstood the "all three platforms" part. I took it to mean Linux, OSX, and Win32. TGE still builds on all three. TGB jettisoned Linux build capability. TSE/TGEA is a recent arrival on OSX. And as far as I know, TGEA won't compile and run on Linux.
#10
02/01/2009 (2:27 am)
Quote:Actually, I'm tempted to do a blog on how we structure our games internally and what the dev process is like on them.

Please do. I enjoy reading developer blogs and such tremendously, and I am sure many others do as well. Especially GG blogs.
#11
02/01/2009 (9:51 am)
+1 to that.

@Alex, that would be a really interesting read.