summaryrefslogtreecommitdiff
path: root/bossCaptainBowser.yaml
blob: 5fb4a6382d887f5371f72ab90067f1bfa77dfd83 (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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
---
# Captain Bowser Replaces Branch
#
# KoopaThrow = WM_ANCHOR
# FlameThrower = WM_ANTLION

source_files: [../src/bossPlayerClown.cpp, ../src/bossCaptainBowser.cpp, ../src/bossKoopaThrow.cpp, ../src/bossFlameThrower.cpp]

hooks:


  ################################################
  # HOOKS FOR CAPTAIN BOWSER
  ################################################
  - name: BossCaptainBoswerBuild
    type: add_func_pointer
    src_addr_pal: 0x80955978
    target_func: 'daCaptainBowser::build(void)'

  - name: UpdateaptainBoswerSpriteInfo
    type: patch
    addr_pal: 0x8030C48C
    #      [010] (  16,  16) (   0, 0   32:  32)   64?   64?    0?    0? | [0:No Flags]
    data: '00000010 00000010  00000000 00000000 00000200 00000200  0000 0000 0200 0200 0002 0000'
    # 0x8030A340 + sprite num * 0x28 == offset (+24 in this case)

  - name: CaptainBowserSpriteFileInfo
    type: add_func_pointer
    src_addr_pal: 0x8031AEA0
    target_func: 'CBarcNameList'

    # 0x8031AB4C + sprite num * 0x4 == offset
    # That offset stores a pointer to a table of pointers to strings, followed by four bytes of padding
    # Each string is an arcname to load


  ################################################
  # HOOKS FOR KOOPA THROW
  ################################################
  - name: KoopaThrowBuild
    type: add_func_pointer
    src_addr_pal: 0x80981960
    target_func: 'daKoopaThrow::build(void)'

  - name: UpdateKoopaThrowSpriteInfo
    type: patch
    addr_pal: 0x8030A4D0
    #      [010] (  16,  16) (   0, 0   32:  32)   64?   64?    0?    0? | [0:No Flags]
    data: '029F 0000  00000010 00000010  00000000 00000000 00000020 00000020  0040 0040 0000 0000  0000 0000'
    # 0x8030A340 + sprite num * 0x28 == offset

  - name: KoopaThrowSpriteFileInfo
    type: add_func_pointer
    src_addr_pal: 0x8031AB74
    target_func: 'KPTarcNameList'
    # 0x8031AB4C + sprite num * 0x4 == offset


  ################################################
  # HOOKS FOR KOOPA FLAME THROWER
  ################################################
  - name: KFlameThrowerBuild
    type: add_func_pointer
    src_addr_pal: 0x80981A3C
    target_func: 'daKoopaBreath::build(void)'

  - name: UpdateKoopaThrowSpriteInfo
    type: patch
    addr_pal: 0x8030A570
    #      [011] (  16,  16) (   0, 0   32:  32)   64?   64?    0?    0? | [0:No Flags]
    data: '0271 0000  00000010 00000010  00000000 00000000 00000020 00000020  0040 0040 0000 0000  0000 0000'
    # 0x8030A340 + sprite num * 0x28 == offset


  ################################################
  # HOOKS FOR CLOWN CAR
  ################################################
  - name: ClownCarFloor
    type: patch
    addr_pal: 0x80810A40
    data: '60000000'

  - name: ClownCarWalls
    type: patch
    addr_pal: 0x80937A60
    data: '471C4000'

  - name: ClownCarAllocation
    type: patch
    addr_pal: 0x8080F918
    data: '386017D0' # Replace 0x0FD0 which how much space I want to allocate


  - name: UpdateClownCarSpriteInfo
    type: patch
    addr_pal: 0x8030A548
    data: '012B 0000'
    # 0x8030A340 + sprite num * 0x28 == offset



  - name: ClownCarSpriteFileInfo
    type: add_func_pointer
    src_addr_pal: 0x8031AB80
    target_func: 'PCCarcNameList'
    # 0x8031AB4C + sprite num * 0x4 == offset


  # Official Funcs
  - name: ClownCarCtor
    type: branch_insn
    branch_type: bl
    src_addr_pal: 0x8080F92C
    target_func: 'newClownCtor(dEn_c *)'

  - name: ClownCarDtor
    type: add_func_pointer
    src_addr_pal: 0x8095FF30
    target_func: 'newClownDtor(dEn_c *, unsigned int)'


  # My overrides
  - name: ClownCarMoveExecute
    type: add_func_pointer
    src_addr_pal: 0x80960184
    target_func: 'CConExecuteMove(dEn_c *)'

  - name: ClownCarAfterCreate
    type: add_func_pointer
    src_addr_pal: 0x8095FEF8
    target_func: 'CCafterCreate(dEn_c *, unsigned int)'

  - name: ClownCarOnExecute
    type: add_func_pointer
    src_addr_pal: 0x8095FF08
    target_func: 'CConExecute(dEn_c *)'

  - name: ClownCarOnDraw
    type: add_func_pointer
    src_addr_pal: 0x8095FF14
    target_func: 'CConDraw(dEn_c *)'

  # - name: ClownCarSpriteCollision
  #   type: add_func_pointer
  #   src_addr_pal: 0x8095FFDC
  #   target_func: 'CCSpriteCollision(dEn_c *, ActivePhysics *, ActivePhysics *)'






  # Clown Shot - Replaces WM_PAKKUN
  - name: ClownShotBuild
    type: add_func_pointer
    src_addr_pal: 0x80988934
    target_func: 'daClownShot::build(void)'