summaryrefslogtreecommitdiff
path: root/Remove-stat-experience.md
blob: 6d67d5617fe6a790e5cd3c445a4952431c3706bf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
This was inspired by Fireburn and comets method on disabling stat experience

For hacks with increased difficulty, this may be a good feature to use

## Contents

1. Delete `ld a, b`, `ld d, a` and replace it with `ld d, 0`


## 1. Delete `ld a, b`, `ld d, a` and replace it with `ld d, 0`

Go to [/engine/pokemon/move_mon.asm](https://github.com/pret/pokecrystal/blob/master/engine/pokemon/move_mon.asm) and delete the little portion of code as follows

```diff
CalcMonStatC:
; 'c' is 1-6 and points to the BaseStat
; 1: HP
; 2: Attack
; 3: Defense
; 4: Speed
; 5: SpAtk
; 6: SpDef
	push hl
	push de
	push bc
-	ld a, b
-	ld d, a
+       ld d, 0
	push hl
	ld hl, wBaseStats
	dec hl ; has to be decreased, because 'c' begins with 1
	ld b, 0
	add hl, bc
	ld a, [hl]
	ld e, a
	pop hl
	push hl
	ld a, c
	cp STAT_SDEF ; last stat
	jr nz, .not_spdef
	dec hl
	dec hl
```

Now you have successfully removed stat experience