Evening, Everyone.
I’ve a question about this:
*label highest_relationship_calc *set rel_counter +1 *label relationship_calc_loop_start *if rel_counter <= total_rel *if rel[rel_counter] > highest_rel_stat *set highest_rel_stat rel[rel_counter] *set highest_rel rel_name[rel_counter] *set rel_counter + 1 *goto relationship_calc_loop_start *return
I got this part to work, which is amazing. I’ve also tweaked it to take care of the romance side of things, as well. But here’s where I’m a bit stumped.
The calculation above works to determine which character has the highest friendship and romance value in a story/game. It doesn’t, however, address the times when there’s a tie. I was wondering how you lovely people work with that bit of code, as I haven’t found it yet.
In the project I’m working on, there are four NPCs that have relationship stats and a possible romance option. If a player/reader happens to get two, or more, of them to be equal in either the friendship points or the romance, what sort of code would I need to address that?
If the players do manage to get equal points for two characters, I would like to have a scene where that’s addressed. Where, instead of one character, both are in the scene. I already have a few scenes in mind that deal with that, but I’m stumped on the coding aspects of it.
As is, I’m getting ready to head out to work.
If anyone has any advice, or codes to share, on this, it would be much appreciated.
Thanks In Advance!