A word from Shadow Code


I talked with the programming fan, Shadow Code, and he wrote up everything he has been working on for the Game Mode, so I could share more info with you dark minions out there!  If you are interested in why the final release of D:BB is taking so long, here is everything going into it!  As an aside, I thank him for his aid, even if it is a matter of pride for him and not altruism, it's appreciated beyond words!

So what has that slacker that calls himself "Shadow Code" have been NOT doing.....

Short answer:
Rewriting the code and fixing bugs
The code base is about 80% overhauled.
The code is now much simpler and safer, and in some places faster

A bit generic and vague you say... OK, Here is a small list of things that I have changed:
a) I added actual debugging code (not just a bunch of random alert() calls, hoping to catch something in there)
b) All the game data (levels aka "hunts", weapon, items, enemies and so on) are no longer hard-coded in the game
c) Memory tracking was introduced and A LOT of clean-up was performed to reduce the memory footprint (map slow downs are gone for good this time) and save bloat (in progress)
d) While by design you can't save on HUNTS, there is a new Checkpoint system in place that can create auto saves (Anax will determine if and when it will be used)
e) The inventory system was completely rewritten, items are no longer "objects". Story Items like keys will be displayed in Abby's inventory.
f) The store was also rewritten (it shared a lot of code with the inventory). It no longer reloads the page after you buy one item and you can see how many items you have in the inventory.
g) The map was redone and it now loads/updates faster (and it is MUCH easier to deal with and debug)
h) You can see health and willpower bars AND buffs (like the Strength Potion) and debuffs (like poison or curses- which is not in yet)
i) The Combat loop is in the process of being overhauled. It is functional now, but some features are still not in.
j) Combat Dialogue was overhauled. Now Anax has a tool to set-up the dialogue, instead of forcing him to edit heavily scripted passages or JS functions
k) A lot of redesign related to how the passage code and text was entered to solve layout issues (and lots of empty lines)
l) Navigation improvement is still an ongoing process (broken links, misbehaving "return" or "back" links)
m) Hunts are being revised (to solve issues like soft-locking yourself in the Caverns if you don't have the required items)
n) Updated notifications, updated to the latest notifyjs library
Also LOTS AND LOTS of bugs are being squashed (and introduced, I guess)

Internally, I also streamlined the process for Anax by creating tools and macros that hopefully will allow him to create "levels" faster and by himself (and some tools to add cool things that were impossible or just plain difficult to do before)
One example is the map creation process that previously looked like a lot of lines like
huntingZoneCaverns.map[6][4] = {region: 'Second',canGoLeft:true,canGoRight:true,};huntingZoneCaverns.map[6][5] = {region: 'Second',canGoLeft:true,canGoRight:true,canGoDown:true,};

And a lot of code that I won't post here (it is a lot of code split in a lot of places)

Now Anax achieve the same with
<<AddCell "Caverns" "G4" "Second" "left" "right">>
<<AddCell "Caverns" "G5" "Second" "left" "right">>

Another example: Music. Instead of unwieldy if/else blocks used to set the audio (and a lot of <<set>> calls and whatnot), he just needs to use
<<RegisterLevelAudio "Caverns" "SomeCoolTrackName">>    <-- Sets Audio for a hunt
<<RegisterRegionAudio "Caverns" "Second" "SpecialTrackForCaverns">>  <-- If the player is on the region called "Second", use this track
<<RegisterEncounterAudio "Caverns" "BigTroll" "TrollMusic">> <-- If we are fighting "BigTroll", use this track while in combat

All of this configs can be added to a single "config passage" (so all the level info is in ONE place). The game code does all the needed stuff behind (and unloads the stuff that is no longer needed once the level is completed)
And with a few debugging tools, Anax can check that it is working as intended:

>audioManager.debugPrint()
AudioManager Info
Zone: Museum
Playing Audio: zone_museum_amb
Default Combat Music Track: zone_museum_bm_1
Encounter Combat Music Defined Rules:
  MuseumPharaoh -> zone_museum_bm_2
  MuseumEvelyn -> zone_museum_bm_3
Default Audio Track: zone_museum_amb

Instead of making him raise an issue to a dev or forcing him to explore code to fix an issue

Now, you are probably wanting to ask a question with the word "When" in it...

There is a lot of things that needs to be done before a new alpha build (Sorry Anax, I'm downgrading your Betas to Alpha status now)
a) I need to deal with some loose ends related to the overhaul process
b) Internal Testing
c) Dealing with the "stack error" that was reported by some players (The overhaul was indeed required to do this, the old code made it unbearable to debug this issue)
d) Reviewing and re-scripting the old hunts (Mountain and Caverns are "done", but the others need some work)
e) Updating the Dialogue editor tool (to account for the code overhaul changes). I believe Anax updated the dialogue up to the Forest, but the other hunts will be just a mess of [Dialogue Missing] prompts
f) Merging Anax' version of DBB (which includes the updated story text and visuals) with my version (new code, updated Twine passages, mostly bug-fixes and to account for code changes)

After that, it is adding the missing features (that exist in separate testing builds) including
a) New Usable Items ("potions") This includes the teased "Speed Potion" (old builds had it listed with "In Development! This'll do something one day soon!")
b) Multi-Turn/Charged attacks (so finally the "Defend" button will do something useful)
c) Combat AI (a very basic AI, but since an enemy can do at least an attack OR a multi-turn attack, it has to pick one, right?)
d) Status effects (Like "paralyzed", that one WILL NOT be in DBB though)
And lots of bug fixing....

Beyond that point it will mostly adding the configuration entries for the new features and updating the level configurations (aka "balancing")

Summary time:
a) Lots of work already done
b) Lots of work remains to be done
c) New build timeframe: unknown, but it is more "soonish" than "soon"

Will it be worth the wait? I hope so.
I started this side project just to help Anax to implement the Museum and Tunnels Hunts (and fix a bug here and there) but the project expanded way beyond what I can consider sensible for a side project.
If I knew the amount of time and effort I end up using, I would have never offered myself to do this.

Now it is a matter of pride, to see the project finished. So please, have some patience before complaining or dismissing our efforts.

SC