I’m having trouble with setting a
input text name
setting gender
setting pronouns
just what I have so far. is there something I am doing wrong?
*label gender
It was the spring of 1891
*choice #Dog(Male)
*set gender “male”
*set he “he”
*set him “him”
*set his “his”
*goto gender_male
#Bitch(Female)
*set gender “female”
*set he “she”
*set him “her”
*set his “her”
*goto gender_female
*label gender_male
You were tiny male wolf cub weighing in at just 1 pound. You are blind and deaf to the world around you with only your sense of smell to guide you. Lucky for you, you have a very devoted mother to help keep you safe in the den. As she licks you and your litter-mates she decides to name you. What did sh call you?
*label gender_female
You were tiny female wolf cub weighing in at just 1 pound. You are blind and deaf to the world around you with only your sense of smell to guide you. Lucky for you, you have a very devoted mother to help keep you safe in the den. As she licks you and your litter-mates she decides to name you. What did she call you?
this is on my startup.txt
*title Journey of a Wolf
*author Jason Keller
*scene_list
startup
beginning
*create leadership 0
*create strength 0
*create health 100
*create Skills 0
*create relationship 0
*create gender “male”
*create he “he”
*create him “him”
*create his “his”
*create name “name”
*create mate “mate”
Not sure about the error but you may also do this to keep things easier:
Instead of doing 2 different labels like this:
*label gender_male
You were tiny male wolf cub weighing in at just 1 pound. You are blind and deaf to the world around you with only your sense of smell to guide you. Lucky for you, you have a very devoted mother to help keep you safe in the den. As she licks you and your litter-mates she decides to name you. What did sh call you?
*label gender_female
You were tiny female wolf cub weighing in at just 1 pound. You are blind and deaf to the world around you with only your sense of smell to guide you. Lucky for you, you have a very devoted mother to help keep you safe in the den. As she licks you and your litter-mates she decides to name you. What did she call you?
You can do this instead:
(After picking the gender, make both *goto gender_selected)
*label gender_selected
You were a tiny ${gender} wolf cub weighing in at just 1 pound. You are blind and deaf to the world around you with only your sense of smell to guide you. Lucky for you, you have a very devoted mother to help keep you safe in the den. As she licks you and your litter-mates she decides to name you. What did she call you?
The ${gender} will display as either male or female, depending on what the player picked.
Perhaps not the advice you were looking for, but… These two are identical save for the MC’s gender. Which you created a variable for. So you can simplify by using that variable instead of duplicating all but a single word of the narration.
For example:
*label gender_selected
You were a tiny ${gender} wolf cub weighing in a just one pound. You are...
What did she call you?
*fake_choice
#Fang.
*set name "Fang"
#Balto.
*set name "Balto"
#My name isn't on this list. Let me write it for you...
She called you...
*input_text name
I shortened the narration for clarity, but you should be able to see how I used ${gender} to display the value of the gender variable, which will be either male or female depending on the player’s choice. Looks like @GoldenSilver beat me to this suggestion.
You can also see how I’m using a *choice (or in this case, a *fake_choice) to give the player a list of suggested names as well as the option to type a custom name. Why did my example use *fake_choice instead of *choice? Simple: *fake_choice doesn’t require a *goto or *label the way *choice does.
Another way to simplify? You don’t need to *set a variable to contain the same value it already contains. So if you start with something like this:
*create gender "male"
*create he "he"
*create him "him"
*create his "his"
Then when it’s time for the players to choose, you only need to do this:
*fake_choice
#Dog (male)
#Bitch (female)
*set gender "female"
*set he "she"
*set him "her"
*set his "her"
I do see one huge problem you’re going to have later, though.
You don’t have a way to separate “her” and “hers,” because the traditionally masculine third-person pronouns are identical for both the Dependent Possessive and the Independent Possessive. They’re both “his.” As a result, you’re missing a pronoun variable.
There are a couple ways around this. I personally strongly recommend using Singular They as your pronoun variable names, like so:
*create they "she"
*create them "her"
*create their "her"
*create theirs "hers"
Or maybe:
*create they "he"
*create them "him"
*create their "his"
*create theirs "his"
Notice how both the traditionally feminine and traditionally masculine pronouns have repeats? Notice how they don’t repeat in the same place? Yeah, that’s going to make things really hard if it catches you by surprise.
That said, you don’t strictly need to use Singular They as your variable’s names. You could use, for example:
The Wikipedia article for English personal pronouns gives a good introduction to what’s going on here. Note: You don’t need a special variable for the Reflexive form. Instead of storing herself/himself somewhere, you can do this: ${them}self. The ${them} will be replace with “her” or “him” as appropriate, producing “herself” or “himself” in the final output.
Your indentation is likely messed up. Choicescript requires indentation after options. Either spaces or a tab (never mix both).
*choice
#Dog(Male)
*goto gender_selected
#Bitch(Female)
*goto gender_selected
*label gender_selected
You were a tiny ${gender} wolf cub weighing in a just one pound. You are…
For example here I indented using 3 spaces. You need to nest the contents of a command in front of it using tabs or spaces.
Edit:
I also recommend using this application, it greatly helps in coding in choicescript.
It was the spring of 1891
*choice
#Dog(Male)
*set gender "male"
*goto gender_selected
#Bitch(Female)
*set gender "female"
*set he "she"
*set his "her"
*set him "her"
*goto gender_selected
*label gender_selected
You are a tiny ${gender} wolf cub, weighing in a just one pound. You are blind and deaf to the world around you with only your sense of smell to guide you. Lucky for you, you have a very devoted mother to help keep you safe in the den. As she licks you and your litter-mates she decides to name you. What did she call you?
*if (gender = "female")
*choice
#Zaria
She named you Zaria. A fitting name for a wolf born into the king's pack.
*finish
#Lelia
She named you Lelia. She must of saw you will grow up to be as beautiful and as gentle as a flower.
*finish
#Grata
She named you Grata. You'll be a graceful little wolf in her eyes.
*finish
#Bella
She named you Bella. You were the most beautify pup in the litter.
*finish
#She named you something else.
*input_text name
She named you ${name}. It was quite a fitting name for you.
*finish
*if (gender = "male")
*choice
#Ciro
She named you Ciro. A fitting name for a wolf born into the king's pack.
*finish
#Actano
She named you Actano. Maybe you'll be a good hunter for your pack.
*finish
#Gonzalo
She named you Gonzalo. Inspired by your father's name.
*finish
#Tavon
She named you Tavon. You seem very good natured.
*finish
#She named you something else.
*input_text name
She named you ${name}. It was quite a fitting name for you.
*finish
I got the female’s name to come up but not the male’s. It gives me this error
“expected at one line in *if true block”
You need to indent after the *if, since the choice only appears as it passes that check.
You are a tiny ${gender} wolf cub, weighing in a just one pound. You are blind and deaf to the world around you with only your sense of smell to guide you. Lucky for you, you have a very devoted mother to help keep you safe in the den. As she licks you and your litter-mates she decides to name you. What did she call you?
*if (gender = "female")
*choice
#Zaria
She named you Zaria. A fitting name for a wolf born into the king's pack.
*finish
#Lelia
She named you Lelia. She must of saw you will grow up to be as beautiful and as gentle as a flower.
*finish
#Grata
She named you Grata. You'll be a graceful little wolf in her eyes.
*finish
#Bella
She named you Bella. You were the most beautify pup in the litter.
*finish
#She named you something else.
*input_text name
She named you ${name}. It was quite a fitting name for you.
*finish
*else
*choice
#Ciro
She named you Ciro. A fitting name for a wolf born into the king's pack.
*finish
#Actano
She named you Actano. Maybe you'll be a good hunter for your pack.
*finish
#Gonzalo
She named you Gonzalo. Inspired by your father's name.
*finish
#Tavon
She named you Tavon. You seem very good natured.
*finish
#She named you something else.
*input_text name
She named you ${name}. It was quite a fitting name for you.
*finish
You can also replace the second *if with *else. The first if will check if the gender is female then display the names. Since the only other possibility according to your code is that there is only male and female to select, the only possible other option is male, so you can use the *else for that.
Make sure to nest the *choices inside the *ifs by indenting them.