Categories
Game Design Game Development Games Geek / Technical Linux Game Development Personal Development

LD#11: Breakfast of Champions

After a quick shower, breakfast!

A banana, some cereal with almond milk, and a peanut butter and raisin and pickle sandwich. I washed all that down with a glass of orange juice (not pictured):

LD11 Saturday Breakfast

Now back to the competition!

Categories
Game Design Game Development Games Geek / Technical Linux Game Development Personal Development

LD#11: Good Morning!

After spending the evening trying to figure out what to do, I went to sleep.

Some of my ideas:

  • Ikebana (thanks, Mandy!)
  • Avoid the Ball
  • Avoid the Walls
  • One Shot Space Invaders

The first one involves the Japanese art of flower arrangement, and it would seem on paper to make a good game, but I am not sure how I would go about making it in 48 hours. The last one is the idea that instead of having unlimited shots to kill Space Invaders, you get only one. You have to depend on a chain reaction explosion to kill them all, so it would be more like a puzzle game. The middle two seem the easiest to make, so I might stick with them since I need to spend a bit more time just getting my code base working than most of the other contestants.

It seems that minimalist games can sometimes be very complex things to create.

I’ll take a quick shower and have some breakfast, and then it is back into the thick of things.

Categories
Game Development Games Geek / Technical Linux Game Development Personal Development

LD#11: It begins…with dinner!

My girlfriend offered to cook me dinner for LD #11, and I am really glad she did. Otherwise, I probably would have made a sandwich.

The beautiful and lovely Mandy at work:
Mandy Makes Me Dinner

The meal. Rice and stir fried chicken, broccoli, zucchini, carrots, garlic, and shitake mushrooms, topped with chopped spring onions and nori strips, washed down with Sapporo beer:
LD11 Friday Dinner

The meal “minimalized”:
LD11 Friday Dinner

Categories
Game Design Game Development Games Geek / Technical Linux Game Development Personal Development

Ludum Dare #11

I will be participating in my first Ludum Dare competition. From the FAQ:

Ludum Dare is a regular community driven game development competition. The goal is, given a theme and 48 hours, to develop a game from scratch. Ludum Dare aims to encourage game design experimentation, and provide a platform to develop and practice rapid game prototyping.

The last time I participated in something like this was June 2005’s Game in a Day, which didn’t go as well as I expected, but I was warned properly. Still, it was fun, and I learned a lot.

The theme for LD #11 won’t be announced until later tonight, when the contest begins. Then I’ll have 48 hours to come up with a design and make a game. There are a few guides out there, such as sol_HSA‘s and MrFun‘s. Generally, to prepare for a grueling 48 hour contest, I need sleep, food, and prepared tools.

The latter is where I think I might falter. In the past few months, I’ve learned that continuing to use the Kyra Sprite Library is more of a detriment than a help. I would rather not use it for newer projects, and if I am not going to use it, I can use libSDL directly. Kyra provided a lot of functionality, such as loading sprites with named animations, dirty rectangle updates, and collision detection. I intend to go without it, especially since I would like the game to be ported to Windows much more easily, and Kyra is giving me enough headaches trying to port it to older Linux-based distros. Since I am not using Kyra, I am worried that I will spend more time trying to implement technical details than making a game. Game in a Day kind of went like that for me, and so I think this time I shouldn’t worry about a complex design. And I should make sure that any simple designs are actually, truly simple.

Other preparations for this weekend include buying kitty litter, cleaning my apartment, and buying groceries.

Keep an eye on my LD blog posts. I will try to cross-post.

Good luck to all of the LD #11 participants!

[tags] game development, video games, competition, contest, ludum dare, tools [/tags]

Categories
Game Development Geek / Technical Linux Game Development Marketing/Business

Linux Game Development: GLIBC_2.4 not found

The following describes a GNU/Linux game development problem I am still tackling have solved, although I’ve made progress and learned a lot. Hopefully the following information can be useful to you.

The Problem

A few weeks ago, one person informed me that Killer Kittens blew up on his Debian Stable machine:

./killerkittens.bin: /lib/tls/i686/cmov/libc.so.6: version `GLIBC_2.4' not found (required by ./killerkittens.bin)

Most of the dependency issues I’ve encountered involved changing flags used in my libraries, such as libSDL. Unfortunately, this issue was different. It was strange because I wasn’t sure why my game was depending on GLIBC_2.4 since I wasn’t explicitly linking to it.

Why This Problem Exists

Since then, I have learned that this is a common problem for GNU/Linux developers, especially when using C++. By default, the linker will use the latest versions of functions you are using. Let’s say that you used gcc v2.94 on your Red Hat 6.1 machine to create your binary years ago. It will link against version 1 of a function. Well, that binary will continue to run on newer systems since version 1 is kept around for backwards-compatibilty, which explains why older games such as Quake 3 Arena will still run just fine.

Now if you use your cutting-edge Ubuntu (8.04) Hardy Heron system to compile (I’m actually on 7.04), you’ll likely have gcc v4.1 or higher, along with its associated libraries. The linker will find version 2 of a function. That binary will work just fine on your system, and it will work just fine on systems that have been upgraded to use the latest libc libraries. The binary will NOT work on an older system, such as Debian Stable, which is still using version 1 functions. The binary will complain that it can’t find GLIBC_2.4 because Debian Stable may have only GLIBC_2.3.

Possible Solutions

To solve this problem, you could make GLIBC_2.4 a requirement to play your game, but frankly, it isn’t truly a requirement, and there is no reason why you should force your users to upgrade if they don’t have to. More likely, you will just cut off your potential audience. Even if you are releasing the source to your game so that your players can always recompile to get it to run on their system, people generally like games that work out of the box. It’s less effort, which means more of a chance for your game to stay on someone’s hard drive.

You could find an older distro and build your binaries on it, but you may not have a spare machine and may not want to go through the hassle. Also, even if you installed it on your current machine, why give up the power of your current updated system? Michael from Linux Game Publishing offered the following advice:

one extra thing I do – I build against a VERY old set of libraries. As in Red Hat 6.1. That is a ‘magic environment’ that ‘just works’ everywhere.

I would like to try setting up a sandbox environment on my system. I know you can setup a new filesystem and chroot to it, but I had trouble finding information on how to put one together. Since I wanted to release this game weeks ago, I decided against spending a lot of time learning how to do yet another thing to get something working just so I can do the thing I initially wanted to do. Look up Yak Shaving if you hadn’t heard of it before.

Hope!

One thing people told me to try was autopackage’s build tools apgcc and apg++. These are wrapper scripts around gcc/g++ that are used to get your binary to build using the older library symbols.

Hopes dashed!

I think they would have worked fine, but there was a problem with building the Kyra Sprite Engine. Building Kyra is supposed to produce two libraries, libengine and libkyra. For some reason, when I used apg++, it forgot to use files found in a util directory, and so it wouldn’t build the libraries. g++ worked just fine, but then I had a dependency on newer symbols. I spent a bit of time trying to figure out if it was a problem with apgcc/apg++ or a problem with Kyra. In either case, I didn’t want to deal with it longer than I had to, and I was getting a bit demoralized. I can’t use my regular compiler, and I can’t use the one tool that people have suggested to help solve this problem. Honestly, if it wasn’t for Kyra, which has been giving me headaches for the past few months, I bet everything would have been solved long ago, but to gut my project of this library would be a bit more work than I would like. There had to be a way to solve this issue.

When I read more about the C++ ABI Problem, I saw the following quote which gave me hope again:

GCC 3.4 is able to generate binaries with the GCC 3.2 ABI using a compiler switch.

A compiler switch? Seriously? After searching a bit and asking questions on IRC, I learned about the compiler flag -fabi-version. According to C++ Standard Library ABI:

Changes to the default compiler option for -fabi-version.

It is versioned as follows:

* gcc-3.0.x: (Error, not versioned)
* gcc-3.1.x: (Error, not versioned)
* gcc-3.2.x: -fabi-version=1
* gcc-3.3.x: -fabi-version=1
* gcc-3.4.x: -fabi-version=2

My installed compiler was gcc v4.1, and I found that passing in -fabi-version=1 by itself didn’t do anything that I could see. I did, however, install gcc-3.3 and g++-3.3, which also pulled down the appropriate stdc++ library. From my own tests, I learned that the compiler switch did nothing useful. So much for that research. Still, with the older compiler, I was able to get a working binary that should run on older systems.

Some Success!

Before switching to gcc-3.3/g++-3.3, I would get the following output from objdump -x libengine.so:


Version References:
required from libm.so.6:
0x0d696910 0x00 06 GLIBC_2.0
required from libgcc_s.so.1:
0x0b792650 0x00 10 GCC_3.0
0x0d696910 0x00 05 GLIBC_2.0
required from libstdc++.so.6:
0x056bafd3 0x00 07 CXXABI_1.3
0x08922974 0x00 03 GLIBCXX_3.4
required from libc.so.6:
0x0d696914 0x00 09 GLIBC_2.4
0x0d696911 0x00 08 GLIBC_2.1
0x09691f73 0x00 04 GLIBC_2.1.3
0x0d696910 0x00 02 GLIBC_2.0

After using the older compiler version:


Version References:
required from libm.so.6:
0x0d696910 0x00 06 GLIBC_2.0
required from libgcc_s.so.1:
0x0b792650 0x00 09 GCC_3.0
0x0d696910 0x00 05 GLIBC_2.0
required from libstdc++.so.5:
0x081a2972 0x00 07 GLIBCPP_3.2
0x056bafd2 0x00 04 CXXABI_1.2
required from libc.so.6:
0x0d696911 0x00 08 GLIBC_2.1
0x09691f73 0x00 03 GLIBC_2.1.3
0x0d696910 0x00 02 GLIBC_2.0

Now I can package up my game and expect that it should run on older systems without a problem. You should expect that most of your players will be running a system with GLIBC_2.3 or GLIBC_2.4, so targeting the former should still allow your project to run on the latter.

Your distribution should also allow you to install multiple versions of gcc and g++. To implement these changes, I simply made sure that I changed my build scripts to use CC=gcc-3.3 and CXX=g++-3.3. My game’s binary and each of the custom-built libraries, including Kyra, no longer depend on the newer symbols.

Not a Full Solution…

Unfortunately, now my custom libSDL has a dependency on libX11 and libXext, even though I am still passing in –enable-X11-shared, which is what I used when I was using gcc-4.1. I learned why when I read the changelog:

SDL 1.2.11 Release Notes

– Dynamic X11 loading is only enabled with gcc 4 supporting -fvisibility=hidden. This fixes crashes related to symbol collisions, and allows building on Solaris and IRIX.

Unfortunately, SDL 1.2.11 was also the release that builds the way you would expect. That is, 1.2.10 does not provide a configure script, and so downgrading to it isn’t going to be a simple matter. If I keep 1.2.11 or even use the latest stable version, 1.2.13, I still have to deal with dependencies if I use gcc-3.3 to get rid of GLIBC_2.4. If I use apgcc, I have to deal with Kyra not building, which requires working on Kyra to fix it or working on my game to get rid of Kyra. Someone on IRC did suggest that Kyra’s build scripts or the code itself might conditionally rely on “gcc” being used, so that’s where I will investigate next.

If you are not using Kyra, however, I imagine the above information should solve any GLIBC_2.4 dependency issues you may have, but you now have to deal with libX11 issues. In fact, if you’re not using Kyra, then the apgcc/apg++ solution should work for you. Once I solve this problem, I will write a follow-up article explaining how I did so.

In the meantime, I did find this post by Gerry JJ about a script he wrote based on apgcc. I’ll have to check out his apgcc-derived script later.

For more info on this issue:

[tags]linux, game development, business, programming [/tags]

Categories
Game Development Games Geek / Technical Linux Game Development

Download Ryan “icculus” Gordon’s Speech at UCLUG

Thanks to LinuxGames.com, I learned that you can now download the icculus UCLUG speech audio files.

If you don’t know, Ryan Gordon is a Loki alumnus who is well-known as the guy who ports commercial games to GNU/Linux. I liked hearing him on FLOSS Weekly a few years back. You can download the audio for that show at http://twit.tv/floss8.

The Upstate Carolina Linux Users Group had a few talks, and Ryan’s talk starts around 35 minutes into the almost 3 hour audio file.

How many of you think of yourselves as game developers? Alright. A lot more of you should be raising your hands. A lot more of you are game developers than you think you are.

He takes you through a very brief history of Linux-based gaming, from Cracked.com to Loki to Vicarious Visions. He talks about Loki’s business model, which was porting existing, shipped Windows titles to Linux. I wrote about the problem with this model in Why Aren’t There More Linux-Using Gamers?, and Ryan mentions how low the interest is for people to buy the games they already purchased. He describes how Linux-based game servers became popular compared to the unreliable Windows servers. He talks about APIs such as OpenAL and SDL, which is a Google Summer of Code project.

He also talks about the false perception that Linux users don’t respect intellectual property, and false impressions about Linux users in general.

He finishes the talk by asking developers to teach other people how to develop. After all, the ability to create something, whether it is a game or not, whether it is on Windows or GNU/Linux, is great. The Q & A session at the end is also fascinating.

You can find the links to the MP3 or OGG files at icculus.org.

[tags] linux games, game development, video games [/tags]

Categories
Game Development Personal Development

Thousander Club Update: April 14th

For this week’s Thousander Club update:

Game Hours: 409.25(previous two years) + 42.5 (current year) = 451.75 / 1000
Game Ideas: 710 (previous two years) + 35 (current year) = 745 / 1000

I finally managed to fix the major problem I had with Killer Kittens. It wouldn’t run on older systems because it depended on newer GLIBC versions, and it seems that gcc and glibc developers have made it difficult to have a universal binary available.

Well, it wasn’t that difficult. Once again, it was just a matter of learning about something I didn’t know existed before. I can package up my game and send it off to the beta testers who had encountered a GLIBC_2.4 dependency problem. Soon I can release my game to the public.

After I have a finished game out there, I can start worrying about making it better. I have a received a lot of feedback, some of it related to game play and some of it related to technical issues. One issue was that my game runs at 1024×768, but because there was no in-game fullscreen mode option, people with displays at 1024×768 found that the bottom of the window would get cut off by the edge of the desktop. I figure I should change the game to use 800×600 instead, but I should also provide an in-game fullscreen option. You could edit a config file to make it run in fullscreen, but it should be easier to do from within the game itself. And even if I don’t provide the fullscreen mode option, I can move the menu options to the center of the screen so that players can see them even if they do end up with a window that takes up the entire screen and won’t fit.

One concern I keep wrestling with is whether or not I should release the game with the intent to make it better later. The game is long overdue, and so I would love to get it out to the public sooner rather than later. On the other hand, I would rather have a polished game as my first public release. One of the common bits of feedback I got was related to the poor quality graphics, which was just programmer art that I always meant to replace. Still, I wanted to release v1.0 over a month ago, and if I keep finding reasons to delay, won’t it just mean that I’ve never finished this game? A finished game is much better than a game no one ever sees, but if the finished game isn’t of high quality, what does that say about me as the developer?

[tags]game, game design, productivity, personal development, video game development, indie[/tags]

Categories
Game Development Games Geek / Technical Linux Game Development Marketing/Business

Why I Can’t Use Flash for Game Development

People everywhere love Flash. It has become the Web’s de facto standard for all manner of interfaces. From simple menus to full-blown games, you can bet that Flash is there. It has been called one of the best prototyping tools available, and game designers love it because they don’t need to be computer science graduates to use it. Most people browsing the web today have a Flash plugin installed, making it a fairly ubiquitous platform.

With all of these things going for it, why won’t I use it?

Because if I can’t even watch YouTube videos without it crashing Firefox on my Ubuntu system, then it can’t be that ubiquitous.

I thought the problem was that I was using an older version of Flash. I checked, and sure enough, there was a newer version available. I downloaded it, installed it, and put it through its paces. That is, went to YouTube and watched a few videos. Sometimes all I do is click a link to load a new page while a video is playing on the old page, and the next thing I know, I need to manually kill Firefox because it stops responding.

It doesn’t happen each time I watch a video, but it does happen often enough to be a source of frustration. Everything else on my system seems to be pretty stable. It’s just Flash support that isn’t.

It isn’t a consistent problem for everyone. It seems that when someone else updated to the latest version, it worked fine, although it did have the side-effect of hogging a lot of system resources. I’d argue that this is a problem, too, but at least it isn’t freezing Firefox for this person anymore.

Recently, Adobe announced it had joined the Linux Foundation “to collaborate on the advancement of Linux as a leading platform for rich Internet applications (RIA) and Web 2.0 technologies.” With people complaining that 64-bit Flash isn’t available and with the existing 32-bit version being too buggy for doing things as simple and as common as watching videos on YouTube, I’m curious how much progress will get made. It seems that almost everything available for Linux on Adobe’s site is “alpha-quality”, with a link to get the already-stable Windows or Mac version.

In any case, until Flash becomes more stable for Linux users, I have to look to other technologies to provide a more consistent experience across platforms. Java applets should be a better proposition, and languages such as Processing make it friendlier for prototyping. And since OpenJDK is Sun-supported, I can’t see it crashing as randomly as Flash does. Unfortunately, it seems that Java isn’t on as many systems as Flash is, and asking someone to download a plugin if it isn’t already installed is just asking too much if you are trying to attract the casual player.

I’d love to use Flash. It’s not a bad technology. It’s just disappointing that Linux support is so inconsistent. If I am going to make web games, I am definitely not going to use something that results in games that I can’t even play.

[tags] video games, game development, linux, flash, java, business [/tags]

Categories
Game Design Game Development Games Marketing/Business

Griefers and Online Games

Thanks to David Edery, I learned about an article on Gamasutra about fixing online gaming idiocy.

Bill Fulton wrote about the problems with griefers as well as people who are just plain rude.

Why do I care? Some gamers might be thinking “If he’s so thin-skinned that he can’t take the online banter, maybe he shouldn’t play online.” Unfortunately, many people do just that — they stop playing online.

Because the online behavior of our customers is dramatically reducing our sales, and continues to stunt the growth of our industry. Non-gamers simply don’t love games enough to put up with the crap they get online. The reason they would consider playing online is to have fun with other people — and right now, playing games online with strangers rarely delivers that for anyone outside the hardcore demographic.

If you’re not familiar with griefers, read Wired’s Mutilated Furries, Flying Phalluses: Put the Blame on Griefers, the Sociopaths of the Virtual World, as well as The Escapist’s 19th issue, Griefer Nation.

If you are familiar with griefers or at least the problems they can cause your online game, you might wonder what can be done about it. You don’t even need to have an MMO to deal with such issues. If your game includes a high score list that automatically gets published to a website, you may find your list the victim of griefers. A recent posting on PuppyGames.net puts future troublemakers on notice:

Now hear this: the online hiscores table is viewed by children and we’re really not going to accept any more of this stuff any longer. You will find yourself banned permanently (and all of your hiscores deleted permanently too) if you abuse the facility.

Fulton argued that yes, it is possible to solve this problem by designing the social environment and culture. He talked about changes that were made to Shadowrun to discourage griefing, and I think it is an encouraging article.

[tags] video games, business, griefing, game development, game design [/tags]

Categories
Game Design Game Development Games Linux Game Development Marketing/Business

CGDG Video Recap is Up

Thanks to the Game Development Society of DeVry DuPage, the video recap of the Chicago Game Developer Gathering is up, so if you missed the event, you can now un-miss it.

It is split into 10 separate videos, and you can see the first one below. I hope a single video can be released as well.

Wow, I sound weird. Maybe I should join Toastmasters.