-
Notifications
You must be signed in to change notification settings - Fork 130
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
HailSanta
authored and
HailSanta
committed
Oct 9, 2023
1 parent
2209585
commit e034751
Showing
17 changed files
with
784 additions
and
763 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,218 @@ | ||
#include "common.h" | ||
#include "battle/battle.h" | ||
#include "sprite/player.h" | ||
|
||
extern IMG_BIN ui_battle_menu_spirits_png[]; | ||
extern PAL_BIN ui_battle_menu_spirits_pal[]; | ||
extern IMG_BIN ui_battle_solid_star_png[]; | ||
extern PAL_BIN ui_battle_solid_star_pal[]; | ||
|
||
PlayerCelebrationAnimOptions bPlayerCelebrations = { | ||
10, 90, | ||
{ | ||
50, ANIM_MarioB1_JumpForJoy, | ||
50, ANIM_Mario1_Chuckle, | ||
0, 0, | ||
0, 0, | ||
0, 0, | ||
0, 0, | ||
0, 0, | ||
0, 0, | ||
50, ANIM_Mario1_DustOff, | ||
50, ANIM_Mario1_DustOff, | ||
0, 0, | ||
0, 0, | ||
0, 0, | ||
0, 0, | ||
0, 0, | ||
0, 0, | ||
50, ANIM_Mario1_ThumbsUp, | ||
50, ANIM_Mario1_ThumbsUp, | ||
0, 0, | ||
0, 0, | ||
0, 0, | ||
0, 0, | ||
0, 0, | ||
0, 0, | ||
50, ANIM_MarioB1_FingerWag, | ||
50, ANIM_MarioB1_FingerWag, | ||
0, 0, | ||
0, 0, | ||
0, 0, | ||
0, 0, | ||
0, 0, | ||
0, 0, | ||
80, ANIM_MarioB1_FingerWag, | ||
20, ANIM_MarioB1_JumpForJoy, | ||
0, 0, | ||
0, 0, | ||
0, 0, | ||
0, 0, | ||
0, 0, | ||
0, 0, | ||
} | ||
}; | ||
|
||
#include "battle/actor_types.inc.c" | ||
|
||
u32 bMarioIdleAnims[] = { | ||
STATUS_KEY_NORMAL, ANIM_Mario1_Walk, | ||
STATUS_KEY_DANGER, ANIM_Mario1_TiredIdle, | ||
STATUS_KEY_STONE, ANIM_MarioB3_Petrified, | ||
STATUS_KEY_SLEEP, ANIM_MarioB1_Sleep, | ||
STATUS_KEY_DIZZY, ANIM_MarioB1_Sick, | ||
STATUS_KEY_STOP, ANIM_Mario1_Still, | ||
STATUS_KEY_HUSTLE, ANIM_Mario1_Run, | ||
STATUS_KEY_BERSERK, ANIM_MarioB2_BerserkIdle, | ||
STATUS_KEY_PARALYZE, ANIM_MarioB1_Sleep, | ||
STATUS_KEY_FROZEN, ANIM_Mario1_Frozen, | ||
STATUS_KEY_TRANSPARENT, ANIM_Mario1_Idle, | ||
STATUS_KEY_INACTIVE, ANIM_Mario1_Still, | ||
STATUS_KEY_INACTIVE_BERSERK, ANIM_MarioB2_BerserkStill, | ||
STATUS_KEY_14, ANIM_MarioB2_Inert, | ||
STATUS_KEY_INACTIVE_SLEEP, ANIM_MarioB1_SleepStill, | ||
STATUS_KEY_INACTIVE_DIZZY, ANIM_MarioB1_SickStill, | ||
STATUS_KEY_INACTIVE_WEARY, ANIM_Mario1_TiredStill, | ||
STATUS_KEY_THINKING, ANIM_Mario1_Thinking, | ||
STATUS_KEY_WEARY, ANIM_Mario1_SpinLand, | ||
STATUS_END | ||
}; | ||
|
||
s32 bMarioDefendAnims[] = { | ||
STATUS_KEY_NORMAL, ANIM_Mario1_Crouch, | ||
STATUS_KEY_DANGER, ANIM_Mario1_TiredIdle, | ||
STATUS_KEY_STONE, ANIM_MarioB3_Petrified, | ||
STATUS_KEY_SLEEP, ANIM_MarioB1_Sleep, | ||
STATUS_KEY_DIZZY, ANIM_MarioB1_Sick, | ||
STATUS_KEY_STOP, ANIM_Mario1_Still, | ||
STATUS_KEY_HUSTLE, ANIM_Mario1_Crouch, | ||
STATUS_KEY_BERSERK, ANIM_Mario1_Crouch, | ||
STATUS_KEY_PARALYZE, ANIM_MarioB1_Sleep, | ||
STATUS_KEY_FROZEN, ANIM_Mario1_Frozen, | ||
STATUS_KEY_TRANSPARENT, ANIM_Mario1_Idle, | ||
STATUS_KEY_INACTIVE, ANIM_Mario1_Still, | ||
STATUS_KEY_INACTIVE_BERSERK, ANIM_MarioB2_BerserkStill, | ||
STATUS_KEY_14, ANIM_MarioB2_Inert, | ||
STATUS_KEY_INACTIVE_SLEEP, ANIM_MarioB1_SleepStill, | ||
STATUS_KEY_INACTIVE_DIZZY, ANIM_MarioB1_SickStill, | ||
STATUS_KEY_INACTIVE_WEARY, ANIM_Mario1_TiredStill, | ||
STATUS_KEY_THINKING, ANIM_Mario1_Thinking, | ||
STATUS_KEY_WEARY, ANIM_Mario1_SpinLand, | ||
STATUS_END | ||
}; | ||
|
||
s32 bMarioHideAnims[] = { | ||
STATUS_KEY_NORMAL, ANIM_Mario1_Crouch, | ||
STATUS_KEY_DANGER, ANIM_Mario1_TiredIdle, | ||
STATUS_KEY_STONE, ANIM_MarioB3_Petrified, | ||
STATUS_KEY_SLEEP, ANIM_MarioB1_Sleep, | ||
STATUS_KEY_DIZZY, ANIM_MarioB1_Sick, | ||
STATUS_KEY_STOP, ANIM_Mario1_Still, | ||
STATUS_KEY_HUSTLE, ANIM_MarioW2_RideLaki, | ||
STATUS_KEY_BERSERK, ANIM_MarioW2_RideLaki, | ||
STATUS_KEY_PARALYZE, ANIM_MarioB1_Sleep, | ||
STATUS_KEY_FROZEN, ANIM_Mario1_Frozen, | ||
STATUS_KEY_TRANSPARENT, ANIM_Mario1_Idle, | ||
STATUS_KEY_INACTIVE, ANIM_Mario1_Crouch, | ||
STATUS_KEY_INACTIVE_BERSERK, ANIM_MarioB2_BerserkStill, | ||
STATUS_KEY_14, ANIM_MarioB2_Inert, | ||
STATUS_KEY_INACTIVE_SLEEP, ANIM_MarioB1_SleepStill, | ||
STATUS_KEY_INACTIVE_DIZZY, ANIM_MarioB1_SickStill, | ||
STATUS_KEY_INACTIVE_WEARY, ANIM_Mario1_TiredStill, | ||
STATUS_KEY_THINKING, ANIM_Mario1_Thinking, | ||
STATUS_KEY_WEARY, ANIM_Mario1_SpinLand, | ||
STATUS_END | ||
}; | ||
|
||
s32 bPeachIdleAnims[] = { | ||
STATUS_KEY_NORMAL, ANIM_Peach1_Walk, | ||
STATUS_KEY_INACTIVE, ANIM_Peach2_Inert, | ||
STATUS_END | ||
}; | ||
|
||
s32 bMarioDefenseTable[] = { | ||
ELEMENT_NORMAL, 0, | ||
ELEMENT_END | ||
}; | ||
|
||
s32 bPlayerStatusTable[] = { | ||
STATUS_KEY_NORMAL, 100, | ||
STATUS_KEY_DEFAULT, 100, | ||
STATUS_KEY_SLEEP, 100, | ||
STATUS_KEY_POISON, 100, | ||
STATUS_KEY_FROZEN, 100, | ||
STATUS_KEY_DIZZY, 100, | ||
STATUS_KEY_FEAR, 100, | ||
STATUS_KEY_STATIC, 100, | ||
STATUS_KEY_PARALYZE, 100, | ||
STATUS_KEY_SHRINK, 100, | ||
STATUS_KEY_STOP, 100, | ||
STATUS_TURN_MOD_DEFAULT, 0, | ||
STATUS_TURN_MOD_SLEEP, 0, | ||
STATUS_TURN_MOD_POISON, 0, | ||
STATUS_TURN_MOD_FROZEN, 0, | ||
STATUS_TURN_MOD_DIZZY, 0, | ||
STATUS_TURN_MOD_FEAR, 0, | ||
STATUS_TURN_MOD_STATIC, 0, | ||
STATUS_TURN_MOD_PARALYZE, 0, | ||
STATUS_TURN_MOD_SHRINK, 0, | ||
STATUS_TURN_MOD_STOP, 0, | ||
STATUS_END | ||
}; | ||
|
||
ActorBlueprint bPlayerActorBlueprint = { | ||
.type = ACTOR_TYPE_PLAYER, | ||
.maxHP = 99, | ||
.statusTable = bPlayerStatusTable, | ||
|
||
.escapeChance = 0, | ||
.airLiftChance = 0, | ||
.hurricaneChance = 0, | ||
.spookChance = 0, | ||
.upAndAwayChance = 0, | ||
.spinSmashReq = 4, | ||
.powerBounceChance = 80, | ||
|
||
.size = { 33, 43 }, | ||
.healthBarOffset = { 0, 0 }, | ||
.statusIconOffset = { -10, 30 }, | ||
.statusTextOffset = { 10, 30 }, | ||
}; | ||
|
||
ActorPartBlueprint bMarioParts[] = { | ||
{ | ||
.index = 1, | ||
.posOffset = { 0, 0, 0 }, | ||
.targetOffset = { 0, 32 }, | ||
.opacity = 255, | ||
.idleAnimations = bMarioIdleAnims, | ||
.defenseTable = bMarioDefenseTable, | ||
}, | ||
}; | ||
|
||
Vec3s StandardActorHomePositions[] = { | ||
[BTL_POS_GROUND_A] { 5, 0, -20 }, | ||
[BTL_POS_GROUND_B] { 45, 0, -5 }, | ||
[BTL_POS_GROUND_C] { 85, 0, 10 }, | ||
[BTL_POS_GROUND_D] { 125, 0, 25 }, | ||
[BTL_POS_AIR_A] { 10, 50, -20 }, | ||
[BTL_POS_AIR_B] { 50, 45, -5 }, | ||
[BTL_POS_AIR_C] { 90, 50, 10 }, | ||
[BTL_POS_AIR_D] { 130, 55, 25 }, | ||
[BTL_POS_HIGH_A] { 15, 85, -20 }, | ||
[BTL_POS_HIGH_B] { 55, 80, -5 }, | ||
[BTL_POS_HIGH_C] { 95, 85, 10 }, | ||
[BTL_POS_HIGH_D] { 135, 90, 25 }, | ||
[BTL_POS_TOP_A] { 15, 125, -20 }, | ||
[BTL_POS_TOP_B] { 55, 120, -5 }, | ||
[BTL_POS_TOP_C] { 95, 125, 10 }, | ||
[BTL_POS_TOP_D] { 135, 130, 25 }, | ||
[BTL_POS_CENTER] { 105, 0, 0 }, | ||
}; | ||
|
||
// TODO: what is this, and look into warnings that are silenced via casts | ||
s32* D_8028358C[] = { | ||
(s32*)-1, (s32*)-1, (s32*)-1, (s32*)-1, (s32*)-1, (s32*)-1, (s32*)-1, (s32*)-1, | ||
(s32*)D_8028358C, (s32*)D_8028358C, (s32*)D_8028358C, (s32*)D_8028358C, (s32*)D_8028358C, (s32*)D_8028358C, | ||
(s32*)D_8028358C, (s32*)D_8028358C, 0 | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,102 @@ | ||
#include "common.h" | ||
#include "entity.h" | ||
|
||
extern IMG_BIN ui_battle_menu_spirits_png[]; | ||
extern PAL_BIN ui_battle_menu_spirits_pal[]; | ||
extern IMG_BIN ui_battle_solid_star_png[]; | ||
extern PAL_BIN ui_battle_solid_star_pal[]; | ||
|
||
#include "ui/battle/cursor_hand.png.inc.c" | ||
#include "ui/battle/cursor_hand.pal.inc.c" | ||
|
||
Vtx BtlCursorModelVtx[] = { | ||
{{{ -22, -6, 0 }, 0, { 1024, 1024 }, { 0, 0, 0, 255 }}}, | ||
{{{ 9, -6, 0 }, 0, { 0, 1024 }, { 0, 0, 0, 255 }}}, | ||
{{{ 9, 25, 0 }, 0, { 0, 0 }, { 0, 0, 0, 255 }}}, | ||
{{{ -22, 25, 0 }, 0, { 1024, 0 }, { 0, 0, 0, 255 }}}, | ||
}; | ||
|
||
Gfx BtlCursorModelGfx[] = { | ||
gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), | ||
gsDPPipeSync(), | ||
gsDPSetCombineMode(G_CC_DECALRGBA, G_CC_DECALRGBA), | ||
gsDPSetTexturePersp(G_TP_PERSP), | ||
gsDPSetTextureDetail(G_TD_CLAMP), | ||
gsDPSetTextureLOD(G_TL_TILE), | ||
gsDPSetTextureLUT(G_TT_NONE), | ||
gsDPSetTextureFilter(G_TF_AVERAGE), | ||
gsDPSetTextureConvert(G_TC_FILT), | ||
gsDPSetTextureLUT(G_TT_RGBA16), | ||
gsDPLoadTLUT_pal16(0, ui_battle_cursor_hand_pal), | ||
gsDPLoadTextureTile_4b(ui_battle_cursor_hand_png, G_IM_FMT_CI, 32, 0, 0, 0, 31, 31, 0, G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMASK, G_TX_NOMASK, G_TX_NOLOD, G_TX_NOLOD), | ||
gsSPClearGeometryMode(G_LIGHTING), | ||
gsSPClearGeometryMode(G_SHADING_SMOOTH), | ||
gsSPVertex(BtlCursorModelVtx, 4, 0), | ||
gsSP1Triangle(0, 1, 2, 0), | ||
gsSP1Triangle(0, 2, 3, 0), | ||
gsSPEndDisplayList(), | ||
}; | ||
|
||
EntityModelScript EMS_CursorIcon = STANDARD_ENTITY_MODEL_SCRIPT(BtlCursorModelGfx, RENDER_MODE_ALPHATEST); | ||
|
||
Vtx BtlBonkModelVtx[] = { | ||
{{{ -16, -16, 0 }, 0, { 0, 0 }, { 0, 0, 0, 255 }}}, | ||
{{{ 15, -16, 0 }, 0, { 1024, 0 }, { 0, 0, 0, 255 }}}, | ||
{{{ 15, 15, 0 }, 0, { 1024, 1024 }, { 0, 0, 0, 255 }}}, | ||
{{{ -16, 15, 0 }, 0, { 0, 1024 }, { 0, 0, 0, 255 }}}, | ||
}; | ||
|
||
Gfx BtlBonkModelGfx[] = { | ||
gsDPPipeSync(), | ||
gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), | ||
gsDPSetCombineMode(PM_CC_01, PM_CC_02), | ||
gsDPSetTexturePersp(G_TP_PERSP), | ||
gsDPSetTextureDetail(G_TD_CLAMP), | ||
gsDPSetTextureLOD(G_TL_TILE), | ||
gsDPSetTextureLUT(G_TT_NONE), | ||
gsDPSetTextureFilter(G_TF_AVERAGE), | ||
gsDPSetTextureConvert(G_TC_FILT), | ||
gsDPSetTextureLUT(G_TT_RGBA16), | ||
gsDPLoadTLUT_pal16(0, ui_battle_menu_spirits_pal), | ||
gsDPLoadTextureTile_4b(ui_battle_menu_spirits_png, G_IM_FMT_CI, 32, 0, 0, 0, 31, 31, 0, G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMASK, G_TX_NOMASK, G_TX_NOLOD, G_TX_NOLOD), | ||
gsSPClearGeometryMode(G_LIGHTING), | ||
gsSPClearGeometryMode(G_SHADING_SMOOTH), | ||
gsSPVertex(BtlBonkModelVtx, 4, 0), | ||
gsSP1Triangle(0, 1, 2, 0), | ||
gsSP1Triangle(0, 2, 3, 0), | ||
gsDPPipeSync(), | ||
gsSPEndDisplayList(), | ||
}; | ||
|
||
EntityModelScript EMS_BonkIcon = STANDARD_ENTITY_MODEL_SCRIPT(BtlBonkModelGfx, RENDER_MODE_2D); | ||
|
||
Vtx BtlStarModelVtx[] = { | ||
{{{ -16, -16, 0 }, 0, { 0, 1024 }, { 0, 0, 0, 255 }}}, | ||
{{{ 15, -16, 0 }, 0, { 1024, 1024 }, { 0, 0, 0, 255 }}}, | ||
{{{ 15, 15, 0 }, 0, { 1024, 0 }, { 0, 0, 0, 255 }}}, | ||
{{{ -16, 15, 0 }, 0, { 0, 0 }, { 0, 0, 0, 255 }}}, | ||
}; | ||
|
||
Gfx BtlStarModelGfx[] = { | ||
gsDPPipeSync(), | ||
gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), | ||
gsDPSetCombineMode(G_CC_DECALRGBA, G_CC_DECALRGBA), | ||
gsDPSetTexturePersp(G_TP_PERSP), | ||
gsDPSetTextureDetail(G_TD_CLAMP), | ||
gsDPSetTextureLOD(G_TL_TILE), | ||
gsDPSetTextureLUT(G_TT_NONE), | ||
gsDPSetTextureFilter(G_TF_AVERAGE), | ||
gsDPSetTextureConvert(G_TC_FILT), | ||
gsDPSetTextureLUT(G_TT_RGBA16), | ||
gsDPLoadTLUT_pal16(0, ui_battle_solid_star_pal), | ||
gsDPLoadTextureTile_4b(ui_battle_solid_star_png, G_IM_FMT_CI, 32, 0, 0, 0, 31, 31, 0, G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMASK, G_TX_NOMASK, G_TX_NOLOD, G_TX_NOLOD), | ||
gsSPClearGeometryMode(G_LIGHTING), | ||
gsSPClearGeometryMode(G_SHADING_SMOOTH), | ||
gsSPVertex(BtlStarModelVtx, 4, 0), | ||
gsSP1Triangle(0, 1, 2, 0), | ||
gsSP1Triangle(0, 2, 3, 0), | ||
gsDPPipeSync(), | ||
gsSPEndDisplayList(), | ||
}; | ||
|
||
EntityModelScript EMS_StarIcon = STANDARD_ENTITY_MODEL_SCRIPT(BtlStarModelGfx, RENDER_MODE_ALPHATEST); |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.