- make state labels symbols (not strings) as a syntax safeguard
- dialog docs: make some pictures with
graphviz - try a mini-mod: patch imoen.dlg
- heavily-modded EET has 82k key resources, 90k overrides, 100k strings
NEEDS:
- API for a given mod:
-
newmod(dir): creates skeleton - suggestion:
include("moddir/setup.jl") - automatic generation of Julia module +
namespace()- [ ] useobjectid(@__MODULE__)in namespaces? or directory? -
translate(dir): creates/updates.pofiles -
install(dir): installs mod - binary resources!
-
uninstall(dir)(harder!) -
validate(dir) - also checks correctness of metadata (in module global vars!)
- module metadata: module name, description, author, url (for git)
- global variables for mod metadata (
AUTHORetc. spring to mind) - Mod components
- component list/tree + metadata: dependencies, parameters
- find something better than
?{M}to indicate gendered dialog language()also loads the translation files (any.poin current directory)- make xgettext-mode easily accessible from author-side
e.g.
use InfinityEngine; translate_mod("foobar.jl") - translation is done for all game languages
- replace calls to
msgfmtby a compilation to Julia dictionaries - which need to be included by the mod(ule)
- translation header should be filled from module info (package version etc.)
- save dialog state priority in
state.toml(this is big!) - needs: for each modified actor, offset + vector of Float32
- encoded as
[priority] dialog1 = offset,prio1,prio2,...etc. - finalize actor (i.e. add exit transition to any empty state)
- see what to do with actions attached to these
- allow specifying actor in
say, e.g.say(actor=>label=>text)
- see if triggers are not more logically placed After actions
- is
\r\nneeded? check this by modifying Hull's actions - trigger/action text: replace strings by
Strref - use interpolated strings...
- a custom string mode? for interpolated strings... action"Journal($s)" # replaces $s by Strref
-
reply(text => actor => state) - reindex states
- all of them (across actors) before saving
- journal flags:
journal(..., Unsolved)? - see what to do with actions attached to transitions on
interjectcalls (i.e. Weidu'sINTERJECT_COPY_TRANS2?). -
.d=> julia syntactic transformation
- try to be a bit faster by pre-hashing all the
Symbols used as keys in object tables (at parser stage) a good hash function islast(s)+121*s[2]⊻238*s[1](only 2 collisions, on infrequent resources) do the 2-step hash thing - write a custom REPL mode (
HeaderREPLs.jl) for mod manager - mod manager (WeiDU + Julia mods)
- mod editing (generate, update, translations, validate)
- typed attack:
Blunt(1d4+1) - converts to Dice?
- speed: maybe add a few
sizehints!in KeyIndex and TlkStrings. - consider using ImmutableDicts DONE and it is less efficient
- decompile dialog to Julia
- missing flags
args_to_kw: use parameters e.g.AbstractString => (:name, :description), Integer => (...)
- items
- dialogs
- try recreating a simple dialog (imoen.dlg, hull.dlg) from scratcho
- with a few translations
- saving a creature reorders the items as needed
- use stacktraces
for item in items(game, r"sw1h.*"i)
item.damage = d6
end
- Almost done, except we need to say
item.ability[1].damage = d6 - we can also keep the damage bonus: x = item.ability[1]; x.damage = d6 + x.damage_bonus
for script in scripts(game, r"ar[0.6].*")
script = myscript * script
XXX use prepend! ?
end
for item in items(game)
(item.type == Longsword) && (item.min_strength = 10)
end
save(game)
glamdring = Longsword("Glamdring", ...)
acolyte1 = creature(game, "acolyte1")
acolyte1.shield == nothing && (acolyte1.shield = "shld01")
- make
inventory(creature)an iterator over all items
ribald = store(game, "ribald")
push!(ribald.items, ("hamm05", 0, 0, 0))
# or simply "hamm05" and charges will be auto-determined
# or insert! to determine position
table(game, "kits")[i, j] = "value"
# allow string indices
damage = Crushing(1d6+1)
timing = Delay_Seconds(...)
vim: et: