Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: Unclear mistake in GivePokerusAndConvertBerries routine #1030

Open
Rangi42 opened this issue Jan 10, 2023 · 0 comments
Open

Bug: Unclear mistake in GivePokerusAndConvertBerries routine #1030

Rangi42 opened this issue Jan 10, 2023 · 0 comments
Labels

Comments

@Rangi42
Copy link
Member

Rangi42 commented Jan 10, 2023

engine/events/pokerus/pokerus.asm had a comment added in c087d44:

	ld b, a
	and $f0
	jr z, .load_pkrs
	ld a, b
	and $7
	inc a
.load_pkrs
	ld b, a ; this should come before the label
	swap b
	and $3
	inc a
	add b
	ld [hl], a

This makes the fix clear, but not the consequences of the bug. It should be documented like the rest.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant