Friday, 28 December 2007

topmudsites.com: A Realm Continuum

Link: A Realm Continuum

I stumbled across this old thread created by Raewyn on Top Mud Sites Forums. There have been more recent threads on logging everything elsewhere, but Kavir came up with a particularly interesting idea which would be interesting to prototype. Namely treating the game as a simulation which can be rolled back, replayed and so forth via the log.

Raewyn: [link]

Given today's current technology, would it be within tangible reach to create an in-game logging system that could record essentially everything that is sent through the main program? Player actions, game states, objects, mobiles, gold -- enough information so that if needed, an administrator could set the time and place and be able to "replay" exactly what happened and when, being able to move and view events as a separated third-party.

By all purposes, one could "travel back in time" and determine how a bug was exploited, why the government collapsed, or even just follow up on a major player event. Someone could go back to obtain as close to historical accuracy as possible.
Kavir: [link]
Raewyn's comment about being able to travel back in time brings to mind a related idea I've been toying with.

I was recently talking with one of my staff about how best to implement weather, and one of the options discussed was generating it based on the system clock. Not only would this save having to store any information, but it would also allow players to accurately predict the weather.

Extending this idea further, I realised it also meant that players could go back in time to witness freak storms or unusually powerful weather. You could even have the sort of supernatural weather events you sometimes see in movies, with a 'freak time storm' starting up that allowed you to move backwards to the previous such event for the duration of the storm.

If this idea were extended beyond weather, and utilised for everything (from mobs to combat) then you could shift back and forth through time, witnessing the same events repeat themselves in exactly the same way each time - at least, unless you interferred, in which case the entire outcome of the event could change. This would allow for some very cool "Butterfly Effect"-like quests, whereby players could change the past in order to have some affect in the current time period. Alternatively you might prefer to avoid paradoxes by having people move back to an alternative timeline, or only allow them to travel to the future.

For combat, it would also allow for some interesting 'sixth sense' capabilities, allowing players to predict the outcome of a certain combat move, or even an entire fight - rather like the mage in Robert Weinberg's Horizon War trilogy, who spent years studying himself fighting against a particularly deadly warrior in the future, memorising every slight move and constantly tweaking the outcome, so that when he finally fought her he was able to respond perfectly to her every attack.

Obviously this doesn't help much from an OOC perspective (catching bugs and the like), but it could provide some excellent IC opportunities for players.

Monday, 26 November 2007

Flux player no longer open source?

Back when I last experimented with Flux Player and Flux Studio, I seem to recall their website still contained references to the player being open source. The source code in CVS at the sourceforge project was however three to four years out of date but there was an archived snapshot of a more recent release (fluxsrc-2006-07-09.zip) which is still available here and other places.

Now unless I am mistaken, all such references to it being open source are gone from the main Media Machines web pages. There are references in various other places to a later source code release from this year but all the files have been deleted from the sourceforge project.

It is still possible to find the deleted files if you google for the file names and substitute them into the standard sourceforge download paths:

This isn't the first time I have seen the wind down of the open source release of a commercial product on sourceforge. It is nice to know that with a minimal amount of effort you can track down the released files.

Given the four year old age of the files checked into CVS I wonder whether it was released based on an initial open source faith which waned in the face of reality or from buying into the false promise of there being volunteers who would pop up and help out.

Sunday, 25 November 2007

Giles Coren's restaurant reviews

Food blogs are a large part of the subscriptions I have in Google Reader. What makes a good food blog for me are good photos mostly, along with a description which adds colour to whatever is pictured. I find food blogs which lack photos mostly disinteresting.

I find it surprising that I enjoy Giles Coren's restaurant reviews on The Times Online website. But I do and I make a point of reading the new one each week when it is published.

A good piece of fluff that leads into the latest review about some Gary Rhodes restaurant:

What the phrase “hotel dining” mostly brings to mind is arriving in a strange city too late, or too tired, to check in your bags and then to scour unfamiliar streets in search of food, and so retiring to your room and dithering between room service and raiding the minibar.

The advantage of room service is that if you’re lucky they might do a cheeseburger, generally the only hot food worth risking from a hotel kitchen at 11.30pm; the downside is having to then wait until 1.30am for it to turn up. The advantage of the minibar is that it’s available immediately. The disadvantage? It’s that its contents have been chosen by someone who believes that (a) what you want when staying in a hotel is to eat macadamia nuts, a snack which no person has ever been known to crave at any time of year, and that (b) you are happy to pay for this jar of macadamia nuts a sum only slightly less than what you pay to get your car serviced. There is a third hotel dining option, available at 11.30pm, of strolling the hotel corridors helping yourself to other guests’ leftovers that they have parked outside their doors on room-service trays ready for collection: think of it as a floor-level buffet table. But few hotel guests are bold enough.

Monday, 1 October 2007

Preventing javascript redirection

For some reason, I wasted a lot of time this afternoon trying to make use of Firefox customisability in order to avoid having to log into Gamasutra in order to view the articles. I have no idea why, the article I was trying to get to, I didn't find interesting when I eventually got to see it. But I feel obliged to document the process for future reference.

When you visit an article on Gamasutra, it loads the page you want to see and in the process executes some javascript which checks if you have a cookie set and if not redirects you to its login page. I wanted to do something to disable this redirection.

var login_link = "https://www.gamasutra.com/php-bin/login.php...

