Skip to content

14 days of Akaldiroka – Day1

August 8, 2011

This week I’ll be posting each day, notes that normally I keep to myself about the development of Akaldiroka. I use these as a sort of developer diary, providing me with historic knowledge of decisions I made, why I made them, and what implications they possibly have to the final outcome of the game. Sometimes they may seem a bit jumbled, but hopefully it’ll give you an insight into what kind of work we do, and how deeply we are considering things during the development cycle.


Today I realised that perhaps things that I planned to delegate, will have to be done more close to the chest. Still at this point there are parts of the engine that most likely need work on, including a suitable set of cameras, and perhaps a way to catch callbacks.

After alot of head-scratching (and no i dont have nits), I decided to finish the scripting system by ensuring that events are fired properly. Interestingly I descovered a problem that was giving me a bit of a headache, the Noesis JavaScript bindings based on google’s V8 system stay very strict to the one context per process rule, so whenever i tried to create multiple instances of a JavascriptContext class, It would destroy the original context and fail miserably.

On top of that, when I moved over to sticking with one single context, I was still getting errors. Thanks to someone elses post in the discussion area on codeplex, I found that while the context is executing a Run() command, no others can be ran at the same time. So I decided to add a queuing system, which turned out quite well seeing as Apollo3D is afterall encapsulated within a tight loop, checks to see weather the context is free so that the next Run() command could be called was very simple.

A note to myself, the ScriptBuddy class has many methods at the moment that really should be placed instead within the ScriptNewHandler class, this would make for more consistant scripting, as they would instead appear within the ‘create.’ global parameter. Also as deep scripts are no longer executed in call-time, instead queued, there will have to be some documentation to explain this type of async model to those unfarmiliar with the concept.

No comments yet

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: