Skip to content

Conditional chains break sometimes around corners: Suggested fix #68

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
ReverendQ opened this issue Sep 16, 2016 · 7 comments
Closed

Conditional chains break sometimes around corners: Suggested fix #68

ReverendQ opened this issue Sep 16, 2016 · 7 comments
Assignees
Labels

Comments

@ReverendQ
Copy link

At the moment, conditional chains are currently handled by checking if the successcount of the previous block was a "1" twice. This works fine, when the successcount is indeed a 1. However, it breaks when there is more than 1.

My proposal is simple: Instead of checking if it is 1, check if it is 0. That way, it works for all values of successcount. It'll invert it, but since there's two blocks it'll invert it twice so the output should be the same.

Going into corner, chain fails:
-First block sees that it failed, runs successfully
-Second block sees that first block was run successfully, fails.
-Continuation of chain sees that previous block failed.

Going into corner, chain succeeds:
-First block sees that chain succeeded, fails.
-Second block sees that first block failed, succeeds.
-Continuation of chain sees that previous block succeeded.

@GnaspGames GnaspGames self-assigned this Oct 4, 2016
@GnaspGames
Copy link
Owner

Thanks for the idea. Sorry it's taken a while to get back to you. I will be looking into this.

The suggestion is good; but I think it will only work if there are a two blocks inserted. I would love to find a way that will pass the correct value through any number of blocks, in case future layout options require it.

@ReverendQ
Copy link
Author

Certainly, but would it at least be possible for this to be used as an intermediary until there are future layout options? After all, it does break things.

@GnaspGames GnaspGames added the bug label Oct 17, 2016
@GnaspGames
Copy link
Owner

Sure; I'll look into it this week :-D

GnaspGames added a commit that referenced this issue Oct 18, 2016
Thsi will only work with the current layout and an even number of testforblock blocks. To make sure this continues to work another method will be needed.
@GnaspGames
Copy link
Owner

This was changed in 838f8d2 and released in 1.1.0-pre4

;-D

@GnaspGames
Copy link
Owner

Reopening this because it's broken if only 1 SuccessCount:0 block is created to fill in a conditional corner.

The fix for this will be to make sure that the number of SuccessCount:0 blocks is ALWAYS even before returning to the map makers commands.

@GnaspGames GnaspGames reopened this Nov 16, 2016
GnaspGames added a commit that referenced this issue Nov 16, 2016
now always puts into an EVEN number of 'SuccessCount:0' blocks to fix the
conditional corner issue.
@GnaspGames
Copy link
Owner

20f4970 should fix this 👍

@GnaspGames
Copy link
Owner

The fix for this is now in 1.1.0-pre8

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants