summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTreeki <treeki@gmail.com>2012-12-09 23:58:06 +0100
committerTreeki <treeki@gmail.com>2012-12-09 23:58:06 +0100
commit6d0dedaa4842125456889fde84aeed474b0cffe8 (patch)
treee72f52eb38d1a49991b9e6aa1ed93b39c9fd4a0b
parentf2957939bddd68ccbffd5cdc1336704b44960c1a (diff)
downloadkamek-6d0dedaa4842125456889fde84aeed474b0cffe8.tar.gz
kamek-6d0dedaa4842125456889fde84aeed474b0cffe8.zip
strongbox fixes
Diffstat (limited to '')
-rw-r--r--poweruphax.yaml4
-rw-r--r--src/poweruphax.S7
2 files changed, 10 insertions, 1 deletions
diff --git a/poweruphax.yaml b/poweruphax.yaml
index eed8785..a8b2dbe 100644
--- a/poweruphax.yaml
+++ b/poweruphax.yaml
@@ -732,6 +732,10 @@ hooks:
src_addr_pal: 0x808AAF90
target_func: 'StrongboxGiveBattleItem'
+ - name: StrongboxNoMushroom
+ type: nop_insn
+ area_pal: 0x808AB3E0
+
- name: NoSoundBattleKinopio
type: nop_insn
area_pal: 0x808AB5FC
diff --git a/src/poweruphax.S b/src/poweruphax.S
index 49babc5..ef957e2 100644
--- a/src/poweruphax.S
+++ b/src/poweruphax.S
@@ -1014,7 +1014,9 @@ StrongboxGiveBattleItem:
clrlwi r29, r7, 28
# now give it
- mr r4, r29
+ lis r4, IndexItemsForStockItem@h
+ ori r4, r4, IndexItemsForStockItem@l
+ lbzx r4, r4, r29
bl AddStockPowerup
# and then copy the position
@@ -1039,3 +1041,6 @@ StrongboxGiveBattleItem:
lwz r29, 0x24(r1)
b continueFromStrongBox2
+.data
+IndexItemsForStockItem:
+.byte 0,1,2,4,5,6,3,7