[I7] A problem with text variables

Hello everyone.
I have a problem with text variables.


Table of stuff
Column1     Column 2
"Something" "Something else"
"More stuff" "Even more stuff"

Repeat through the table of stuff:
    Let T be "Hi! [column1 entry] and [column2 entry]";

In the cycle I want T to assume the values “Hi! Something and Something else” (first iteration) and “Hi! More stuff and Even more stuff” (second iteration). But apparently Inform understands

Let T be "Hi! [column1 entry] and [column2 entry]";

as if I want to leave the reference to column1 entry and column2 entry (without replacing their values).

Can you help me? (assuming that I have managed to explain myself)

If I understand, you’ll want the line let T be some indexed text; before the assignment to T. Ordinary text maintains references; indexed text does not.

Yes, you understood, thank you! :slight_smile:
But actually my problem still remains, because now I need to convert indexed text to text (I’m using Questions extension and I want to set the variable current question menu, which is a list of texts), but Inform doesn’t want to do that:

You could try replacing this:

Include Questions by Michael Callaghan.

With this:

[code]Include Questions by Michael Callaghan.

Section 1 - Variables For Asking Questions Improved (in place of Section 1 - Variables For Asking Questions in Questions by Michael Callaghan)

Current question is text that varies.
Current prompt is text that varies.
Saved prompt is text that varies.
Current question menu is a list of indexed text that varies.
Current answer is indexed text that varies.

Section 2 - Game Code[/code]

If this doesn’t work, try posting your complete source code and we’ll try to find out what’s wrong.

Hope this helps.

Yes, changing the source code of the extension is exactly what I finally did. :slight_smile:
Thank you!

Actually, I rather meant adding the replacement in your source code rather than the extension source code, otherwise you may lose your changes when you update the extension. Also, it may cause incompatibility issues with code that already uses the extension in its unchanged form.

Ah, right! Thank you very much!