Skip to content

Commit

Permalink
Merge 'Change "Easy bite" hack to fix aggressive fish' (#2326)
Browse files Browse the repository at this point in the history
  • Loading branch information
cjohnson57 committed Dec 7, 2024
2 parents 7f5ef3f + 6185070 commit 5d1aa8d
Show file tree
Hide file tree
Showing 10 changed files with 21,354 additions and 21,329 deletions.
1,477 changes: 739 additions & 738 deletions ASM/build/asm_symbols.txt

Large diffs are not rendered by default.

Binary file modified ASM/build/bundle.o
Binary file not shown.
1,051 changes: 526 additions & 525 deletions ASM/build/c_symbols.txt

Large diffs are not rendered by default.

7 changes: 7 additions & 0 deletions ASM/c/inputviewer.c
Original file line number Diff line number Diff line change
Expand Up @@ -170,3 +170,10 @@ void draw_input_viewer(z64_disp_buf_t* db) {
draw_y_stick(db);
}
}

uint8_t is_hook_static() {
if (z64_game.common.input[0].raw.pad.a || z64_game.common.input[0].raw.x != 0 || z64_game.common.input[0].raw.y != 0) {
return 0;
}
return 1;
}
2 changes: 2 additions & 0 deletions ASM/c/inputviewer.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,6 @@ extern colorRGB16_t CFG_C_BUTTON_COLOR;

void draw_input_viewer(z64_disp_buf_t* db);

uint8_t is_hook_static();

#endif
13 changes: 8 additions & 5 deletions ASM/src/fishing.asm
Original file line number Diff line number Diff line change
Expand Up @@ -40,16 +40,19 @@ cast_fishing_rod_if_equipped:
nop

fishing_bite_when_stable:
lui t0, 0x801F
addiu t0, t0, 0x5DE0 ; BSS fishing data pointer
lw at, 0x009C(t0) ; at = current hook movement
bnez at, @@return
addiu sp, sp, -0x18
sw ra, 0x14(sp)

jal is_hook_static
nop
beqz v0, @@return
mul.s f4, f10, f2 ; if the hook is not stable, use the default code (set bite chance)
lui t0, 0x3F80 ; else, guarantee bite
mtc1 t0, f4 ; f4 = 1.00
@@return:
lw ra, 0x14(sp)
jr ra
nop
addiu sp, sp, 0x18

give_loach_reward:
la at, SAVE_CONTEXT
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,7 @@ issue. You should always Hard Reset to avoid this issue entirely.
* Fix a possible void out at the Forest Temple boss door.
* Fix importing settings from older versions on web.
* Fix a Mac-specific issue when loading track .meta files.
* Fix an error in the easy bite fishing hack.

#### New Speedups
* The first text box from each carpenter in the Thieves' Hideout is skipped.
Expand Down
Loading

0 comments on commit 5d1aa8d

Please sign in to comment.