Create a directory called "Hashtables" in your script's directory (or modify the $hashdir identifier) and use this:
alias -l hashdir { return $scriptdirHashtables\ }
alias -l _hload {
if (nli_* !iswm $nopath($1-)) {
var %hash = $nopath($deltok($1-,-1,46))
if (!$hget(%hash)) { hmake %hash 50 }
hload %hash $qt($1-)
}
}
alias hloadall { noop $findfile($scriptdirHashtables\,*.hsh,0,_hload $1-) }
alias hsaveall {
if (!$isdir($hashdir)) { mkdir $qt($hashdir) }
var %i = 1, %hash
while ($hget(%i)) {
%hash = $v1
if (tmp_* !iswm %hash) { hsave %hash $qt($+($hashdir,$mkfn(%hash),.hsh)) }
inc %i
}
}
on *:start:{ hloadall }
on *:exit:{ hsaveall }
Easy peasy. No modification of the script required. A lot of the time even though it's easier to script initially, hard coding things creates more work for you in the long run. You may as well just use a script like the one above to have everything done automatically.
If you want to create a table that doesn't get saved, just call it "tmp_<something>" (which stands for temporary)
If you want to create a table that is saved, but not loaded on start, then just call it "nli_<something>" (not loaded initially)