MultipleChoiceNode modify choices in runtime

NodeCanvas Forums Support MultipleChoiceNode modify choices in runtime

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #17837
    arika
    Participant

    Hi, I am making a MultipleChoiceNode that the amount of choices is variable in runtime on how many quest player can take at the moment.
    What is the suggest way to achieve this?
    Is there a way to access MultipleChoiceNode.availableChoices?
    Thank you for the help!

    #17863
    Gavalakis
    Keymaster

    Hello,
    There is no built-in way to achieve this at the moment, but you can access the node with ‘Graph.GetNodeWithTag(“tagName”)’ (just make sure to add a tag to the node from within its inspector). The availableChoices is also private at the moment and there are no AddChoice/RemoveChoice methods, therefore you will want to make it public to access it and add choices to it.

    With that said your suggestions is interesting to add as built-in. Would adding an optional pre-condition (condition task) check for each choice to filter whether it should be shown or not, work for what you want to achieve and as a feature in general?

    Let me know.

    Join us on Discord: https://discord.gg/97q2Rjh

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.