mirror of
https://git.do.srb2.org/KartKrew/Kart-Public.git
synced 2024-11-17 10:11:12 +00:00
Fix warnings
Possibly fix some whitespace problems
This commit is contained in:
parent
592c4482a9
commit
be3acfff0b
14 changed files with 128 additions and 116 deletions
|
@ -19,7 +19,7 @@
|
||||||
#define __D_NET__
|
#define __D_NET__
|
||||||
|
|
||||||
// Max computers in a game
|
// Max computers in a game
|
||||||
#define MAXNETNODES 32
|
#define MAXNETNODES 16
|
||||||
#define BROADCASTADDR MAXNETNODES
|
#define BROADCASTADDR MAXNETNODES
|
||||||
#define MAXSPLITSCREENPLAYERS 2 // Max number of players on a single computer
|
#define MAXSPLITSCREENPLAYERS 2 // Max number of players on a single computer
|
||||||
|
|
||||||
|
|
|
@ -401,7 +401,7 @@ extern UINT16 extralifetics;
|
||||||
// SRB2kart
|
// SRB2kart
|
||||||
extern INT32 bootime;
|
extern INT32 bootime;
|
||||||
extern INT32 mushroomtime;
|
extern INT32 mushroomtime;
|
||||||
extern INT32 bonustime;
|
extern INT32 itemtime;
|
||||||
|
|
||||||
extern UINT8 introtoplay;
|
extern UINT8 introtoplay;
|
||||||
extern UINT8 creditscutscene;
|
extern UINT8 creditscutscene;
|
||||||
|
|
|
@ -199,7 +199,7 @@ UINT16 extralifetics = 4*TICRATE;
|
||||||
// SRB2kart
|
// SRB2kart
|
||||||
INT32 bootime = 7*TICRATE;
|
INT32 bootime = 7*TICRATE;
|
||||||
INT32 mushroomtime = TICRATE + (TICRATE/3);
|
INT32 mushroomtime = TICRATE + (TICRATE/3);
|
||||||
INT32 bonustime = 8*TICRATE;
|
INT32 itemtime = 8*TICRATE;
|
||||||
|
|
||||||
INT32 gameovertics = 15*TICRATE;
|
INT32 gameovertics = 15*TICRATE;
|
||||||
|
|
||||||
|
|
70
src/k_kart.c
70
src/k_kart.c
|
@ -17,6 +17,7 @@
|
||||||
#include "v_video.h"
|
#include "v_video.h"
|
||||||
#include "z_zone.h"
|
#include "z_zone.h"
|
||||||
#include "m_misc.h"
|
#include "m_misc.h"
|
||||||
|
#include "k_kart.h"
|
||||||
|
|
||||||
//{ SRB2kart Color Code
|
//{ SRB2kart Color Code
|
||||||
|
|
||||||
|
@ -778,6 +779,11 @@ static void K_KartSetItemResult(fixed_t position, fixed_t giveitem)
|
||||||
*/
|
*/
|
||||||
static void K_KartItemRoulette(player_t *player, ticcmd_t *cmd)
|
static void K_KartItemRoulette(player_t *player, ticcmd_t *cmd)
|
||||||
{
|
{
|
||||||
|
INT32 i;
|
||||||
|
INT32 roulettestop = (TICRATE*1) + (3*(pingame - player->kartstuff[k_position]));
|
||||||
|
fixed_t prandom = P_RandomFixed();
|
||||||
|
fixed_t ppos = player->kartstuff[k_position] - 1;
|
||||||
|
|
||||||
// This makes the roulette cycle through items - if this is 0, you shouldn't be here.
|
// This makes the roulette cycle through items - if this is 0, you shouldn't be here.
|
||||||
if (player->kartstuff[k_itemroulette])
|
if (player->kartstuff[k_itemroulette])
|
||||||
player->kartstuff[k_itemroulette]++;
|
player->kartstuff[k_itemroulette]++;
|
||||||
|
@ -792,8 +798,6 @@ static void K_KartItemRoulette(player_t *player, ticcmd_t *cmd)
|
||||||
basechance = chance = prevchance = 0;
|
basechance = chance = prevchance = 0;
|
||||||
numchoices = pingame = pexiting = 0;
|
numchoices = pingame = pexiting = 0;
|
||||||
|
|
||||||
INT32 i;
|
|
||||||
|
|
||||||
// Initializes existing spawnchance values
|
// Initializes existing spawnchance values
|
||||||
for (i = 0; i < (NUMKARTITEMS * NUMKARTODDS); i++)
|
for (i = 0; i < (NUMKARTITEMS * NUMKARTODDS); i++)
|
||||||
spawnchance[i] = 0;
|
spawnchance[i] = 0;
|
||||||
|
@ -807,8 +811,6 @@ static void K_KartItemRoulette(player_t *player, ticcmd_t *cmd)
|
||||||
pexiting++;
|
pexiting++;
|
||||||
}
|
}
|
||||||
|
|
||||||
INT32 roulettestop = (TICRATE*1) + (3*(pingame - player->kartstuff[k_position]));
|
|
||||||
|
|
||||||
// If the roulette finishes or the player presses BT_ATTACK, stop the roulette and calculate the item.
|
// If the roulette finishes or the player presses BT_ATTACK, stop the roulette and calculate the item.
|
||||||
// I'm returning via the exact opposite, however, to forgo having another bracket embed. Same result either way, I think.
|
// I'm returning via the exact opposite, however, to forgo having another bracket embed. Same result either way, I think.
|
||||||
// Finally, if you get past this check, now you can actually start calculating what item you get.
|
// Finally, if you get past this check, now you can actually start calculating what item you get.
|
||||||
|
@ -821,10 +823,6 @@ static void K_KartItemRoulette(player_t *player, ticcmd_t *cmd)
|
||||||
|
|
||||||
player->kartstuff[k_itemclose] = 0; // Reset the item window closer.
|
player->kartstuff[k_itemclose] = 0; // Reset the item window closer.
|
||||||
|
|
||||||
// Yes I know I'm defining variables half-way into the function, but they aren't needed until now :/
|
|
||||||
fixed_t prandom = P_RandomFixed();
|
|
||||||
fixed_t ppos = player->kartstuff[k_position] - 1;
|
|
||||||
|
|
||||||
// Tiny catcher in case player position is unset.
|
// Tiny catcher in case player position is unset.
|
||||||
if (ppos < 0) ppos = 0;
|
if (ppos < 0) ppos = 0;
|
||||||
|
|
||||||
|
@ -903,7 +901,7 @@ static void K_KartItemRoulette(player_t *player, ticcmd_t *cmd)
|
||||||
|
|
||||||
\return void
|
\return void
|
||||||
*/
|
*/
|
||||||
void K_UpdateOffroad(player_t *player)
|
static void K_UpdateOffroad(player_t *player)
|
||||||
{
|
{
|
||||||
fixed_t kartweight = player->kartweight;
|
fixed_t kartweight = player->kartweight;
|
||||||
fixed_t offroad;
|
fixed_t offroad;
|
||||||
|
@ -911,13 +909,13 @@ void K_UpdateOffroad(player_t *player)
|
||||||
player->mo->x + player->mo->momx*2, player->mo->y + player->mo->momy*2)->sector;
|
player->mo->x + player->mo->momx*2, player->mo->y + player->mo->momy*2)->sector;
|
||||||
|
|
||||||
// If you are offroad, a timer starts. Depending on your weight value, the timer increments differently.
|
// If you are offroad, a timer starts. Depending on your weight value, the timer increments differently.
|
||||||
if (nextsector->special & 256 && nextsector->special != 768 && (nextsector->special != 1024 || nextsector->special != 4864))
|
if ((nextsector->special & 256) && nextsector->special != 768 && nextsector->special != 1024 && nextsector->special != 4864)
|
||||||
{
|
{
|
||||||
if (P_IsObjectOnGround(player->mo) && player->kartstuff[k_offroad] == 0)
|
if (P_IsObjectOnGround(player->mo) && player->kartstuff[k_offroad] == 0)
|
||||||
player->kartstuff[k_offroad] = 16;
|
player->kartstuff[k_offroad] = 16;
|
||||||
if (player->kartstuff[k_offroad] > 0)
|
if (player->kartstuff[k_offroad] > 0)
|
||||||
{
|
{
|
||||||
if (kartweight < 1) kartweight = 1; if (kartweight > 9) kartweight = 9; // Safety Net
|
if (kartweight < 1) { kartweight = 1; } if (kartweight > 9) { kartweight = 9; } // Safety Net
|
||||||
|
|
||||||
// 1872 is the magic number - 35 frames adds up to approximately 65536. 1872/4 = 468/3 = 156
|
// 1872 is the magic number - 35 frames adds up to approximately 65536. 1872/4 = 468/3 = 156
|
||||||
// A higher kart weight means you can stay offroad for longer without losing speed
|
// A higher kart weight means you can stay offroad for longer without losing speed
|
||||||
|
@ -1052,7 +1050,7 @@ void K_KartPlayerThink(player_t *player, ticcmd_t *cmd)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void K_PlayTauntSound(mobj_t *source)
|
static void K_PlayTauntSound(mobj_t *source)
|
||||||
{
|
{
|
||||||
switch (P_RandomFixed() % 4)
|
switch (P_RandomFixed() % 4)
|
||||||
{
|
{
|
||||||
|
@ -1071,7 +1069,7 @@ void K_PlayTauntSound(mobj_t *source)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
fixed_t K_GetKartBoostPower(player_t *player, boolean speedonly)
|
static fixed_t K_GetKartBoostPower(player_t *player, boolean speedonly)
|
||||||
{
|
{
|
||||||
fixed_t boostpower = FRACUNIT;
|
fixed_t boostpower = FRACUNIT;
|
||||||
fixed_t boostvalue = 0;
|
fixed_t boostvalue = 0;
|
||||||
|
@ -1088,13 +1086,13 @@ fixed_t K_GetKartBoostPower(player_t *player, boolean speedonly)
|
||||||
numboosts++;
|
numboosts++;
|
||||||
}
|
}
|
||||||
if (player->kartstuff[k_growshrinktimer] > 1
|
if (player->kartstuff[k_growshrinktimer] > 1
|
||||||
&& (player->kartstuff[k_growshrinktimer] > (bonustime - 25)
|
&& (player->kartstuff[k_growshrinktimer] > (itemtime - 25)
|
||||||
|| player->kartstuff[k_growshrinktimer] <= 26) && speedonly)
|
|| player->kartstuff[k_growshrinktimer] <= 26) && speedonly)
|
||||||
{ // Mega Mushroom - Mid-size
|
{ // Mega Mushroom - Mid-size
|
||||||
boostvalue += 9; // 9/8 speed (*1.125)
|
boostvalue += 9; // 9/8 speed (*1.125)
|
||||||
numboosts++;
|
numboosts++;
|
||||||
}
|
}
|
||||||
if (player->kartstuff[k_growshrinktimer] < (bonustime - 25)
|
if (player->kartstuff[k_growshrinktimer] < (itemtime - 25)
|
||||||
&& player->kartstuff[k_growshrinktimer] > 26 && speedonly)
|
&& player->kartstuff[k_growshrinktimer] > 26 && speedonly)
|
||||||
{ // Mega Mushroom
|
{ // Mega Mushroom
|
||||||
boostvalue += 10; // 10/8 speed (*1.250)
|
boostvalue += 10; // 10/8 speed (*1.250)
|
||||||
|
@ -1130,6 +1128,7 @@ fixed_t K_GetKartBoostPower(player_t *player, boolean speedonly)
|
||||||
|
|
||||||
return boostpower;
|
return boostpower;
|
||||||
}
|
}
|
||||||
|
|
||||||
fixed_t K_GetKartSpeed(player_t *player, boolean doboostpower)
|
fixed_t K_GetKartSpeed(player_t *player, boolean doboostpower)
|
||||||
{
|
{
|
||||||
fixed_t k_speed = 151;
|
fixed_t k_speed = 151;
|
||||||
|
@ -1155,7 +1154,8 @@ fixed_t K_GetKartSpeed(player_t *player, boolean doboostpower)
|
||||||
return FixedMul(FixedMul(k_speed<<14, g_cc), K_GetKartBoostPower(player, true));
|
return FixedMul(FixedMul(k_speed<<14, g_cc), K_GetKartBoostPower(player, true));
|
||||||
return FixedMul(k_speed<<14, g_cc);
|
return FixedMul(k_speed<<14, g_cc);
|
||||||
}
|
}
|
||||||
fixed_t K_GetKartAccel(player_t *player)
|
|
||||||
|
static fixed_t K_GetKartAccel(player_t *player)
|
||||||
{
|
{
|
||||||
fixed_t k_accel = 36;
|
fixed_t k_accel = 36;
|
||||||
|
|
||||||
|
@ -1163,15 +1163,16 @@ fixed_t K_GetKartAccel(player_t *player)
|
||||||
|
|
||||||
return FixedMul(k_accel, K_GetKartBoostPower(player, false));
|
return FixedMul(k_accel, K_GetKartBoostPower(player, false));
|
||||||
}
|
}
|
||||||
|
|
||||||
fixed_t K_3dKartMovement(player_t *player, boolean onground, boolean forwardmovement)
|
fixed_t K_3dKartMovement(player_t *player, boolean onground, boolean forwardmovement)
|
||||||
{
|
{
|
||||||
if (!onground) return 0; // If the player isn't on the ground, there is no change in speed
|
|
||||||
|
|
||||||
fixed_t accelmax = 4000;
|
fixed_t accelmax = 4000;
|
||||||
fixed_t newspeed, oldspeed, finalspeed;
|
fixed_t newspeed, oldspeed, finalspeed;
|
||||||
fixed_t p_speed = K_GetKartSpeed(player, true);
|
fixed_t p_speed = K_GetKartSpeed(player, true);
|
||||||
fixed_t p_accel = K_GetKartAccel(player);
|
fixed_t p_accel = K_GetKartAccel(player);
|
||||||
|
|
||||||
|
if (!onground) return 0; // If the player isn't on the ground, there is no change in speed
|
||||||
|
|
||||||
// ACCELCODE!!!1!11!
|
// ACCELCODE!!!1!11!
|
||||||
oldspeed = P_AproxDistance(player->rmomx, player->rmomy); // FixedMul(P_AproxDistance(player->rmomx, player->rmomy), player->mo->scale);
|
oldspeed = P_AproxDistance(player->rmomx, player->rmomy); // FixedMul(P_AproxDistance(player->rmomx, player->rmomy), player->mo->scale);
|
||||||
newspeed = FixedDiv(FixedDiv(FixedMul(oldspeed, accelmax - p_accel) + FixedMul(p_speed, p_accel), accelmax), ORIG_FRICTION);
|
newspeed = FixedDiv(FixedDiv(FixedMul(oldspeed, accelmax - p_accel) + FixedMul(p_speed, p_accel), accelmax), ORIG_FRICTION);
|
||||||
|
@ -1187,6 +1188,7 @@ fixed_t K_3dKartMovement(player_t *player, boolean onground, boolean forwardmove
|
||||||
|
|
||||||
void K_SpinPlayer(player_t *player, mobj_t *source)
|
void K_SpinPlayer(player_t *player, mobj_t *source)
|
||||||
{
|
{
|
||||||
|
(void) source;
|
||||||
if (player->health <= 0)
|
if (player->health <= 0)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
@ -1226,6 +1228,7 @@ void K_SpinPlayer(player_t *player, mobj_t *source)
|
||||||
|
|
||||||
void K_SquishPlayer(player_t *player, mobj_t *source)
|
void K_SquishPlayer(player_t *player, mobj_t *source)
|
||||||
{
|
{
|
||||||
|
(void) source;
|
||||||
if (player->health <= 0)
|
if (player->health <= 0)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
@ -1252,6 +1255,7 @@ void K_SquishPlayer(player_t *player, mobj_t *source)
|
||||||
|
|
||||||
void K_ExplodePlayer(player_t *player, mobj_t *source) // A bit of a hack, we just throw the player up higher here and extend their spinout timer
|
void K_ExplodePlayer(player_t *player, mobj_t *source) // A bit of a hack, we just throw the player up higher here and extend their spinout timer
|
||||||
{
|
{
|
||||||
|
(void) source;
|
||||||
if (player->health <= 0)
|
if (player->health <= 0)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
@ -1364,7 +1368,7 @@ void K_SpawnKartExplosion(fixed_t x, fixed_t y, fixed_t z, fixed_t radius, INT32
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
mobj_t *K_SpawnKartMissile(mobj_t *source, mobjtype_t type, angle_t angle, INT32 flags2, fixed_t speed)
|
static mobj_t *K_SpawnKartMissile(mobj_t *source, mobjtype_t type, angle_t angle, INT32 flags2, fixed_t speed)
|
||||||
{
|
{
|
||||||
mobj_t *th;
|
mobj_t *th;
|
||||||
angle_t an;
|
angle_t an;
|
||||||
|
@ -1540,12 +1544,11 @@ static mobj_t *P_ThrowKartItem(player_t *player, boolean missile, mobjtype_t map
|
||||||
if (mo)
|
if (mo)
|
||||||
{
|
{
|
||||||
angle_t fa = player->mo->angle>>ANGLETOFINESHIFT;
|
angle_t fa = player->mo->angle>>ANGLETOFINESHIFT;
|
||||||
int DIST = 50*FRACUNIT + player->speed*FRACUNIT; // 6 when dropping CTF flag
|
INT32 DIST = 50*FRACUNIT + player->speed*FRACUNIT; // 6 when dropping CTF flag
|
||||||
|
INT32 HEIGHT;
|
||||||
if (DIST > 64*FRACUNIT)
|
if (DIST > 64*FRACUNIT)
|
||||||
DIST = 64*FRACUNIT;
|
DIST = 64*FRACUNIT;
|
||||||
|
|
||||||
int HEIGHT;
|
|
||||||
|
|
||||||
if (dir == 2)
|
if (dir == 2)
|
||||||
HEIGHT = 16*FRACUNIT + player->mo->momz;
|
HEIGHT = 16*FRACUNIT + player->mo->momz;
|
||||||
else
|
else
|
||||||
|
@ -1745,7 +1748,7 @@ void K_DoMushroom(player_t *player, boolean doPFlag)
|
||||||
player->kartstuff[k_sounds] = 50;
|
player->kartstuff[k_sounds] = 50;
|
||||||
}
|
}
|
||||||
|
|
||||||
void K_DoLightning(player_t *player, boolean bluelightning)
|
static void K_DoLightning(player_t *player, boolean bluelightning)
|
||||||
{
|
{
|
||||||
mobj_t *mo;
|
mobj_t *mo;
|
||||||
thinker_t *think;
|
thinker_t *think;
|
||||||
|
@ -1783,11 +1786,10 @@ fixed_t K_GetKartTurnValue(player_t *player, ticcmd_t *cmd)
|
||||||
{
|
{
|
||||||
fixed_t p_angle = cmd->angleturn;
|
fixed_t p_angle = cmd->angleturn;
|
||||||
fixed_t p_maxspeed = K_GetKartSpeed(player, false);
|
fixed_t p_maxspeed = K_GetKartSpeed(player, false);
|
||||||
|
fixed_t adjustangle = FixedDiv((p_maxspeed>>16) - (player->speed>>16), (p_maxspeed>>16) + player->kartweight);
|
||||||
|
|
||||||
p_maxspeed = FixedMul(p_maxspeed, 3*FRACUNIT);
|
p_maxspeed = FixedMul(p_maxspeed, 3*FRACUNIT);
|
||||||
|
|
||||||
fixed_t adjustangle = FixedDiv((p_maxspeed>>16) - (player->speed>>16), (p_maxspeed>>16) + player->kartweight);
|
|
||||||
|
|
||||||
p_angle = FixedMul(p_angle, adjustangle); // Weight has a small effect on turning
|
p_angle = FixedMul(p_angle, adjustangle); // Weight has a small effect on turning
|
||||||
|
|
||||||
if (player->kartstuff[k_startimer] || player->kartstuff[k_mushroomtimer] || player->kartstuff[k_growshrinktimer] > 0)
|
if (player->kartstuff[k_startimer] || player->kartstuff[k_mushroomtimer] || player->kartstuff[k_growshrinktimer] > 0)
|
||||||
|
@ -1811,7 +1813,7 @@ fixed_t K_GetKartTurnValue(player_t *player, ticcmd_t *cmd)
|
||||||
return p_angle;
|
return p_angle;
|
||||||
}
|
}
|
||||||
|
|
||||||
fixed_t K_GetKartDriftValue(player_t *player, fixed_t turntype)
|
static fixed_t K_GetKartDriftValue(player_t *player, fixed_t turntype)
|
||||||
{
|
{
|
||||||
fixed_t driftangle = FRACUNIT;
|
fixed_t driftangle = FRACUNIT;
|
||||||
fixed_t p_angle = player->kartstuff[k_driftangle];
|
fixed_t p_angle = player->kartstuff[k_driftangle];
|
||||||
|
@ -1836,7 +1838,7 @@ fixed_t K_GetKartDriftValue(player_t *player, fixed_t turntype)
|
||||||
return driftangle;
|
return driftangle;
|
||||||
}
|
}
|
||||||
|
|
||||||
void K_KartDrift(player_t *player, ticcmd_t *cmd, boolean onground)
|
static void K_KartDrift(player_t *player, ticcmd_t *cmd, boolean onground)
|
||||||
{
|
{
|
||||||
fixed_t dsone = 26 + player->kartspeed;
|
fixed_t dsone = 26 + player->kartspeed;
|
||||||
fixed_t dstwo = 52 + player->kartspeed*2;
|
fixed_t dstwo = 52 + player->kartspeed*2;
|
||||||
|
@ -2057,7 +2059,7 @@ static void K_KartUpdatePosition(player_t *player)
|
||||||
player->kartstuff[k_position] = position;
|
player->kartstuff[k_position] = position;
|
||||||
}
|
}
|
||||||
|
|
||||||
boolean K_CheckForHoldItem(player_t *player)
|
static boolean K_CheckForHoldItem(player_t *player)
|
||||||
{
|
{
|
||||||
if ( player->kartstuff[k_greenshell] == 1
|
if ( player->kartstuff[k_greenshell] == 1
|
||||||
|| player->kartstuff[k_redshell] == 1
|
|| player->kartstuff[k_redshell] == 1
|
||||||
|
@ -2143,7 +2145,7 @@ void K_MoveKartPlayer(player_t *player, ticcmd_t *cmd, boolean onground)
|
||||||
&& player->kartstuff[k_goldshroomtimer] == 0 && NO_BOO)
|
&& player->kartstuff[k_goldshroomtimer] == 0 && NO_BOO)
|
||||||
{
|
{
|
||||||
K_DoMushroom(player, true);
|
K_DoMushroom(player, true);
|
||||||
player->kartstuff[k_goldshroomtimer] = bonustime;
|
player->kartstuff[k_goldshroomtimer] = itemtime;
|
||||||
player->kartstuff[k_goldshroom] = 0;
|
player->kartstuff[k_goldshroom] = 0;
|
||||||
}
|
}
|
||||||
// GoldenMushroom power
|
// GoldenMushroom power
|
||||||
|
@ -2179,7 +2181,7 @@ void K_MoveKartPlayer(player_t *player, ticcmd_t *cmd, boolean onground)
|
||||||
S_ChangeMusicInternal("minvnc", true);
|
S_ChangeMusicInternal("minvnc", true);
|
||||||
if (!P_IsLocalPlayer(player))
|
if (!P_IsLocalPlayer(player))
|
||||||
S_StartSound(player->mo, sfx_star);
|
S_StartSound(player->mo, sfx_star);
|
||||||
player->kartstuff[k_startimer] = bonustime; // Activate it
|
player->kartstuff[k_startimer] = itemtime; // Activate it
|
||||||
K_PlayTauntSound(player->mo);
|
K_PlayTauntSound(player->mo);
|
||||||
player->kartstuff[k_star] = 0;
|
player->kartstuff[k_star] = 0;
|
||||||
player->kartstuff[k_itemclose] = 10;
|
player->kartstuff[k_itemclose] = 10;
|
||||||
|
@ -2483,7 +2485,7 @@ void K_MoveKartPlayer(player_t *player, ticcmd_t *cmd, boolean onground)
|
||||||
if (!P_IsLocalPlayer(player))
|
if (!P_IsLocalPlayer(player))
|
||||||
S_StartSound(player->mo, sfx_mega);
|
S_StartSound(player->mo, sfx_mega);
|
||||||
K_PlayTauntSound(player->mo);
|
K_PlayTauntSound(player->mo);
|
||||||
player->kartstuff[k_growshrinktimer] = bonustime;
|
player->kartstuff[k_growshrinktimer] = itemtime;
|
||||||
S_StartSound(player->mo, sfx_mario3);
|
S_StartSound(player->mo, sfx_mario3);
|
||||||
player->pflags |= PF_ATTACKDOWN;
|
player->pflags |= PF_ATTACKDOWN;
|
||||||
player->kartstuff[k_megashroom] = 0;
|
player->kartstuff[k_megashroom] = 0;
|
||||||
|
@ -2514,7 +2516,7 @@ void K_MoveKartPlayer(player_t *player, ticcmd_t *cmd, boolean onground)
|
||||||
player->kartstuff[k_boosting] = 0;
|
player->kartstuff[k_boosting] = 0;
|
||||||
|
|
||||||
// Megashroom - Make the player grow!
|
// Megashroom - Make the player grow!
|
||||||
if (player->kartstuff[k_growshrinktimer] > (bonustime - 25))
|
if (player->kartstuff[k_growshrinktimer] > (itemtime - 25))
|
||||||
{
|
{
|
||||||
if (leveltime & 2)
|
if (leveltime & 2)
|
||||||
player->mo->destscale = FRACUNIT*3/2;
|
player->mo->destscale = FRACUNIT*3/2;
|
||||||
|
@ -2522,7 +2524,7 @@ void K_MoveKartPlayer(player_t *player, ticcmd_t *cmd, boolean onground)
|
||||||
player->mo->destscale = FRACUNIT;
|
player->mo->destscale = FRACUNIT;
|
||||||
}
|
}
|
||||||
else if (player->kartstuff[k_growshrinktimer] > 26
|
else if (player->kartstuff[k_growshrinktimer] > 26
|
||||||
&& player->kartstuff[k_growshrinktimer] <= (bonustime - 25))
|
&& player->kartstuff[k_growshrinktimer] <= (itemtime - 25))
|
||||||
player->mo->destscale = FRACUNIT*3/2;
|
player->mo->destscale = FRACUNIT*3/2;
|
||||||
// Megashroom - Back to normal...
|
// Megashroom - Back to normal...
|
||||||
else if (player->kartstuff[k_growshrinktimer] > 1
|
else if (player->kartstuff[k_growshrinktimer] > 1
|
||||||
|
@ -3457,7 +3459,7 @@ static void K_DrawKartPositionFaces(void)
|
||||||
boolean completed[MAXPLAYERS];
|
boolean completed[MAXPLAYERS];
|
||||||
INT32 rankplayer[MAXPLAYERS];
|
INT32 rankplayer[MAXPLAYERS];
|
||||||
INT32 rankcolor[MAXPLAYERS];
|
INT32 rankcolor[MAXPLAYERS];
|
||||||
UINT32 myplayer;
|
INT32 myplayer;
|
||||||
UINT8 *colormap;
|
UINT8 *colormap;
|
||||||
patch_t *localpatch = kp_facenull;
|
patch_t *localpatch = kp_facenull;
|
||||||
|
|
||||||
|
|
|
@ -8243,7 +8243,6 @@ void A_RedShellChase(mobj_t *actor)
|
||||||
void A_BobombExplode(mobj_t *actor)
|
void A_BobombExplode(mobj_t *actor)
|
||||||
{
|
{
|
||||||
mobj_t *mo2;
|
mobj_t *mo2;
|
||||||
mobj_t *mo3;
|
|
||||||
thinker_t *th;
|
thinker_t *th;
|
||||||
INT32 d;
|
INT32 d;
|
||||||
INT32 locvar1 = var1;
|
INT32 locvar1 = var1;
|
||||||
|
@ -8254,7 +8253,7 @@ void A_BobombExplode(mobj_t *actor)
|
||||||
for (d = 0; d < 16; d++)
|
for (d = 0; d < 16; d++)
|
||||||
K_SpawnKartExplosion(actor->x, actor->y, actor->z, actor->info->painchance + 32*FRACUNIT, 32, type, d*(ANGLE_45/4), false, false); // 32 <-> 64
|
K_SpawnKartExplosion(actor->x, actor->y, actor->z, actor->info->painchance + 32*FRACUNIT, 32, type, d*(ANGLE_45/4), false, false); // 32 <-> 64
|
||||||
|
|
||||||
mo3 = P_SpawnMobj(actor->x, actor->y, actor->z, MT_BOMBEXPLOSIONSOUND);
|
P_SpawnMobj(actor->x, actor->y, actor->z, MT_BOMBEXPLOSIONSOUND);
|
||||||
|
|
||||||
//S_StartSound(actor, sfx_prloop);
|
//S_StartSound(actor, sfx_prloop);
|
||||||
|
|
||||||
|
|
|
@ -3925,8 +3925,10 @@ static boolean PIT_ChangeSector(mobj_t *thing, boolean realcrush)
|
||||||
killer = P_SpawnMobj(thing->x, thing->y, thing->z, MT_NULL);
|
killer = P_SpawnMobj(thing->x, thing->y, thing->z, MT_NULL);
|
||||||
killer->threshold = 44; // Special flag for crushing
|
killer->threshold = 44; // Special flag for crushing
|
||||||
}
|
}
|
||||||
//P_DamageMobj(thing, killer, killer, 10000);
|
if (thing->player)
|
||||||
K_SquishPlayer(thing, killer); // SRB2kart - Squish instead of kill
|
P_DamageMobj(thing, killer, killer, 10000);
|
||||||
|
else
|
||||||
|
K_SquishPlayer(thing->player, killer); // SRB2kart - Squish instead of kill
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -6490,15 +6490,15 @@ void P_MobjThinker(mobj_t *mobj)
|
||||||
&& mobj->target->player->health > 0 && !mobj->target->player->spectator)
|
&& mobj->target->player->health > 0 && !mobj->target->player->spectator)
|
||||||
{
|
{
|
||||||
INT32 zfixds = 56;
|
INT32 zfixds = 56;
|
||||||
|
INT32 DIST = FixedMul(zfixds, mobj->target->scale);
|
||||||
|
INT32 HEIGHT;
|
||||||
|
const fixed_t radius = DIST*FRACUNIT; // mobj's distance from its Target, or Radius.
|
||||||
|
|
||||||
if (mobj->type == MT_BANANASHIELD || mobj->type == MT_TRIPLEBANANASHIELD1 || mobj->type == MT_TRIPLEBANANASHIELD2 || mobj->type == MT_TRIPLEBANANASHIELD3)
|
if (mobj->type == MT_BANANASHIELD || mobj->type == MT_TRIPLEBANANASHIELD1 || mobj->type == MT_TRIPLEBANANASHIELD2 || mobj->type == MT_TRIPLEBANANASHIELD3)
|
||||||
zfixds = 64;
|
zfixds = 64;
|
||||||
else
|
else
|
||||||
zfixds = 56;
|
zfixds = 56;
|
||||||
|
|
||||||
INT32 DIST = FixedMul(zfixds, mobj->target->scale);
|
|
||||||
INT32 HEIGHT;
|
|
||||||
const fixed_t radius = DIST*FRACUNIT; // mobj's distance from its Target, or Radius.
|
|
||||||
|
|
||||||
//mobj->angle += FixedAngle(12*FRACUNIT); // mobj's actual speed.
|
//mobj->angle += FixedAngle(12*FRACUNIT); // mobj's actual speed.
|
||||||
if (mobj->type == MT_TRIPLEGREENSHIELD1 || mobj->type == MT_TRIPLEGREENSHIELD2 || mobj->type == MT_TRIPLEGREENSHIELD3
|
if (mobj->type == MT_TRIPLEGREENSHIELD1 || mobj->type == MT_TRIPLEGREENSHIELD2 || mobj->type == MT_TRIPLEGREENSHIELD3
|
||||||
|| mobj->type == MT_TRIPLEREDSHIELD1 || mobj->type == MT_TRIPLEREDSHIELD2 || mobj->type == MT_TRIPLEREDSHIELD3)
|
|| mobj->type == MT_TRIPLEREDSHIELD1 || mobj->type == MT_TRIPLEREDSHIELD2 || mobj->type == MT_TRIPLEREDSHIELD3)
|
||||||
|
|
28
src/p_user.c
28
src/p_user.c
|
@ -1005,9 +1005,11 @@ void P_DoSuperTransformation(player_t *player, boolean giverings)
|
||||||
// Adds to the player's score
|
// Adds to the player's score
|
||||||
void P_AddPlayerScore(player_t *player, UINT32 amount)
|
void P_AddPlayerScore(player_t *player, UINT32 amount)
|
||||||
{
|
{
|
||||||
return; // SRB2kart - no score.
|
|
||||||
UINT32 oldscore;
|
UINT32 oldscore;
|
||||||
|
|
||||||
|
return; // SRB2kart - no score.
|
||||||
|
// This will probably be temporary until we do battle modes?
|
||||||
|
|
||||||
if (player->bot)
|
if (player->bot)
|
||||||
player = &players[consoleplayer];
|
player = &players[consoleplayer];
|
||||||
|
|
||||||
|
@ -3413,6 +3415,7 @@ static void P_DoFiring(player_t *player, ticcmd_t *cmd) // SRB2kart - unused.
|
||||||
}
|
}
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#if 0
|
||||||
//
|
//
|
||||||
// P_DoSuperStuff()
|
// P_DoSuperStuff()
|
||||||
//
|
//
|
||||||
|
@ -3420,7 +3423,6 @@ static void P_DoFiring(player_t *player, ticcmd_t *cmd) // SRB2kart - unused.
|
||||||
//
|
//
|
||||||
static void P_DoSuperStuff(player_t *player)
|
static void P_DoSuperStuff(player_t *player)
|
||||||
{
|
{
|
||||||
return; // SRB2kart - don't neeeeed
|
|
||||||
mobj_t *spark;
|
mobj_t *spark;
|
||||||
ticcmd_t *cmd = &player->cmd;
|
ticcmd_t *cmd = &player->cmd;
|
||||||
//if (player->mo->state >= &states[S_PLAY_SUPERTRANS1] && player->mo->state <= &states[S_PLAY_SUPERTRANS9])
|
//if (player->mo->state >= &states[S_PLAY_SUPERTRANS1] && player->mo->state <= &states[S_PLAY_SUPERTRANS9])
|
||||||
|
@ -3552,6 +3554,7 @@ static void P_DoSuperStuff(player_t *player)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
//
|
//
|
||||||
// P_SuperReady
|
// P_SuperReady
|
||||||
|
@ -4536,12 +4539,12 @@ static void P_3dMovement(player_t *player)
|
||||||
{
|
{
|
||||||
ticcmd_t *cmd;
|
ticcmd_t *cmd;
|
||||||
angle_t movepushangle, movepushsideangle; // Analog
|
angle_t movepushangle, movepushsideangle; // Analog
|
||||||
INT32 topspeed, acceleration, thrustfactor;
|
//INT32 topspeed, acceleration, thrustfactor;
|
||||||
fixed_t movepushforward = 0, movepushside = 0;
|
fixed_t movepushforward = 0, movepushside = 0;
|
||||||
INT32 mforward = 0, mbackward = 0;
|
INT32 mforward = 0, mbackward = 0;
|
||||||
angle_t dangle; // replaces old quadrants bits
|
angle_t dangle; // replaces old quadrants bits
|
||||||
boolean dangleflip = false; // SRB2kart - toaster
|
//boolean dangleflip = false; // SRB2kart - toaster
|
||||||
fixed_t normalspd = FixedMul(player->normalspeed, player->mo->scale);
|
//fixed_t normalspd = FixedMul(player->normalspeed, player->mo->scale);
|
||||||
boolean analogmove = false;
|
boolean analogmove = false;
|
||||||
fixed_t oldMagnitude, newMagnitude;
|
fixed_t oldMagnitude, newMagnitude;
|
||||||
#ifdef ESLOPE
|
#ifdef ESLOPE
|
||||||
|
@ -4629,7 +4632,7 @@ static void P_3dMovement(player_t *player)
|
||||||
if (dangle > ANGLE_180) //flip to keep to one side
|
if (dangle > ANGLE_180) //flip to keep to one side
|
||||||
{
|
{
|
||||||
dangle = InvAngle(dangle);
|
dangle = InvAngle(dangle);
|
||||||
dangleflip = true;
|
//dangleflip = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
// now use it to determine direction!
|
// now use it to determine direction!
|
||||||
|
@ -4668,7 +4671,7 @@ static void P_3dMovement(player_t *player)
|
||||||
player->aiming = cmd->aiming<<FRACBITS;
|
player->aiming = cmd->aiming<<FRACBITS;
|
||||||
|
|
||||||
// Set the player speeds.
|
// Set the player speeds.
|
||||||
if (player->pflags & PF_SLIDING)
|
/*if (player->pflags & PF_SLIDING)
|
||||||
{
|
{
|
||||||
normalspd = FixedMul(36<<FRACBITS, player->mo->scale);
|
normalspd = FixedMul(36<<FRACBITS, player->mo->scale);
|
||||||
thrustfactor = 5;
|
thrustfactor = 5;
|
||||||
|
@ -4699,14 +4702,14 @@ static void P_3dMovement(player_t *player)
|
||||||
thrustfactor = player->thrustfactor*2;
|
thrustfactor = player->thrustfactor*2;
|
||||||
acceleration = player->accelstart/2 + (FixedDiv(player->speed, player->mo->scale)>>FRACBITS) * player->acceleration/2;
|
acceleration = player->accelstart/2 + (FixedDiv(player->speed, player->mo->scale)>>FRACBITS) * player->acceleration/2;
|
||||||
|
|
||||||
/*
|
|
||||||
if (player->powers[pw_tailsfly])
|
if (player->powers[pw_tailsfly])
|
||||||
topspeed = normalspd;
|
topspeed = normalspd;
|
||||||
else if (player->mo->eflags & (MFE_UNDERWATER|MFE_GOOWATER))
|
else if (player->mo->eflags & (MFE_UNDERWATER|MFE_GOOWATER))
|
||||||
{
|
{
|
||||||
topspeed = normalspd;
|
topspeed = normalspd;
|
||||||
acceleration = 2*acceleration/3;
|
acceleration = 2*acceleration/3;
|
||||||
}*/
|
}
|
||||||
|
|
||||||
if (cmd->forwardmove < 0)
|
if (cmd->forwardmove < 0)
|
||||||
topspeed = 5<<16;
|
topspeed = 5<<16;
|
||||||
|
@ -4718,14 +4721,14 @@ static void P_3dMovement(player_t *player)
|
||||||
thrustfactor = player->thrustfactor;
|
thrustfactor = player->thrustfactor;
|
||||||
acceleration = player->accelstart + (FixedDiv(player->speed, player->mo->scale)>>FRACBITS) * player->acceleration;
|
acceleration = player->accelstart + (FixedDiv(player->speed, player->mo->scale)>>FRACBITS) * player->acceleration;
|
||||||
|
|
||||||
/*
|
|
||||||
if (player->powers[pw_tailsfly])
|
if (player->powers[pw_tailsfly])
|
||||||
topspeed = normalspd/2;
|
topspeed = normalspd/2;
|
||||||
else if (player->mo->eflags & (MFE_UNDERWATER|MFE_GOOWATER))
|
else if (player->mo->eflags & (MFE_UNDERWATER|MFE_GOOWATER))
|
||||||
{
|
{
|
||||||
topspeed = normalspd/2;
|
topspeed = normalspd/2;
|
||||||
acceleration = 2*acceleration/3;
|
acceleration = 2*acceleration/3;
|
||||||
}*/
|
}
|
||||||
if (cmd->forwardmove < 0)
|
if (cmd->forwardmove < 0)
|
||||||
topspeed = 5<<16;
|
topspeed = 5<<16;
|
||||||
else
|
else
|
||||||
|
@ -4741,6 +4744,7 @@ static void P_3dMovement(player_t *player)
|
||||||
|
|
||||||
if (player->mo->movefactor != FRACUNIT) // Friction-scaled acceleration...
|
if (player->mo->movefactor != FRACUNIT) // Friction-scaled acceleration...
|
||||||
acceleration = FixedMul(acceleration<<FRACBITS, player->mo->movefactor)>>FRACBITS;
|
acceleration = FixedMul(acceleration<<FRACBITS, player->mo->movefactor)>>FRACBITS;
|
||||||
|
*/
|
||||||
|
|
||||||
// Forward movement
|
// Forward movement
|
||||||
if (player->climbing)
|
if (player->climbing)
|
||||||
|
@ -9248,7 +9252,7 @@ void P_PlayerThink(player_t *player)
|
||||||
player->cmomy = player->cmomx = 0;
|
player->cmomy = player->cmomx = 0;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
P_DoSuperStuff(player);
|
//P_DoSuperStuff(player);
|
||||||
P_CheckSneakerAndLivesTimer(player);
|
P_CheckSneakerAndLivesTimer(player);
|
||||||
P_DoBubbleBreath(player); // Spawn Sonic's bubbles
|
P_DoBubbleBreath(player); // Spawn Sonic's bubbles
|
||||||
P_CheckUnderwaterAndSpaceTimer(player); // Display the countdown drown numbers!
|
P_CheckUnderwaterAndSpaceTimer(player); // Display the countdown drown numbers!
|
||||||
|
|
|
@ -468,6 +468,7 @@ static INT32 STRINGY(INT32 y)
|
||||||
return y;
|
return y;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
static INT32 SPLITFLAGS(INT32 f)
|
static INT32 SPLITFLAGS(INT32 f)
|
||||||
{
|
{
|
||||||
// Pass this V_SNAPTO(TOP|BOTTOM) and it'll trim them to account for splitscreen! -Red
|
// Pass this V_SNAPTO(TOP|BOTTOM) and it'll trim them to account for splitscreen! -Red
|
||||||
|
@ -480,6 +481,7 @@ static INT32 SPLITFLAGS(INT32 f)
|
||||||
}
|
}
|
||||||
return f;
|
return f;
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
static INT32 SCX(INT32 x)
|
static INT32 SCX(INT32 x)
|
||||||
{
|
{
|
||||||
|
@ -518,11 +520,12 @@ static INT32 SCR(INT32 r)
|
||||||
#define ST_DrawPadNumFromHudWS(h,n,q) V_DrawPaddedTallNum(SCX(hudinfo[h+!!splitscreen].x), SCY(hudinfo[h+!!splitscreen].y), V_NOSCALESTART|V_HUDTRANS, n, q)
|
#define ST_DrawPadNumFromHudWS(h,n,q) V_DrawPaddedTallNum(SCX(hudinfo[h+!!splitscreen].x), SCY(hudinfo[h+!!splitscreen].y), V_NOSCALESTART|V_HUDTRANS, n, q)
|
||||||
#define ST_DrawPatchFromHudWS(h,p) V_DrawScaledPatch(SCX(hudinfo[h+!!splitscreen].x), SCY(hudinfo[h+!!splitscreen].y), V_NOSCALESTART|V_HUDTRANS, p)
|
#define ST_DrawPatchFromHudWS(h,p) V_DrawScaledPatch(SCX(hudinfo[h+!!splitscreen].x), SCY(hudinfo[h+!!splitscreen].y), V_NOSCALESTART|V_HUDTRANS, p)
|
||||||
|
|
||||||
|
/*
|
||||||
// Draw a number, scaled, over the view, maybe with set translucency
|
// Draw a number, scaled, over the view, maybe with set translucency
|
||||||
// Always draw the number completely since it's overlay
|
// Always draw the number completely since it's overlay
|
||||||
//
|
//
|
||||||
// Supports different colors! woo!
|
// Supports different colors! woo!
|
||||||
static void ST_DrawNightsOverlayNum(INT32 x /* right border */, INT32 y, INT32 a,
|
static void ST_DrawNightsOverlayNum(INT32 x, INT32 y, INT32 a,
|
||||||
INT32 num, patch_t **numpat, skincolors_t colornum)
|
INT32 num, patch_t **numpat, skincolors_t colornum)
|
||||||
{
|
{
|
||||||
INT32 w = SHORT(numpat[0]->width);
|
INT32 w = SHORT(numpat[0]->width);
|
||||||
|
@ -548,6 +551,7 @@ static void ST_DrawNightsOverlayNum(INT32 x /* right border */, INT32 y, INT32 a
|
||||||
|
|
||||||
// Sorry chum, this function only draws UNSIGNED values!
|
// Sorry chum, this function only draws UNSIGNED values!
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
// Devmode information
|
// Devmode information
|
||||||
static void ST_drawDebugInfo(void)
|
static void ST_drawDebugInfo(void)
|
||||||
|
@ -616,6 +620,7 @@ static void ST_drawDebugInfo(void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
static void ST_drawScore(void)
|
static void ST_drawScore(void)
|
||||||
{
|
{
|
||||||
// SCORE:
|
// SCORE:
|
||||||
|
@ -630,7 +635,9 @@ static void ST_drawScore(void)
|
||||||
else
|
else
|
||||||
ST_DrawNumFromHud(HUD_SCORENUM, stplyr->score);
|
ST_DrawNumFromHud(HUD_SCORENUM, stplyr->score);
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
static void ST_drawTime(void)
|
static void ST_drawTime(void)
|
||||||
{
|
{
|
||||||
INT32 seconds, minutes, tictrn, tics;
|
INT32 seconds, minutes, tictrn, tics;
|
||||||
|
@ -668,6 +675,7 @@ static void ST_drawTime(void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
static inline void ST_drawRings(void)
|
static inline void ST_drawRings(void)
|
||||||
{
|
{
|
||||||
|
@ -899,6 +907,7 @@ static void ST_drawFirstPersonHUD(void)
|
||||||
V_NOSCALESTART|V_OFFSET|V_TRANSLUCENT, p);
|
V_NOSCALESTART|V_OFFSET|V_TRANSLUCENT, p);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
// [21:42] <+Rob> Beige - Lavender - Steel Blue - Peach - Orange - Purple - Silver - Yellow - Pink - Red - Blue - Green - Cyan - Gold
|
// [21:42] <+Rob> Beige - Lavender - Steel Blue - Peach - Orange - Purple - Silver - Yellow - Pink - Red - Blue - Green - Cyan - Gold
|
||||||
static skincolors_t linkColor[14] =
|
static skincolors_t linkColor[14] =
|
||||||
{SKINCOLOR_BEIGE, SKINCOLOR_LAVENDER, SKINCOLOR_STEELBLUE, SKINCOLOR_PEACH, SKINCOLOR_ORANGE,
|
{SKINCOLOR_BEIGE, SKINCOLOR_LAVENDER, SKINCOLOR_STEELBLUE, SKINCOLOR_PEACH, SKINCOLOR_ORANGE,
|
||||||
|
@ -971,6 +980,7 @@ static void ST_drawNightsRecords(void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
/*
|
/*
|
||||||
static void ST_drawNiGHTSHUD(void) // SRB2kart - unused.
|
static void ST_drawNiGHTSHUD(void) // SRB2kart - unused.
|
||||||
|
@ -1354,6 +1364,7 @@ static void ST_drawNiGHTSHUD(void) // SRB2kart - unused.
|
||||||
}
|
}
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
static void ST_drawWeaponRing(powertype_t weapon, INT32 rwflag, INT32 wepflag, INT32 xoffs, patch_t *pat)
|
static void ST_drawWeaponRing(powertype_t weapon, INT32 rwflag, INT32 wepflag, INT32 xoffs, patch_t *pat)
|
||||||
{
|
{
|
||||||
INT32 txtflags = 0, patflags = 0;
|
INT32 txtflags = 0, patflags = 0;
|
||||||
|
@ -1385,6 +1396,7 @@ static void ST_drawWeaponRing(powertype_t weapon, INT32 rwflag, INT32 wepflag, I
|
||||||
else if (stplyr->ringweapons & rwflag)
|
else if (stplyr->ringweapons & rwflag)
|
||||||
V_DrawScaledPatch(8 + xoffs, STRINGY(162), V_SNAPTOLEFT|V_TRANSLUCENT, pat);
|
V_DrawScaledPatch(8 + xoffs, STRINGY(162), V_SNAPTOLEFT|V_TRANSLUCENT, pat);
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
/*
|
/*
|
||||||
static void ST_drawMatchHUD(void) // SRB2kart - unused.
|
static void ST_drawMatchHUD(void) // SRB2kart - unused.
|
||||||
|
@ -1631,6 +1643,7 @@ static void ST_drawSpecialStageHUD(void) // SRB2kart - unused.
|
||||||
}
|
}
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
static INT32 ST_drawEmeraldHuntIcon(mobj_t *hunt, patch_t **patches, INT32 offset)
|
static INT32 ST_drawEmeraldHuntIcon(mobj_t *hunt, patch_t **patches, INT32 offset)
|
||||||
{
|
{
|
||||||
INT32 interval, i;
|
INT32 interval, i;
|
||||||
|
@ -1670,6 +1683,7 @@ static INT32 ST_drawEmeraldHuntIcon(mobj_t *hunt, patch_t **patches, INT32 offse
|
||||||
V_DrawScaledPatch(hudinfo[HUD_HUNTPICS].x+offset, STRINGY(hudinfo[HUD_HUNTPICS].y), V_HUDTRANS, patches[i]);
|
V_DrawScaledPatch(hudinfo[HUD_HUNTPICS].x+offset, STRINGY(hudinfo[HUD_HUNTPICS].y), V_HUDTRANS, patches[i]);
|
||||||
return interval;
|
return interval;
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
/*
|
/*
|
||||||
// Separated a few things to stop the SOUND EFFECTS BLARING UGH SHUT UP AAAA
|
// Separated a few things to stop the SOUND EFFECTS BLARING UGH SHUT UP AAAA
|
||||||
|
|
|
@ -257,7 +257,7 @@ void Y_IntermissionDrawer(void)
|
||||||
}
|
}
|
||||||
else if (intertype == int_race)
|
else if (intertype == int_race)
|
||||||
{
|
{
|
||||||
INT32 i = 0, j = 0;
|
INT32 j = 0;
|
||||||
INT32 x = 4;
|
INT32 x = 4;
|
||||||
INT32 y = 48;
|
INT32 y = 48;
|
||||||
char name[MAXPLAYERNAME+1];
|
char name[MAXPLAYERNAME+1];
|
||||||
|
@ -1850,29 +1850,20 @@ static void Y_CalculateTournamentPoints(void)
|
||||||
INT32 i, j;
|
INT32 i, j;
|
||||||
boolean completed[MAXPLAYERS];
|
boolean completed[MAXPLAYERS];
|
||||||
INT32 numplayersingame = 0;
|
INT32 numplayersingame = 0;
|
||||||
INT32 zz1 = 0, zz2 = 0, zz3 = 0, zz4 = 0, zz5 = 0, zz6 = 0, zz7 = 0, zz8 = 0,
|
INT32 increase[MAXPLAYERS];
|
||||||
zz9 = 0, zz10 = 0, zz11 = 0, zz12 = 0, zz13 = 0, zz14 = 0, zz15 = 0, zz16 = 0;
|
|
||||||
|
|
||||||
for (i = 0; i < MAXPLAYERS; i++)
|
for (i = 0; i < MAXPLAYERS; i++)
|
||||||
{
|
{
|
||||||
if (playeringame[i])
|
if (playeringame[i])
|
||||||
numplayersingame++;
|
numplayersingame++;
|
||||||
|
|
||||||
|
increase[i] = numplayersingame-i;
|
||||||
|
|
||||||
|
if (increase[i] < 0)
|
||||||
|
increase[i] = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
zz1 = numplayersingame; zz2 = numplayersingame-1; zz3 = numplayersingame-2; zz4 = numplayersingame-3;
|
|
||||||
zz5 = numplayersingame-4; zz6 = numplayersingame-5; zz7 = numplayersingame-6; zz8 = numplayersingame-7;
|
|
||||||
zz9 = numplayersingame-8; zz10= numplayersingame-9; zz11= numplayersingame-10; zz12= numplayersingame-11;
|
|
||||||
zz13= numplayersingame-12; zz14= numplayersingame-13; zz15= numplayersingame-14; zz16= numplayersingame-15;
|
|
||||||
|
|
||||||
if (zz1 < 0) zz1 = 0; if (zz2 < 0) zz2 = 0; if (zz3 < 0) zz3 = 0; if (zz4 < 0) zz4 = 0;
|
|
||||||
if (zz5 < 0) zz5 = 0; if (zz6 < 0) zz6 = 0; if (zz7 < 0) zz7 = 0; if (zz8 < 0) zz8 = 0;
|
|
||||||
if (zz9 < 0) zz9 = 0; if (zz10< 0) zz10= 0; if (zz11< 0) zz11= 0; if (zz12< 0) zz12= 0;
|
|
||||||
if (zz13< 0) zz13= 0; if (zz14< 0) zz14= 0; if (zz15< 0) zz15= 0; if (zz16< 0) zz16= 0;
|
|
||||||
|
|
||||||
INT32 increase[MAXPLAYERS] = {zz1,zz2,zz3,zz4,zz5,zz6,zz7,zz8,zz9,zz10,zz11,zz12,zz13,zz14,zz15,zz16};
|
|
||||||
|
|
||||||
// Initialize variables
|
// Initialize variables
|
||||||
|
|
||||||
for (j = 0; j < MAXPLAYERS; j++)
|
for (j = 0; j < MAXPLAYERS; j++)
|
||||||
data.match.scores[j] = INT32_MAX;
|
data.match.scores[j] = INT32_MAX;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue