blob: 07a9bcd1e6f6d1f565c979e498ddff60d5987e90 (
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
46
47
48
49
50
51
|
The simplest possible way to implement Running Shoes is to double the player's walking speed, just like the Bicycle, if you're holding the B button. Don't bother to disable running indoors like Gen 3, or have a permanent toggle like Gen 4.
This is easy to do, as discovered by [Victoria Lacroix](https://github.com/VictoriaLacroix/pokecrystal/commit/ed7f525d642cb02e84e856f2e506d2a6425d95db). Just edit [engine/overworld/player_movement.asm](../blob/master/engine/overworld/player_movement.asm):
```diff
DoPlayerMovement::
...
; Downhill riding is slower when not moving down.
+ call .RunCheck
+ jr z, .fast
call .BikeCheck
jr nz, .walk
...
.fast
ld a, STEP_BIKE
call .DoStep
scf
ret
.walk
ld a, STEP_WALK
call .DoStep
scf
ret
...
.BikeCheck:
ld a, [wPlayerState]
cp PLAYER_BIKE
ret z
cp PLAYER_SKATE
ret
+
+.RunCheck:
+ ld a, [wPlayerState]
+ cp PLAYER_NORMAL
+ ret nz
+ ldh a, [hJoypadDown]
+ and B_BUTTON
+ cp B_BUTTON
+ ret
```
That's it!
If you want Running Shoes to have a speed in-between walking and biking... that's more complicated. I'll update this tutorial if I ever figure out how to do that.
|