weewar.com corner
Travian.com
Mar 30

I spent a little time yesterday searching for good examples of a basic asynchronous TCP socket class in C#. We’ll need one eventually at work, and I wanted to use it to throw together a simple MUD. Basically, I want to be able to instantiate the object (SocketServer server = new SocketServer()), set a few properties (server.Port = 4444, etc), and have it start listening for connections and data. When a connection is made or lost, I want it to raise events. When data is sent/received, I want it to raise events. Is that so hard? I could research it and code one myself, but I thought surely there was one already out there. Nope.

While I was researching that, I had a brainstorm (I often get them in the middle of doing something else). I’ve already got a small application that acts as an AIM bot using the AIM SDK. I was planning on one day creating a MUD with IM capabilities to go along with MUD Ideas #3. The thought was that the MUD would send you IMs about stuff like when another player knocks on your home’s door, the town crier has an announcement, or when an administrator was about to run a new quest. That would be simple enough. When a player knocks on the door to a player-owned house, check to see if the owner’s character logged out while in the house. If so, get the AIM ScreenName for that player and send him an IM saying, “Someone is knocking on your door.” If the player logged out in a city, send the town crier’s announcements, etc.

Then, I started thinking, “Well, what if I forego the socket layer and just use AIM as the connection method?” A player could send an IM to the MUD’s AIM ScreenName and the MUD would parse it just like it would from a telnet or MUD client. Well, I gave it a shot last night, threw together a quick and dirty MUD using AIM. It’s got 5 rooms (laid out in a plus [+]). You can navigate using standard N, S, E, W directions. You can view the room’s title, description, exits, and occupants (other players) using the LOOK command. The SAY command is next, which will be very simple, too. In order to do anything, you first send it an IM saying “LOGIN”. After that, you’re MUDding via IM.

I’m sure AIM has very strict spam levels that would keep such a mechanism from being a viable connection layer for a true MUD, but as a proof of concept, it sure works. Plus, I can start coding the objects for use when I have the socket layer done and use the IM interface for testing. You may be asking yourself, “Why code a MUD in C#?” Well, because I love that language. It’s easy to code, the IDE is powerful, and I already know it. With most MUD codebases out there, you need to use a Linux box (or Cygwin) to compile. Plus, I wanted to start one from scratch using OOP. I think I want to do the data side of things with XML files (for possible portability using Mono), but it would be much easier to do it with SQL Server, since I’m already familiar with it and have a data layer that can already do it. Using XML would help me learn, though, which is one of the main reasons I wanted to do this in the first place.

Ultimately, this will be a socket-based MUD with IM notifications, a web interface for some features (player-owned shops, auctions, world building, etc), RSS feeds for in-game news and events, and web services for data retrieval with widgets, etc.

Any suggestions or comments?

Mar 30

The teaser trailer for Grand Theft Auto IV is out at the Rockstar site. It looks very pretty. I’ve always enjoyed the detail that they put into crafting every nook and cranny of the fictional cities in the GTA setting. It’s fun to find little Easter eggs and use the environment for emergent gameplay. I remember in GTA 3, there was a jump at the top of a hill where you could get some gnarly air and rack up cash for doing a few flips. The view was excellent, too.

Mar 28

Revision 3’s new show, The Totally Rad Show is out. I’ve been looking forward to this since I heard about it. It has Alex Albrecht from Diggnation, Dan Trachtenberg from Geekdrome, and Jeff Cannata, who guest hosted Geekdrome once or twice. It’s excellent. Basically, it’s a candid, off-the-cuff review show for movies, comics, video games, etc. If you like Diggnation or Geekdrome, check it out.

Mar 28

Straight from the horse’s mouth, the XBox 360 Elite is the new version. According to Best Buy, it’ll be released on April 29th for $480. This kind of sucks, since I just got my 360 in December. The only differences between mine are that the Elite has a larger drive, HDMI output, comes with the “play and charge kit”, and it’s black. I would have gladly forked out the extra $80 for the drive (which sells for $180 by itself), HDMI, and charge kit (sells for $20 by itself). I guess that’s the price of investing in technology, but I would have expected Microsoft to drop the price before this was released, and especially after this was released. Now, you’d really be getting screwed if you got the “Premium” system for $400 when the “Elite” is only $80 more. Thanks, Microsoft. How about throwing early adopters a bone? Free marketplace points for games or movies, maybe? Free, easy-to-set-up first-party software to allow streaming audio/video from a Windows PC (not requiring Media Center)? Heck, at the least, you could give everybody an “Early Adopter” achievement for XBL. That wouldn’t cost anything at all, but you probably still won’t do it. Bah. Fie to thee.

Mar 27

Today’s headlines:

AppleTV OS booting on a MacBook: Why? With the Front Row interface, what more does AppleTV give you?

Justin.tv: An interesting experiment. I don’t have any interest in watching what some average Joe does all day, but I guess some people do. The Real World, Survivor, and The Amazing Race are all part of that “Reality TV” craze, but they were edited to show the good stuff. Plus, the [inhabitants, contestants?] were selected based on several criteria that would make the show interesting. It might be different if Justin was a Navy Seal, a treasure hunter, or stranded on a desert island.

Battlestar Galactica Jumps the Shark: Say wha? Those who watch Sci-Fi’s version of BSG may have been surprised by the season finale. Me? I think the creators just like jumping the shark every year. The “occupation of New Caprica” plot was bad enough, but I fear next season will introduce more oddness. Don’t get me wrong, I’ll still watch it, but I just wish they would return to their roots for once. The mini-series was great, as was the first season, but now they’re so deep in their marijuana-induced haze that they need a spin-off to bring them back to reality. The show is called “Battlestar Galactica,” but it should be called “Guess Who’s A Cylon?” Apollo’s a wuss, Starbuck’s a wackjob, and Adama’s a lovesick puppy. Let’s get back to the Sci-Fi military theme.

Netflix CEO Joins Microsoft Board: Could this mean I’ll be able to use my Netflix Watch Now on my XBox 360 soon? That would be great, especially if it didn’t require a Windows Media Center to proxy the streaming like the AppleTV. Unfortunately, my XBox 360 will soon be out-dated. It would be nice to have HDMI and a cooler-running box. It would be even nicer to have the 120GB drive to handle IPTV DVR capabilities that are sure to come out soon.

Mar 22

Evidently Twitter is the hot new website. I’m not much of a social person, though, especially online. As I’ve probably said before, I have a select group of friends and it takes me a while to warm up to new people. So, I wouldn’t get much out of Twitter as a way to let your friends know what you’re up to (I’m usually just working, or sitting at home anyway). I do, however, think that it’s a great part of an online presence. In online gaming terms, it could be your place marker on the map. Your buddies could look on their world map and see where you are. It goes very well with a Gravatar. Both are pieces of an online presence. Now, if there were only a global login for websites, you could link your Gravatar and Twitter to any website and not have to maintain 50,000 online profiles.

I’ve been playing with AppleScript a little this week. It’s a lot of fun. It’s an easy way to manipulate my Mac to do my bidding. Check this out: I’ve got Proximity installed (thanks to this page). It detects when your Bluetooth device (my phone) is within range. I’ve also got iAlertU installed. It acts as a car alarm for your Mac. I have an AppleScript that pops up and asks what I’m doing and where I am. Right now, the script just adds a calendar event and updates the previous event’s end date. Basically, I want to try to track my time a little better to see how I can optimize it. I plan on having it pop up every 30 minutes or so and ask what’s up. I’ve also got an Adium (instant messenger) plugin that uses my Twitter status as a status/away message. So, if I combine all of that using scripts, I should be able to do the following: When I’m in range of my computer, I’ll be tracking my time every 30 minutes. When I leave range of my computer, it’ll lock it, turn on the screen saver, set my Twitter (and thus status/away) message, and track when I’m gone. When I come back into range, it’ll unlock, set my status as back, and resume as normal. After a month or so, I should be able to see when I’m most productive and where I can improve productivity.

Just another in a long line of useless projects.

Mar 21

I downloaded the pilot for Andy Barker, PI from iTunes the other day. I figured it would be a good “watch while feeding the baby” show. Pilots are usually pretty good, and this one was no exception. Good comedic acting, good script, good production. It actually reminded me a little of Magnum PI. I set it up to record on my HTPC.

On top of that, I watched it using Front Row on my notebook (Apple doesn’t like to call it a “laptop” due to possible heat problems). The experience was good. If you have to navigate through menus, it’s nice to do it with style. Nice fades and swipes. The UI is easily readable from a distance, too. If it had Live TV and PVR functionality, it would be the ultimate HTPC interface. Here’s hoping for version 2 of the Apple TV.

Update: Feeding time again, so I watched the Raines pilot. Another interesting show. Jeff Goldblum is a good neurotic actor. It’s a bit Monk at times, but not bad. I think I’ll set that one up to record, too. Now, I’ll need to find the time to watch all of these shows. I was 3 weeks behind on 24, I haven’t seen The Unit all season, Star Trek Enterprise is stacking up, along with Skyland. One rainy weekend this spring I’ll have to sit down for a TV marathon.

