Joined
Jul 29, 2016
Messages
1
Reaction score
0
First Language
English
Primarily Uses
I want an rpg game where the player chooses to play as male or female. However, I am unsure how characters would refer to the character as male or female. For example, character's siblings talks about them (you the player) to other NPC; how do I make it where they refer to them as by your gender? For instance, "Where is my brother" if you-the player chooses as male or "Where is my sister" if you-the player chooses as female. What or how would a program look like?
 

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
22,305
Reaction score
11,734
First Language
English
Primarily Uses
RMVXA
As far as I know there is the complicated way, and there is the easy way.


The complicated way would be to activate control switch #n if male is chosen and control switch#nn if female.  Then assign the term 'brother' and 'sister' to 2 variables.  Getting variables to accept strings instead of numbers is a bit tricky, but can be done.  Then in your event you would have to use a conditional branch - control switch #n ON.


In the dialogue in that branch where you want 'brother' to appear you type \V[n] where n = the number of the switch you have assigned.  In the branch where you want 'sister' to appear, you use the switch for that.


The easy way:


I assume that when the gender is chosen, so is a name.  Instead of using brother or sister, the sibling says "Have you seen Peter" or "Have you seen Jane".  To get that you type \N[n] which gives the name of the nth actor.  If the character has a gender neutral name which is common to both, then just use the name.
 

Shaz

Global Moderators
Global Mod
Joined
Mar 2, 2012
Messages
42,140
Reaction score
14,646
First Language
English
Primarily Uses
RMMV
I would just specify a series of variables - him/her, his/hers, brother/sister, he/she and use Control Variables to assign the correct value to each one depending on the choice (I'm pretty sure you can just type the text into the Script box, putting "" around it, to assign text to a variable).


Then in your dialogue, use the standard \v[#] and it should insert the contents of the variable.


Also, if you've set up two actors - one for the male and one for the female - you're doing it the hard way.  You should just have a single actor, and in addition to setting up the variables above, also use the Change Actor Name, Change Actor Graphics, Change Actor Class, etc commands to set up the single actor.  I provided a script that lets you put \f[1] into a message and it will use the actor's assigned face graphic, so you don't have to specify the face.  This means you can get out of heaps of conditional branches to show the face depending on who the player selected.
 
Last edited by a moderator:

SaburoX

Veteran
Veteran
Joined
Jan 27, 2013
Messages
89
Reaction score
8
Primarily Uses
Since you're using Ace, Mr. Bubble's Gender Functions Script might also be useful in handling those conditions and give you some extra options to work with.
 

Arcmagik

Game Developer
Veteran
Joined
Sep 27, 2015
Messages
522
Reaction score
680
First Language
English
Primarily Uses
RMMV
I feel like using two actors is fundamentally easier to understand if you are new to the engine and events (as it doesn't require a bunch of extra knowledge) as you can set a condition branch for each actor or a event page for each version that checks for that actor being presence. That's absolutely all you need to do and then while writing dialogue you can copy it then switch terms around so your workload isn't doubled.


Are there more steamlined version? Clearly yes based on the above if you have some knowledge of how variables, scripts, or switches work. Pick your poison!
 
Last edited by a moderator:

Latest Profile Posts

I wish I can work faster on my game. But I don't want to get burned out. :(
I've been working on something on and off for a few years now, and I've been reluctant to share any details on the project before I had anything playable because I did not want to generate hype only for the project to go back on hiatus. That being said I believe what I'm working on is very unique and pushes the boundaries of what RPG Maker projects can be. Bold claims, I know but just wait.
Happy Mother's Day to all the moms :)
Create Anime Art w/ AI, Tall Sprites with Aurora, Customize Variable Display | RPG Maker News #34

[My favorite slow moving track I've made so far]

Forum statistics

Threads
111,197
Messages
1,059,206
Members
144,448
Latest member
earhart
Top