I have noticed recently that the following command has the side effect of converting “say Hello Luke” to “say hello luke”.
change the text of the player's command to "say Hello Luke";
This is odd, because it is my understanding that whereas Z-code player commands are case-insensitive, Glulx allows case sensitive player commands (and yes, I have verified that I am compiling this in Glulx). Indeed, if I don’t try to ‘change’ the player’s command and simply type in ‘say Hello Luke’ at the command line, the two upper case letters are preserved: it is only if I try to ‘change’ the command to some text that includes upper case that the upper case letters are converted to lower case.
I wonder if this behaviour is intentional and if it is specified anywhere. Is there a rationale for it? I can’t find any reference to a ‘change the text of’ statement auto-converting anything into lower case: neither at inform7.com, nor on this forum.
I wonder if there is an alternate way to successfully change the player’s command to something that includes upper case letters. I did try stuff like…
change the text of the player's command to "SAY HELLO LUKE" in upper case
…just to see if I could effect a change in the results, but nope - it always comes out lower case, regardless.
[P.S. Don’t try to make sense of WHY I am implementing dialogue in this ‘say Hello Luke’ fashion because I’m not. That was just a quickie example I invented for the purpose of illustrating this apparent deficiency in the language. The actual mechanic I am designing is much more complex, has nothing to do with dialogue, and involves processing words from player commands for output WITHOUT associating them with any pre-existing object; thus, I cannot substitute the ‘official’ name for an object, and can only rely on what the player actually typed as a guide to how it should be capitalised - but it seems I can’t do that if I also need to change anything in the command prior to letting i7 process it, because the ‘change’ operation obliterates case.]