SpriteTemplate formatting

This commit is contained in:
Eduardo Quezada 2022-08-27 02:07:58 -04:00
parent 1f0a952546
commit 866d916f2f
7 changed files with 39 additions and 23 deletions

View File

@ -202,7 +202,7 @@ static const struct OamData sOam_Cable =
.paletteNum = 0,
};
static const struct SpriteTemplate sSpriteTemplate_CableCar[] =
static const struct SpriteTemplate sSpriteTemplates_CableCar[] =
{
{
.tileTag = TAG_CABLE_CAR,
@ -224,7 +224,8 @@ static const struct SpriteTemplate sSpriteTemplate_CableCar[] =
},
};
static const struct SpriteTemplate sSpriteTemplate_Cable = {
static const struct SpriteTemplate sSpriteTemplate_Cable =
{
.tileTag = TAG_CABLE,
.paletteTag = TAG_CABLE_CAR,
.oam = &sOam_Cable,
@ -836,12 +837,12 @@ static void CreateCableCarSprites(void)
gSprites[spriteId].sYPos = 73;
}
// Create car sprite
spriteId = CreateSprite(&sSpriteTemplate_CableCar[0], 176, 43, 0x67);
spriteId = CreateSprite(&sSpriteTemplates_CableCar[0], 176, 43, 0x67);
gSprites[spriteId].x2 = gSprites[spriteId].y2 = 32;
gSprites[spriteId].sXPos = 176;
gSprites[spriteId].sYPos = 43;
// Create door sprite
spriteId = CreateSprite(&sSpriteTemplate_CableCar[1], 200, 99, 0x65);
spriteId = CreateSprite(&sSpriteTemplates_CableCar[1], 200, 99, 0x65);
gSprites[spriteId].x2 = 8;
gSprites[spriteId].y2 = 4;
gSprites[spriteId].sXPos = 200;
@ -864,12 +865,12 @@ static void CreateCableCarSprites(void)
gSprites[spriteId].sYPos = 39;
}
// Create car sprite
spriteId = CreateSprite(&sSpriteTemplate_CableCar[0], 104, 9, 0x67);
spriteId = CreateSprite(&sSpriteTemplates_CableCar[0], 104, 9, 0x67);
gSprites[spriteId].x2 = gSprites[spriteId].y2 = 32;
gSprites[spriteId].sXPos = 104;
gSprites[spriteId].sYPos = 9;
// Create door sprite
spriteId = CreateSprite(&sSpriteTemplate_CableCar[1], 128, 65, 0x65);
spriteId = CreateSprite(&sSpriteTemplates_CableCar[1], 128, 65, 0x65);
gSprites[spriteId].x2 = 8;
gSprites[spriteId].y2 = 4;
gSprites[spriteId].sXPos = 128;

View File

@ -944,7 +944,8 @@ static const struct OamData sOamData_TriangleCursor = {
.affineParam = 0,
};
static const struct SpriteTemplate sSpriteTemplate_TriangleCursor = {
static const struct SpriteTemplate sSpriteTemplate_TriangleCursor =
{
.tileTag = PALTAG_TRIANGLE_CURSOR,
.paletteTag = GFXTAG_TRIANGLE_CURSOR,
.oam = &sOamData_TriangleCursor,
@ -1005,7 +1006,8 @@ static const union AnimCmd *const sAnims_RectangleCursor[] = {
[RECTCURSOR_ANIM_ON_LETTER] = sAnim_RectangleCursor_OnLetter,
};
static const struct SpriteTemplate sSpriteTemplate_RectangleCursor = {
static const struct SpriteTemplate sSpriteTemplate_RectangleCursor =
{
.tileTag = GFXTAG_RECTANGLE_CURSOR,
.paletteTag = PALTAG_RECTANGLE_CURSOR,
.oam = &sOamData_RectangleCursor,
@ -1075,7 +1077,8 @@ static const union AnimCmd *const sAnims_ModeWindow[] = {
[MODEWINDOW_ANIM_TRANSITION] = sAnim_ModeWindow_Transition,
};
static const struct SpriteTemplate sSpriteTemplate_ModeWindow = {
static const struct SpriteTemplate sSpriteTemplate_ModeWindow =
{
.tileTag = GFXTAG_MODE_WINDOW,
.paletteTag = PALTAG_MISC_UI,
.oam = &sOamData_ModeWindow,
@ -1101,7 +1104,8 @@ static const struct OamData sOamData_ButtonWindow = {
.affineParam = 0,
};
static const struct SpriteTemplate sSpriteTemplate_ButtonWindow = {
static const struct SpriteTemplate sSpriteTemplate_ButtonWindow =
{
.tileTag = GFXTAG_BUTTON_WINDOW,
.paletteTag = PALTAG_MISC_UI,
.oam = &sOamData_ButtonWindow,
@ -1159,7 +1163,8 @@ static const union AnimCmd *const sAnims_TwoFrame[] = {
sAnim_Frame1,
};
static const struct SpriteTemplate sSpriteTemplate_StartSelectButton = {
static const struct SpriteTemplate sSpriteTemplate_StartSelectButton =
{
.tileTag = GFXTAG_START_SELECT_BUTTONS,
.paletteTag = PALTAG_MISC_UI,
.oam = &sOamData_StartSelectButton,
@ -1169,7 +1174,8 @@ static const struct SpriteTemplate sSpriteTemplate_StartSelectButton = {
.callback = SpriteCallbackDummy,
};
static const struct SpriteTemplate sSpriteTemplate_ScrollIndicator = {
static const struct SpriteTemplate sSpriteTemplate_ScrollIndicator =
{
.tileTag = GFXTAG_SCROLL_INDICATOR,
.paletteTag = PALTAG_MISC_UI,
.oam = &sOamData_ScrollIndicator,

View File

@ -3766,7 +3766,8 @@ static const union AnimCmd *const sAnims_DeoxysRockFragment[] = {
sAnim_RockFragment_BottomRight,
};
static const struct SpriteTemplate sSpriteTemplate_DeoxysRockFragment = {
static const struct SpriteTemplate sSpriteTemplate_DeoxysRockFragment =
{
.tileTag = TAG_NONE,
.paletteTag = 4378,
.oam = &sOam_8x8,

View File

@ -201,7 +201,8 @@ static const struct OamData sOamData_CeilingCrumbleSmall =
.affineParam = 0,
};
static const struct SpriteTemplate sSpriteTemplate_CeilingCrumbleSmall = {
static const struct SpriteTemplate sSpriteTemplate_CeilingCrumbleSmall =
{
.tileTag = TAG_CEILING_CRUMBLE,
.paletteTag = TAG_NONE,
.oam = &sOamData_CeilingCrumbleSmall,
@ -239,7 +240,8 @@ static const struct OamData sOamData_CeilingCrumbleLarge =
.affineParam = 0,
};
static const struct SpriteTemplate sSpriteTemplate_CeilingCrumbleLarge = {
static const struct SpriteTemplate sSpriteTemplate_CeilingCrumbleLarge =
{
.tileTag = TAG_CEILING_CRUMBLE,
.paletteTag = TAG_NONE,
.oam = &sOamData_CeilingCrumbleLarge,

View File

@ -162,7 +162,8 @@ static const struct SpritePalette sSpritePalettes_StampShadow[] = {
{sStampShadowPal8, TAG_STAMP_SHADOW}
};
static const struct SpriteTemplate sSpriteTemplate_StampShadow = {
static const struct SpriteTemplate sSpriteTemplate_StampShadow =
{
.tileTag = TAG_STAMP_SHADOW,
.paletteTag = TAG_STAMP_SHADOW,
.oam = &gOamData_AffineOff_ObjNormal_32x16,

View File

@ -2662,7 +2662,7 @@ static const struct SpriteTemplate sSpriteTemplates_ColorHeaders[NUM_BOARD_COLOR
}
};
static const struct SpriteTemplate sSpriteTemplate_GridIcons[NUM_BOARD_POKES] =
static const struct SpriteTemplate sSpriteTemplates_GridIcons[NUM_BOARD_POKES] =
{
{
.tileTag = GFXTAG_GRID_ICONS,
@ -3537,7 +3537,7 @@ static void CreateGridSprites(void)
u8 y = i * 24;
for (j = 0; j < NUM_BOARD_POKES; j++)
{
spriteId = sRoulette->spriteIds[(i * NUM_BOARD_POKES) + SPR_GRID_ICONS + j] = CreateSprite(&sSpriteTemplate_GridIcons[j], (j * 24) + 148, y + 92, 30);
spriteId = sRoulette->spriteIds[(i * NUM_BOARD_POKES) + SPR_GRID_ICONS + j] = CreateSprite(&sSpriteTemplates_GridIcons[j], (j * 24) + 148, y + 92, 30);
gSprites[spriteId].animPaused = TRUE;
y += 24;
if (y >= 72)

View File

@ -793,7 +793,8 @@ static const union AnimCmd *const sAnims_KeyboardCursor[] = {
sAnim_KeyboardCursorWide_Closed
};
static const struct SpriteTemplate sSpriteTemplate_KeyboardCursor = {
static const struct SpriteTemplate sSpriteTemplate_KeyboardCursor =
{
.tileTag = GFXTAG_KEYBOARD_CURSOR,
.paletteTag = PALTAG_INTERFACE,
.oam = &sOam_KeyboardCursor,
@ -809,7 +810,8 @@ static const struct OamData sOam_TextEntrySprite = {
.priority = 2
};
static const struct SpriteTemplate sSpriteTemplate_TextEntryCursor = {
static const struct SpriteTemplate sSpriteTemplate_TextEntryCursor =
{
.tileTag = GFXTAG_TEXT_ENTRY_CURSOR,
.paletteTag = PALTAG_INTERFACE,
.oam = &sOam_TextEntrySprite,
@ -819,7 +821,8 @@ static const struct SpriteTemplate sSpriteTemplate_TextEntryCursor = {
.callback = SpriteCB_TextEntryCursor
};
static const struct SpriteTemplate sSpriteTemplate_TextEntryArrow = {
static const struct SpriteTemplate sSpriteTemplate_TextEntryArrow =
{
.tileTag = GFXTAG_TEXT_ENTRY_ARROW,
.paletteTag = PALTAG_INTERFACE,
.oam = &sOam_TextEntrySprite,
@ -868,7 +871,8 @@ static const union AnimCmd *const sAnims_RButtonLabels[] = {
sAnim_RegisterIcon
};
static const struct SpriteTemplate sSpriteTemplate_RButtonIcon = {
static const struct SpriteTemplate sSpriteTemplate_RButtonIcon =
{
.tileTag = GFXTAG_RBUTTON_ICON,
.paletteTag = PALTAG_INTERFACE,
.oam = &sOam_RButtonIcon,
@ -878,7 +882,8 @@ static const struct SpriteTemplate sSpriteTemplate_RButtonIcon = {
.callback = SpriteCallbackDummy
};
static const struct SpriteTemplate sSpriteTemplate_RButtonLabels = {
static const struct SpriteTemplate sSpriteTemplate_RButtonLabels =
{
.tileTag = GFXTAG_RBUTTON_LABELS,
.paletteTag = PALTAG_INTERFACE,
.oam = &sOam_RButtonLabel,