Friday, October 23, 2009

Informatics fail

So one of the subjects I'm doing this semester is Informatics 2. It's basically an introductory programming/comp.sci course. Coming up is a major major assessment, worth 25% of our final unit mark. For this assessment, we have to write a web application to search/view movies from a database.

Simple enough, and the code is fairly trivial. I was working on code to scrape for movie images, so we could display them alongside the search results. Now, we have to use this online system called IVLE, which was written by the university (apparently). IVLE is essentially an online web-based IDE for developing in Python. It stores your files on a central server at the uni, and you develop your scripts through your browser and execute them remotely on the university's servers.

On the surface it sounds pretty good. If only the damn thing actually worked.

You see, IVLE is so buggy that at times it becomes near-unusable. Sometimes IVLE will incorrectly copy/paste text. Sometimes it won't properly save your work, causing you to lose data. And every now and then it has a habit of inserting phantom text into your code at random, causing all sorts of weirdness.

But those problems I can live with. Those bugs can be worked around with enough effort. No, the real problem is that IVLE fails at doing the one thing it was designed for: running scripts.

I can't do any work if I can't actually run my scripts through IVLE. If the IDE is crappy and buggy, I can work around that with enough effort. But this is just ridiculous.

So I'm trying to write a python script to scrape Amazon for movie images. All it involves is unpickling about 4200 files, downloading a page from Amazon, scraping the page for an image link, then downloading the image to file.

Firstly, doing it one by one is too slow, since urllib is synchronous (blocking). So I used Python threading to run a bunch of threads to scrape multiple images in parallel. Problem solved, right? Well, IVLE can't even handle that. Creating a measly 32 threads doesn't work - I get a "cannot create any more threads" exception. You're kidding me, right? I had to drop it down to 16 simultaneous threads.

Well, 16 threads should still run pretty fast, right? Sure. IF IVLE ACTUALLY ALLOWED ME TO RUN MY SCRIPT. You see, IVLE is so buggy that 90% of the time, it throws up a "internal Python console error". And then the Python console becomes unusable - resetting it has no effect (it just throws up another internal console error).

So I have to log out of IVLE, and log back in again. This time I successfully start the script, but I soon discover that there's a minor bug in my program, so I hit "interrupt" to stop the program. I fixed the bug, and then try running it again. OH WAIT, I SUPPOSE IVLE DOESN'T ACTUALLY LIKE PEOPLE ACCOMPLISHING ANY WORK. It throws another "internal Python console error".

Now rinse and repeat this experience. Many, many times. I spent 4 hours battling with IVLE and it's incessant internal Python console errors. Obviously, IVLE either doesn't like my script or it handles creation/destruction of threads really, really badly.

Now, after spending an afternoon battling with IVLE, I finally got it to run without any problems. And after a few minutes, with only half the images downloaded, IVLE threw an error saying that I'd exceeded the CPU time limit. CPU time limits are fair enough, the simple solution is just run the script a second time and skip over the work done in the first pass.

Wait, you mean I have to run the script a second time? And go through all that pain again!? Already I can hear IVLE laughing at me from beyond the deepest gates of Hell as I vainly try to finish my work before the due date.


Sunday, September 20, 2009

An overly elaborate alarm clock

The mid-semester break has just started, and I thought I'd celebrate my 2 weeks of freedom by creating a pointlessly elaborate alarm clock.

The problem: I can't get up in the morning. I don't have an alarm clock, and I'm too cheap/lazy to buy one.

Solution: Write an alarm clock program to run on my desktop.

I use 2 Dell 24" 2408WFP LCDs as part of my desktop - which sits opposite my bed. So I decided to make an alarm clock out of them.

First thing's first: turning on my PC. Every night I put my desktop to sleep, since it's far more convenient than shutting it down. Luckily, Windows Vista's task scheduler allows for waking the computer from sleep in order to run scheduled tasks. Perfect!

Next, the alarm clock program. Using task scheduler, it's set to run every morning at the pre-set time. Once the computer wakes and the program runs, this is what I'm presented with:

On the left monitor I have a big polar clock, which I shamelessly stole from Although the idea belongs to someone else, this implementation is my own. On the right monitor I have some daily weather information pulled directly from the Bureau of Meteorology's data feeds. When getting dressed in the morning it always helps to know the current weather forecasts for the day.

When the program starts, it starts playing music (from my music collection) to wake me up. It also makes sure to set the system master volume automatically to make sure it's loud enough to get be out of bed.

The program was written in C# using XNA Game Studio 3.1. What a way to waste a weekend. :)

Wednesday, August 12, 2009

Damnit, Melbourne

Maybe it's just me, but Melbourne Uni seems really disorganised. Just the other day, I was trying to find more information about the MSDN Academic Alliance, which allows staff and students of IT-related departments to recieve free Microsoft software.

So to find out about the MSDNAA, I needed to contact the department which teaches IT-related subjects. There are two departments, though - the Departement of Information Systems and the Department of Computer Science and Software Engineering. The Department of Information Systems falls under the Faculty of Science, while the Department of Computer Science and Software Engineering falls under the Faculty of Engineering.

I'm currently enrolled in a Bachelor of Science, so I suppose I should contact the Department of Information Systems since that's the department that falls under the Faculty of Science. But hold on, I'll be majoring in Computer Science which means that I should belong to the Department of Computer Science and Software Engineering. But the actual subjects that lead to this major (Informatics 1&2) are administered by the Department of Information Systems.

So to sort this confusion out, I asked one of the subject co-ordinators for Informatics 2. He didn't know about the MSDNAA specifically, so he referred me to the Information Services division. I emailed them through Student IT Support, and they forwarded my request to the university's IT Licensing Group. The IT Licensing Group apparently told Student IT Support that the university's MSDNAA subscription only allows for the software to be installed on "University Assets" and not personal workstations.

That appeared contrary to the terms of the MSDNAA subscription, so I contacted the Melbourne University Computer Students Association (MUCSA) who sell legitimate copies of Windows Vista/XP to students for a nominal fee of $10. I asked them where they got their keys from, and they told me that they went through MSDNAA (via. one of the departments). This means that Melbourne Uni does have an MSDNAA subscription, and is allowed to distribute software to students, contradicting what the IT Licensing Group told me.

Now after wading through that quagmire, I didn't find what I was looking for, don't have any more information, and don't know what's going on. Nevertheless, I've contacted the subject co-ordinator for Informatics 2 again, who might be able to shed some more light on all this. I await his reply.

Thursday, July 30, 2009

NextWar now available in more regions; cheaper

With the new updates to XNA and Xbox Live Community Indie Games, games are now available for sale in Germany, Japan, Singapore and Sweden. I've updated NextWar so that it can now be sold in these regions. So if you live in these regions, and are itching to play Tower Defence on your Xbox 360, check out NextWar!

Also, with the introduction of the new pricepoints (80MSP, 240MSP and 400MSP, corresponding to $1, $3, and $5 respectively), I've decided to drop the price of NextWar to 80MSP. So if you were holding off buying NextWar or didn't think it was worth 200MSP, you might want to reconsider! NextWar is now in the Xbox Live version of the $1 bargain bin. :)

NextWar: The Quest for Earth official site

Xbox Live Marketplace link

Thursday, July 2, 2009

How well did NextWar really do?

Well, it's been 3 months since the release of NextWar: The Quest for Earth over Xbox Live Community Games. How well did it really do?

I'll let the graphs speak for themselves first:

The sales graph curved pretty much exactly how I expected it: an exponential decrease immediately after release, then dropping off a cliff after the game fell off the New Releases/Most Popular lists. Once that happened, sales trickled down to single digits per day.

Overall statistics:
Downloads to date: 14572
Sales to date: 2703
Conversion Rate: 18.55%
Total revenue: US$4578.88

It did reasonably well compared to many other Community Games - but the overall conclusion is "don't quit your day job". Making a game and selling it on Community Games can be fun as a hobby, but it's not viable as a full-time job. This is essentially echoed by many other developers who have released games on XBLCG. Nevertheless, despite only being a minor success, the amount of money generated by NextWar's sales (however small) is still nice for something that I put together in my free time.

The Future
So what lies ahead for Micron Game Studios and the future of my hobbyist game development?

Well, I'm doing this for fun and not for the money, so I think I'll be making another game regardless of how I think NextWar did in terms of sales.

There are a few viable game designs I'm batting around right now, so stay tuned for more stuff coming out of Micron Game Studios in the coming months!

Wednesday, May 6, 2009


I'm on the train. I think somebody just tried to bluejack me.

Tuesday, May 5, 2009

Getting Past the Melbourne Uni Proxy

Melbourne University has a slightly draconian policy for use of their internet on campus. All traffic must go through an HTTP proxy; basically everything besides port 80 (for regular HTTP) and port 443 (for HTTPS) is blocked.

It means I can't access my LAN, my home computers, or my Perforce server. I first tried Hamachi, which is a free (as in beer) piece of software that allows you to quickly and very easily set up a VPN. Start the software, connect to a network, and you're good to go. It worked fine outside the uni. But it's tunnelling capabilities were... limited. Hamachi supports HTTP tunnelling, but not in a peer-to-peer fashion. Instead, connections had to go through Hamachi's private "relay servers". For the free version of Hamachi, this was incredibly slow (and unreliable, in my experience). The commercial (ie: paid) version is apparently faster, but I wasn't prepared to pay ~$50/year to be able to access my home LAN from uni.

Next try: OpenVPN. OpenVPN supports HTTP tunnelling out of the box, and was relatively painless to configure (though not nearly as easy as Hamachi). I installed OpenVPN on the server at home, which is always on and always connected to the internet. Using a bridged network, OpenVPN acts as a virtual gateway to my LAN at home. I set it up to listen for TCP on port 443.

I installed OpenVPN as well, and set it up to go through the Melbourne Uni proxy, connecting to my home server (via. dynamic DNS provided by through port 443. And lo and behold, it works. The proxy can't tell the difference between regular HTTPS traffic and the encrypted OpenVPN traffic, and I can now access my LAN from uni.

Tuesday, April 21, 2009

New PC

Well, I bit the bullet and bought myself a new PC. Specifications are as follows:

Intel Core i7 920
Asus P6T motherboard
12GB (6x2GB) Kingston DDR3-1333
Asus HD4870 1GB
Lian-Li PC-A77 full tower case
Noctua NH-U12P CPU cooler

Kept the DVD drives and 1.5TB worth of hard drives from my old PC. Total cost? About AUD$1900 (USD$1330) all up.


Initial results for overclocking the i7 seemed promising - it shipped stock with a core voltage (vcore) of 1.2V. The default range of voltages for the i7 920 is 0.8v - 1.375v, according to Intel. The CPU core is a c0/c1 stepping, according to CPU-Z. I didn't really expect to be able to get a new D0 stepping, since it's way too new for the local retailers here to stock it.

Using the stock voltage, I was able to get it to run at 3.6ghz stable. At 1.375v, I could run it at 3.8ghz stable. I reached 4ghz only by increasing voltage to 1.44v. 1.44v was considered far beyond safe for regular usage - the CPU was hitting >87C load, and that's using one of the highest performing air coolers on the market (the Noctua NH-U12P).

I eventually settled for 1.375v and 3.8ghz. With a multiplier of 20x, that means a BCLK of 190mhz. The cheap Kingston ValueRAM also reached a surprising overclock - it's currently running at 760mhz (1520mhz DDR), which is a 14% overclock over the stock 666mhz (1333mhz DDR). And that's at stock voltage of 1.5v, and stock latency of CL9.

That's one mighty fast CPU - a definite upgrade over my ageing Core 2 Duo E6600 circa 2006.

Didn't bother overclocking the video card; it's plenty fast enough for pretty much anything except Crysis.

The Old PC

My old hardware won't be going to waste. there's still a perfectly good E6600 and 4GB DDR2 RAM in there. It'll replace the network server I have here at home; it's currently running on a ~2001 era Northwood Pentium 4 with 512mb DDR. The Core 2 should be a significant upgrade for the server, which runs stuff like my Perforce server and media storage.

Thursday, April 9, 2009

NextWar: The Quest for Earth for Xbox 360 Version 1.01 Released

Hi all.

An updated version of NextWar: The Quest for Earth for the Xbox 360 has been released to Xbox LIVE Community Games. Version 1.01 fixes the "Send Next Wave" crash bug.

If you've experienced this bug, you should redownload the game from Xbox Live Marketplace. Thanks to all who noticed and reported this bug, I wouldn't have been able to fix it without you!

Friday, April 3, 2009

NextWar Developer Q&A

I recently did a short interview for

You can read it here.

Monday, March 30, 2009

NextWar Crash Bug

A crash bug involving the "Send Next Wave" button has been identified and a workaround available. If you are experiencing this problem, please see the problem page at the Micron Game Studios website:

NextWar for Xbox 360: "Send Next Wave" Crash Bug

Saturday, March 28, 2009

NextWar: The Quest for Earth released for the Xbox 360!

I'm proud to announce that NextWar: The Quest for Earth is now available for download on Xbox Live Community Games!

It is available from the Xbox 360 dashboard in the regions of Canada, France, Italy, Spain, United Kingdom and the United States. Alternatively, you can visit the Xbox 360 marketplace website.

Micron Game Studios Website Link

Tuesday, March 17, 2009

NextWar: Coming Soon to Xbox Live

NextWar: The Quest for Earth Xbox 360 Trailer

High Resolution Download (46.9mb, right-click save-as)

Coming soon to Xbox Live Community Games.

Thursday, March 5, 2009

Melbourne Uni

The UniWireless wireless network sucks. Everything must go through a proxy. Can't SSH, can't telnet, can't rdesktop, can't access my Perforce server at home.

At least HTTP works just fine.