mirror of
https://github.com/coop-deluxe/sm64coopdx.git
synced 2024-11-22 12:05:11 +00:00
663e4549d8
* Proof of concept for loading rom assets at runtime * Added skybox textures * Adjusted format * Load all texture assets from rom * Adjusted rom asset loading * Load all Vtx lists from rom * clean up toad, wario and his cap conflicts * Load sound samples from rom * fix toad sounds * Loaded sequences from rom * Load collisions from rom * Object animations are now loaded from the rom * Load player animations from rom * Load goddard anims from rom * whoops * fix some compile errors * drag and drop rom checker, everything works now. * fix errors due to merge conflicts * fix compile errors on windows, switch to md5 * fix vertex colors during load Co-Authored-By: Agent X <44549182+agent-11@users.noreply.github.com> * Load dialogs from rom * Loaded course/act names from rom * Loaded ingame text from rom * rerun autogen & blacklist smlua_text_utils_init * fix ttc_seg7_vertex_0700B238 colors --------- Co-authored-by: MysterD <myster@d> Co-authored-by: Agent X <44549182+agent-11@users.noreply.github.com>
149 lines
6 KiB
C
149 lines
6 KiB
C
#include "pc/rom_assets.h"
|
|
#include <PR/ultratypes.h>
|
|
#include <PR/gbi.h>
|
|
|
|
#include "macros.h"
|
|
#include "types.h"
|
|
|
|
#include "make_const_nonconst.h"
|
|
|
|
UNUSED static const u64 effect_unused_0 = 0;
|
|
|
|
// Flower (Unused)
|
|
// 0x0B000008
|
|
ROM_ASSET_LOAD_TEXTURE(effect_0B000008, "textures/effect/flower.00008.rgba16.inc.c", 0x0036f530, 9994, 0x00000008, 2048);
|
|
|
|
// 0x0B000808
|
|
ROM_ASSET_LOAD_TEXTURE(effect_0B000808, "textures/effect/flower.00808.rgba16.inc.c", 0x0036f530, 9994, 0x00000808, 2048);
|
|
|
|
// 0x0B001008
|
|
ROM_ASSET_LOAD_TEXTURE(effect_0B001008, "textures/effect/flower.01008.rgba16.inc.c", 0x0036f530, 9994, 0x00001008, 2048);
|
|
|
|
// 0x0B001808
|
|
ROM_ASSET_LOAD_TEXTURE(effect_0B001808, "textures/effect/flower.01808.rgba16.inc.c", 0x0036f530, 9994, 0x00001808, 2048);
|
|
|
|
// 0x0B002008
|
|
const Texture *const flower_bubbles_textures_ptr_0B002008[] = {
|
|
effect_0B000008,
|
|
effect_0B000808,
|
|
effect_0B001008,
|
|
effect_0B001808,
|
|
effect_0B001008,
|
|
effect_0B000808,
|
|
};
|
|
|
|
// Lava Bubble
|
|
// 0x0B002020
|
|
ROM_ASSET_LOAD_TEXTURE(effect_0B002020, "textures/effect/lava_bubble.02020.rgba16.inc.c", 0x0036f530, 9994, 0x00002020, 2048);
|
|
|
|
// 0x0B002820
|
|
ROM_ASSET_LOAD_TEXTURE(effect_0B002820, "textures/effect/lava_bubble.02820.rgba16.inc.c", 0x0036f530, 9994, 0x00002820, 2048);
|
|
|
|
// 0x0B003020
|
|
ROM_ASSET_LOAD_TEXTURE(effect_0B003020, "textures/effect/lava_bubble.03020.rgba16.inc.c", 0x0036f530, 9994, 0x00003020, 2048);
|
|
|
|
// 0x0B003820
|
|
ROM_ASSET_LOAD_TEXTURE(effect_0B003820, "textures/effect/lava_bubble.03820.rgba16.inc.c", 0x0036f530, 9994, 0x00003820, 2048);
|
|
|
|
// 0x0B004020
|
|
ROM_ASSET_LOAD_TEXTURE(effect_0B004020, "textures/effect/lava_bubble.04020.rgba16.inc.c", 0x0036f530, 9994, 0x00004020, 2048);
|
|
|
|
// 0x0B004820
|
|
ROM_ASSET_LOAD_TEXTURE(effect_0B004820, "textures/effect/lava_bubble.04820.rgba16.inc.c", 0x0036f530, 9994, 0x00004820, 2048);
|
|
|
|
// 0x0B005020
|
|
ROM_ASSET_LOAD_TEXTURE(effect_0B005020, "textures/effect/lava_bubble.05020.rgba16.inc.c", 0x0036f530, 9994, 0x00005020, 2048);
|
|
|
|
// 0x0B005820
|
|
ROM_ASSET_LOAD_TEXTURE(effect_0B005820, "textures/effect/lava_bubble.05820.rgba16.inc.c", 0x0036f530, 9994, 0x00005820, 2048);
|
|
|
|
// 0x0B006020
|
|
const Texture *const lava_bubble_ptr_0B006020[] = {
|
|
effect_0B002020,
|
|
effect_0B002820,
|
|
effect_0B003020,
|
|
effect_0B003020,
|
|
effect_0B003020,
|
|
effect_0B003820,
|
|
effect_0B004020,
|
|
effect_0B004820,
|
|
effect_0B005020,
|
|
effect_0B005820,
|
|
};
|
|
|
|
// Bubble
|
|
// 0x0B006048
|
|
ROM_ASSET_LOAD_TEXTURE(effect_0B006048, "textures/effect/bubble.06048.rgba16.inc.c", 0x0036f530, 9994, 0x00006048, 2048);
|
|
|
|
// 0x0B006848
|
|
const Texture *const bubble_ptr_0B006848[] = {
|
|
effect_0B006048,
|
|
};
|
|
|
|
// Tiny Bubble
|
|
// 0x0B00684C
|
|
ROM_ASSET_LOAD_TEXTURE(effect_0B00684C, "textures/effect/tiny_bubble.0684C.rgba16.inc.c", 0x0036f530, 9994, 0x0000684c, 512);
|
|
|
|
// 0x0B006A50 - 0x0B006AB0
|
|
const Gfx tiny_bubble_dl_0B006A50[] = {
|
|
gsDPPipeSync(),
|
|
gsSPClearGeometryMode(G_LIGHTING | G_CULL_BACK | G_SHADING_SMOOTH),
|
|
gsSPTexture(0x8000, 0x8000, 0, G_TX_RENDERTILE, G_ON),
|
|
gsDPSetCombineMode(G_CC_MODULATERGBA, G_CC_MODULATERGBA),
|
|
gsDPSetRenderMode(G_RM_AA_ZB_TEX_EDGE, G_RM_AA_ZB_TEX_EDGE2),
|
|
gsDPSetTextureImage(G_IM_FMT_RGBA, G_IM_SIZ_16b, 1, effect_0B00684C),
|
|
gsDPSetTile(G_IM_FMT_RGBA, G_IM_SIZ_16b, 0, 0, G_TX_LOADTILE, 0, G_TX_WRAP | G_TX_NOMIRROR, 4, G_TX_NOLOD, G_TX_WRAP | G_TX_NOMIRROR, 4, G_TX_NOLOD),
|
|
gsDPLoadSync(),
|
|
gsDPLoadBlock(G_TX_LOADTILE, 0, 0, 16 * 16 - 1, CALC_DXT(16, G_IM_SIZ_16b_BYTES)),
|
|
gsDPSetTile(G_IM_FMT_RGBA, G_IM_SIZ_16b, 4, 0, G_TX_RENDERTILE, 0, G_TX_WRAP | G_TX_NOMIRROR, 4, G_TX_NOLOD, G_TX_WRAP | G_TX_NOMIRROR, 4, G_TX_NOLOD),
|
|
gsDPSetTileSize(0, 0, 0, (16 - 1) << G_TEXTURE_IMAGE_FRAC, (16 - 1) << G_TEXTURE_IMAGE_FRAC),
|
|
gsSPEndDisplayList(),
|
|
};
|
|
|
|
// 0x0B006AB0 - 0x0B006AD8
|
|
const Gfx tiny_bubble_dl_0B006AB0[] = {
|
|
gsSPTexture(0x0001, 0x0001, 0, G_TX_RENDERTILE, G_OFF),
|
|
gsDPSetCombineMode(G_CC_SHADE, G_CC_SHADE),
|
|
gsDPSetRenderMode(G_RM_AA_ZB_OPA_SURF, G_RM_AA_ZB_OPA_SURF2),
|
|
gsSPSetGeometryMode(G_LIGHTING | G_CULL_BACK | G_SHADING_SMOOTH),
|
|
gsSPEndDisplayList(),
|
|
};
|
|
|
|
// 0x0B006AD8
|
|
ROM_ASSET_LOAD_TEXTURE(effect_0B006AD8, "textures/effect/tiny_bubble.06AD8.rgba16.inc.c", 0x0036f530, 9994, 0x00006ad8, 512);
|
|
|
|
// 0x0B006CD8 - 0x0B006D38
|
|
const Gfx tiny_bubble_dl_0B006CD8[] = {
|
|
gsDPPipeSync(),
|
|
gsSPClearGeometryMode(G_LIGHTING | G_SHADING_SMOOTH),
|
|
gsDPSetTextureImage(G_IM_FMT_RGBA, G_IM_SIZ_16b, 1, effect_0B006AD8),
|
|
gsDPSetCombineMode(G_CC_MODULATERGBA, G_CC_MODULATERGBA),
|
|
gsDPSetRenderMode(G_RM_AA_ZB_TEX_EDGE, G_RM_AA_ZB_TEX_EDGE2),
|
|
gsSPTexture(0x8000, 0x8000, 0, G_TX_RENDERTILE, G_ON),
|
|
gsDPSetTile(G_IM_FMT_RGBA, G_IM_SIZ_16b, 0, 0, G_TX_LOADTILE, 0, G_TX_WRAP | G_TX_NOMIRROR, G_TX_NOMASK, G_TX_NOLOD, G_TX_WRAP | G_TX_NOMIRROR, G_TX_NOMASK, G_TX_NOLOD),
|
|
gsDPLoadSync(),
|
|
gsDPLoadBlock(G_TX_LOADTILE, 0, 0, 16 * 16 - 1, CALC_DXT(16, G_IM_SIZ_16b_BYTES)),
|
|
gsDPSetTile(G_IM_FMT_RGBA, G_IM_SIZ_16b, 4, 0, G_TX_RENDERTILE, 0, G_TX_WRAP | G_TX_NOMIRROR, G_TX_NOMASK, G_TX_NOLOD, G_TX_WRAP | G_TX_NOMIRROR, G_TX_NOMASK, G_TX_NOLOD),
|
|
gsDPSetTileSize(0, 0, 0, (16 - 1) << G_TEXTURE_IMAGE_FRAC, (16 - 1) << G_TEXTURE_IMAGE_FRAC),
|
|
gsSPEndDisplayList(),
|
|
};
|
|
|
|
// 0x0B006D38 - 0x0B006D68
|
|
const Gfx tiny_bubble_dl_0B006D38[] = {
|
|
gsDPPipeSync(),
|
|
gsSPClearGeometryMode(G_LIGHTING | G_SHADING_SMOOTH),
|
|
gsDPSetCombineMode(G_CC_MODULATERGBA, G_CC_MODULATERGBA),
|
|
gsDPSetRenderMode(G_RM_AA_ZB_TEX_EDGE, G_RM_AA_ZB_TEX_EDGE2),
|
|
gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON),
|
|
gsSPEndDisplayList(),
|
|
};
|
|
|
|
// 0x0B006D68 - 0x0B006D98
|
|
const Gfx tiny_bubble_dl_0B006D68[] = {
|
|
gsDPSetTile(G_IM_FMT_RGBA, G_IM_SIZ_16b, 0, 0, G_TX_LOADTILE, 0, G_TX_CLAMP, 5, G_TX_NOLOD, G_TX_CLAMP, 5, G_TX_NOLOD),
|
|
gsDPLoadSync(),
|
|
gsDPLoadBlock(G_TX_LOADTILE, 0, 0, 32 * 32 - 1, CALC_DXT(32, G_IM_SIZ_16b_BYTES)),
|
|
gsDPSetTile(G_IM_FMT_RGBA, G_IM_SIZ_16b, 8, 0, G_TX_RENDERTILE, 0, G_TX_CLAMP, 5, G_TX_NOLOD, G_TX_CLAMP, 5, G_TX_NOLOD),
|
|
gsDPSetTileSize(0, 0, 0, (32 - 1) << G_TEXTURE_IMAGE_FRAC, (32 - 1) << G_TEXTURE_IMAGE_FRAC),
|
|
gsSPEndDisplayList(),
|
|
};
|