mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
WIP: Overdrive polish 2
This commit is contained in:
parent
2b61497536
commit
81e9441218
4 changed files with 28 additions and 18 deletions
|
|
@ -578,6 +578,7 @@ char sprnames[NUMSPRITES + 1][5] =
|
||||||
"EGOO",
|
"EGOO",
|
||||||
|
|
||||||
"AMPA",
|
"AMPA",
|
||||||
|
"AMPB",
|
||||||
|
|
||||||
"WTRL", // Water Trail
|
"WTRL", // Water Trail
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1117,6 +1117,7 @@ typedef enum sprite
|
||||||
SPR_EGOO,
|
SPR_EGOO,
|
||||||
|
|
||||||
SPR_AMPA,
|
SPR_AMPA,
|
||||||
|
SPR_AMPB,
|
||||||
|
|
||||||
SPR_WTRL, // Water Trail
|
SPR_WTRL, // Water Trail
|
||||||
|
|
||||||
|
|
|
||||||
11
src/k_kart.c
11
src/k_kart.c
|
|
@ -2012,12 +2012,6 @@ static void K_SpawnGenericSpeedLines(player_t *player, boolean top)
|
||||||
fast->color = SKINCOLOR_WHITE;
|
fast->color = SKINCOLOR_WHITE;
|
||||||
fast->colorized = true;
|
fast->colorized = true;
|
||||||
}
|
}
|
||||||
else if (player->overdrive)
|
|
||||||
{
|
|
||||||
fast->color = player->skincolor;
|
|
||||||
fast->renderflags |= RF_ADD;
|
|
||||||
fast->scale *= 2;
|
|
||||||
}
|
|
||||||
else if (player->ringboost)
|
else if (player->ringboost)
|
||||||
{
|
{
|
||||||
UINT8 ringboostcolors[] = {SKINCOLOR_AQUAMARINE, SKINCOLOR_EMERALD, SKINCOLOR_GARDEN, SKINCOLOR_CROCODILE, SKINCOLOR_BANANA};
|
UINT8 ringboostcolors[] = {SKINCOLOR_AQUAMARINE, SKINCOLOR_EMERALD, SKINCOLOR_GARDEN, SKINCOLOR_CROCODILE, SKINCOLOR_BANANA};
|
||||||
|
|
@ -12026,11 +12020,6 @@ static void K_KartSpindash(player_t *player)
|
||||||
K_KartSpindashWind(player->mo);
|
K_KartSpindashWind(player->mo);
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((player->overdrive > 0) && (spawnWind == true))
|
|
||||||
{
|
|
||||||
K_KartSpindashWind(player->mo);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (player->spindashboost > (TICRATE/2))
|
if (player->spindashboost > (TICRATE/2))
|
||||||
{
|
{
|
||||||
K_KartSpindashDust(player->mo);
|
K_KartSpindashDust(player->mo);
|
||||||
|
|
|
||||||
|
|
@ -17,6 +17,8 @@
|
||||||
#include "../k_kart.h"
|
#include "../k_kart.h"
|
||||||
#include "../k_powerup.h"
|
#include "../k_powerup.h"
|
||||||
|
|
||||||
|
static UINT8 interlacedfuckingthing[] = {6,1,7,2,8,3,9,2,1,1,1,2,1,3,1,2,10,1,11,2,4,3,5,2,1,1,1,2,1,3,1,2};
|
||||||
|
|
||||||
void Obj_BlockRingThink (mobj_t *ring)
|
void Obj_BlockRingThink (mobj_t *ring)
|
||||||
{
|
{
|
||||||
if (P_MobjWasRemoved(ring->target) || !ring->target->player)
|
if (P_MobjWasRemoved(ring->target) || !ring->target->player)
|
||||||
|
|
@ -32,23 +34,42 @@ void Obj_BlockRingThink (mobj_t *ring)
|
||||||
ring->flags &= ~(MF_NOCLIPTHING);
|
ring->flags &= ~(MF_NOCLIPTHING);
|
||||||
P_MoveOrigin(ring, mo->x, mo->y, mo->z + mo->height/2);
|
P_MoveOrigin(ring, mo->x, mo->y, mo->z + mo->height/2);
|
||||||
ring->flags |= MF_NOCLIPTHING;
|
ring->flags |= MF_NOCLIPTHING;
|
||||||
ring->color = mo->color;
|
ring->color = mo->player->skincolor;
|
||||||
|
|
||||||
fixed_t baseScale = mo->scale / 2;
|
fixed_t baseScale = mo->scale / 2;
|
||||||
baseScale += (mo->scale / 30) * player->spheres;
|
baseScale += (mo->scale / 30) * player->spheres;
|
||||||
|
|
||||||
if (player->overdrive)
|
if (player->overdrive)
|
||||||
|
{
|
||||||
baseScale += mo->scale;
|
baseScale += mo->scale;
|
||||||
|
ring->sprite = SPR_AMPB;
|
||||||
|
ring->frame = interlacedfuckingthing[(leveltime/1)%32]-1;
|
||||||
|
ring->colorized = true;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
ring->colorized = false;
|
||||||
|
ring->frame = 0;
|
||||||
|
}
|
||||||
|
|
||||||
P_SetScale(ring, baseScale);
|
P_SetScale(ring, baseScale);
|
||||||
|
|
||||||
// Twirl
|
// Twirl
|
||||||
ring->angle = ring->target->angle + (ANG15 * leveltime);
|
ring->angle = ring->target->angle + (ANG15/2 * leveltime);
|
||||||
// Visuals
|
// Visuals
|
||||||
ring->renderflags |= RF_ADD|RF_PAPERSPRITE;
|
ring->renderflags |= RF_ADD|RF_PAPERSPRITE;
|
||||||
|
|
||||||
if (leveltime%2)
|
if (player->overdrive > 35)
|
||||||
|
{
|
||||||
ring->renderflags &= ~RF_DONTDRAW;
|
ring->renderflags &= ~RF_DONTDRAW;
|
||||||
|
}
|
||||||
else
|
else
|
||||||
ring->renderflags |= RF_DONTDRAW;
|
{
|
||||||
|
if (leveltime%2)
|
||||||
|
ring->renderflags &= ~RF_DONTDRAW;
|
||||||
|
else
|
||||||
|
ring->renderflags |= RF_DONTDRAW;
|
||||||
|
}
|
||||||
|
|
||||||
if (K_PowerUpRemaining(player, POWERUP_BARRIER) || !(K_PlayerGuard(player) || player->overdrive))
|
if (K_PowerUpRemaining(player, POWERUP_BARRIER) || !(K_PlayerGuard(player) || player->overdrive))
|
||||||
ring->renderflags |= RF_DONTDRAW;
|
ring->renderflags |= RF_DONTDRAW;
|
||||||
|
|
@ -71,8 +92,6 @@ void Obj_BlockBodyThink (mobj_t *body)
|
||||||
|
|
||||||
fixed_t baseScale = mo->scale / 2;
|
fixed_t baseScale = mo->scale / 2;
|
||||||
baseScale += (mo->scale / 30) * player->spheres;
|
baseScale += (mo->scale / 30) * player->spheres;
|
||||||
if (player->overdrive)
|
|
||||||
baseScale += mo->scale;
|
|
||||||
P_SetScale(body, baseScale);
|
P_SetScale(body, baseScale);
|
||||||
|
|
||||||
P_MoveOrigin(body, mo->x, mo->y, mo->z + mo->height/2);
|
P_MoveOrigin(body, mo->x, mo->y, mo->z + mo->height/2);
|
||||||
|
|
@ -87,7 +106,7 @@ void Obj_BlockBodyThink (mobj_t *body)
|
||||||
else
|
else
|
||||||
body->renderflags |= RF_DONTDRAW;
|
body->renderflags |= RF_DONTDRAW;
|
||||||
|
|
||||||
if (K_PowerUpRemaining(player, POWERUP_BARRIER) || !(K_PlayerGuard(player) || player->overdrive))
|
if (K_PowerUpRemaining(player, POWERUP_BARRIER) || !K_PlayerGuard(player))
|
||||||
body->renderflags |= RF_DONTDRAW;
|
body->renderflags |= RF_DONTDRAW;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue