Thoughts of ‘home’

Now this old article from Joel Spolsky makes me think of what it’s like to be here, *and* trying to get work done. Managing computer work flow is simple, at best, just tell everyone to go to hell or sign off the IM. After so many years of being on the Internet, I can usually juggle multiple tabs without any real loss to getting stuff done. Having to get up and respond to an interrupt, and usually being interrupted twice more on the way back to my console on the other hand, is something that occurs so frequently I’ve almost a spider sense about it…

If I had a penny for every time I’ve been shafted that way, for lack of being able to escape to a private bunker, I would have enough cash to pay off the national debt!

Experience shows me one fact: I am most productive when I’m camped in front of a laptop, all is quiet in the world, NO interrupts, no morons to wait on hand and foot, nada, not even a music stream. Oh, that and realising the clocks changed from PM to AM, and I’m still coding smoothly xD.

I’ve nether yet fallen off the earth, or finally laid down and died; I’ve just been busier then a Japanese beaver doing over time.

After catching the opening segment three or four times, I’ve finally gotten to watch a classic western. It has about as much to do with historical fact, as my big toe has with rocket propulsion, but never the less it’s a good portrayal.

In a cavern, in a canyon,
Excavating for a mine
Dwelt a miner forty niner,
And his daughter Clementine.

Oh my darling, Oh my darling,
Oh my darling, Clementine,
You are lost and gone forever,
Dreadful sorry, Clementine.

Light she was and like a fairy,
And her shoes were number nine,
Herring boxes, without topses,
Sandals were for Clementine.

Drove she ducklings to the water
Ev’ry morning just at nine,
Stubbed her toe against a splinter,
Fell into the foaming brine.

Ruby lips above the water,
Blowing bubbles, soft and fine,
But, alas, I was no swimmer,
So I lost my Clementine.

In a corner of the churchyard,
Where the myrtle boughs entwine,
Grow the roses and the posies,
Fertilized by Clementine.

Then the miner, forty-niner,
Soon began to peak and pine,
Thought he oughter join his daughter,
Now he’s with his Clementine.

In my dreams she still doth haunt me,
Robed in garments soaked in brine;
How in life I used to hug her,
Now she’s dead, and I draw the line.

Like wise followed up with Gunfight at the O.K. Corral and Crimson Tide.

A technical and pseudo psychological peek into Raven Shields AI


In putting the last touches on Private Airport (kai), I’ve been spending some more time to study how the games Artificial Intelligence works, special thanks to [SAS]_Maj_WIZ for pointing out a more thorough list of developer diagnostics ;). Since this is the closest look I’ve taken at Rainbows AI in about 5 years, and an even closer study of Terrorist and Hostage behaviour, I think it’s only fair to make a journal entry about it.

Here is a summery of my findings, and annotations about theories I’ve maintained for years:

The laser eyebrow problem

From the standing position, the source of each pawns aim is directly behind the skull, roughly where the head would be if the pawns stood erectly (like a tango). The point of aim, passes directly though eye level. When crouched the point is roughly near to behind the collar bone, and passes through the lower nasal cavity. In prone, it is much the same.

In real life (and any decent shooting game), that aim point should be chained to the weapon in the players hands.

How Tangos Fire Out Their Ass

Experiments with ShowFOV and GunDirection, demonstrate that there is no real connection between pawn animations, where the AI is looking, and where the AI is actually aiming; or as I have been saying for years, What You See Is Not Always What You Get. The most humerus moment in my testing, occurred with the Rear Guard “Facing” the rear but covering the elements front. My research shows that even if Rainbow is aiming at the target, they fail to engage terrorists outside their point of view. I.e. in the case of that rear guard, if a tango had walked up behind the element: it would’ve taken a moment for his aim point to realign with his field of view, resulting in the death of 2/3 the Rainbow AI element!

In short, this means that the AI walks around much like a Tank with an independent turret, only the artificial intelligence is riding in the drivers seat, not the gunners. Coincidentally, this is why the game has no real concept of muzzle clearance (as I have also been saying for years).

This may explain some of the more rolling on the floor laughing moments that often occur, when a “How close can you go” opportunity crops up in game. To prove a point, I cornered a tango in a corner and had him empty his magazine into me. Side stepping away and deactivating GOD mode, he was able to fire several rounds point blank into my pawn, before his aim point rotated to my new position – I died once the aim point got to me, not when the animations showed him shooting me.

Also it seems that hostages always seem to aim directly at Rainbow, but luckily the terrorist AI doesn’t notice that (or they would always see us comming).

So far, these tests satisfactory seem to prove that my ~6 years old hypothesis, about the “Tango firing out of his arse” problem being is indeed codified into Raven Shield by design. Between network latency, the (usual) use of unreliable UDP communication methods for multiplayer game play, and the systems divergent means of rendering and applying these actions (seeing, aiming, firing, hitting), suggest that there is no way to solve the aforementioned (annoying) problem without fundamental changes to the way Raven Shield works. Since that is not viable, one can only look at working around the problem; even with more processing power then a Cray XT5 super computer, you also need a very high throughput network link between clients and server, likely to an extend that is unobtainable over the modern internet.

In laymen’s terms, this means no matter how good your computer hardware or internet connection is,  the computer will always be able to cheat you. Should that change, most likely it will be so far in the future, we will be dead by then.

On the upside, I do believe that why the game is like this, was probably done in order to give the player more ‘time’ to shoot first (yes, some tangos have very slow reaction times: this appears why). It also appears to explain many of the discrepancies between common online play, single player, and LAN parties. However it is also worth noting, that this may have instead occurred due to limitations of the Unreal Engine (2) or Raven Shields own design and implementation.

Interesting Note: Now that an illegal RvS 1.60 SDK is available on the internet, it may be possible for cheaters to develop a method to take advantage of these problems. Imagine walking up on some one in Adversarial because you think they are looking away, then they shoot you out their arse ;). Luckily the engine has some respectable counter messures to such becoming (more) common.

Looking at the AIs skills

One of the very few things, that I have ever been able to praise Rainbow Six 3: Raven Shield for, is that the Rainbow AI often “Appears” to be covering their sectors, even if they totally suck at room clearing. In fact, their room clearing behaviour suggests that either the AI engine is extremely limited, or the game was made by people who know as much about CQB as the average RvS player, that is: absolutely nothing.

Since there is no connection (see above) between where the character on screen is looking (seeing), and where they are aiming (pointing), this means What You See Is Really Not What You Get. Have you ever seen in Single Player, where Rainbow is looking straight at a tango and gets owned without a shot? This is why. It is also why we can do the same to tangos online.

Terrorist movement is closer to What You See Is What You Get, then Rainbows; IMHO the movement for Rainbow was done to ‘look’ more realistic then it actually is (or the AI programmer sucked even worse then everything thinks). They also seem to have a tendency to remain fixed on hostages with their aimpoint, even while walking around a fair distance away. Ever got first sight on a tango, shot him trice, only to curse at him “Magically” shooting the hostage with barely a twitch? Yeah baby… he had that gun pointed at the hostage, all the while he was looking into your eyes.

Every type of AI in the game, demonstrates very poor skills at getting around the maps. I remember when I first started learning about pathing in Unreal Engines, I couldn’t help but think, “We’re still living in a dark age”… and that’s all I will say on that lol.

Hostage behaviour, well, what can I say… what you see is exactly what you get: a stupid slug. On the upside, the terrorists do not show any signs of being aware to hostages; this is why for example, if a Rainbow goes down while escorting, and the hostage becomes a prisoner again, the terrorist may continue walking past. All the fancy stuff about the tangos shooting the hostage, is a mixture of the games rudimentary AI, and things that map designer has programmed.

Since I don’t believe in taking advantage of the map design, or exploiting things I shouldn’t know in real life about the missions, I will not make a closer study of that kind of stuff, nor will I tell others much about it. If you want to figure out how to take even that (ugly) edge over the game, you can go learn how RvS works for yourself. Beat it punk.

I just study the mechanics and psychology of the games AI, you know, the whole know your enemy thing. In actual ops with SAS, I tend to employ more knowledge of human psychological behaviour then how the game was designed. That is both by intention

A Random Bullet Test

A tango surrendered and I fired a shot into his head, the round should have impacted his hand (placed on his head). There was a blood puff and a bullet hole in the wall directly behind his head, however the tango survived. Weapon used was an M16A2 at approximately 350-450 unreal units.

This suggests that terrorists have no brains, since the angle means the bullet must have penetrated his skull, and his hand (I pray) being all that slowed the high velocity FMJ round down enough to prevent a kill. Suggesting that any hit box modifiers applied, were for a ‘hand’ (arm) shot rather then a head shot.

N.B. other tests I have done over the years suggest this kind of problem and the ballistics model used, is why sniper rifles may incur a two-shot requirement on tango kills, and the exaggerated effects of JHP/FMJ selection on SWAT 4.

Anyone still awake and scratching their heads?



All this is based on roughly 6+ years of playing the game, much more then trivial knowledge of such matters, and being a very, highly observant individual.

