Skip to content

Commit d3559b8

Browse files
committed
Merge 'Add Double Magic Model and Clean Magic 1 ZOBJ' (#2413)
2 parents 5596076 + d73ae4b commit d3559b8

15 files changed

Lines changed: 6220 additions & 6218 deletions

ASM/build/asm_symbols.txt

Lines changed: 654 additions & 654 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

ASM/build/bundle.o

40 Bytes
Binary file not shown.

ASM/build/c_symbols.txt

Lines changed: 90 additions & 90 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

ASM/c/item_draw_functions.c

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -730,13 +730,13 @@ void draw_gi_magic_meter(z64_game_t* game, uint32_t draw_id) {
730730
z64_gfx_t *gfx = game->common.gfx;
731731

732732
// Magic
733-
colorRGBA8_t prim_color = item_draw_table[draw_id].args[5].color;
733+
colorRGBA8_t prim_color = item_draw_table[draw_id].args[4].color;
734734
if (CFG_CORRECT_MODEL_COLORS) {
735735
prim_color.r = CFG_MAGIC_COLOR.r;
736736
prim_color.g = CFG_MAGIC_COLOR.g;
737737
prim_color.b = CFG_MAGIC_COLOR.b;
738738
}
739-
colorRGBA8_t env_color = item_draw_table[draw_id].args[6].color;
739+
colorRGBA8_t env_color = item_draw_table[draw_id].args[5].color;
740740

741741
uint8_t alpha = 0x80;
742742
if (curr_drawn_actor != NULL && curr_drawn_actor->actor_id == 21) {// En_Item00
@@ -749,33 +749,27 @@ void draw_gi_magic_meter(z64_game_t* game, uint32_t draw_id) {
749749
colorRGBA8_t rainbow_color;
750750
rainbow_color.a = 0xFF;
751751
rainbow_color.color = get_rainbow_color(game->gameplay_frames, 10);
752-
//z64_xyzf_t translation = { .x = 0, .y = -35.0f, .z = -20.0f };
753752
z64_xyzf_t translation = { .x = 0.0, .y = -35.0f, .z = 0.0f };
754753
z64_xyzf_t scale = { .x = .0125f, .y = .0075f, .z = .01f };
755754
draw_gi_flame(&gfx->poly_xlu, game, rainbow_color, rainbow_color, translation, scale);
755+
756756
// Parchment
757757
append_setup_dl_25_to_xlu(gfx);
758758
gSPMatrix(gfx->poly_xlu.p++, append_sys_matrix(gfx), G_MTX_MODELVIEW | G_MTX_LOAD | G_MTX_NOPUSH);
759-
gSPDisplayList(gfx->poly_xlu.p++, item_draw_table[draw_id].args[3].dlist);
759+
gSPDisplayList(gfx->poly_xlu.p++, item_draw_table[draw_id].args[2].dlist);
760+
760761
// Writing
761762
append_setup_dl_25_to_xlu(gfx);
762763
gSPMatrix(gfx->poly_xlu.p++, append_sys_matrix(gfx), G_MTX_MODELVIEW | G_MTX_LOAD | G_MTX_NOPUSH);
763-
gSPDisplayList(gfx->poly_xlu.p++, item_draw_table[draw_id].args[4].dlist);
764-
765-
// Shine
766-
/*append_setup_dl_25_to_xlu(gfx);
767-
gSPMatrix(gfx->poly_xlu.p++, append_sys_matrix(gfx), G_MTX_MODELVIEW | G_MTX_LOAD | G_MTX_NOPUSH);
768-
gDPSetPrimColor(gfx->poly_xlu.p++, 0, 0x80, prim_color.r, prim_color.g, prim_color.b, alpha);
769-
gDPSetEnvColor(gfx->poly_xlu.p++, env_color.r, env_color.g, env_color.b, env_color.a);
770-
gSPDisplayList(gfx->poly_xlu.p++, item_draw_table[draw_id].args[2].dlist);
771-
*/
764+
gSPDisplayList(gfx->poly_xlu.p++, item_draw_table[draw_id].args[3].dlist);
772765

773766
// Jar
774767
append_setup_dl_25_to_xlu(gfx);
775768
gSPMatrix(gfx->poly_xlu.p++, append_sys_matrix(gfx), G_MTX_MODELVIEW | G_MTX_LOAD | G_MTX_NOPUSH);
776769
gDPSetPrimColor(gfx->poly_xlu.p++, 0, 0x80, prim_color.r, prim_color.g, prim_color.b, alpha);
777770
gDPSetEnvColor(gfx->poly_xlu.p++, env_color.r, env_color.g, env_color.b, env_color.a);
778771
gSPDisplayList(gfx->poly_xlu.p++, item_draw_table[draw_id].args[0].dlist);
772+
779773
// Label
780774
append_setup_dl_25_to_xlu(gfx);
781775
gSPMatrix(gfx->poly_xlu.p++, append_sys_matrix(gfx), G_MTX_MODELVIEW | G_MTX_LOAD | G_MTX_NOPUSH);

ASM/c/item_draw_table.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,9 +174,10 @@ item_draw_table_entry_t item_draw_table[] = {
174174
[0x9C] = { draw_gi_stones, { 0x06000b00, 0x060012f0, 0x32ffffff, 0x320096ff } }, // Zora Sapphire
175175
[0x9D] = { draw_gi_fairy, { 0x06000EF0 } }, // Fairy (not in a bottle but uses the fairy from the bottle)
176176
[0x9E] = { draw_gi_nothing, {} },
177-
[0x9F] = { draw_gi_magic_meter, { 0x06000000, 0x060007B0, 0x06000FD8, 0x060009F8, 0x06001438, 0x286428FF, 0x000000FF } }, // Magic Meter Scroll
177+
[0x9F] = { draw_gi_magic_meter, { 0x06000000, 0x060007B0, 0x060009F8, 0x06000FD8, 0x286428FF, 0x000000FF } }, // Magic Meter Scroll
178178
[0xA0] = { draw_gi_xlu_with_flame, { 0x060004D0, 0xC0C0C0FF, 0xC0C0C0FF } }, // Deku Stick Upgrade w/ Smoke Effect
179179
[0xA1] = { draw_gi_deku_nut_with_flame, { 0x06000E90, 0xC0C0C0FF, 0xC0C0C0FF } }, // Deku Nut Upgrade w/ Smoke Effect
180+
[0xA2] = { draw_gi_magic_meter, { 0x06000000, 0x06000CC0, 0x06000F08, 0x060014E8, 0x286428FF, 0x000000FF } }, // Magic Meter Scroll 2
180181
};
181182

182183
void base_draw_gi_model(z64_game_t* game, uint32_t draw_id) {

ASM/c/item_table.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ item_row_t item_table[GI_RANDO_MAX] = {
224224

225225
[GI_DOUBLE_DEFENSE] = ITEM_ROW(0x53, GILDED_CHEST, 0x41, -1, 0x00E9, 0x0194, 0x13, no_upgrade, give_defense, -1, -1, NULL), // Double Defense
226226
[GI_MAGIC_METER] = ITEM_ROW(0x53, GILDED_CHEST, 0x41, -1, 0x00E4, 0x01B4, 0xA0, no_upgrade, give_magic, -1, -1, NULL), // Magic Meter
227-
[GI_DOUBLE_MAGIC] = ITEM_ROW(0x53, GILDED_CHEST, 0x41, -1, 0x00E8, 0x01B4, 0xA0, no_upgrade, give_double_magic, -1, -1, NULL), // Double Magic
227+
[GI_DOUBLE_MAGIC] = ITEM_ROW(0x53, GILDED_CHEST, 0x41, -1, 0x00E8, 0x01B5, 0xA3, no_upgrade, give_double_magic, -1, -1, NULL), // Double Magic
228228

229229
[GI_MINUET_OF_FOREST] = ITEM_ROW(0x53, GILDED_CHEST, 0x41, -1, 0x9091, 0x0196, 0x78, no_upgrade, give_quest_item, 6, -1, NULL), // Minuet of Forest
230230
[GI_BOLERO_OF_FIRE] = ITEM_ROW(0x53, GILDED_CHEST, 0x41, -1, 0x9092, 0x0196, 0x79, no_upgrade, give_quest_item, 7, -1, NULL), // Bolero of Fire

ASM/src/config.asm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ INITIAL_SAVE_DATA:
153153
EXTENDED_INITIAL_SAVE_DATA:
154154
.endarea
155155

156-
.area 0x110, 0 ; size must be at least 8 * ((max object_id parameter Patches.add_to_extended_object_table is called with) - 0x192)
156+
.area 0x118, 0 ; size must be at least 8 * ((max object_id parameter Patches.add_to_extended_object_table is called with) - 0x192)
157157
EXTENDED_OBJECT_TABLE:
158158
.endarea
159159

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838

3939
## Other Changes
4040
* Now supports custom music written for the Majora's Mask Randomizer.
41-
* New Magic Meter item model to allow magic drops to be shuffled in the future.
41+
* New Magic Meter item models to allow magic drops to be shuffled in the future.
4242
* Add a smoke effect to Deku Stick Capacity and Deku Nut Capacity items to distinguish them from refills.
4343
* Seeds rolled on ootrandomizer.com display their ID in the top left corner of the file select screen.
4444
* The `Other` tab of the generator has been rearranged for better grouping of settings, and the `One Major Item per Dungeon` setting has been moved there since it was causing frequent failures with `Randomize Main Rule Settings`.

Patches.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,7 @@ def patch_rom(spoiler: Spoiler, world: World, rom: Rom) -> Rom:
9191
('object_gi_cbutton', data_path('items/C_Button_Horizontal.zobj'), 0x1A9), # C button Horizontal
9292
('object_gi_cbutton', data_path('items/C_Button_Vertical.zobj'), 0x1AA), # C button Vertical
9393
('object_gi_magic_meter', data_path('items/MagicMeter.zobj'), 0x1B4), # Magic Scroll
94+
('object_gi_magic_meter', data_path('items/MagicMeter2.zobj'), 0x1B5), # Magic Scroll 2
9495
)
9596

9697
if world.settings.key_appearance_match_dungeon:

data/generated/patch_symbols.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)