Saving custom texts with these external file-based save functions is covered in this blog post (but let me know if that post is missing anything important).
Letting the player name things is documented pretty well—there’s this example in the I7 documentation, there’s @DeusIrae’s example in the other thread, there’s the example in that blog post I already linked (which includes splitting up names so the parser will recognize individual words). But I find my brain to be very tickled by a sentence at the very beginning of this thread:
could you have the player “name” an action, like let’s say a magic spell, and have that name recorded into the table?
— @pinkunz
To me this implies a game that works like this:
As long as you hold this magic scroll, you can give a name to your signature spell.
>NAME SPELL SMARGUS
Okay, your signature spell is Smargus! Have fun!
>SMARGUS
You cast the mighty spell of Smargus! The enemy crumbles before you!
But I can’t figure out how to name actions! I can’t do An action has a text called the custom-name.
because actions can’t have properties. Is there a way around this? I don’t know.
Maybe I could satisfy myself with a custom argument for the >CAST action. I could >NAME FIREBALL FANTASTIC FIREBLITZ, and then the parser would know when I >CAST FANTASTIC FIREBLITZ it should treat that as >CAST FIREBALL.
Well,
A spell is a kind of value.
Fireball is a spell.
A spell has text called the custom name.
Understand the custom name property as describing a spell.
This doesn’t compile, because “a property can be understood as referring to a single object (or a kind of object) but not to something of any other kind.” So am I stuck?
(If I treat a spell as a kind of thing—which is not very satisfying–assigning a custom name works okay, but then I run into an unrelated issue where I can’t cast a spell that isn’t physically present, despite defining Understand "cast [any thing]" as casting.
Has [any thing]
been nerfed?)