Mar 19

I’m at home with the kiddo today. Laura started back to work this week, but our daycare doesn’t start until next week. I had planned on working while I was here, but it’s hard to find a groove when Fussy McDirtypants doesn’t like to be put down. She’s good otherwise, just craves attention. I’ve resolved to just working one-handed the best I can for now and hopefully find a groove tonight.

Damion linked to an article that said Blizzard is setting up a customer service shop in Austin. Good for Austin. I’m glad to see more game studios setting up shop in Texas. Austin is like a Mecca for MMO developers.

I swear I’m a Logitech fanboy. My VX Revolution mouse arrived this afternoon. I only just installed it and my computing speed has already doubled. Built-in mousing devices such as touchpads, pointer nubs, and (at one point) trackballs are great when you’re in a pinch or traveling light, but there’s nothing like a good blaster at your side and the same goes for a mouse. The VX Revolution is good because it has the same grip as the other Logitech mice, but is slightly smaller. It runs on a single AA and you store the teeny USB receiver in the mouse, itself. It’ll be easy to pack up. It’s also got the heavy “micro-gear” scroll wheel that can be set to spin freely or ratchet like normal. I’m sticking with the ratchet for now.

Also in the Amazon box is my new Linksys WRT54GL (the L is for Linux) WiFi router. We’ve been having problems with our BEFS11R4 and my new notebook won’t even connect to it, so it was time for a new one. I’ve been wanting the Linux flavor of the 802.11G router for a while. Since it’s Linux, you can put new firmware on it as well as different software. The OpenWRT project seems like the way to go. You can even put Asterisk (the PBX software) on it. Heck, I bet you could even run a MUD server on it…hmm…initial searches on Google don’t show anything, but we shall see. Hopefully it won’t burst into flames if I try. If nothing else, I’ll at least get Apache web server going and have it update DynDNS for me. I’ll probably keep the other router around as another WAP. I might reconfigure it to work with Laura’s Nintendo DS or something.

Speaking of MUDs, do any readers still play them? If I got one running and included some of my “MMO Ideas”, would I be alone in my virtual world, or would others come around and live there with me?

Mar 15

Why Fantasy?
Why Combat?
Why Classes, Levels, and the Grind?

Damion moderated a roundtable discussion at this year’s Game Developer’s Conference. He posted three articles focusing on different elements of the MMO. There are some very interesting thoughts here. I have a couple of thoughts of my own:

Why Fantasy? Because there are so few good fantasy movies. Seriously, there are very few good fantasy movies out there, so everybody wants to live their own. Fantasy is the easy path, though. Sci-Fi or Post-apocalypse needs a posterchild MMO. Star Wars Galaxies and Anarchy Online just can’t cut it.

Why Combat? Combat is good. Actually, I should say that conflict is good. How the conflict is resolved is usually best when one person is king of the hill. It’s true, though, that today’s MMO combat is basically DikuMUD combat. My turn. Your turn. Wait for the next combat pulse. The new Star Wars Galaxies adds a bit of twitch gaming to this, but still boils down to the same. So, conflict is good, but what other (fun) ways are there to resolve conflict? I, for one, would like to see more team-based competitions. It doesn’t have to be a battleground where one team wails on the other. Take a look at RTS games: he who controls the spice controls the universe.

Why Classes, Levels, and the Grind? I’ve covered much of this before. Basically, the current model is easily boiled down to two or three easily repeated functions. Depending on the game, it’s usually “get quest, kill quota, return for reward” or “travel to spawn area, kill all in sight”. Take Oblivion, on the other hand. It is, essentially, a skill-based system. Sure, there are levels and classes, but it plays more like scaling difficulty and archetypes (or skill groups). Levels and classes are tried and true, though.

So, who will break the cycle? Will the Firefly MMO be a skill-based sandbox focusing on character development? One can only hope. Unfortunately, that would require innovation and a long design cycle, right? Who has the budget for that?

Mar 15

My 17″ MacBook Pro arrived Monday afternoon. Getting to it was like a Russian doll: Open Amazon’s huge shipping box, dig through packing material, open Apple’s shipping box, open MacBook Pro box. Initial setup was exceptional. I was going within a few minutes. Basic tasks on the Mac are extremely easy, and the system didn’t walk me through them like a child. I tinkered around a little, tweaked a couple of settings, downloaded a few apps, and installed them, all without any problems. In fact, I got it set up for my normal daily tasks within an hour or so.

