I’m using italics for some of the writing in my game. It’s been brought to my attention that this will make the text hard to follow for readers with some forms of dyslexia.
Is there an easy way to give the reader the option of disabling italics? I’d obviously like to keep things as accessible as possible, but going through the game code line by line is already going to be at least an hour’s work.
Well, since the only way to use italicized text on ChoiceScript is through the [i] [/i] tag, the only way I can think of to not include them is to not use the tag
I mean, going through the code line by line is probably inevitable. Italicization on choicescript is not applied universally through the whole game.
Thanks. I was really hoping for the option to give readers the option to disable italics when they start a new game. For example, by adding a few lines of code to tell the programme to ignore the italics tag if the reader has selected that option.
Offhand, I can’t think of any quick or easy way to go through a game’s code and edit it to allow a new function you want, even though the function itself should be quite easy on an individual instance level.
Here’s how I would do it:
I’d start with a boolean variable (something like *create italics true .) I’d then offer a *choice or *fake_choice at the beginning of the game so players could allow the variable to remain true, or switch it to false.
Then I’d use the Find function of whatever text editor I was using to write the game to jump to each use of italics without spending the time scrolling through and re-reading it all.
Finally, at each instance of italics use, I’d replace the [i]italic text[/i] with the following structure: @{variable_name [i]this_displays_if_true[/i] | this_displays_if_false}
In practice it may look something like this: "She said @{italics [i]what?![/i]|what!?}" Jamie shrieked as she jumped out of her chair.
I feel like this would be something that could quite easily be implemented though. Perhaps worth a feature request?
For multireplace, I’d be tempted to say use variables, as if you ever made a mistake, it would error, rather than silently italicise half your page.
*create is "[i]"
*create ie "[/i]"
...
*temp italic_text "what!?"
@{italics ((is&italic_text)&ie)|italic_text}
*comment I *think* this syntax will work, haven't ran it though
This wouldn’t be practical within a paragraph with lots of different words, but where it is practical, it provides some extra safety (in exchange for verbosity).
I still had my test code for this discussion up (I wanted to get the right order of true-false results when using multireplace) so I added your sample to my test code like so:
*title Code Test 3
*author @Minnow
*create italics true
*create is "[i]"
*create ie "[/i]"
*temp italic_text "what?!"
Should the game display mixed [i]italic text[/i] and standard text, or display all text as standard?
*fake_choice
#Use mixed [i]italics[/i] and standard.
#Use standard text only.
*set italics false
Your choice regarding @{italics [i]italics[/i]|italics} has been recorded.
Test line:
@{italics ((is&italic_text)&ie)|italic_text}
*finish
Your sample didn't work as written. It produced the following:
Fixed it!
You need two things: First, an extra *set before the multi-replace operator. (Specifically, *set italic_text ((is&italic_text)&ie) . Second, you need to use ${italic_text} in the content of the multi-replace.
Like so:
*title Code Test 3
*author @Minnow
*create italics true
*create is "[i]"
*create ie "[/i]"
*temp italic_text "what?!"
Should the game display mixed [i]italic text[/i] and standard text, or display all text as standard?
*fake_choice
#Use mixed [i]italics[/i] and standard.
#Use standard text only.
*set italics false
Your choice regarding @{italics [i]italics[/i]|italics} has been recorded.
Test line:
*set italic_text ((is&italic_text)&ie)
@{italics ${italic_text}|italic_text}
*finish