//if the Gama Demo string does not exist, send them to login screen
if (pos == -1)
location.href = login_link
else {
My first attempt was in installing Greasemonkey. This seems to get invoked after the page has been loaded, at which point the redirection is already in progress. I could change the document.location value back to what it was being redirected from, but this just resulted in an infinite loop of redirection. I could catch the unload event and tell the browser to stop with window.stop(), but it seemed to stop after the redirection had started giving a blank page. Unless there is a formal way to stop what a previous assignment to document.location starts, Greasemonkey doesn't get invoked soon enough to help here.

The next attempt was with something I stumbled across when googling for "redirection". Firefox security policies. These have no user interface, but seem to be fully implemented. They enable you to do things like disable javascript for all sites or specified sites. Or disable access to various parts of the DOM, like document.location.

These lines would be added to a user's "prefs.js" file ("nogo" is just the random name I gave the profile myself):
user_pref("capability.policy.nogo.location.set", "noAccess");
user_pref("capability.policy.nogo.sites", "http://www.gamasutra.com");
user_pref("capability.policy.policynames", "nogo");
However, I could see myself wondering why the Gamasutra website wasn't working properly, so I just went with disabling javascript instead:
user_pref("capability.policy.nogo.javascript.enabled", "noAccess");
user_pref("capability.policy.nogo.sites", "http://www.gamasutra.com");
user_pref("capability.policy.policynames", "nogo");
More information on customising Firefox security policies can be found here.

Sunday, 30 September 2007

Vista explorer fixes

I use the explorer to browse directories a lot and in Vista which I had no choice but to get with my laptop, this is horribly broken.

There are two symptoms I see:

  • When I enter a directory it has reverted away from the Details view to whatever the icon default view is (not one I find usable).
  • When I enter a directory the files slowly appear one by one over the course of up to half a minute. While this is happening, a gray progress bar fills out in the address field at the top of the window and the disk is hammered with activity. I can abort this activity by pressing escape, but then I do not see whatever files haven't been listed yet.
I have finally found a partial solution for the former and a full solution for the latter in this forum post:
Set the list view for a folder that's using the 'All Items' template, then
use 'Apply to Folders'. Then override content-sniffing with my 'AllFolders'
regedit:

Copy the text between the lines below into notepad & save as a .reg file.
Watch out for line wrap -- [HKEY_CURRENT_USER\...\Shell] is all one line,
there is a space between 'Local' and 'Settings'.

--------------------------------------------------
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\Classes\Local
Settings\Software\Microsoft\Windows\Shell\Bags\AllFolders\Shell]
"FolderType"="NotSpecified"
--------------------------------------------------

Merging the .reg file will set the 'All Items' template for any folders that
don't currently have a view saved with a different template. You can clear
all saved views by deleting the

"HKCU\Software\Classes\Local Settings\Software\Microsoft\Windows\Shell\Bags"

key BEFORE merging the .reg file. If any folders open with a different
template after clearing the 'Bags' key & merging the .reg file, they most
likely have a template specified via their desktop.ini file.
Basically there is some mechanic which determines what kind of folder a directory is considered to be. If it is a folder for a kind of media, it will go through and read in all the files in that folder extracting information you do not know or care about so that it can be ready in the event you do. If you have the Windows Search indexing enabled, it might not do this every time explorer views the directory. But let's face it, search functionality in Windows never seemed to find what I want and in my experience with Vista it still doesn't. Enabling something which does nothing worthwhile is a choice I choose not to make.

When I select some directories I still see the wrong view, but it is much less often.

I only hope I can find fixes for all the other aspects of explorer which obstruct usability.

Wednesday, 1 August 2007

Live in Iceland: Moving apartments

My current landlord gave me notice that I have to move out of my apartment around a month ago, and was quite flexible about when I actually moved out. By law, the notice period by either party is usually three months. And it is a nice amount of leeway to find a new apartment, especially at this time of year when university is starting again and the good ones are snapped up almost immediately. So having a landlord who is happy for you to move out as soon as you can, can make it a little easier and cheaper, not having to pay two rents at the same time in the worst case.

As it is nice to know what needs to be done as part of this process, and to have a record of it for next time, I thought I would write it up here. On the agenda today was to transfer my telephone and internet connections to the new apartment. My telephone connection is through Siminn and my internet provider is Hive.

So first I called Siminn. Apparently you need to know the old phone number for the apartment you are moving to, so that they can reconnect your existing number there without sending a technician over which would incur charges (the salesgirl rattled off numbers like 7000ISK for the base fee and possibly 5000ISK more). I had a number I believed was the right one. However, the lease uses a different definition of which floor the apartment is on than what Siminn had for the phone number, so there was some confusion about whether the number was right.

After calling my landlady back, and discussing this I just decided to have faith that getting connected to the same place as her old number was sufficient. So I called Siminn again and went through the process, the salesman I got this time seemed unconcerned with the difference in floor numbers for the apartment. The process of transferring a phone number is supposed to take 1-3 working days. However, he then asked me if I had an internet connection and arranged for it to move with the phone number. He also mentioned that transferring the internet connection would take 1-5 working days. Excellent, that simplifies things a lot! Now I don't need to call Hive.

I hope however that the difference in floor numbering isn't a problem.

The lack of a cellphone is a big inconvenience in this day and age. A workplace isn't guaranteed to have phone system (given that all other employees have cellphones and are owners anyway so can use them for work business) like my current job or it might have a computerised phone system which is awkward to use like my last job. But something I have found with both my bank and now Siminn, is that they are more than happy to use an email address as a point of contact, in the absence of a cell phone. Communicating an email address over the phone however is sometimes not that easy. But as I get incoming emails pretty much instantaneously, it is a good way of making sure I am contactable. In the situation of not having a cell phone, it does make me wonder how people got by with just normal telephones before cell phones became common -- it just seems such an inconvenience to have to make sure you are in your apartment in case a call comes.

Tuesday, 17 July 2007

Stackless on the NDS actually usable now

While my port of Stackless Python to the Nintendo DS has been around for a while now, it was of little use as none of the native Nintendo DS hardware was exposed. The only IO supported was file IO through the homebrew library support (the disk being non-native hardware, the compact flash or SD cards which homebrew code was run from).

I had no expectation that I would ever find the time to wrap the hardware so it was callable from Python, and had pretty much given up hope that anyone else would step forward and do a little work on it. However, at the start of the month I got an email from Lorenzo Mancini, and he has started wrapping libnds and given a talk about it at PyCon Uno 2007.

Thursday, 14 June 2007

SoulFu

I stumbled across SoulFu on Free Gamer and from the screenshots alone, it looks like a quality piece of work. Turns out it is by the same guy who wrote Egoboo.


As a 3D hack and slash type game, it has a lot of depth. These are the sort of features which it has:

  • Minimap (as seen in the screenshot above).
  • Chests you can either use a key on, or bash open.
  • Pets or henchmen which follow you around and fight alongside you.
  • Objects and animals you can ride around.
  • Food dropping from slaughtered monsters.
  • Chests which are actually monsters (mimics!).
  • Traps.
There are all sorts of nice little touches. It gives you the feeling that once you have the solid base for a game, building on top of it and fleshing it out is a pleasure rather than a chore. And it reminds me of Dungeon Master in a way - it has that same sort of enjoyable to play, immersive and believable feeling which Dungeon Master had when it came out.

From what I have read, the author of SoulFu took four years to develop the game. And that is not surprising, especially looking at it at the source code level. Built on SDL and OpenGL, Aaron Bishop wrote his own scripting language (indentation based like Python), drew all the graphics, built in his own room and model editors. Also a editor for the font and even a music tracker! You can access these developer features by downloading the DevTool version from his website (linked above).

Looking at it for what it is, a one man effort, from the graphics to the music and programming, it reminds me of the programmers back in the day of the C64 or the ZX Spectrum. You can read diaries kept by some of the programmers back in the day documenting their efforts, which were published in Zzap!64 magazine. The collection section on this page features diaries, especially the one by Martin Walker.

Monday, 11 June 2007

rec.arts.int-fiction: Explaining Inform 7

Link: Explaining Inform 7.

Occasionally in the rec.arts.int-fiction newsgroup, between the requests for help with the syntax of the different interactive fiction interpreters, other interesting things are posted. I particularly enjoyed reading the thread I link to here.

Jeff Nyman:

In the thread "I7 Philosophical Distinctions" I had brought up some of the conceptual difficulties some classes I was teaching had with Inform 7. I was in danger of carrying that thread too far off topic, so I figured I'd post a follow-up here for those interested.
Jeff goes on to describe his findings in using the Inform 7 manual to teach the language to classes of both programmers and writers, and proceeds to discuss it with Emily Short, Graham Nelson and a few others.

Jeff Nyman:
Rather than have a manual broken up by conceptual topics (Relations, Actions, Advanced Actions) you'd have a conceptual chapter based on what storytellers (and game writers) do: i.e., represent characters. Within that chapter you'd talk about the means by which that can be achieved with Inform 7. (After all, they're reading about Inform 7; they're going to try this in Inform 7; you're trying to convince them Inform 7 is a good tool for doing so; --- you can't really separate the implementation too much from the ideas because then it becomes too theoretical, which would be the kiss of death for some people.)
Emily Short:
Now this is something that I can begin to imagine the shape of. Off the top of my head, I'm imagining things like:
...
Emily goes on to break down a very detailed hierarchy.

Jeff Nyman:
I think what you put there is definitely the closest I've seen to where this has all been leading me. I really like it.
This is some selective quoting of a small part of the thread. The thread goes into a lot more detail of course, and there is a lot I was not willing to extract quotes from because it would have meant I would have felt that I was summarising the thread rather than just highlighting its presence.

Update: Emily Short has posted about it on her blog.

Thursday, 7 June 2007

Firefox extension: Nuke Anything Enhanced

Having just printed out several articles from Gamasutra, the Nuke Everything Enhanced extension was extremely useful. Typically Gamasutra articles have padding on the right hand side of the page to fit in some text about the author and maybe some links to some other unimportant and disinteresting parts of the website. And an ad at the top of the page with a banner just below that.

With this extension I could just select sections of the page and choose the context menu option "Remove this selection". And within seconds the only thing left on the page was content.

Before:
After:

Wednesday, 6 June 2007

mudlab.org: Distance-based descriptions

Link: Distance-based descriptions.

This is just a summarisation of the first part of the thread. There are some interesting posts after this point by shasarak.

Kavir:

Long ago Alayla and I discussed the concept of having multiple descriptions for things based on how far away they are, and I've now come to the point where I could really do with the support for a centaur camp, which is only visible as a camp when up close, but can be spotted from a distance by smoke rising above the treetops.

However while thinking about it's usage for the centaur camp, I've come to realise that perhaps it'll need more flexibility than simply a handful of descriptions based on distance - I think it may require support for the sense of smell as well, which in turn may need to take into account wind strength and direction.
...
Kjartan:
Sound, too. Because there's necessarily a wind shear as you move away from the ground, sound headed upwind gets deflected into the ground after a certain distance, while headed downwind it gets deflected upwards. See this page, for example.
Kavir:
Good point, I hadn't considered that - although arguably there should be an overall "sound pollution" of which wind is only one factor. Other factors might include rain or nearby noises (eg if you're standing in a noisy town centre, you might not hear the distance sound of mine workers).

Although come to think of it, the same argument could be made for smell as well. Tracking someone by scent through a sewer or during heavy rain is going to be pretty hard, even for the most gifted of werewolves.

Could these all be handled through the combination of two generic factors though, I wonder? Weather (rain, snow, wind, etc) and Local (sound/smell/etc polution in the current area)? Light and dark could possibly be extensions of the same system, too.

Thus light rain might give a minor sound penalty and a medium smell penalty, while heavy rain could give a medium sound penalty and a major smell penalty, and a thunderstorm would give a major sound penalty and an extreme smell penalty. Equally, a rushing river might give a minor sound penalty, a sewer might give an extreme smell penalty, and so on.

You'd then just combine the two to calculate the overall penalty for each sense, which would then apply as modifiers to the PCs personal senses (adjusted based on injuries and such).
Kjartan:
Well, you've got a computer, might as well use it. If you're already coding a wind/smell interaction then it's minimal extra work to do sound.

It's actually a real effect, I have noticed it when shouting - it's not just that the sound gets dampened, if someone is far enough upwind - not even all that far if the wind is blowing hard - they absolutely cannot hear you no matter how loud you shout, but if you climb up a tree and shout then they can hear you just fine.

Monday, 4 June 2007

Rice milk with strawberry sauce

This is the third of three flavours.

Once again the strawberry sauce was very nice on its own and had a strong strawberry flavour similar to a more liquid strawberry jam. But I also preferred the rice milk without sauce here. See the cinnamon entry for more details.

2007-05-30 - CCP snacks - Strawberry rice pudding - 216
2007-05-30 - CCP snacks - Strawberry rice pudding, open - 231
2007-05-30 - CCP snacks - Strawberry rice pudding, mixed - 234

Rice milk with caramel sauce

This is the second of three flavours.

Flavourwise, the sauce had a very nice caramel flavour, but once again, I preferred the flavour of the rice milk when I had it without the sauce. There isn't much more to say over what I said in the entry for the cinnamon flavour.

2007-05-30 - CCP snacks - Caramel rice pudding - 219
2007-05-30 - CCP snacks - Caramel rice pudding, opened - 227
2007-05-30 - CCP snacks - Caramel rice pudding, mixed - 229

Rice milk with cinnamon sauce

This is the first of three flavours.

I love rice pudding. So it gives me great pleasure to see a form of it available in Icelandic stores as a snack food, although I would never buy or eat this form of it. The rice pudding I make myself has a much ricier taste and is less fattening for much more volume.

2007-05-30 - CCP snacks - Cinnamon rice pudding - 220
2007-05-30 - CCP snacks - Cinnamon rice pudding, opened - 224
2007-05-30 - CCP snacks - Cinnamon rice pudding, mixed - 225

When I tasted the rice milk part by itself, my first impression was that the rice was undercooked as it was surprisingly firm. But having tasted the other two flavours in the range where the rice was so soft as to blend in with the cream, I actually prefer it firm. Although I suspect in this case it was a manufacturing anomaly that it was firm at all.

The cinnamon sauce is sweet and tasty, as it should be given the nice amount of sugar which probably went into it. Mixed into the rice milk, I tend to find they blend together in such a way to produce a confusing flavour which doesn't stand out. This is something I find for all three flavours of rice milk pottle -- that I prefer the rice milk by itself. And that the sauce only really has a flavour when tasted by itself.

Skyr

As part of my dietary regine, I try and keep a given ratio of protein, carbohydrates and fat. This being high in protein is something I rely on to keep the protein part of that ratio. It saves me a lot of time, effort and money to be able to just grab a pottle out of the CCP fridge each morning.. well most mornings when it is in there.

It has a rather strong taste, a little bitter. I used to flavour it with honey and cinnamon, but I don't think that made much of an improvement. Now I kind of don't mind the flavour and eat it plain. I would also recommend cutting up bits of red pepper and scooping skyr out with them, they go nicely together, and the skyr then has a sour cream taste (but is much healthier).

2007-05-30 - CCP snacks - Skyr - 222

Skyr.is mango and passionfruit drink

I usually have one of these first thing in the morning. While it is definitely mango flavoured, I am not 100% certain about what √°staraldin is. I think it is passionfruit. It tastes like neither of these things to me, but unlike some of the other yoghurt drink flavours, it doesn't taste chemically either. The liquid inside just looks like thin white milk.

2007-05-30 - CCP snacks - Skyr.is drink, mango and passionfruit - 223

The CCP snack fridge

CCP is a great place to work. And one thing I really like about it is the food. While I no longer eat the lunches there (the only meal I am present there for), I do eat from the snack fridge in order to get more protein into my diet. It is interesting to note that you have to mark down what soft drinks you consume and that gets taken out of your wages at the end of the month but these snacks, most of which are healthy, are free.

The full selection you can see here is actually missing some items. Usually there are rice puddings and more flavours of the yoghurt drink on the lower shelf.

2007-05-30 - CCP snack fridge - 205

These skyr drinks are all very tasty. I tend to go for green mango one as it has a higher ratio of protein to carbohydrates. I think they are all sweetened with aspartame, which keeps the calories low. There is no need to be afraid of the aspartame :-)

2007-05-30 - CCP snack fridge - 206

I tend to avoid these flavours of skyr. None of them particularly taste appealing. Not that they taste bad, they just don't register as something I recognise the flavour of.

2007-05-30 - CCP snack fridge - 207

The one the left is the plain skyr. This is what I eat and tends to have a lower amount of calories and higher amount of protein. The yoghurt drinks I tend to avoid, finding they taste more like some weird chemical combination rather than fruity goodness. And the breakfast cereals / yoghurt combos.. well, they like the rice puddings are unlikely to be too healthy. I tend to find yoghurt tends to crowd out the flavour of anything mixed with it anyway, so it would just be a grittier yoghurt.

2007-05-30 - CCP snack fridge - 208

Sausages, eggs, bacon and scones

Since seeing something similar on someone else's blog, I had been craving a Saturday morning meal along these lines. And normally eating like a monk, that craving was getting stronger and stronger. This is what I ended up with.

2007-04-20 - Sausage, egg, beans and scones - 159

The sausages were of course tasteless, the beans most likely hiding the distinguishing taste of nitrates. As was the bacon. But the beans and scones were delicious.

Icelandic cheddar

