port: fix muzzle flashes on some guns

This commit is contained in:
fgsfds 2023-08-15 00:49:35 +02:00
parent 0cc29d2c99
commit 7666ccf2c7
1 changed files with 7 additions and 1 deletions

View File

@ -341,13 +341,19 @@ static void preprocessModelNode(struct modelnode *node, u8 *base, u32 ofs)
break;
case MODELNODETYPE_STARGUNFIRE:
PD_SWAP_VAL(ro->stargunfire.unk00);
PD_SWAP_PTR(ro->stargunfire.vertices);
PD_SWAP_PTR(ro->stargunfire.baseaddr);
if (ro->stargunfire.gdl) {
PD_SWAP_PTR(ro->stargunfire.gdl);
preprocessGfx(PD_PTR_BASEOFS(ro->stargunfire.gdl, base, ofs), base, ofs);
ro->stargunfire.gdl = SEGADDR(ro->stargunfire.gdl);
}
if (ro->stargunfire.vertices) {
PD_SWAP_PTR(ro->stargunfire.vertices);
Vtx *vtx = PD_PTR_BASEOFS(ro->stargunfire.vertices, base, ofs);
for (s32 i = 0; i < 4 * ro->stargunfire.unk00; ++i, ++vtx) {
preprocessVtx(vtx);
}
}
break;
case MODELNODETYPE_HEADSPOT:
PD_SWAP_VAL(ro->headspot.rwdataindex);