json_object_merge: Don't create deep copies.

Why should we when there's a reference counter? Sure, you might want to re-use and change the original object... but in every single instance this function is currently used, the new array is trashed immediately after merging, anyway.

Also, change the function parameters to make a bit more sense, and remove that part about array merging - this has become such an integral part of the whole spec by now.
stack_json_resolve: Refactor the inner loop into its own function.

Because in the next step...
Introduce "fn_for_" as a prefix for functions operating on file names.
Include build-specific files in the patch stack resolving functions.
Layout command 't': Choose the longest string out of all given parameters.

... wow, 9 levels of indentation. I should work on this...
Add basic translation of hardcoded strings via dictionary lookup.
IsLatestBuild: Fix a crash if "latest" is neither array nor string.

... or simply not given at all. This is probably my most hated function in this whole project anyway.
Spell translation: Support base ID calculation based on the difficulty level offset.

This is necessary for the result screen, because we don't have spell_id there.
Yes, this *will* in some cases display the wrong translation if the actual target is not present in spells.js - but it's better than counting down all the way to zero.
strings_lookup: Optionally return the length of the final string.
Add a safe and persistent vsprintf handler.

This function should be inserted via binary hacks everywhere a game calls sprintf, as it guarantees a sufficiently large buffer for the result.