The last couple of days have only been marginally productive :-(. The infrastructure for Stargellas console is virtually complete, except for the prerequisite renderer code. Soon it’s time to move on with the usual loop, progressing to [SAS] related projects, then cycling to EPI, and back again to my usual loops.

My dreams have been someone erratic lately, but so far, have remained quite consistently the opposite of whatever I’m thinking about when I drift off to sleep. I’m not sure if that’s a good thing or not. It seems no matter what, it’s virtually impossible to sleep without thinking, short of working myself to exhaustion. While maintaining a deep holmesian focus seems to be great for pushing everything out of mind, keeping that up for more then a few weeks is staggering :-/.

One good thing to come of today in particular, was scoring a 95% on the driver’s practice exams on the relevant state website. I can’t help but wonder, if some of the multiple-choice answers were intended for evaluating brain damage, but hey, maybe I’ll pass it. I’ve also found out that out here at least, being in my current age group, I could forgo the learners permit and skip straight to an exam for a full driver’s license, but rather would prefer the proper chance for learners-time. Although, I still expect family to fsck me in the end o/.

A fairly full work week is starting off tomorrow (the one luxury of being off Mondays, is work begins Tuesday). If it wasn’t passing 02:22 local time, I think I would grab a snack and read the a few standards cos, but alas, time to hit the hay, eh, pillow.

Much of the last few days has been spent in toying with data structures, and testing a few dozen hash functions for use with a simple hash table module. It’s actually the first time I’ve ever had to implement a hash table myself, lol. It’s a fairly simple creation built on top of chaining.

The perfect hungry mans analogy for those that know squat about data structures: let’s say you want to find a recipe for peanut butter cookies in a cook book. You could thumb through every couple pages of the book, looking for cookie recipes, or even flip over to the index in back, and depending on the quality of the index, hunt down by looking down the index and systematically checking all cookie references; linked lists and arrays more or less work similar. A hash table is more like a table of contents: you flip open the book, go to the ToC, and find the section with the cookie recipes, then flip to that page and start flipin’ every few pages until you find the one you want.

Hash tables work essentially the same way, you feed in the key (peanut butter cookies, yum), hash it down to an index to where you can find the target. Although hash functions that don’t collide (often enough to care) are possible, when you have to bind the generated index within a given size, the odds of several different keys sharing the same index skyrockets. So instead of a direct 1 to 1 mapping, you have a needle to which haystack mapping.

My implementation uses a dynamic array of bucket lists that are allocated with HashTableCreate(), each element is a list: every key is hashed then squashed down to the size. When a new key:value is inserted, it gets added to the bucket list. On look up, the key is hashed back to the same value in order to find the correct list, in which to hunt down the correct entry.

One reason I chose separate chaining, other then it fits with how my brain works; many schemes for open addressing (the alternative), feels more like something I would think up, in order to skip writing a hash table >_>. Although, I must admit the possibilities of  open addressing combined with quadratic probing are interesting; I’m more in favour of the chains. While I doubt my implementation is memory efficient—since the only two design goals were to be faster then a (pure) linear search and quick to hash out the code, it undoubtedly has it’s flaws. For the sake of testing how it effects the intended usage, I may try augment/replace the current behavior of prepending new entries to the lists with moving last requested keys to the head, or switch to using red-black trees in place of a linked list.

I spent several hours testing different hash functions, using a small input set of words and a larger system dictionary file for testing. HashTableCreate() allows one to specify which hash function should be used, and it’s possible to override with a user supplied one. In testing, I’ve found using hash functions created by people with a background in mathematics, works significantly better then my own, as duly expected lol. Other then dealing with hash function issues, the rest was a cake walk.

Of geeks and logs

Took it ‘easy’ yesterday, played some games and the only work that got done, was fairly light debugging / library installing / feature adding. Originally I planned to setup expat, libxml2, and libxslt under MinGW/MSVC, but called it a night after expat. Found an interesting thread on Daemon Forums, which shows either I really need to get a life, or a good nights sleep.

Grabbed a trio of cookies, put on the simpsons, and went to bed early, around 0100R; the easier solution :-o.

Had a fair bit of trouble getting to sleep as always, but being winded helps. By a quarter to 0700R, I had already woken up three times :-/. It was a half past noon when I finally got out of bed, not being disturbed makes for an interesting opportunity to sleep like a log and enjoy crazy dreams lol.

For my p resent activities, I’ve merely worke don importing my Live Journal entries from February 2009, into Blogger. I don’t think I’ll make my goal of having it all done before 2010 arrives, but alas, it will get done eventually!

Local time is reading 01:40R, so it seems that I’ve survived another Christmas on this rock. Much of the day, has really been spent trying to avoid the holiday altogether, for all practical intents and purposes. At least I got plenty of C code written for my games :-/.

The only real good thing out of the day, was a the ecard a friend sent—my one smile of the day.

It has been a some what hectic day, logged off around 0400R last night and couldn’t sleep, by the time I finally started to doze off, ma started shouting and jarred me awake again :-(.

Fast forward to like 0815 this morning and she does the same damn thing, I’ve had about 3 hours sleep, tops. Getting back to sleep is unbearable, improbable, and time passes slowly. Fast forward again, to about 1045R, and I’m thusly awoke again. In fact, by this point, I’ve had sooo little sleep, that I didn’t even realise that I was having a dream, until I was woken up! Went back to bed and finally got up sometime after 1200R, to be used yet again as a cheap slave…. I’m tired of being nothing more then an asset.

The only positive things so far, is I’ve had time (~1 hour) to play with my file server with only a half dozen interruptions or so. For me, that’s a blessing.

No idea what I’m going to do for the rest of the day, I’m not really in a good mood…. and there’s nothing much that I can get done right now, that is not going to result in headaches later. I fucking hate my life here.

I just had some fun :-D

Was walking to the mail box, and on the way back an older man asked if I was cold—like normal, I’m out in sandals, shorts, and T-shirt and it’s freezing cold out.

“Nope”
“Wow, you must be part escamo or something”
“I was born in Flordia, so I love it: beats 90 degrees!”

😀

****sigh****

Haven’t been updating my journal here lately, been to busy with work…. still 2 or 3 days of labour to deal with to boot.

Router has been giving me grief for at least two days, and previously was a power outage; I’m starting to think that the outage my have damaged the router somehow. If that’s the case, I am really fucked—because I can’t afford to replace the S.O.B.

Even worse, on top of that, I got up to cycle the router again and my finger hit my laptops power button while a port was upgrading, what a fsckin’ night!

If only I could …

My original plans for the night, was to be working on my games and setting up a test suite for the SAS project I’ve got on the side burner. However, since  being informed  Thursday that my Saturday was being taken *away*, I’ve been tasked with not staying up all night tonight: fat freaking chance of that. So instead of being up until 7 am working on code, I played a few hours of Quake Live, lol.

I expect that tomorrow is going to be a living hell anyway it’s sliced…. have to be used as a navcom so we can get to work, it’s likely to be to be on par with the worst job I ever had, and is in effect, a continuation of the second or third most utterly-exhausting-fml job I’ve ever had…. the kind you feel like you were dead when you get off work, instead of feeling like you’re dying. On the upside, I ought to get to see a few dogs that I haven’t seen in a while; which reminds me of a pair of sad memories[1][2].

One way or another, tomorrow is likely to be a wash out, of torture and getting nothing done. I’m already wishing it was Sunday…… !

Don’t feel like going to sleep, but if I don’t start snoring in the next 15 minutes, I’m not likely to be up tomorrow; would rather be having a snack. I know my body, and in all probability, I’m probably going to be awake for 2 or 3 more hours 🙁 🙁 :-(.

I’ve just posted a call for title/story ideas on [SAS], in the hopes of moving foreward with the TacFPSGame project and my toolkit for working on the Starfighter game.

Today I was reading an arcticle off /. and started to think…. gee, wouldn’t it be an interesting game idea: it started me to thinkin’ and combined with all the Quake Live I’ve been playing lately, get’s me back in the mood to work on game development lol. I really want the FPS to reflect my style of things: it should be fairly realistic in nature, but still a fun action game. Perhaps the original Rainbow Six or SWAT 3 are my strongest inspirations for the tactical elements, while Quake III and Urban Terror remind me of how much fun “Crazy off the wall” can get ;).

When it comes to the general game design and architecture, I know what I want both inside and out. It’s just the issue of having time to work on it. My primary loops at the moment, are working on EPI and some stuff for [SAS], but once that’s done, I’ll have plenty of time, in so far as my available coding time goes that is lol.

I’ve also elected, to start testing a conversion from C++ to Python. I originally elected C++ because it was the lowest common denominator for getting the best tools, and well, I can care less about having to deal with manual memory management. My reasons for contemplating the switch over, is because Python has largely become my standard utility language for cross platform stuff—and I would like to be able to play my games on my FreeBSD laptop!!! 90% of all heartaches have been due to differences between GNU Compiler Collection and Microsoft Visual C++. The most pissy problems being how they implement templates >_>. Ah, sweet, sweet C++, all your best features are also your biggest liabilities.

Most of what I’m interested in, is doing the game logic and stuff, I’m not willing to spend 6 months to 2 years writing a fourth rate rendering system when there is plenty of good open source code to draw upon. Yet, I’m not interested in being limited by most existing engines, like updated Id Tech 3 (Quake III: Arena), Blender-stuff, or the snazzy Unreal Engine 3 that was recently released. You could say, I don’t want an engine, I want a frame work :-/.

I was originally planning to integrate python for AI and level scripting tasks anyway, so big deal… it would become less problem to do it if everythings in Python anyway hehe.