Iceland isn't a country I would recommend to someone who enjoys food. And cheese is one of those things which there is a lack of availability of decent types - especially cheddar. Since Noatun is the cheapest place to buy the brand of tea I prefer, I often pick up other items I need while I am there. This led to me stumbling onto an Icelandic cheddar.

2007-05-10 - Icelandic cheddar - 182

The cheese had a distinctive flavour which I am no longer able to recall. I would qualify it as edible but a little bland. One might say it was a worthy representative of other Icelandic food.

Shortbread with cornmeal

I have become addicted to shortbread to the point where I often find myself thinking that a cup of tea just isn't enjoyable without a piece. When I made this batch I decided to substitute cornmeal for cornstarch - I think I mistakenly thought I was out of cornstarch.

That substitution is not something I would recommend. The shortbread tasted like someone had mixed cigarette ash into it and had a sandy texture when eaten. However after sitting for several days the ash taste seemed to go away, reinforcing my preference that a batch of shortbread should sit a few days before being eaten.

2007-04-21 - Shortbread, cornmeal, cigarette ash flavour - 168

Friday, 1 June 2007

mudlab.org: Database options

Link: Database options.

This is how it is done in EVE Online. We also have a web based interface which all game design, game mastering and general live game state browsing/modification is done within which we call ESP (EVE server pages).

We initially started off when we built one of the intermediate prototypes of the game by serialising the complete state for objects (using Python's pickle module). Like the character's state and the state for a ship which the character might own.

The pickling was ditched as a matter of course once we got a database server hooked up. However, where we have pickled blobs into the database for certain features (other programmers than I) it has resulted in confusion and pain. The problem encountered was that it made the saved state dependent on the implementation of the object, which is definitely something to avoid. Since the programmer who did it left the company, the next programmer who inherited the system proceeded to make changes which were incompatible with saved state which was then erroring when unpersisted. It was very difficult to track down, considering that only a few rare persisted blobs were incompatible.

Our objects are authored by content with values in this manner:

typeID, attributeID, valueInt, valueFloat
And attributes are defined in this manner:
attributeID, attributeName
And values for object instances are persisted in this manner:
itemID, attributeID, valueInt, valueFloat
We started off with valueString as well. But it turned out we had no need for it, so it was dropped along the way. In a text MUD I can see that this would of course not be the case.

If there is one thing I could change about this in retrospect, it would be to create some manner in which a set of attribute values could be defined as a group. And then rather than having to set all of those values on a type, you could just associate the attribute value sets with the type. This achieves several things. It reduces the work which the content department has to do to author new types and maintain existing types where all these attributes had been authored in a similar manner. But the key reason it has been discussed is that the sheer number of types and attribute values defined for types in EVE Online makes for a huge amount of static data which has to be sent to every client which connects. I personally care less about the latter reason and more about the former.

Another area discussed where it has been appealing to allow the content department to author sets of attributes for types, but in a different manner, was for the scenarios they author. The problem here was that if they wanted an existing type to be spawned, but with some type attributes changed, they needed to copy the type and modify those attributes. By allowing spawning of types but with overriding sets of attributes (something which wouldn't be too hard to implement for EVE but hasn't been done), this removes that need to copy.

Wednesday, 2 May 2007

Using the free MS C toolkit

The final part of updating Stackless Python to Python 2.5.1 is where I need to build the Windows binaries. Anyone downloading these extracts them over a Python installation and they need to be compatible with any extensions, which requires the use of Visual Studio 2003 or the free MS C toolkit in compiling them. Not having Visual Studio 2003 I had to try the toolkit approach.

After installing all the prerequisites, executing the provided .bat file and then running nant as described, I started the build process. However it failed, unable to find make_buildinfo.lib. I generated this lib file myself using lib /def: x86-temp-release\make_buildinfo.obj. Then I had to do the same for make_versioninfo.lib. After which the release build process was completed successfully. And the debug build process also, although that required editing the python.build file to replace references to 'release'.

For anyone else needing to compile Python or extensions for it compatibly with the released version, I would recommend this approach. It involved a little extra effort, but this is something I expect in this day in age in pretty much any development activity.

Thursday, 19 April 2007

Honey Tea Buns

If I had had the ingredients, this is what I would have cooked rather than rock cakes as a promising accompanyment to my cups of tea. Honey tea buns. It pretty much describes what I am looking for.

2007-04-19 Honey Tea Buns 147


Unfortunately, it is just a gussied up scone :-(

The ingredients required presumably over a basic scone recipe (although I have not checked) were ground ginger, orange rind and honey. However, these things barely affected the flavour. I ended up topping the halves with jam, butter and jam and finally honey in order to round off the blandness of the taste of scone.

If I knew I was going to be cooking scones, I probably would have tried to make clotted cream and gone for what is classed where I grew up, as devonshire tea. Cream and jam on scones with a pot of tea.

But this attempt at finding a good tea accompanyment was definitely educational. It left me with the feeling I wanted something more biscuitlike. The rock cakes for instance, although small, were definitely on the right track. Perhaps if I made larger sugar bun sized versions of those. Although that would be very high in calories.. the rock cakes were around 180 calories for two small cakes which together weighed 50 grams. So looked at from that perpective, the rock cakes are a good size for having one or two as an indulgent snack during the day.

Wednesday, 18 April 2007

Polish Sausages

One of the many foods I have been missing since I moved to Iceland, are normal sausages. I can find salami, which are actually pretty good. Spanish sausages, which have that the same icky mouth taste as you get when you walk near where a cat has sprayed. But there are no normal sausages in sight.

I do most of my shopping at Bonus, a supermarket which is the cheapest in Iceland -- for what that is worth. Most of the time the vegetables are already off, if not then fairly well along their way to being off. And more often than not what I am looking for just hasn't been restocked or is no longer available. Which leads to me really scrutinising the shelves to make sure I haven't missed it. And that led to me finding these sausages.

The ones I initially found were bratwurst sausages. And I fried a couple up. Not a good show. They had a hard taste, if I had to guess what it was, I would say the nitrates used in making them. But since I am a glutton for punishment, and because I really want to punish myself with a full on english breakfast, I bought these polish sausages as well today.

2007-04-17 Polish Sausages 133


On Saturday morning it is going to be sausages, bacon, beans, eggs and buttered bread. I can't wait.

Rock Cakes

Most of my baking efforts are aimed at finding something decent to eat with a nice relaxing cup of tea. In this case, what I really wanted was sugar buns. Not having a recipe for them, or much in the way of ingredients, what I did could cook were rock cakes. I pictures large hefty buns which became more and more satisfying as they got a little stale (the best kind of "cup of tea" snack).

What actually ended up being baked were these tiny walnut sized "cakes"...

2007-04-15 Rock cakes 17


Still, they were tasty and just as good the more stale they got. Next step, find a recipe for something like what was called sugar buns back in New Zealand.

Wednesday, 11 April 2007

Anachronox modding

Several years ago now, I bought a budget release of an old RPG called Anachronox. After playing it through, something of an odyssey given the large amount of gameplay it provides, for some reason I ended up wanting to decompile the game logic scripts which were used to implement the gameplay. Actually, now that I think about it, it is more likely that I wanted to bypass a part of the game I just couldn't work out how to complete. In any case, one thing led to another and I ended up looking at Species' Java APE decompiler.

Now I could have easily extended his decompiler but there was no documentation about all the eccentricities of the compiled format and in order to learn enough about them to understand why his decompiler worked the way it did, I would need to have written it. So I ended up writing my own decompiler from the ground up in Python. It worked well enough, it seemed to handle all the APE constructs I could locate in all the forms I could think of and definitely handled things Species' decompiler didn't. Like nested if statements.

Having something which "worked enough", I released the source code to what served as the Anachronox modding community. By this time, several years after the game's acclaimed (but not as popular as it should have been) release, the community was pretty subdued.

But a fellow New Zealander called Laguna (who was still in high school) popped up. He did a lot of work towards making Anachronox more approachable for modders, including pushing me to look into various things. Then he faded away having graduated high school (most likely to a more thankful productive life) working a burger doodad at McDonalds from what I hear. A pity as he was an extremely skilled game modder and Anachronox wasn't the only project he worked on, another was an impressive looking Half-Life mod by the name of Battlegrounds.

Now thankfully someone else, called Creaper, is working to move the Anachronox modding support forward. Initially he started by fleshing out the modding documentation which the original game developers released and now he is submitting bug reports for the APE decompiler! In the past couple of weeks, with his help, it has been getting much more polished.

While I am focused on the decompiler, I have decided to take advantage of the impetus and release my Anachronox modding scripts and other related projects to Google project hosting:

Empirical evidence dictates that only Creaper and I will use them, but maybe eventually his efforts will bear fruit and someone might find them useful in helping develop their own modded game based on Anachronox.

Help wanted: Creaper needs hosting for the Anachrodox website (currently comes to around 5 gigabytes of space) so if you know anyone who is willing to host a game modding website for free please sing out.

Monday, 9 April 2007

Rice Pudding

Another food from my childhood that I have been craving since starting my diet is rice pudding. A dessert I remember making myself when we lived on Alford Forest Road in Ashburton.

While I remember how my brothers and I made it as children, I am a little ambivalent to cook it that way as I think it involved sweetening with large lumps of ice cream. Instead I decided to search the internet for a promising looking recipe and ended up with this one, which curiously uses an egg, something we definitely didn't do when making it. However I cut the recipe back to milk, rice, egg and raisins and sweetened it with honey, which I find I need to use very little of.

2007-04-08 Rice Pudding 81


Dietwise there are a number of reasons I can justify this. It uses less rice than I used to cook with my stir fries. It uses a lot of milk which bumps my calcium intake over the 100% RDA level. And it also usually bumps my calories up over the 2000 calorie point, something which is definitely good as it will prevent me from losing weight as fast as I am. Something my other wanton efforts at baking are no doubt more than making up for anyway.

Sunday, 8 April 2007

Banana Loaf

After being well pleased by how the banana cake turned out, I felt like a loaf would be more satisfying eating. As it happened my cookbook of choice, a stained and soiled copy of the Edmonds cookbook, had a recipe which claimed to a banana loaf. And also as it happened I had several more bananas which were stinking up my apartment more every day.

This is the result, or what is left of it:

2007-04-07 Banana Loaf


At first I tore off chunks and was kind of dissatisfied by them. I had two thoughts as to what to do with the loaf. If I were making it again, I would put in raisins and broken up walnuts and make something with a deeper taste. Or I could treat it like a pudding sponge and sprinkle raisins and cinnamon over it, then soak it in milk. Since only the latter was a practical suggestion, I went with that. It was so good that I had two servings. And then I remembered to take that picture..

Since the banana flavour in the banana cake was not as strong as I would have liked, I went with more bananas than the recipe required and left them chunky. Which should explain the slimey look the loaf has in the picture :-)

If I am going to do a better job of food blogging, I need to be a bit more proactive about taking pictures. I was too slack about getting one of the iced banana cake and also here with the loaf as a sponge dessert. Like my high school reports said, "Must try harder."

Banana Cake

Having had some sort of success with the coffee cake and my diet not being followed too well, I was inspired to try and bake a banana cake. The first step was to buy some bananas and let them ripen. Once the bananas were looking kind of ripe on my fruit and veggie table *cough* I felt obligated to actually step up and bake the cake. This is how it turned out:

2007-04-05 Banana Cake


Light, well risen. I would call it a success.

However it didn't taste particularly special. It wasn't bad, just lacking something which took it beyond un-iced cake and into delicious snack territory. So I iced it with chocolate icing. And it tasted better, but I think I could do better. Next time I would probably go with a lemon butter icing. Or a chocolate icing made with something more chocolatey tasting than icing sugar and cocoa powder.

Coffee Cake

One memory I have of childhood birthdays which sticks out is eating coffee cake at my grandmother's place on Porter street in Ashburton. While I have cooked one since coming to Iceland, I didn't have all the right ingredients or any suitable baking dishes to cook it in. As a result it turned out rather.. well, misformed, but definitely still tasty.

Now being on a CRON diet I have been hankering to bake another but unable to. Since I was going to a friend's place for dinner on what I call an "off diet" day several weekends back, I offered to cook dessert.. namely coffee cake! However, the cake I initially baked didn't rise that well. I decided to bake another and ended up with two halves which hadn't risen. So I glued them together with coffee icing and then iced over the stack ending up with this:

2007-03-24 Coffee Cake


Needless to say it was rather heavy, something like five kilograms, but I was reassured that cakes were supposed to be pretty heavy. And it went down quite well, I wasn't the only one to have second helpings.

How could I do it better next time? Well, I have a suspicion that it makes a difference to follow the recipe and split the cake mix in two and bake two halves from that separately. It might rise better. And in any case I could pad it out with filling to make it seem larger. I recall the cakes I had at my childhood birthday having both raspberry jam and mock cream slathered between the two layers (the former then the latter).

Sunday, 11 March 2007

Ajax3D experiment: Flux Studio - Getting acquainted

I don't have much experience with using 3D modeling tools, so when I see something like the following when I start a tool like Flux Studio, I am at a loss for any idea what to do with it.


So in order to work out how to accomplish what I have seen others create using this, I started by looking at their creations. One example which stands out in the gallery on Media Machines' web site is New by MrGB.


Looking at it didn't learn me nothing, as they say. Well, 'they' probably don't say it. In any case I decided to download the X3D file and see what I could learn from that. After all, X3D is XML. Loading it into a text editor quickly showed that it was either compressed or saved as some form of binary encoding. So I decided to try and import it into Flux Studio with the following result.


With it imported I could now export readable XML within which I could see local references to textures. So I went back, tracked down the directory the X3D file came from and downloaded all the images located there. This gave me a textured display in both Flux Player and Flux Studio.



Looking at the preceding Flux Studio and XML screenshots, you can see that the same node is highlighted in each. In the XML it is named 'dad_MoveF' and in Flux Studio it is called 'Group13'. I am not sure what is up with this, but it makes it quite a bit harder to ascertain what is going on when looking through the node hierarchy in Flux Studio than it is when doing the same by browsing the XML.

The most interesting thing which I came to realise through poking around at New is that all its game behaviours are completely implemented in terms of nodes. While it is possible to embed ECMAScript in X3D, as it was also in VRML, MrGB (also called GammonBrat in some other places) did not use it in the creation of this game prototype. And New includes a variety of interesting behaviours like picking up objects, jumping, using picked up objects and killing an opponent. And of course it looks great :-)

