You've already forked pokecrystal-board
mirror of
https://gitlab.com/xCrystal/pokecrystal-board.git
synced 2025-04-09 05:44:44 -07:00
More optimal fix for the experience underflow bug
This commit is contained in:
@@ -839,10 +839,9 @@ This can bring Pokémon straight from level 1 to 100 by gaining just a few exper
|
|||||||
CalcExpAtLevel:
|
CalcExpAtLevel:
|
||||||
; (a/b)*n**3 + c*n**2 + d*n - e
|
; (a/b)*n**3 + c*n**2 + d*n - e
|
||||||
+ ld a, d
|
+ ld a, d
|
||||||
+ cp 1
|
+ dec a
|
||||||
+ jr nz, .UseExpFormula
|
+ jr nz, .UseExpFormula
|
||||||
+; Pokémon have 0 experience at level 1
|
+; Pokémon have 0 experience at level 1
|
||||||
+ xor a
|
|
||||||
+ ld hl, hProduct
|
+ ld hl, hProduct
|
||||||
+ ld [hli], a
|
+ ld [hli], a
|
||||||
+ ld [hli], a
|
+ ld [hli], a
|
||||||
|
Reference in New Issue
Block a user