Is there a purpose to having multiple Flowchart Controllers?

0 favourites
  • 11 posts
From the Asset Store
Small pixel icons for the 3 most popular controller types.
  • I'm getting a lot of great use out of the flowchart plugin. I've been using multiple flowchart controller objects, some with instance variables and the like. I just noticed however that when you set one flowchart controller to use a specific flowchart, you're also setting any other flowchart controllers to use that same flowchart.

    Is this how the flowchart controller plugin is supposed to work? And if so, is there any functional difference to having multiple controllers vs just 1 seeing as they can handle multiple flowcharts anyway?

  • It sounds like it was never meant to allow for multiple flowchart controllers in the first place. Could be an oversight, or it's just a bug. Since the big flowchart thread is unstickied at this point I'd just post a bug report and see what happens. Ideally I'd prefer that it's possible to have multiple flowchart controllers.

  • I agree, I was supper confused when I realized it about a week ago.

    I initially assumed Flowcharts controller hold their own data and state, just like a the JSON, Array and Dictionary Plugins. But it seems like flowchart controllers all reference the same current flowchart, they only differ in the state of that current flowchart.

    This makes it way less flexible, can't really have one flowchartController for npc dialogue (maybe you would even want to have a flowchart controller in a container of each npc, each referencing their own dialogue tree) and one for the progression system etc.

    With the current implementation it means you have to swap the flowchart all the time making it really weird imo.

    Tough I'm sad as it seems like it might be too late to change it due to backwards compat.

  • It's by design: they work the same as Array and Dictionary, which is that you can put them in a container with another object to have per-instance state. So just like you can put an Array in a container with a Sprite to have per-instance array data, you can put a Flowchart Controller in a container with a Sprite to have per-instance flowchart state.

  • Array, dictionary and JSON all can have different data and state.

    FlowchartControllers all have the same data but a different state.

    Unless I am missing something.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • This makes it way less flexible, can't really have one flowchartController for npc dialogue (maybe you would even want to have a flowchart controller in a container of each npc, each referencing their own dialogue tree) and one for the progression system etc.

    Yes I was trying to use a controller to handle narration text while having another one handle the AI states of multiple enemies at once. In isolation they work fine but trying to have the flowcharts do their thing simultaneously is turning out to be a headache.

  • It's by design: they work the same as Array and Dictionary, which is that you can put them in a container with another object to have per-instance state. So just like you can put an Array in a container with a Sprite to have per-instance array data, you can put a Flowchart Controller in a container with a Sprite to have per-instance flowchart state.

    So is this the only case where it makes sense for a project to have multiple flowchart controllers at one time? Trying to navigate flowcharts with different flowchart controller objects from the the event sheet is pointless?

  • There is often more than one way to go about doing any particular thing, some methods may make more sense for a certain person or project or workflow, so I wouldn't necessarily say pointless.

  • FlowchartControllers all have the same data but a different state.

    fedca Can you expand on this? I'm struggling with understanding the use case for multiple flowchart controllers. If I use the move to next node action for one flowchart controller, the second flowchart controller also moves to the next node

  • Using multiple instances of the same flowchart controller is meant for the use case of coupling a flowchart with an instance in a container. So when you pick that instance by some method, clicking on it for example, you can control the flowchart associated to that one instance.

    That is how it's supposed to work, the reason it is confusing is because it is not working properly. This will be fixed soon.

  • Thank you That sounds very useful looking forward to try it out once its fixed

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)