Saturday, 10 March 2007

Ajax3D experiment: Learning X3D

One of the problems with X3D is how little useful information there is on how to use it. There is the occasional tutorial, blog entry or forum post which is relevant to what you want to know, but beyond this it seems to come down to blind experimentation. With plugins which also support Firefox but tend to be very crash prone in it. Or largely undocumented editing studios.

Now X3D is a standard and it does have specifications which you can browse and download, but in my experience they tend to have their own accessibility issues. Designed using frames and not available in a form conducive to either printing or looking up items of interest, what you really need is for them to be available in other more accessible forms. Like PDF. Unfortunately they are not.. well, actually they are available to some definition of the word. You can pay an extortionately high price to get a PDF of at least the main specification from ISO:


230 CHF? That's around 270 $NZ in real money. Or 11000 ISK in not so real money. It'd almost be worth my time for that price to write a Python script to reformat the frame based HTML.

On the bright side however, www.web3d.org does provide zipped versions of the HTML for download. And I may refer to a few problems with Media Machines' plugin and editing studio in my initial paragraph, but they are both very capable and free and still my X3D tools of choice.

Friday, 9 March 2007

Ajax3D experiment

Years ago I used to do MUD development as a hobby. The direction we were heading was to define the text based game world in 3D in order to have a continuous world rather than room based as was the standard. The long term goal was to have a simple 3D editor to streamline world building. Luckily one of the other programmers, Brian Behlendorf, was a doer and he put his head down and came up with a prototype. A VRML viewer for the game world. It took advantage of the fact that our MUD had an integrated web server, which could be used to fetch the static world data, and used Javascript to make a VRML plugin (Cosmo Player) fetch that data from it.

Nowadays I have a hobby project I need to visualise. There are easy ways to do this like PyOpenGL or PyGame, but taking the direction behind Brian's VRML viewer and extending it for the latest trends like AJAX (which I assumed could be used to establish a bidirectional channel) has a lot more advantages. It is in my best interest to educate myself about the latest web development techniques like AJAX and the end goal of having an X3D based browser client is an interesting project in and of itself.

The first step was to learn what AJAX was and to get it working with a web server. I encountered Pyjamas which looked promising, but the problem was that it had been a long time since I last did Javascript programming and given that it replaces that with Python, it looked like it would get in the way of the learning process. Next were the various Javascript frameworks and as interesting as they looked, it also looked like I needed to learn Javascript before I could benefit from what they offered. In fact it looked like the approach I needed to take in order to achieve what I wanted and to ensure I understood how it all worked from the ground up was to build it from the ground up.

Interestingly the people behind my X3D plugin of choice (Flux Player) have started Ajax3D.org in order to forward the use of AJAX with X3D. Although the examples it provides are just simple client based AJAX and none go to the extent of establishing bidirectional communication.

Anyway AJAX led to JSON and I ended up using BaseHTTPServer with simplejson on the server side and JSON in Javascript on the client side with Flux Player embedded. And this is the point I am at now, learning X3D and how to use it, especially controlled by browser based Javascript. One setback however, is the fact that Flux Player seems crash prone. When you combine that with Firefox's saving of tabs, what you get is a browser which
continually crashes every time it restarts unless you are willing to throw away whatever else is in your other tabs. In theory Flux Player is open source but it looks like releases of the latest source code have trailed off years ago, so debugging this myself is out of the question. Oh well, will see how it goes.

Tuesday, 9 January 2007

Stackless Python 2.5 for the Nintendo DS

I have recently been corresponding about NDS Python with several people on a range of topics and a common problem each had was that they were unable to work out how it should be compiled. Since there were some gray sunless summer days, I decided to flesh out and correct the instructions I originally wrote. A day later and the end result is that this lead to me updating the existing port to the latest version of Stackless Python.

Porting Python to another platform given the presence of C runtime libraries is actually pretty straightforward. Most of the work I did in the original port of Python 2.4.3 was on two different aspects, getting the Stackless hard switching to compile properly with arm-elf-gcc and hooking up the hobbyist file system support for homebrew devices to the C runtime so that Python could access it. And similarly with the Stackless switching already working, the work in porting Python 2.5 was updating the code which hooked the file system support to the C runtime for the changes in the development environment devkitPro.

As a standalone Nintendo DS application it is still as useless as the last port due to lack of support for the DS hardware. I go into that in detail on the web page I link to for it above. But given an application which provides Python bindings for custom access to that hardware it might however be usable as an embedded scripting language.

Monday, 1 January 2007

The state of hobbyist MUD development

While it is summer here in New Zealand at the moment, the weather hasn't been reflecting it. I have been taking advantage of the opportunity afforded by the gray skies and occasional rain to look at a few things on the internet which I find interesting, but never seem to have the time for. In this case, the current state of MUD development discussion.

One of the topics which many opinions were shared about back in the day was what the term MUD covered. Some thought that it should just refer to text based games, as it originally did. Others thought that it should include all similar networked multiplayer games, specifically graphical massively multiplayer ones. However the most vocal of these tended to run their own text MUDs and their insistence on this was most likely because they felt not establishing this link diminished their own games. But my interest for the purposes of this post is networked text based games and discussion about their development which I hope this post covers. If I use the term MUD below, it is with regard to text MUD development.

Five years or so ago the MUD-Dev mailing list was the best place for technical discussion. However the discussion there turned towards the business and design aspects as "massively multiplayer" games became more and more popular. But it was mostly a mix of commentary on the state of the industry and personal opinions often directed by frustration with the design of the current games people were playing. Eventually the list died out although it has since been been relaunched by someone else as MUD-Dev2 although discussion on it is still sparse. The online periodical Imaginary Realities was another interesting resource with its own discussion forum although it stopped being published around the time MUD-Dev started to wane for text MUD development discussion. Fortunately there is an unofficial archive containing all the articles it published (some can also still be found in on archive.org).

I think part of the reason MUD-Dev died out was because there were better places to have the discussions. MUD-Dev was an improvement on the newsgroups like rec.games.mud.lp and rec.games.mud.admin which were the alternative before it. And the improvement on MUD-Dev were the posts and comments on blogs and in forums.

I was unable to locate anything worth mentioning in the way of blogs. Looking for mailing lists was not worth the effort because if there were any interest in discussing MUDs on mailing lists, MUD-Dev or rather MUD-Dev2 would be the place to do it. The newsgroups now serve only to receive spam. But forums with development discussion areas seemed to be relatively common.

The most general and relevant of the forums I found were:

Between them there is a decent level of activity with a range of different topics and posters involved, something heartening to see. Although to a degree the same things are being discussed, the same questions asked and the same answers given as "back in the day".

One thread posted in October was called "MUD design... all talk?" And new threads do often seem more an act of procrastination rather than something the poster needs help with. Many posts ask about things which aren't that complex and which the poster wouldn't need to ask about if they just went ahead and implemented what they described in the rest of the post. Then there were the posts about how to implement standard MUD systems, something not wrong in and of itself unless there is no consideration given to or understanding involved about why those systems had to exist. And completely worthless, the involved discussion that went on about trivial implementation details, so trivial that you wouldn't believe. The only way I could reconcile the existence of these discussions was by assuming that the posters were writing their code in languages which were unsuited to productive MUD development and got in the way of their seeing the triviality. On a positive note however, higher level languages like scripting languages feature much more commonly as a choice of language in the discussion.

Reading the forums made me wish there were summaries of the range of discussion for the common topics, so that I could post a link whack-a-mole style as each arose. Not that I would want to discourage further discussion on those topics, but rather to hopefully divert discussion towards areas not already covered in the summaries or to encourage meta-discussion about the content of the summaries. The thought of someone posting links in this manner does seem like it could dampen discussion. But is that discussion needed? In its absence would more productive discussion take place? An interesting project would to to use the linked forums, the MUD-Dev post archive, the Imaginary Realities article archive and the newsgroups which Google hosts archives for these days as a resource to base wiki pages covering common topics on.

Is there anything new and interesting being discussed? Not that I could see. But that is not necessarily a negative sign and doesn't mean that there aren't interesting things being discussed. There is a certain level of gameplay which can be implemented if a MUD is ever going to open and even if the developers are interested in something more, they are unlikely to have the time to implement them. Under the ceiling imposed by what can realistically be implemented there should still be a wide scope to varying under it, and a lot of the discussion in the linked forums falls there and confirms this.