|
7 | 7 | #include "memorywatch.h"
|
8 | 8 |
|
9 | 9 | #include <gc/gx.h>
|
| 10 | +#include <gc/ppc.h> |
10 | 11 | #include <ttyd/battle_unit.h>
|
11 | 12 | #include <ttyd/fontmgr.h>
|
12 | 13 | #include <ttyd/battle_disp.h>
|
@@ -42,9 +43,6 @@ void drawArtAttackHitboxes()
|
42 | 43 | uint8_t HSVA[4];
|
43 | 44 | *reinterpret_cast<uint32_t *>(&HSVA) = 0x00FFCCFF; // RGBA value is 0xCC0000FF
|
44 | 45 |
|
45 |
| - // Get the address of the write gather pipe, and handle the value at the address as a float |
46 |
| - volatile float *WriteGatherPipe = reinterpret_cast<float *>(0xCC008000); |
47 |
| - |
48 | 46 | for (uint32_t Slot = 0; Slot < 64; Slot++)
|
49 | 47 | {
|
50 | 48 | void *BattleUnitPtr = getActorPointer(Slot);
|
@@ -193,13 +191,13 @@ void drawArtAttackHitboxes()
|
193 | 191 | // Draw the line from corner 1 to corner 2
|
194 | 192 | gc::gx::GXBegin(gc::gx::GXPrimitive::GX_LINES, gc::gx::GXVtxFmt::GX_VTXFMT0, 2);
|
195 | 193 |
|
196 |
| - *WriteGatherPipe = ScreenPointOutLineStart[0]; |
197 |
| - *WriteGatherPipe = ScreenPointOutLineStart[1]; |
198 |
| - *WriteGatherPipe = 0; |
| 194 | + gc::ppc::writeGatherPipe.f32 = ScreenPointOutLineStart[0]; |
| 195 | + gc::ppc::writeGatherPipe.f32 = ScreenPointOutLineStart[1]; |
| 196 | + gc::ppc::writeGatherPipe.f32 = 0; |
199 | 197 |
|
200 |
| - *WriteGatherPipe = ScreenPointOutLineEnd[0]; |
201 |
| - *WriteGatherPipe = ScreenPointOutLineEnd[1]; |
202 |
| - *WriteGatherPipe = 0; |
| 198 | + gc::ppc::writeGatherPipe.f32 = ScreenPointOutLineEnd[0]; |
| 199 | + gc::ppc::writeGatherPipe.f32 = ScreenPointOutLineEnd[1]; |
| 200 | + gc::ppc::writeGatherPipe.f32 = 0; |
203 | 201 | }
|
204 | 202 | }
|
205 | 203 | }
|
|
0 commit comments