summaryrefslogtreecommitdiff
path: root/src/field_effect.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/field_effect.c')
-rw-r--r--src/field_effect.c88
1 files changed, 44 insertions, 44 deletions
diff --git a/src/field_effect.c b/src/field_effect.c
index f01be2f2c..90d43c809 100644
--- a/src/field_effect.c
+++ b/src/field_effect.c
@@ -407,35 +407,35 @@ static const struct SpriteFrameImage sPicTable_HofMonitorSmall[] =
static const struct Subsprite sSubsprites_PokecenterMonitor[] =
{
{
- .x = -12,
- .y = -8,
- .shape = SPRITE_SHAPE(16x8),
+ .x = -12,
+ .y = -8,
+ .shape = SPRITE_SHAPE(16x8),
.size = SPRITE_SIZE(16x8),
- .tileOffset = 0,
+ .tileOffset = 0,
.priority = 2
},
{
- .x = 4,
+ .x = 4,
.y = -8,
- .shape = SPRITE_SHAPE(8x8),
- .size = SPRITE_SIZE(8x8),
- .tileOffset = 2,
- .priority = 2
+ .shape = SPRITE_SHAPE(8x8),
+ .size = SPRITE_SIZE(8x8),
+ .tileOffset = 2,
+ .priority = 2
},
{
- .x = -12,
- .y = 0,
- .shape = SPRITE_SHAPE(16x8),
+ .x = -12,
+ .y = 0,
+ .shape = SPRITE_SHAPE(16x8),
.size = SPRITE_SIZE(16x8),
- .tileOffset = 3,
+ .tileOffset = 3,
.priority = 2
},
{
- .x = 4,
- .y = 0,
- .shape = SPRITE_SHAPE(8x8),
- .size = SPRITE_SIZE(8x8),
- .tileOffset = 5,
+ .x = 4,
+ .y = 0,
+ .shape = SPRITE_SHAPE(8x8),
+ .size = SPRITE_SIZE(8x8),
+ .tileOffset = 5,
.priority = 2
}
};
@@ -445,35 +445,35 @@ static const struct SubspriteTable sSubspriteTable_PokecenterMonitor = subsprite
static const struct Subsprite sSubsprites_HofMonitorBig[] =
{
{
- .x = -32,
- .y = -8,
- .shape = SPRITE_SHAPE(32x8),
+ .x = -32,
+ .y = -8,
+ .shape = SPRITE_SHAPE(32x8),
.size = SPRITE_SIZE(32x8),
- .tileOffset = 0,
+ .tileOffset = 0,
.priority = 2
},
{
- .x = 0,
- .y = -8,
- .shape = SPRITE_SHAPE(32x8),
+ .x = 0,
+ .y = -8,
+ .shape = SPRITE_SHAPE(32x8),
.size = SPRITE_SIZE(32x8),
- .tileOffset = 4,
+ .tileOffset = 4,
.priority = 2
},
{
- .x = -32,
- .y = 0,
- .shape = SPRITE_SHAPE(32x8),
+ .x = -32,
+ .y = 0,
+ .shape = SPRITE_SHAPE(32x8),
.size = SPRITE_SIZE(32x8),
- .tileOffset = 8,
+ .tileOffset = 8,
.priority = 2
},
{
- .x = 0,
- .y = 0,
- .shape = SPRITE_SHAPE(32x8),
+ .x = 0,
+ .y = 0,
+ .shape = SPRITE_SHAPE(32x8),
.size = SPRITE_SIZE(32x8),
- .tileOffset = 12,
+ .tileOffset = 12,
.priority = 2
}
};
@@ -937,19 +937,19 @@ void MultiplyInvertedPaletteRGBComponents(u16 i, u8 r, u8 g, u8 b)
{
int curRed, curGreen, curBlue;
u16 color = gPlttBufferUnfaded[i];
-
+
curRed = (color & RGB_RED);
curGreen = (color & RGB_GREEN) >> 5;
curBlue = (color & RGB_BLUE) >> 10;
-
+
curRed += (((0x1F - curRed) * r) >> 4);
curGreen += (((0x1F - curGreen) * g) >> 4);
curBlue += (((0x1F - curBlue) * b) >> 4);
-
+
color = curRed;
color |= (curGreen << 5);
color |= (curBlue << 10);
-
+
gPlttBufferFaded[i] = color;
}
@@ -958,19 +958,19 @@ void MultiplyPaletteRGBComponents(u16 i, u8 r, u8 g, u8 b)
{
int curRed, curGreen, curBlue;
u16 color = gPlttBufferUnfaded[i];
-
+
curRed = (color & RGB_RED);
curGreen = (color & RGB_GREEN) >> 5;
curBlue = (color & RGB_BLUE) >> 10;
-
+
curRed -= ((curRed * r) >> 4);
curGreen -= ((curGreen * g) >> 4);
curBlue -= ((curBlue * b) >> 4);
-
+
color = curRed;
color |= (curGreen << 5);
color |= (curBlue << 10);
-
+
gPlttBufferFaded[i] = color;
}
@@ -1715,7 +1715,7 @@ static bool8 EscalatorWarpIn_Init(struct Task *task)
// If dest is down escalator tile, player is riding up
behavior = TRUE;
task->tState = 3; // jump to EscalatorWarpIn_Up_Init
- }
+ }
else // MB_UP_ESCALATOR
{
// If dest is up escalator tile, player is riding down
@@ -2265,7 +2265,7 @@ static void EscapeRopeWarpOutEffect_Spin(struct Task *task)
gFieldCallback = FieldCallback_EscapeRopeWarpIn;
SetMainCallback2(CB2_LoadMap);
DestroyTask(FindTaskIdByFunc(Task_EscapeRopeWarpOut));
- }
+ }
else if (task->tSpinDelay == 0 || (--task->tSpinDelay) == 0)
{
ObjectEventSetHeldMovement(objectEvent, GetFaceDirectionMovementAction(spinDirections[objectEvent->facingDirection]));