Show Menu Hyperlinks disappearing

Hi, so I was creating a show menu for dialogue options and what is supposed to happen is when you click on each option there is a second show menu with more options for varying responses. When I run the script, the second show menu disappears on the first and fourth choice but seems to work for the second and third choice. Can anyone help me fix this bug?

topics = split ("Fight with Aphrodite;Bake Sale;Yellow Envelope;Never mind...", ";")
ShowMenu ("Talk to Tiffany about...", topics, false) {
  switch (result) {
    case ("Fight with Aphrodite") {
      topics2 = split ("You were a bitch! (Mean);What was that about? (Neutral);Why would you refuse her like that? (Nice);Never mind...", ";")
      switch (result) {
        case ("You were a bitch! (Mean)") {
          msg ("\"Um...excuse me?\"")
          NpcScore (npc, obj)
          npc.score = npc.score - 1
          msg ("Your relationship with tiffany has gone done by one.")
        }
        case ("What was that about? (Neutral)") {
          msg ("\"Aphrodite is an attention seeking whore and I couldn't care less about what lies she wants to tell me about the contest.\"")
        }
        case ("Why would you refuse her like that? (Nice)") {
          msg ("\"Because I know she is a lying sniveling little bitch! And people like her who come from poor families and bitch about their life don't deserve to be a part of my group! You seem like okay though.\" ")
        }
        case ("Never mind...") {
          msg ("Tiffany rolls her eyes. \"Whatever\"")
        }
      }
    }
    case ("Bake Sale") {
      topics3 = split ("What is this bake sale for?;I want to buy something;Never mind...", ";")
      ShowMenu ("Bake Sale", topics3, false) {
        switch (result) {
          case ("What is this bake sale for?") {
            msg ("\"I'm raising money for the dance team so we can go to LA and compete in a national dance competition.\" ")
          }
          case ("I want to buy something") {
            msg ("\"What do you want?\" ")
            MoveObject (player, Bake Sale)
            msg ("You are now at the bake sale! To leave, just click out or type go out.")
          }
          case ("Never mind...") {
            msg ("Tiffany rolls her eyes. \"Whatever\"")
          }
        }
      }
    }
    case ("Yellow Envelope") {
      msg ("\"Like what do you think it is? It has everything you need to compete for that school. It's so elite that they hold competitions every year. My sister won, but she can't even talk about it because it is that elite, like she signed an NDA or something. That's why I know Aphrodite there is lying, nobody can get information about the contest until it starts.\"")
      topics4 = split ("What is this about teams?;Would you team up with me?;Nevermind...", ";")
    }
    case ("Never Mind...") {
      msg ("Tiffany rolls her eyes. \"Whatever\"")
    }
  }
}

And the custom function I used for this script is here, just in case the problem lies within the function. It is supposed to add a score for each npc for relationship scores.

obj.parent = npc
npc.score = 10
npc.statusattributes = NewStringDictionary()
dictionary add (npc.statusattributes, "score", "Score: !/20")
if (npc.score => 15) {
  SetObjectFlagOn (npc, "love")
}
else if (npc.score => 10) {
  SetObjectFlagOn (npc, "like")
}
else if (npc.score => 8) {
  SetObjectFlagOn (npc, "neutral")
}
else if (npc.score => 5) {
  SetObjectFlagOn (npc, "dislike")
}
else if (npc.score => 0 ) {
  SetObjectFlagOn (npc, "hate")
}
else {
  SetObjectFlagOn (npc, "loathe")
}

Hello.


topics = split ("Fight with Aphrodite;Bake Sale;Yellow Envelope;Never mind...", ";")
ShowMenu ("Talk to Tiffany about...", topics, false) {
  switch (result) {
    case ("Fight with Aphrodite") {
      topics2 = split ("You were a bitch! (Mean);What was that about? (Neutral);Why would you refuse her like that? (Nice);Never mind...", ";")
      switch (result) {

It looks like maybe you meant to call ShowMenu just beforeswitch (result) { for the second menu.


topics4 = split ("What is this about teams?;Would you team up with me?;Nevermind...", ";")
    }
    case ("Never Mind...") {

And maybe the same sort of thing here?


Oh, I am an idiot, how did I not notice that? I guess I had to retype the code after it crashed too many times lol. Now I gotta fix this npc score function that won't work


This topic is now closed. Topics are closed after 14 days of inactivity.

Support

Forums