Oh Brother, Where Art Thou Noggin?

With the questions my brother has been asking me about his computer, and his “Plans” for rebuilding her into a higher end machine, I’m starting to wonder how he even got one built in the first place… what was it, in one ear and out the other? lol.

And I am the moron, who was barred from building his own computer !?

Marc Espie on portability

Marc Espie on portability: “
A short while ago, Marc Espie (espie@) wrote to the ports mailinglist with a short rant about autoconf. His mail gives good insights into the problems porters face when dealing with GNU software, especially those using autoconf.”

This actually describes one of the many reasons I despise working a lot of other ‘programmers’ in this world, many of whom exhibit even greater levels of brain injury then that post takes as examples.
In my not so humble opinion: GNU autotools is either a good idea gone horrible wrong (in practice), or a royal brain fuck that just got out of hand. Users who can use such tools properly, seem to be falling by attrition to younger developers, many of whom (in my experinces anyway) wouldn’t know portability if it strung them on the keester like sitting on a scorpion. The GNU build system can an extremely good tool chain to work with, or it can be your worst freaking nightmare; a lot of people just don’t seem to care any more. My policy has always been, to support what I use (BSD/Win), and trying to minimise the heartache of getting code built on another platform.
Although the GNU project is perhaps the largest distributor of infectious disease on the Internet, I blame the developer idiocy I see around me, on the youth and not on the software. Most “Old wizards” seem to actually know their tools…..

Mario: Treat your tools like a friend. Keep ’em by you. Never let ’em down, and they’re always at your side.

Luigi: Hey, Mario, how is it that for every situation that could possibly come up, you always got a saying about tools? 

Mario: I got ’em from Papa. 

Both: He got ’em from Grandpapa!

Private Airport (kai) going RC

After much abuse and perhaps a weeks kicking, or two thirds of a week in man hours, the first map in my RvS map pack is almost complete. The first one, as one might infer from the title above, is a custom version of the Private Airport. In having to find something reasonable to prefix or suffix the maps with, I chose the simple suffix of ‘(kai)’ for each map, why? Just blame it on an Endless Waltz.

The map has been optimized for Co-Op Mission and Team Adversarial play, but should function as expected in most game types; there is also a tweak for Bomb mode. You would still recognize it as the Private Airport, and I have tried not to destroy the maps excellent flow, merely augment it and revivify the game play. Several areas are in my humble opinion, more realistic, while still reflecting the intended feel of the map. Since there is virtually no one left alive, who is playing Raven Shield off a 32MB or 64MB AGP card, I have also taken the liberty of “Fixing” the portaling a bit, trading the frame rate on your toaster oven, in the hopes of reducing some of the floating guns a wee bit (in so far, as that is actually doable in this fucked up game). I also seem to have fixed one of the most annoying rooms in all of RvS, in that process ;). See, I do know what I have been cussin’ at for all these years :-P. My changes shouldn’t impact anyone who has a computer that could play RvS without extreme abuse in the first place (Yes, it is time to give up on your 4MB 3dfx card and buy a new computer), and shouldn’t effect performance for 96-98% of players.

In architecting the changes for mission mode, the thought that kept running through my mind is “This map is gonna be pure evil”, and if you enjoy doing things Ninja style as much as I do, on top of forceful dynamic fare, one will no doubt enjoy playing the coop mission on ROE: RED and saving the day like a sneaky son of a gun, hehehe. Things have been engineered to offer a more tactical experience to both coop and advers. mode, and I think my Private Airport (kai) will be much better suited for Force on Force Training, not to mention bounding drills.

The changes are numerous, tallying over 25 completed tasks on my RTM, and countless dozens of on-the-fly changes that occurred to my twisted mind during editing phase. Being a methodical type about getting my plans carried out, of course corrections and issue tracking was pushed into my RTM list as needed, instant triage.

I will likely make the map available to a select few for closed door testing, once I’ve finished a bit more private testing on the airport. After that, I would say the map is essentially good to go out the door. There is still an unfinished portion of the map, that is non essential, but to complete it properly, would entail triple the work and completing a subsequently desired feature set. There is also a few other features I would like to add, such as maximizing the sniping opportunities even further, but that can wait until later. The next iteration of the map, will likely contain such changes.

For now, I’m content to move onto the last leg of testing the map, and to get started on my ‘next’ one, mauhauhauahauhauha!!!!!

Building better memory management for high performance wired/wireless networks: Part 1

Building better memory management for high performance wired/wireless networks: Part 1: “The authors describe a variable pool memory management scheme that has been implemented for LTE and WiMAX protocol stacks and has exhibited excellent performance, especially when compared to traditional fixed-pool implementations.

Email this Article
Add to digg
Add to del.icio.us


Maybe I’m a freako, but I find these this article set to be intensely interesting.
In my travels, I’ve read plenty of miles of code, including more then a few programs that go as far as memory pools, and even writing a real memory allocator for all practical intents and purposes. This ranges from programs simpler then most (non UNIX) users would think trivial, all the way to more “Complex” systems. In fact, I’ve even spent time spelunking kernel virtual memory and file system code, which can be a truly interesting set of experiences in their own right.
In working on Stargella, I’ve wondered whether or not using such techniques would be a viable method of improving the games performance, but for this point in time, everything relies on the C library to work wonders where dynamic memory is needed. While I can see potential savings from adapting a more elaborate memory management schema, it’s rare that I’m kicking something around, that really warrants the extra time for creating and debugging code for it, over just rolling with the local libc brew. Of course being the code monkey I am, I always keep an open mind for what the future may bring in the way of change.
Although I will use malloc() quite freely in coding, I also look at it like a reload in a CQB situation: if you’re reloading, you’re not able to engage more threats, and that (at least for me in SAS) is often the slowest element to an aggressive and dynamic advance. On the other hand though, I generally expect the operating system to provide a decent memory allocator for most tasks, rather then a brain damaged one o/. Ways to minimize the cost of allocating memory however, is something that I always consider a plus.
Hmmm 🙂

Redefining pot luck

Tonight Food Network displayed one cracker jack of a mission, in which Robert Irvine of Dinner: Impossible was sent off to the UNC. The objective? Turn whatever he could scavenge out of the dorm rooms into a quality meal for a ~hundred students, in less then six hours!

So here Irvine is with his sous-chef, and they’re trying to figure out what the hell can you do with a barrel of cheese balls, dozens of cans of different soups, a megaton of ramen noodles, and so many other odds and ends lined up on tables. Not to mention a deep fryer that went out so many times, he had to threaten the to throw the rent-a-fryer guy in it, lol. In the end they had to raid the sonority houses just to gather enough proteins to make a decent meal. Impressively they shipped about 19 dishes, and no one died of a heart attack in the process. Battle planning went out in like the first 15-min, and they had to result to an on the fly menu plan. It was shocking that they actually came up with something edible, let along that much food lol. In response to someone saying they would make his last minute concoction for the fair, billed as “Robert’s Corn Dogs”, he quibbled something about how he would never cook like that in a sane situation.  Despite what’s probably the most ludicrous episode I’ve ever seen, somehow they pulled it off with a hair trigger.

What makes Dinner: Impossible such an enjoyable show, is watching the host stew through it… and thanking GOD that you don’t have his job, hahaha. If Guy Fieri has the best job on Food Network, Robert Irvine has the most stressful. Me, I would just like to tag along on Triple-D, and gain back my lost 40 lbs in the process xD.

It’s just one of those nights….

… where I’m to restless about getting things done, yet to freaking tired to actually get anything of value done. I’ve already spent most of the day like a humming bird, even while on an RvS break; so it’s starting to get ridiculous lol.

For the past few days, I’ve been pondering ideas and looking at where I would like to be in the next ten years. Of course, getting through this year is a prerequisite 8=). I tend to analyze things systematically, so it’s a problem I engage no differently then any other, it is merely a bigger issue to study. At present Operation Redeemer is proceeding at a terribly slow pace, one that’s being forced upon me o/, and likewise data also suggests this will increase the odds of later being shafted before things conclude. Experience has shown me that families either represents the finest support system ever created, or the exact opposite: matter and anti-matter. Sadly with about the same impact on moving forward, only useful with a warp core and containment field. The principal agenda guiding my short term plans (Redeemer), is focused on brushing away the obstacles that make any larger aims, an utter impossibility. Ever being who I am inside, of course I’ve gotta lay foundation on later plans too. In the end though, only time can tell the future.

At the more immediate moment, I’m just whipped. There’s no shelter from exhaustion at this point, and probably never will be in my life: that’s one reason that I tend to take things one day at a time. I’m so fucking tired, yet hate to watch the hours go by without getting anything practical done. I also know, working on most of the stuff that needs doing, isn’t wise when I feel like passin’ out.

The crappy thing is, if I log off now, either I’ll be wide awake in a couple of hours (and back in the same boat), or by the time dawn rolls around, I’ll feel like slamming my sleep starved head into a wall, o/.