Does anyone know how to code a certain outfit for if/elif/else? For example if I have the reader choose from three different outfits but the character depending on what you choose from the three different outfits has to have bruises on her later in the chapter. How would I code that?
You canât code an outfit like this⊠youâd have to create copies of each one and add bruises. Then use if/else, like this for example:
if (episode2outfit1) {
@
CHARACTER changes into outfit1bruises
}elif (episode2outfit2) {
@
CHARACTER changes into outfit2bruises
}elif (episode2outfit3) {
@
CHARACTER changes into outfit3bruises
}
Okay I did that but how would I code it to change from the regular to the outfit with bruises?
choice
âOutfit 1â {
@CHARACTER changes into OUTFIT_1_BRUISES
gain outfit_1
} âOutfit 2â {
@CHARACTER changes into OUTFIT_2_BRUISES
gain outfit_2
} âOutfit 3â {
@CHARACTER changes into OUTFIT_3_BRUISES
gain outfit_3
}
if (outfit_1) {
@CHARACTER changes into OUTFIT_1
} elif (outfit_2) {
@CHARACTER changes into OUTFIT_2
} else {
@CHARACTER changes into OUTFIT_3
}
But you can also make this with the point system, I usually use this method â
choice
âOutfit 1â {
@CHARACTER changes into OUTFIT_1_BRUISES
@OUTFIT =1
} âOutfit 2â {
@CHARACTER changes into OUTFIT_2_BRUISES
@OUTFIT =2
} âOutfit 3â {
@CHARACTER changes into OUTFIT_3_BRUISES
@OUTFIT =3
}
if (OUTFIT =1) {
@CHARACTER changes into OUTFIT_1
} elif (OUTFIT =2) {
@CHARACTER changes into OUTFIT_2
} else {
@CHARACTER changes into OUTFIT_3
}
Just make sure you made the outfit with bruises and without them (in this script, I refer to the latter as âOUTFIT_xâ).
I hope this helps!^^
Okay thank you!
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.