I ran into one problem at home, though. It wouldn’t connect to my wireless network. It picked up a couple of other networks around the neighborhood, but not mine. It’s a Linksys 802.11b network and searches said that Apples have some problems with Linksys WiFi. I was able to connect to the office WiFi (Linksys 802.11g), though, after filtering my MAC address. We’ve been having problems with our WiFi at home anyway, so I might bite the bullet and get a new router. It doesn’t make much sense to finally have a notebook that is easily portable and not be able to connect to the WiFi.

I installed Windows using Boot Camp right now. It didn’t like the DVD, so I had to burn a CD ISO image. Parallels installed without a hitch and booted using my Boot Camp partition. I dedicated 1GB of memory to it and so far, I can hardly notice any performance hit. My development applications are working perfectly, save a few hiccups with domain authentication and source control working folders.

So far, I have installed and made use of the following Mac applications:
- Firefox: I don’t drink boring, flavorless, light beer, and I don’t use boring, featureless, browsers.
- Adium: Trillian? Who’s that?
- Quicksilver: I believe the hype now. I had trouble finding the Terminal application, hit Ctrl-Space, typed “Term” and there I was. I later found it under Applications->Utilities, but who wants to navigate through the file system to run an application? What’s great is that not only is this better than the Windows “Run”, but you can make it do other stuff, like triggers and even add Google Calendar events (”mow lawn saturday 10am”).
- Mail: Most email apps are the same. I had planned on using Thunderbird, but figured I’d give the built-in app a try first. So far, there’s nothing that stands out. As I said, most email apps are the same. Plus, I’m not a huge email junkie. I receive a few emails here and there and send them less often. I figure Mail will suit my needs for now. Plus, it integrates with Address Book, although there’s no way to select a contact and compose a new message to him/her. I find that strange. Surely there’s some way to do that. Automator, maybe?

What I like so far:
- UI: Clean, concise, pleasing to the eye.
- Expose, Show Desktop, and Dashboard: F9 rearranges your open windows and allows you select the one you want to switch to. It is much better than the classic Alt-Tab (which still works as Option->Tab). F11 pushes all windows out of the way and shows you the desktop. This is a great feature, but I haven’t used it much. With Mac, the desktop is a much more prominent figure than in Windows where I usually Maximize windows. F12 shows you your Dashboard Widgets. I’m still trying to figure out a great function for Widgets other than showing the weather. I found a system statistics Widget that works like (better than) Windows’ Task Manager.
- Portability: I used OmniOutliner in a meeting yesterday. I turned the screen brightness way down. After 4.5 hours, it still said I had 30 minutes left on the battery. 6.5 lbs. is just fine.
- The Dock: I thought I’d miss the Windows Taskbar (where the Start menu lives), but I really don’t. The Dock lets you launch apps and also lets you keep tabs on the ones that are active. It’s not revolutionary, but works really well.

What I’m on the fence about:
- Finder: While I’m having Windows Explorer withdrawals (cold, sweaty palms, jitters, etc), the Finder hasn’t been a total loss. In two words: it works. It’s not flashy, it doesn’t sort the way I’d like, I can’t find out how to open all windows in List view, and I really miss the Folders tree, but it works for what I’ve needed so far.

What I don’t like so far:
- Keyboard layout: I miss my dedicated Home/End/PgUp/PgDn keys. There’s plenty of room for them. Instead, you have to use Option->Direction (Up/Down/Left/Right). What a pain! Plus, when in Windows, the modifier is not Option, it’s Function, so you have to switch around. Plus, the “delete” key is actually like Windows “backspace”. To get Windows “delete” functionality, you use Function->Delete.
- UI is not keyboard-friendly: As far as I can tell, so far there is no way to navigate menus using the keyboard. In Windows, you could hit Alt to drop down a menu, then use the Direction keys to navigate. No dice on Mac. Plus, message boxes aren’t simply “Yes/No/Cancel”. I can’t just hit “Y” when it asks me if I want to save. I have to click “Save”. Why have keyboard shortcuts (Option-S for Save) when you can’t hit “S” when prompted?
- Scrolling with the touchpad: While not as big of a deal, scrolling (using two fingers) on the touchpad is finicky. I’m still looking for that perfect mouse. When I find it, it’ll solve my scrolling woes. Right clicking is fairly simple, but a new mouse would make that easier, too.

Does anyone have any tips for a heavy Windows user who’s adopting Mac (I wouldn’t consider myself a switcher). Any useful Automator stuff (I haven’t quite figured out how to work that)?