tempest.asm useful comment change#14
Open
ScriptCoolestIdkSomeOne wants to merge 1 commit into
Open
Conversation
updated ; There appears to be a loop beginning here ; for ($37=7;$37>=0;$37--) running from here through a827. I'm not sure ; just what goes on inside it, yet, though. comment to the useful comment
rbergen
reviewed
Jun 5, 2026
Comment on lines
+4336
to
+4344
| ; Decrement animation timers for 8 slots at $03FE-$0405 | ||
| ; (likely sprite/effect states during level transitions) | ||
| ; LOGIC: non zero values: subtract 7 (countdown), clamp based on $0115: | ||
| ; $0115.7=1 (zoom active): expired timers reset to $F0 (full) | ||
| ; $0115.7=0 (normal): expired timers clear to $00 | ||
| ; zero values: if $0115.7=1, inherit from next slot (circular, | ||
| ; $03FE[0] wraps to $03FE[7]); values <$D5 become $F0, >=$D5 become $00 | ||
| ; $29 accumulates OR of all results; if zero after loop, clears $0115 | ||
| ; called during level transitions (zoom in/out effects). |
Collaborator
There was a problem hiding this comment.
The new comment seems more specific than the code here supports. In particular, the $0115.7=1 claim looks inconsistent with nearby code that sets $0115 to $01, not a bit-7 value. The rest of the comment also assigns high-level meaning (“animation timers”, “zoom active”, “level transitions”) that may be plausible, but doesn’t look clearly established from this routine alone. I’d suggest rewriting it more conservatively unless those behaviors were verified from the full loop and its callers.
Phrased differently: please explain how you came to the conclusions your comment documents, and include specific references to the supporting source code.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
updated
; There appears to be a loop beginning here
; for ($37=7;$37>=0;$37--) running from here through a827. I'm not sure ; just what goes on inside it, yet, though.
comment to the useful comment