Compare commits

...

1 Commits
0.7.0 ... main

  1. 6
      inc/guess.asm
  2. 4
      inc/hints.asm
  3. 6
      inc/init.asm
  4. 8
      inc/input.asm
  5. 4
      wordle.asm

6
inc/guess.asm

@ -7,11 +7,11 @@
; Updates the objects of the entered characters ; Updates the objects of the entered characters
; -> [guesses] ; -> [guess_attempts]
; <- [obj_guess_letters] ; <- [obj_guess_letters]
update_guess_objects: update_guess_objects:
ld hl, obj_guess_letters ld hl, obj_guess_letters
ld de, guesses ld de, guess_attempts
ld a, $14 ld a, $14
call update_guess_row call update_guess_row
@ -100,7 +100,7 @@ get_guess_offset:
call multiply_ab call multiply_ab
ld b, 0 ld b, 0
ld c, a ld c, a
ld hl, guesses ld hl, guess_attempts
add hl, bc add hl, bc
ret ret

4
inc/hints.asm

@ -8,12 +8,12 @@
; Updates the background layer with the obtained hints. ; Updates the background layer with the obtained hints.
; Note: a row within the background map consists of 32 tiles ; Note: a row within the background map consists of 32 tiles
; -> [guesses_hints] ; -> [guess_hints]
; <- [BKG_LOC_9800] ; <- [BKG_LOC_9800]
update_hint_markings: update_hint_markings:
; calculate the ; calculate the
ld hl, BKG_LOC_9800 + 32*20 + 6 ld hl, BKG_LOC_9800 + 32*20 + 6
ld de, guesses_hints ld de, guess_hints
ld b, 6 ld b, 6
.loop_outer: .loop_outer:

6
inc/init.asm

@ -153,8 +153,8 @@ init_state_game:
ld [current_guess], a ld [current_guess], a
ld [current_char], a ld [current_char], a
.reset_guesses .reset_guess_attempts
ld hl, guesses ld hl, guess_attempts
ld a, NULL ld a, NULL
ld d, 30 ld d, 30
.loop1: .loop1:
@ -163,7 +163,7 @@ init_state_game:
jp nz, .loop1 jp nz, .loop1
.reset_hints .reset_hints
ld hl, guesses_hints ld hl, guess_hints
ld a, TILE_WHITE ld a, TILE_WHITE
ld d, 30 ld d, 30
.loop2: .loop2:

8
inc/input.asm

@ -212,7 +212,7 @@ handle_input_after:
; -> e: y position of the cursor ; -> e: y position of the cursor
; <- [current_guess] ; <- [current_guess]
; <- [current_char] ; <- [current_char]
; <- [guesses] ; <- [guess_attempts]
select_letter: select_letter:
push hl push hl
push af push af
@ -235,7 +235,7 @@ select_letter:
jp .return jp .return
.normal_letter: .normal_letter:
ld hl, guesses ld hl, guess_attempts
ld a, [current_guess] ld a, [current_guess]
ld b, 5 ld b, 5
call multiply_ab call multiply_ab
@ -265,14 +265,14 @@ select_letter:
; Delete the last entered letter ; Delete the last entered letter
; <- [current_guess] ; <- [current_guess]
; <- [current_char] ; <- [current_char]
; <- [guesses] ; <- [guess_attempts]
delete_letter: delete_letter:
push hl push hl
push af push af
push bc push bc
push de push de
ld hl, guesses ld hl, guess_attempts
ld a, [current_guess] ld a, [current_guess]
ld b, 5 ld b, 5
call multiply_ab call multiply_ab

4
wordle.asm

@ -372,11 +372,11 @@ current_word:
DS 5 DS 5
; The guess attempts ; The guess attempts
guesses: guess_attempts:
DS 30 DS 30
; The corresponding hints ; The corresponding hints
guesses_hints: guess_hints:
DS 30 DS 30
; Message timeout (remaining number of frames) ; Message timeout (remaining number of frames)

Loading…
Cancel
Save