My Kung-fu is Strong!
Mar. 13th, 2005 03:42 amLast week (Tuesday, actually; less than a week ago) Tucker came over and we played, among other things, this new game he'd gotten called Xe Queo!.
I thought this was neat, and wanted a computer game version of it. I've been doing that a lot lately; partly out of a desire to have many popular boardgames have Java versions, partly out of a desire to have projects that are easy and fun.
Just tonight I finished and tested this thing; you can get it here. It's kinda surprising to me that I was able to finish this game (which I think is pretty nice looking, all things considered) in less than a week. The world is fortunate that I use my powers only for good.
I learned a lot of stuff while doing this. One thing I learned is that the Gimp does not a paint program make; so before I do this again I want a real paint program for OS X. Anyone have any suggestions?
The biggest thing I learned is that it's a lot easier to write something if you do the interface first. The very first thing I wrote was a widget to display the board, and before I even did that I drew some cheesy images, so that the entire time I was writing the game, I could see it on the screen. The usual way I do things is to write the logic first and then tie an interface on to it, and I always finish the logic and then look at the mountain I have to do for the interface and quit.
This game has a strange network model. Rather than a client-server model, it's peer-to-peer. It only works since the game is two-player, and it made it a lot easier to write. No need for a complicated server with rooms and matchmaking, no need for any complex code to route messages between players, just a class called NetTalk with a single method called sendMessage().
I have spent the last three evenings at Dave and Kayla's house. On Thursday Kayla and I watched Hero (very pretty), on Friday Dave and I watched the Stargates (and Galactica, but I've seen all of those already), and Saturday I went to Dave's birthday party, which reminded me again how much I prefer small groups of people to large ones, but was pretty fun. Everyone got him a very small gift certificate to Gourmet Pantry, so he has a stack of about ten of them. Blame Adam.
Having discovered that I really do like (and miss) some PC games, but that I really do not like having to deal with Windows to play them, I'm building a Windows machine for gaming (the idea being that if all I ever do on it is play games, it won't do that Windows thing where it develops "character" after a few months). "Building" is sort of a misnomer here, since I really more "discovered that I had a machine that lacked only a hard drive" and "decided to play games on it". The one problem: I can't read. The hard drive I ordered is SATA instead of IDE. SATA is a slightly faster, brand new drive interface designed for RAID. RAID stands for Redundant Array of Inexpensive Disks, and means that you take a lot of very expensive disks and set them up in an array so that if one of them fails, your data on all the rest of them is hosed and lost forever. The upshot of all this is that my cheapass, low-budget gaming system is going to have the fastest, nicest hard drive of any system I own, and take a week longer to assemble than I thought. Grr.
I thought this was neat, and wanted a computer game version of it. I've been doing that a lot lately; partly out of a desire to have many popular boardgames have Java versions, partly out of a desire to have projects that are easy and fun.
Just tonight I finished and tested this thing; you can get it here. It's kinda surprising to me that I was able to finish this game (which I think is pretty nice looking, all things considered) in less than a week. The world is fortunate that I use my powers only for good.
I learned a lot of stuff while doing this. One thing I learned is that the Gimp does not a paint program make; so before I do this again I want a real paint program for OS X. Anyone have any suggestions?
The biggest thing I learned is that it's a lot easier to write something if you do the interface first. The very first thing I wrote was a widget to display the board, and before I even did that I drew some cheesy images, so that the entire time I was writing the game, I could see it on the screen. The usual way I do things is to write the logic first and then tie an interface on to it, and I always finish the logic and then look at the mountain I have to do for the interface and quit.
This game has a strange network model. Rather than a client-server model, it's peer-to-peer. It only works since the game is two-player, and it made it a lot easier to write. No need for a complicated server with rooms and matchmaking, no need for any complex code to route messages between players, just a class called NetTalk with a single method called sendMessage().
I have spent the last three evenings at Dave and Kayla's house. On Thursday Kayla and I watched Hero (very pretty), on Friday Dave and I watched the Stargates (and Galactica, but I've seen all of those already), and Saturday I went to Dave's birthday party, which reminded me again how much I prefer small groups of people to large ones, but was pretty fun. Everyone got him a very small gift certificate to Gourmet Pantry, so he has a stack of about ten of them. Blame Adam.
Having discovered that I really do like (and miss) some PC games, but that I really do not like having to deal with Windows to play them, I'm building a Windows machine for gaming (the idea being that if all I ever do on it is play games, it won't do that Windows thing where it develops "character" after a few months). "Building" is sort of a misnomer here, since I really more "discovered that I had a machine that lacked only a hard drive" and "decided to play games on it". The one problem: I can't read. The hard drive I ordered is SATA instead of IDE. SATA is a slightly faster, brand new drive interface designed for RAID. RAID stands for Redundant Array of Inexpensive Disks, and means that you take a lot of very expensive disks and set them up in an array so that if one of them fails, your data on all the rest of them is hosed and lost forever. The upshot of all this is that my cheapass, low-budget gaming system is going to have the fastest, nicest hard drive of any system I own, and take a week longer to assemble than I thought. Grr.