Multiple state link condition settings don't work properly.

I tried combining the two conditions into a single state link by setting the “Other Conditions” as follows, but it didn’t work:

AND Collision with wall
AND Switch 1 is off
OR Collision with wall
AND Switch 2 is on

No matter how many times I tried, only the conditions below the OR (Collision with wall AND Switch 2 is on) were executed. Interestingly, if I swap the order, the conditions above the OR (Collision with wall AND Switch 1 is off) are executed, but the conditions placed above the OR after swapping are ignored. Even if the conditions above the OR are met, they are not executed regardless of the conditions.

The result was the same whether I set the switch conditions to “All” or “Any”.

I also tried changing the position of the OR as follows, but the result was the same:

AND Collision with wall
OR Switch 1 is off
AND Collision with wall
AND Switch 2 is on

The state does not transition unless Switch 2 is turned on, even if the wall is touched.

When these two conditions are connected via separate links, both transitions work correctly.

Only when combined into a single link is only the latter one executed.

As a test, the following configuration with one condition each also worked:

AND Collision with wall
OR Switch 1 is off

If I connect multiple links to a single state with one condition each, it works, but connecting multiple links to an ANY state causes abnormal behavior and significant lag, so I want to reduce the number of links as much as possible.

Could you please explain what the specification is for this? I would appreciate any insight.

Hello! This was explained by Moonling in this earlier thread: 複数の条件分岐の AND OR の挙動について

In short, the OR isn’t being ignored. AGMaker evaluates the conditions strictly left to right, so A AND B OR C AND D becomes (((A AND B) OR C) AND D). That means your last AND condition gates the whole link, which is why only the conditions after the OR seem to work. This is different from how アクツクMV grouped them.

For now the workaround is to split the two condition sets into separate links, or copy the target state as non unique and connect one link to each. I know it’s more work, but that thread also mentions the free connection point links being worked on, which should allow multiple links between the same states like アクツクMV. Hopefully that helps!

Thank you. I apologize for posting a duplicate question, as I was unable to find previous topics. Although that topic was from a year ago, has the situation not changed much since then?

I generally understand the specifications, but they are quite disappointing.

The tedious parts can be managed somehow, but linking from the Any state is very resource-intensive. I wanted to consolidate conditions to reduce the number of links, but it seems that’s not possible.

Although the recent update alleviated the issue somewhat, objects with a large number of links still cause long loading times.

It’s very disappointing, but I’ll have to accept a certain level of loading time and poor performance and continue developing by connecting as many links as possible.

One option might be to change how you generate flags and variables.

For example, when updating variable X and this update always happens after Y is updated, add an extra check. If X is now 2 and Y is already at 3, go ahead and set variable Z to 5.

And then on your other check, instead of checking for both X and Y, just compare with the value in Z. If Z is 4 or less, no good, and if Z is 5 it is good.

This isn’t doable in every situation, but it’s useful when you want to simplify the condition logic in return for a more active management of variable/flag values.

1 Like