Skip to content

Instantly share code, notes, and snippets.

@taylus
Created September 4, 2018 05:06
Show Gist options
  • Select an option

  • Save taylus/7d0fa6d2bb0ecd8710ba9fc9278e9c26 to your computer and use it in GitHub Desktop.

Select an option

Save taylus/7d0fa6d2bb0ecd8710ba9fc9278e9c26 to your computer and use it in GitHub Desktop.
; if (a == $05)
    cp $05
    jr nz, .else_if     ;----+
    ; ...                    |
    jr .end_if          ;----|----+
.else_if:               ;<---+    |
    cp $06              ;         |
    jr nz, .else        ;---------|----+
    ; ...                         |    |
    jr .end_if          ;---------+    |
.else:                  ;<--------|----+
    ; ...                         |
.end_if:                ;<--------+
; if (a == $05)
    cp $05
    jr nz, .else_if     ;----+
    ; ...                    |
    jr .end_if          ;----|----+
.else_if:               ;<---+    |
    cp $06              ;         |
    jr nz, .else        ;---------|----+
    ; ...                         |    |
    jr .end_if          ;---------+    |
.else:                  ;<--------|----+
    ; ...                         |
.end_if:                ;<--------+
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment