Skip to content

Make sequence puzzle hint signs optional - #2924

Merged
manuq merged 5 commits into
endlessm:mainfrom
BiancaPierina:sequence-puzzle-optional-hint-signs
Sep 22, 2026
Merged

manuq merged 5 commits into
endlessm:mainfrom
BiancaPierina:sequence-puzzle-optional-hint-signs

Conversation

@BiancaPierina

Copy link
Copy Markdown
Contributor
  • Removed the editor warning that required a hint sign.
  • Added is_solved to SequencePuzzleStep.
  • Updated SequencePuzzle to use step-level solved state.
  • Added null guards around all hint_sign access.

Closes: #2149

@BiancaPierina
BiancaPierina requested a review from a team as a code owner September 18, 2026 03:52
@github-actions

github-actions Bot commented Sep 18, 2026 •

Copy link
Copy Markdown

Test build no longer available.

@Un-player0

Copy link
Copy Markdown
Contributor

Hola!

He estado probando los cambios que hiciste y he visto que funcionan correctamente.

En todo caso recomiendo que resuelvas el check de formateo del codigo, la forma mas sencilla es instalar pre-commit como se indica aqui.

@manuq

manuq commented Sep 21, 2026

Copy link
Copy Markdown
Collaborator

@Un-player0 thank you so much for the peer review! @BiancaPierina let us know when it's ready for review again.

- Removed the editor warning that required a hint sign.
- Added is_solved to SequencePuzzleStep.
- Updated SequencePuzzle to use step-level solved state.
- Added null guards around all hint_sign access.
@BiancaPierina
BiancaPierina force-pushed the sequence-puzzle-optional-hint-signs branch from 08d7144 to 1a4965c Compare September 21, 2026 19:33
@manuq

manuq commented Sep 22, 2026

Copy link
Copy Markdown
Collaborator

@BiancaPierina this still has formatting issues, as @Un-player0 mentioned. They are shown here: https://github.com/endlessm/threadbare/actions/runs/35646980876/job/106489712011?pr=2924

But the easiest thing you can do is to install pre-commit, which will automatically fix them for you. Check https://github.com/endlessm/threadbare/wiki/Contributing#coding-style

@manuq
manuq requested a review from a team as a code owner September 22, 2026 17:59
@manuq
manuq requested a review from a team as a code owner September 22, 2026 18:05
@manuq

manuq commented Sep 22, 2026

Copy link
Copy Markdown
Collaborator

@BiancaPierina I commited the formatting fixes myself this time. Also I removed the hint sign from After The Tremor:

image

And this shows that your solution works! I tested music_puzzle.tscn and haven't seen any regression. Now I will look at the code in more detail.

Comment thread scenes/game_logic/sequence_puzzle.gd Outdated
@@ -80,7 +82,7 @@ func _update_current_step() -> void:
var previous_step := _current_step
for i in range(_current_step, steps.size()):
# We find the next fire that is not solved, and that's the _current_step

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The comment is outdated. The "next fire" was referring to the hint (a bonfire in the main game).

Suggested change
# We find the next fire that is not solved, and that's the _current_step
# We find the next step that is not solved, and that's the _current_step

Comment on lines -83 to +85
if steps[i].hint_sign.is_solved:
if steps[i].is_solved:

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

Comment on lines +19 to +20
## Whether this step has been solved.
var is_solved: bool = false

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes I think it's good adding this to the step. The hint needs it for showing different animations (idle or solved). I wonder if we can get rid of this duplication by passing the step to the hint.

This can be an @export. And in that case I would add it above the optional hint_sign export.

Comment on lines +60 to +62
if step.hint_sign:
step.is_solved = step.hint_sign.is_solved
step.hint_sign.demonstrate_sequence.connect(_on_demonstrate_sequence.bind(step))

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
if step.hint_sign:
step.is_solved = step.hint_sign.is_solved
step.hint_sign.demonstrate_sequence.connect(_on_demonstrate_sequence.bind(step))
if step.hint_sign:
step.hint_sign.demonstrate_sequence.connect(_on_demonstrate_sequence.bind(step))

I don't think that the step is_solved should be set to the hint_sign is_solved here.

@manuq

manuq commented Sep 22, 2026

Copy link
Copy Markdown
Collaborator

@BiancaPierina this time I did the changes myself in order to merge. Thank you!

@manuq
manuq merged commit a15f22c into endlessm:main Sep 22, 2026
6 checks passed
@BiancaPierina

Copy link
Copy Markdown
Contributor Author

Thank you so much for taking care of the final changes and merging the pull request! I did try to run pre-commit in Git Bash, but the manual command didn’t work. I was planning to ask my professors for help in class today.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Sequence puzzle hint signs should be optional

3 participants