mirror of
https://git.do.srb2.org/KartKrew/Kart-Public.git
synced 2025-01-17 23:21:05 +00:00
Merge remote-tracking branch 'refs/remotes/origin/master' into sal-misc
This commit is contained in:
commit
c1a32c609f
14 changed files with 423 additions and 197 deletions
|
@ -121,7 +121,7 @@ void B_BuildTiccmd(player_t *player, ticcmd_t *cmd)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Bot AI isn't programmed in analog.
|
// Bot AI isn't programmed in analog.
|
||||||
CV_SetValue(&cv_analog2, false);
|
//CV_SetValue(&cv_analog2, false);
|
||||||
|
|
||||||
#ifdef HAVE_BLUA
|
#ifdef HAVE_BLUA
|
||||||
// Let Lua scripts build ticcmds
|
// Let Lua scripts build ticcmds
|
||||||
|
|
195
src/dehacked.c
195
src/dehacked.c
|
@ -5815,9 +5815,15 @@ static const char *const STATE_LIST[] = { // array length left dynamic for sanit
|
||||||
"S_FIREBALL2",
|
"S_FIREBALL2",
|
||||||
"S_FIREBALL3",
|
"S_FIREBALL3",
|
||||||
"S_FIREBALL4",
|
"S_FIREBALL4",
|
||||||
|
"S_FIREBALL5",
|
||||||
|
"S_FIREBALL6",
|
||||||
|
"S_FIREBALL7",
|
||||||
"S_FIREBALLEXP1",
|
"S_FIREBALLEXP1",
|
||||||
"S_FIREBALLEXP2",
|
"S_FIREBALLEXP2",
|
||||||
"S_FIREBALLEXP3",
|
"S_FIREBALLEXP3",
|
||||||
|
"S_FIREBALLEXP4",
|
||||||
|
"S_FIREBALLEXP5",
|
||||||
|
"S_FIREBALLEXP6",
|
||||||
"S_SHELL",
|
"S_SHELL",
|
||||||
"S_SHELL1",
|
"S_SHELL1",
|
||||||
"S_SHELL2",
|
"S_SHELL2",
|
||||||
|
@ -6410,6 +6416,10 @@ static const char *const STATE_LIST[] = { // array length left dynamic for sanit
|
||||||
"S_BATTLEBALLOON2",
|
"S_BATTLEBALLOON2",
|
||||||
"S_BATTLEBALLOON3",
|
"S_BATTLEBALLOON3",
|
||||||
|
|
||||||
|
// Lakitu
|
||||||
|
"S_LAKITU1",
|
||||||
|
"S_LAKITU2",
|
||||||
|
|
||||||
// Pokey
|
// Pokey
|
||||||
"S_POKEY1",
|
"S_POKEY1",
|
||||||
"S_POKEY2",
|
"S_POKEY2",
|
||||||
|
@ -6421,6 +6431,130 @@ static const char *const STATE_LIST[] = { // array length left dynamic for sanit
|
||||||
"S_POKEY8",
|
"S_POKEY8",
|
||||||
"S_POKEYIDLE",
|
"S_POKEYIDLE",
|
||||||
|
|
||||||
|
// Audience Members
|
||||||
|
"S_RANDOMAUDIENCE",
|
||||||
|
"S_AUDIENCE_TOAD1",
|
||||||
|
"S_AUDIENCE_TOAD2",
|
||||||
|
"S_AUDIENCE_BOO1",
|
||||||
|
"S_AUDIENCE_BOO2",
|
||||||
|
"S_AUDIENCE_GMBA1",
|
||||||
|
"S_AUDIENCE_GMBA2",
|
||||||
|
"S_AUDIENCE_SHYG1",
|
||||||
|
"S_AUDIENCE_SHYG2",
|
||||||
|
"S_AUDIENCE_SNIF1",
|
||||||
|
"S_AUDIENCE_SNIF2",
|
||||||
|
|
||||||
|
"S_FANCHAR_KOTE",
|
||||||
|
"S_FANCHAR_RYAN",
|
||||||
|
"S_FANCHAR_WENDY",
|
||||||
|
"S_FANCHAR_FREEZOR",
|
||||||
|
"S_FANCHAR_METALKO",
|
||||||
|
"S_FANCHAR_BLACKOUT",
|
||||||
|
"S_FANCHAR_BLADE",
|
||||||
|
"S_FANCHAR_HINOTE",
|
||||||
|
|
||||||
|
// 1.0 Kart Decoratives
|
||||||
|
"S_FLAYM1",
|
||||||
|
"S_FLAYM2",
|
||||||
|
"S_FLAYM3",
|
||||||
|
"S_FLAYM4",
|
||||||
|
"S_DEVIL",
|
||||||
|
"S_ANGEL",
|
||||||
|
"S_PALMTREE",
|
||||||
|
"S_FLAG",
|
||||||
|
"S_HEDGEHOG", // (Rimshot)
|
||||||
|
"S_BUSH1",
|
||||||
|
"S_TWEE",
|
||||||
|
"S_HYDRANT",
|
||||||
|
|
||||||
|
// New Misc Decorations
|
||||||
|
"S_BIGPUMA1",
|
||||||
|
"S_BIGPUMA2",
|
||||||
|
"S_BIGPUMA3",
|
||||||
|
"S_BIGPUMA4",
|
||||||
|
"S_BIGPUMA5",
|
||||||
|
"S_BIGPUMA6",
|
||||||
|
"S_APPLE1",
|
||||||
|
"S_APPLE2",
|
||||||
|
"S_APPLE3",
|
||||||
|
"S_APPLE4",
|
||||||
|
"S_APPLE5",
|
||||||
|
"S_APPLE6",
|
||||||
|
"S_APPLE7",
|
||||||
|
"S_APPLE8",
|
||||||
|
|
||||||
|
// D00Dkart - Fall Flowers
|
||||||
|
"S_DOOD_FLOWER1",
|
||||||
|
"S_DOOD_FLOWER2",
|
||||||
|
"S_DOOD_FLOWER3",
|
||||||
|
"S_DOOD_FLOWER4",
|
||||||
|
"S_DOOD_FLOWER5",
|
||||||
|
"S_DOOD_FLOWER6",
|
||||||
|
|
||||||
|
// D00Dkart - Super Circuit Box
|
||||||
|
"S_DOOD_BOX1",
|
||||||
|
"S_DOOD_BOX2",
|
||||||
|
"S_DOOD_BOX3",
|
||||||
|
"S_DOOD_BOX4",
|
||||||
|
"S_DOOD_BOX5",
|
||||||
|
|
||||||
|
// D00Dkart - Diddy Kong Racing Balloon
|
||||||
|
"S_DOOD_BALLOON",
|
||||||
|
|
||||||
|
// D00Dkart - Big Ring
|
||||||
|
"S_DOOD_RING1",
|
||||||
|
"S_DOOD_RING2",
|
||||||
|
"S_DOOD_RING3",
|
||||||
|
"S_DOOD_RING4",
|
||||||
|
"S_DOOD_RING5",
|
||||||
|
|
||||||
|
// SNES Objects
|
||||||
|
"S_SNES_DONUTBUSH1",
|
||||||
|
"S_SNES_DONUTBUSH2",
|
||||||
|
"S_SNES_DONUTBUSH3",
|
||||||
|
|
||||||
|
// GBA Objects
|
||||||
|
"S_GBA_BOO1",
|
||||||
|
"S_GBA_BOO2",
|
||||||
|
"S_GBA_BOO3",
|
||||||
|
"S_GBA_BOO4",
|
||||||
|
|
||||||
|
// Sapphire Coast Mobs
|
||||||
|
"S_BUZZBOMBER_LOOK1",
|
||||||
|
"S_BUZZBOMBER_LOOK2",
|
||||||
|
"S_BUZZBOMBER_FLY1",
|
||||||
|
"S_BUZZBOMBER_FLY2",
|
||||||
|
"S_BUZZBOMBER_FLY3",
|
||||||
|
"S_BUZZBOMBER_FLY4",
|
||||||
|
|
||||||
|
"S_CHOMPER_SPAWN",
|
||||||
|
"S_CHOMPER_HOP1",
|
||||||
|
"S_CHOMPER_HOP2",
|
||||||
|
"S_CHOMPER_TURNAROUND",
|
||||||
|
|
||||||
|
"S_PALMTREE2",
|
||||||
|
"S_PURPLEFLOWER1",
|
||||||
|
"S_PURPLEFLOWER2",
|
||||||
|
"S_YELLOWFLOWER1",
|
||||||
|
"S_YELLOWFLOWER2",
|
||||||
|
"S_PLANT2",
|
||||||
|
"S_PLANT3",
|
||||||
|
"S_PLANT4",
|
||||||
|
|
||||||
|
// Crystal Abyss Mobs
|
||||||
|
"S_SKULL",
|
||||||
|
"S_PHANTREE",
|
||||||
|
"S_FLYINGGARG1",
|
||||||
|
"S_FLYINGGARG2",
|
||||||
|
"S_FLYINGGARG3",
|
||||||
|
"S_FLYINGGARG4",
|
||||||
|
"S_FLYINGGARG5",
|
||||||
|
"S_FLYINGGARG6",
|
||||||
|
"S_FLYINGGARG7",
|
||||||
|
"S_FLYINGGARG8",
|
||||||
|
"S_LAMPPOST",
|
||||||
|
"S_MOSSYTREE",
|
||||||
|
|
||||||
"S_SHADOW",
|
"S_SHADOW",
|
||||||
"S_WHITESHADOW",
|
"S_WHITESHADOW",
|
||||||
|
|
||||||
|
@ -6981,7 +7115,6 @@ static const char *const MOBJTYPE_LIST[] = { // array length left dynamic for s
|
||||||
"MT_INVISSPRING",
|
"MT_INVISSPRING",
|
||||||
"MT_BLUEDIAG",
|
"MT_BLUEDIAG",
|
||||||
"MT_RANDOMITEM",
|
"MT_RANDOMITEM",
|
||||||
"MT_FLINGRANDOMITEM",
|
|
||||||
"MT_RANDOMITEMPOP",
|
"MT_RANDOMITEMPOP",
|
||||||
|
|
||||||
"MT_MUSHROOMTRAIL",
|
"MT_MUSHROOMTRAIL",
|
||||||
|
@ -7032,14 +7165,72 @@ static const char *const MOBJTYPE_LIST[] = { // array length left dynamic for s
|
||||||
"MT_LAKITU",
|
"MT_LAKITU",
|
||||||
|
|
||||||
"MT_POKEY", // Huh, thought this was a default asset for some reason, guess not.
|
"MT_POKEY", // Huh, thought this was a default asset for some reason, guess not.
|
||||||
|
|
||||||
"MT_ENEMYFLIP",
|
"MT_ENEMYFLIP",
|
||||||
"MT_WAYPOINT",
|
"MT_WAYPOINT",
|
||||||
|
|
||||||
|
"MT_RANDOMAUDIENCE",
|
||||||
|
"MT_FANCHAR_KOTE",
|
||||||
|
"MT_FANCHAR_RYAN",
|
||||||
|
"MT_FANCHAR_WENDY",
|
||||||
|
"MT_FANCHAR_FREEZOR",
|
||||||
|
"MT_FANCHAR_METALKO",
|
||||||
|
"MT_FANCHAR_BLACKOUT",
|
||||||
|
"MT_FANCHAR_BLADE",
|
||||||
|
"MT_FANCHAR_HINOTE",
|
||||||
|
|
||||||
|
"MT_FLAYM",
|
||||||
|
"MT_DEVIL",
|
||||||
|
"MT_ANGEL",
|
||||||
|
"MT_PALMTREE",
|
||||||
|
"MT_FLAG",
|
||||||
|
"MT_HEDGEHOG",
|
||||||
|
"MT_BUSH1",
|
||||||
|
"MT_TWEE",
|
||||||
|
"MT_HYDRANT",
|
||||||
|
|
||||||
|
"MT_BIGPUMA",
|
||||||
|
"MT_APPLE",
|
||||||
|
|
||||||
|
"MT_DOOD_FLOWER1",
|
||||||
|
"MT_DOOD_FLOWER2",
|
||||||
|
"MT_DOOD_FLOWER3",
|
||||||
|
"MT_DOOD_FLOWER4",
|
||||||
|
"MT_DOOD_BOX",
|
||||||
|
"MT_DOOD_BALLOON",
|
||||||
|
"MT_DOOD_RING",
|
||||||
|
|
||||||
|
"MT_SNES_DONUTBUSH1",
|
||||||
|
"MT_SNES_DONUTBUSH2",
|
||||||
|
"MT_SNES_DONUTBUSH3",
|
||||||
|
|
||||||
|
"MT_GBA_BOO",
|
||||||
|
|
||||||
|
"MT_BUZZBOMBER",
|
||||||
|
"MT_CHOMPER",
|
||||||
|
"MT_PALMTREE2",
|
||||||
|
"MT_PURPLEFLOWER1",
|
||||||
|
"MT_PURPLEFLOWER2",
|
||||||
|
"MT_YELLOWFLOWER1",
|
||||||
|
"MT_YELLOWFLOWER2",
|
||||||
|
"MT_PLANT2",
|
||||||
|
"MT_PLANT3",
|
||||||
|
"MT_PLANT4",
|
||||||
|
|
||||||
|
"MT_SKULL",
|
||||||
|
"MT_PHANTREE",
|
||||||
|
"MT_FLYINGGARG",
|
||||||
|
"MT_LAMPPOST",
|
||||||
|
"MT_MOSSYTREE",
|
||||||
|
|
||||||
"MT_SHADOW",
|
"MT_SHADOW",
|
||||||
|
|
||||||
"MT_BUMP",
|
"MT_BUMP",
|
||||||
|
|
||||||
|
"MT_FLINGENERGY",
|
||||||
|
|
||||||
"MT_ITEMCLASH",
|
"MT_ITEMCLASH",
|
||||||
|
|
||||||
"MT_FIREDITEM",
|
"MT_FIREDITEM",
|
||||||
|
|
||||||
"MT_PLAYERARROW",
|
"MT_PLAYERARROW",
|
||||||
|
|
34
src/g_game.c
34
src/g_game.c
|
@ -1497,7 +1497,7 @@ void G_BuildTiccmd(ticcmd_t *cmd, INT32 realtics, UINT8 ssplayer)
|
||||||
if (!player->powers[pw_tailsfly] && (cmd->forwardmove || cmd->sidemove || cmd->buttons))
|
if (!player->powers[pw_tailsfly] && (cmd->forwardmove || cmd->sidemove || cmd->buttons))
|
||||||
{
|
{
|
||||||
player->bot = 2; // A player-controlled bot. Returns to AI when it respawns.
|
player->bot = 2; // A player-controlled bot. Returns to AI when it respawns.
|
||||||
CV_SetValue(&cv_analog2, true);
|
//CV_SetValue(&cv_analog2, true);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -1593,40 +1593,40 @@ void G_BuildTiccmd(ticcmd_t *cmd, INT32 realtics, UINT8 ssplayer)
|
||||||
// fudging with it.
|
// fudging with it.
|
||||||
static void UserAnalog_OnChange(void)
|
static void UserAnalog_OnChange(void)
|
||||||
{
|
{
|
||||||
if (cv_useranalog.value)
|
/*if (cv_useranalog.value)
|
||||||
CV_SetValue(&cv_analog, 1);
|
CV_SetValue(&cv_analog, 1);
|
||||||
else
|
else
|
||||||
CV_SetValue(&cv_analog, 0);
|
CV_SetValue(&cv_analog, 0);*/
|
||||||
}
|
}
|
||||||
|
|
||||||
static void UserAnalog2_OnChange(void)
|
static void UserAnalog2_OnChange(void)
|
||||||
{
|
{
|
||||||
if (botingame)
|
if (botingame)
|
||||||
return;
|
return;
|
||||||
if (cv_useranalog2.value)
|
/*if (cv_useranalog2.value)
|
||||||
CV_SetValue(&cv_analog2, 1);
|
CV_SetValue(&cv_analog2, 1);
|
||||||
else
|
else
|
||||||
CV_SetValue(&cv_analog2, 0);
|
CV_SetValue(&cv_analog2, 0);*/
|
||||||
}
|
}
|
||||||
|
|
||||||
static void UserAnalog3_OnChange(void)
|
static void UserAnalog3_OnChange(void)
|
||||||
{
|
{
|
||||||
if (botingame)
|
if (botingame)
|
||||||
return;
|
return;
|
||||||
if (cv_useranalog3.value)
|
/*if (cv_useranalog3.value)
|
||||||
CV_SetValue(&cv_analog3, 1);
|
CV_SetValue(&cv_analog3, 1);
|
||||||
else
|
else
|
||||||
CV_SetValue(&cv_analog3, 0);
|
CV_SetValue(&cv_analog3, 0);*/
|
||||||
}
|
}
|
||||||
|
|
||||||
static void UserAnalog4_OnChange(void)
|
static void UserAnalog4_OnChange(void)
|
||||||
{
|
{
|
||||||
if (botingame)
|
if (botingame)
|
||||||
return;
|
return;
|
||||||
if (cv_useranalog4.value)
|
/*if (cv_useranalog4.value)
|
||||||
CV_SetValue(&cv_analog4, 1);
|
CV_SetValue(&cv_analog4, 1);
|
||||||
else
|
else
|
||||||
CV_SetValue(&cv_analog4, 0);
|
CV_SetValue(&cv_analog4, 0);*/
|
||||||
}
|
}
|
||||||
|
|
||||||
static void Analog_OnChange(void)
|
static void Analog_OnChange(void)
|
||||||
|
@ -1636,10 +1636,10 @@ static void Analog_OnChange(void)
|
||||||
|
|
||||||
// cameras are not initialized at this point
|
// cameras are not initialized at this point
|
||||||
|
|
||||||
if (!cv_chasecam.value && cv_analog.value) {
|
/*if (!cv_chasecam.value && cv_analog.value) {
|
||||||
CV_SetValue(&cv_analog, 0);
|
CV_SetValue(&cv_analog, 0);
|
||||||
return;
|
return;
|
||||||
}
|
}*/
|
||||||
|
|
||||||
if (cv_analog.value)
|
if (cv_analog.value)
|
||||||
players[consoleplayer].pflags |= PF_ANALOGMODE;
|
players[consoleplayer].pflags |= PF_ANALOGMODE;
|
||||||
|
@ -1656,10 +1656,10 @@ static void Analog2_OnChange(void)
|
||||||
|
|
||||||
// cameras are not initialized at this point
|
// cameras are not initialized at this point
|
||||||
|
|
||||||
if (!cv_chasecam2.value && cv_analog2.value) {
|
/*if (!cv_chasecam2.value && cv_analog2.value) {
|
||||||
CV_SetValue(&cv_analog2, 0);
|
CV_SetValue(&cv_analog2, 0);
|
||||||
return;
|
return;
|
||||||
}
|
}*/
|
||||||
|
|
||||||
if (cv_analog2.value)
|
if (cv_analog2.value)
|
||||||
players[secondarydisplayplayer].pflags |= PF_ANALOGMODE;
|
players[secondarydisplayplayer].pflags |= PF_ANALOGMODE;
|
||||||
|
@ -1676,10 +1676,10 @@ static void Analog3_OnChange(void)
|
||||||
|
|
||||||
// cameras are not initialized at this point
|
// cameras are not initialized at this point
|
||||||
|
|
||||||
if (!cv_chasecam3.value && cv_analog3.value) {
|
/*if (!cv_chasecam3.value && cv_analog3.value) {
|
||||||
CV_SetValue(&cv_analog3, 0);
|
CV_SetValue(&cv_analog3, 0);
|
||||||
return;
|
return;
|
||||||
}
|
}*/
|
||||||
|
|
||||||
if (cv_analog3.value)
|
if (cv_analog3.value)
|
||||||
players[thirddisplayplayer].pflags |= PF_ANALOGMODE;
|
players[thirddisplayplayer].pflags |= PF_ANALOGMODE;
|
||||||
|
@ -1696,10 +1696,10 @@ static void Analog4_OnChange(void)
|
||||||
|
|
||||||
// cameras are not initialized at this point
|
// cameras are not initialized at this point
|
||||||
|
|
||||||
if (!cv_chasecam4.value && cv_analog4.value) {
|
/*if (!cv_chasecam4.value && cv_analog4.value) {
|
||||||
CV_SetValue(&cv_analog4, 0);
|
CV_SetValue(&cv_analog4, 0);
|
||||||
return;
|
return;
|
||||||
}
|
}*/
|
||||||
|
|
||||||
if (cv_analog4.value)
|
if (cv_analog4.value)
|
||||||
players[fourthdisplayplayer].pflags |= PF_ANALOGMODE;
|
players[fourthdisplayplayer].pflags |= PF_ANALOGMODE;
|
||||||
|
|
45
src/info.c
45
src/info.c
|
@ -2564,7 +2564,7 @@ state_t states[NUMSTATES] =
|
||||||
{SPR_RNDM, 21, 3, {NULL}, 0, 0, S_RANDOMITEM23}, // S_RANDOMITEM22
|
{SPR_RNDM, 21, 3, {NULL}, 0, 0, S_RANDOMITEM23}, // S_RANDOMITEM22
|
||||||
{SPR_RNDM, 22, 3, {NULL}, 0, 0, S_RANDOMITEM24}, // S_RANDOMITEM23
|
{SPR_RNDM, 22, 3, {NULL}, 0, 0, S_RANDOMITEM24}, // S_RANDOMITEM23
|
||||||
{SPR_RNDM, 23, 3, {NULL}, 0, 0, S_RANDOMITEM1}, // S_RANDOMITEM24
|
{SPR_RNDM, 23, 3, {NULL}, 0, 0, S_RANDOMITEM1}, // S_RANDOMITEM24
|
||||||
{SPR_RNDM, 0, 1, {A_ItemPop}, 0, 0, S_NULL}, // S_DEADRANDOMITEM
|
{SPR_RNDM, 0, 1, {A_ItemPop}, 0, 0, S_NULL}, // S_DEADRANDOMITEM
|
||||||
|
|
||||||
{SPR_RPOP, FF_FULLBRIGHT, 5, {NULL}, 0, 0, S_RANDOMITEMPOP2}, // S_RANDOMITEMPOP1
|
{SPR_RPOP, FF_FULLBRIGHT, 5, {NULL}, 0, 0, S_RANDOMITEMPOP2}, // S_RANDOMITEMPOP1
|
||||||
{SPR_RPOP, FF_FULLBRIGHT|1, 5, {NULL}, 0, 0, S_RANDOMITEMPOP3}, // S_RANDOMITEMPOP2
|
{SPR_RPOP, FF_FULLBRIGHT|1, 5, {NULL}, 0, 0, S_RANDOMITEMPOP3}, // S_RANDOMITEMPOP2
|
||||||
|
@ -14252,7 +14252,7 @@ mobjinfo_t mobjinfo[NUMMOBJTYPES] =
|
||||||
1000, // spawnhealth
|
1000, // spawnhealth
|
||||||
S_NULL, // seestate
|
S_NULL, // seestate
|
||||||
sfx_None, // seesound
|
sfx_None, // seesound
|
||||||
MT_FLINGRANDOMITEM, // reactiontime
|
0, // reactiontime
|
||||||
sfx_None, // attacksound
|
sfx_None, // attacksound
|
||||||
S_NULL, // painstate
|
S_NULL, // painstate
|
||||||
0, // painchance
|
0, // painchance
|
||||||
|
@ -14267,48 +14267,21 @@ mobjinfo_t mobjinfo[NUMMOBJTYPES] =
|
||||||
36*FRACUNIT, // height
|
36*FRACUNIT, // height
|
||||||
0, // display offset
|
0, // display offset
|
||||||
100, // mass
|
100, // mass
|
||||||
0, // damage
|
MT_RANDOMITEMPOP, // damage
|
||||||
sfx_None, // activesound
|
sfx_None, // activesound
|
||||||
MF_SLIDEME|MF_SPECIAL|MF_NOGRAVITY|MF_NOCLIPHEIGHT, // flags
|
MF_SLIDEME|MF_SPECIAL|MF_NOGRAVITY|MF_NOCLIPHEIGHT, // flags
|
||||||
S_NULL // raisestate
|
S_NULL // raisestate
|
||||||
},
|
},
|
||||||
|
|
||||||
{ // MT_FLINGRANDOMITEM
|
|
||||||
-1, // doomednum
|
|
||||||
S_RANDOMITEM1, // spawnstate
|
|
||||||
1000, // spawnhealth
|
|
||||||
S_NULL, // seestate
|
|
||||||
sfx_None, // seesound
|
|
||||||
MT_FLINGRANDOMITEM, // reactiontime
|
|
||||||
sfx_None, // attacksound
|
|
||||||
S_NULL, // painstate
|
|
||||||
MT_RANDOMITEM, // painchance
|
|
||||||
sfx_None, // painsound
|
|
||||||
S_NULL, // meleestate
|
|
||||||
S_NULL, // missilestate
|
|
||||||
S_DEADRANDOMITEM, // deathstate
|
|
||||||
S_NULL, // xdeathstate
|
|
||||||
sfx_pop, // deathsound
|
|
||||||
60*FRACUNIT, // speed
|
|
||||||
31*FRACUNIT, // radius
|
|
||||||
16*FRACUNIT, // height
|
|
||||||
0, // display offset
|
|
||||||
100, // mass
|
|
||||||
0, // damage
|
|
||||||
sfx_None, // activesound
|
|
||||||
MF_SLIDEME|MF_SPECIAL, // flags
|
|
||||||
S_NULL // raisestate
|
|
||||||
},
|
|
||||||
|
|
||||||
{ // MT_RANDOMITEMPOP
|
{ // MT_RANDOMITEMPOP
|
||||||
-1, // doomednum
|
-1, // doomednum
|
||||||
S_SPRK1, // spawnstate
|
S_INVISIBLE, // spawnstate
|
||||||
1, // spawnhealth
|
1, // spawnhealth
|
||||||
S_NULL, // seestate
|
S_NULL, // seestate
|
||||||
sfx_None, // seesound
|
sfx_None, // seesound
|
||||||
0, // reactiontime
|
0, // reactiontime
|
||||||
sfx_None, // attacksound
|
sfx_None, // attacksound
|
||||||
S_SPRK1, // painstate
|
S_NULL, // painstate
|
||||||
0, // painchance
|
0, // painchance
|
||||||
sfx_None, // painsound
|
sfx_None, // painsound
|
||||||
S_NULL, // meleestate
|
S_NULL, // meleestate
|
||||||
|
@ -14320,7 +14293,7 @@ mobjinfo_t mobjinfo[NUMMOBJTYPES] =
|
||||||
16*FRACUNIT, // radius
|
16*FRACUNIT, // radius
|
||||||
32*FRACUNIT, // height
|
32*FRACUNIT, // height
|
||||||
0, // display offset
|
0, // display offset
|
||||||
100, // mass
|
MT_SPARK, // mass
|
||||||
0, // damage
|
0, // damage
|
||||||
sfx_None, // activesound
|
sfx_None, // activesound
|
||||||
MF_NOCLIP, // flags
|
MF_NOCLIP, // flags
|
||||||
|
@ -14951,10 +14924,10 @@ mobjinfo_t mobjinfo[NUMMOBJTYPES] =
|
||||||
{ // MT_BOMBITEM
|
{ // MT_BOMBITEM
|
||||||
-1, // doomednum
|
-1, // doomednum
|
||||||
S_BOMBAIR, // spawnstate
|
S_BOMBAIR, // spawnstate
|
||||||
105, // spawnhealth
|
1, // spawnhealth
|
||||||
S_NULL, // seestate
|
S_NULL, // seestate
|
||||||
sfx_tossed, // seesound
|
sfx_tossed, // seesound
|
||||||
8, // reactiontime
|
105, // reactiontime
|
||||||
sfx_None, // attacksound
|
sfx_None, // attacksound
|
||||||
S_NULL, // painstate
|
S_NULL, // painstate
|
||||||
288*FRACUNIT, // painchance
|
288*FRACUNIT, // painchance
|
||||||
|
@ -14971,7 +14944,7 @@ mobjinfo_t mobjinfo[NUMMOBJTYPES] =
|
||||||
100, // mass
|
100, // mass
|
||||||
1, // damage
|
1, // damage
|
||||||
sfx_bomb, // activesound
|
sfx_bomb, // activesound
|
||||||
MF_BOUNCE|MF_NOCLIPTHING|MF_MISSILE|MF_SHOOTABLE, // flags
|
MF_BOUNCE|MF_SHOOTABLE, // flags
|
||||||
S_NULL // raisestate
|
S_NULL // raisestate
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
|
@ -3386,6 +3386,7 @@ typedef enum state
|
||||||
S_FLYINGGARG8,
|
S_FLYINGGARG8,
|
||||||
S_LAMPPOST,
|
S_LAMPPOST,
|
||||||
S_MOSSYTREE,
|
S_MOSSYTREE,
|
||||||
|
|
||||||
S_SHADOW,
|
S_SHADOW,
|
||||||
S_WHITESHADOW,
|
S_WHITESHADOW,
|
||||||
|
|
||||||
|
@ -3963,7 +3964,6 @@ typedef enum mobj_type
|
||||||
MT_INVISSPRING,
|
MT_INVISSPRING,
|
||||||
MT_BLUEDIAG,
|
MT_BLUEDIAG,
|
||||||
MT_RANDOMITEM,
|
MT_RANDOMITEM,
|
||||||
MT_FLINGRANDOMITEM,
|
|
||||||
MT_RANDOMITEMPOP,
|
MT_RANDOMITEMPOP,
|
||||||
|
|
||||||
MT_MUSHROOMTRAIL,
|
MT_MUSHROOMTRAIL,
|
||||||
|
@ -4071,6 +4071,7 @@ typedef enum mobj_type
|
||||||
MT_FLYINGGARG,
|
MT_FLYINGGARG,
|
||||||
MT_LAMPPOST,
|
MT_LAMPPOST,
|
||||||
MT_MOSSYTREE,
|
MT_MOSSYTREE,
|
||||||
|
|
||||||
MT_SHADOW,
|
MT_SHADOW,
|
||||||
|
|
||||||
MT_BUMP,
|
MT_BUMP,
|
||||||
|
|
16
src/k_kart.c
16
src/k_kart.c
|
@ -587,7 +587,7 @@ static void K_KartItemRouletteByDistance(player_t *player, ticcmd_t *cmd)
|
||||||
&& players[i].kartstuff[k_position] < player->kartstuff[k_position])
|
&& players[i].kartstuff[k_position] < player->kartstuff[k_position])
|
||||||
pdis += P_AproxDistance(P_AproxDistance(players[i].mo->x - player->mo->x,
|
pdis += P_AproxDistance(P_AproxDistance(players[i].mo->x - player->mo->x,
|
||||||
players[i].mo->y - player->mo->y),
|
players[i].mo->y - player->mo->y),
|
||||||
players[i].mo->z - player->mo->z) / mapheaderinfo[gamemap-1]->mobj_scale
|
players[i].mo->z - player->mo->z) / mapheaderinfo[gamemap-1]->mobj_scale
|
||||||
* (pingame - players[i].kartstuff[k_position])
|
* (pingame - players[i].kartstuff[k_position])
|
||||||
/ ((pingame - 1) * (pingame + 1) / 3);
|
/ ((pingame - 1) * (pingame + 1) / 3);
|
||||||
}
|
}
|
||||||
|
@ -654,7 +654,7 @@ static void K_KartItemRouletteByDistance(player_t *player, ticcmd_t *cmd)
|
||||||
//}
|
//}
|
||||||
/*else if (gametype == GT_NEO)
|
/*else if (gametype == GT_NEO)
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
CONS_Printf("ERROR: P_KartItemRoulette - There's no applicable game type!\n");
|
CONS_Printf("ERROR: P_KartItemRoulette - There's no applicable game type!\n");
|
||||||
|
@ -840,7 +840,7 @@ static void K_UpdateOffroad(player_t *player)
|
||||||
offroadstrength = 3;
|
offroadstrength = 3;
|
||||||
|
|
||||||
// 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
|
//if ((nextsector->special & 256) && nextsector->special != 768
|
||||||
// && nextsector->special != 1024 && nextsector->special != 4864)
|
// && nextsector->special != 1024 && nextsector->special != 4864)
|
||||||
if (offroadstrength)
|
if (offroadstrength)
|
||||||
{
|
{
|
||||||
|
@ -2576,6 +2576,9 @@ static void K_KartUpdatePosition(player_t *player)
|
||||||
|
|
||||||
mo = (mobj_t *)th;
|
mo = (mobj_t *)th;
|
||||||
|
|
||||||
|
if (mo->type != MT_BOSS3WAYPOINT) // TODO: Change to 'MT_WAYPOINT'?
|
||||||
|
continue;
|
||||||
|
|
||||||
pmo = P_AproxDistance(P_AproxDistance( mo->x - player->mo->x,
|
pmo = P_AproxDistance(P_AproxDistance( mo->x - player->mo->x,
|
||||||
mo->y - player->mo->y),
|
mo->y - player->mo->y),
|
||||||
mo->z - player->mo->z) / FRACUNIT;
|
mo->z - player->mo->z) / FRACUNIT;
|
||||||
|
@ -2583,9 +2586,6 @@ static void K_KartUpdatePosition(player_t *player)
|
||||||
mo->y - players[i].mo->y),
|
mo->y - players[i].mo->y),
|
||||||
mo->z - players[i].mo->z) / FRACUNIT;
|
mo->z - players[i].mo->z) / FRACUNIT;
|
||||||
|
|
||||||
if (mo->type != MT_BOSS3WAYPOINT) // TODO: Change to 'MT_WAYPOINT'?
|
|
||||||
continue;
|
|
||||||
|
|
||||||
if (mo->health == player->starpostnum)
|
if (mo->health == player->starpostnum)
|
||||||
{
|
{
|
||||||
player->kartstuff[k_prevcheck] += pmo;
|
player->kartstuff[k_prevcheck] += pmo;
|
||||||
|
@ -4227,7 +4227,7 @@ static void K_DrawKartPositionNum(INT32 num)
|
||||||
// Alternate frame every three frames
|
// Alternate frame every three frames
|
||||||
switch (leveltime % 21)
|
switch (leveltime % 21)
|
||||||
{
|
{
|
||||||
case 1: case 2: case 3:
|
case 1: case 2: case 3:
|
||||||
localpatch = kp_winnernum[0];
|
localpatch = kp_winnernum[0];
|
||||||
break;
|
break;
|
||||||
case 4: case 5: case 6:
|
case 4: case 5: case 6:
|
||||||
|
@ -4998,7 +4998,7 @@ void K_drawKartHUD(void)
|
||||||
{
|
{
|
||||||
if (leveltime < 178)
|
if (leveltime < 178)
|
||||||
K_drawStartLakitu();
|
K_drawStartLakitu();
|
||||||
|
|
||||||
if (stplyr->kartstuff[k_lapanimation])
|
if (stplyr->kartstuff[k_lapanimation])
|
||||||
K_drawLapLakitu();
|
K_drawLapLakitu();
|
||||||
|
|
||||||
|
|
|
@ -740,8 +740,7 @@ static boolean P_LookForShield(mobj_t *actor)
|
||||||
(actor->type == MT_BLUETEAMRING && player->ctfteam != 2))
|
(actor->type == MT_BLUETEAMRING && player->ctfteam != 2))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
// SRB2kart - magnet item
|
if ((player->powers[pw_shield] & SH_NOSTACK) == SH_ATTRACT
|
||||||
if (player->kartstuff[k_magnettimer] //(player->powers[pw_shield] & SH_NOSTACK) == SH_ATTRACT
|
|
||||||
&& (P_AproxDistance(P_AproxDistance(actor->x-player->mo->x, actor->y-player->mo->y), actor->z-player->mo->z) < FixedMul(RING_DIST/4, player->mo->scale)))
|
&& (P_AproxDistance(P_AproxDistance(actor->x-player->mo->x, actor->y-player->mo->y), actor->z-player->mo->z) < FixedMul(RING_DIST/4, player->mo->scale)))
|
||||||
{
|
{
|
||||||
P_SetTarget(&actor->tracer, player->mo);
|
P_SetTarget(&actor->tracer, player->mo);
|
||||||
|
@ -3613,7 +3612,7 @@ void A_AttractChase(mobj_t *actor)
|
||||||
|
|
||||||
// Turn flingrings back into regular rings if attracted.
|
// Turn flingrings back into regular rings if attracted.
|
||||||
if (actor->tracer && actor->tracer->player
|
if (actor->tracer && actor->tracer->player
|
||||||
&& actor->tracer->player->kartstuff[k_magnettimer] //&& (actor->tracer->player->powers[pw_shield] & SH_NOSTACK) != SH_ATTRACT
|
&& (actor->tracer->player->powers[pw_shield] & SH_NOSTACK) != SH_ATTRACT
|
||||||
&& actor->info->reactiontime && actor->type != (mobjtype_t)actor->info->reactiontime)
|
&& actor->info->reactiontime && actor->type != (mobjtype_t)actor->info->reactiontime)
|
||||||
{
|
{
|
||||||
mobj_t *newring;
|
mobj_t *newring;
|
||||||
|
@ -3627,9 +3626,7 @@ void A_AttractChase(mobj_t *actor)
|
||||||
|
|
||||||
P_LookForShield(actor); // Go find 'em, boy!
|
P_LookForShield(actor); // Go find 'em, boy!
|
||||||
|
|
||||||
if (actor->tracer && actor->tracer->player && actor->tracer->player->kartstuff[k_comebackmode] == 1)
|
if (!actor->tracer
|
||||||
;
|
|
||||||
else if (!actor->tracer
|
|
||||||
|| !actor->tracer->player
|
|| !actor->tracer->player
|
||||||
|| !actor->tracer->health
|
|| !actor->tracer->health
|
||||||
|| !P_CheckSight(actor, actor->tracer)) // You have to be able to SEE it...sorta
|
|| !P_CheckSight(actor, actor->tracer)) // You have to be able to SEE it...sorta
|
||||||
|
@ -8094,6 +8091,7 @@ void A_ToggleFlameJet(mobj_t* actor)
|
||||||
void A_ItemPop(mobj_t *actor)
|
void A_ItemPop(mobj_t *actor)
|
||||||
{
|
{
|
||||||
mobj_t *remains;
|
mobj_t *remains;
|
||||||
|
mobjtype_t explode;
|
||||||
#ifdef HAVE_BLUA
|
#ifdef HAVE_BLUA
|
||||||
if (LUA_CallAction("A_ItemPop", actor))
|
if (LUA_CallAction("A_ItemPop", actor))
|
||||||
return;
|
return;
|
||||||
|
@ -8107,12 +8105,24 @@ void A_ItemPop(mobj_t *actor)
|
||||||
}
|
}
|
||||||
|
|
||||||
// de-solidify
|
// de-solidify
|
||||||
//P_UnsetThingPosition(actor);
|
P_UnsetThingPosition(actor);
|
||||||
//actor->flags &= ~MF_SOLID;
|
actor->flags &= ~MF_SOLID;
|
||||||
//actor->flags |= MF_NOCLIP;
|
actor->flags |= MF_NOCLIP;
|
||||||
//P_SetThingPosition(actor);
|
P_SetThingPosition(actor);
|
||||||
|
|
||||||
remains = P_SpawnMobj(actor->x, actor->y, actor->z, MT_RANDOMITEMPOP);
|
// item explosion
|
||||||
|
explode = mobjinfo[actor->info->damage].mass;
|
||||||
|
remains = P_SpawnMobj(actor->x, actor->y,
|
||||||
|
((actor->eflags & MFE_VERTICALFLIP) ? (actor->z + 3*(actor->height/4) - FixedMul(mobjinfo[explode].height, actor->scale)) : (actor->z + actor->height/4)), explode);
|
||||||
|
if (actor->eflags & MFE_VERTICALFLIP)
|
||||||
|
{
|
||||||
|
remains->eflags |= MFE_VERTICALFLIP;
|
||||||
|
remains->flags2 |= MF2_OBJECTFLIP;
|
||||||
|
}
|
||||||
|
remains->destscale = actor->destscale;
|
||||||
|
P_SetScale(remains, actor->scale);
|
||||||
|
|
||||||
|
remains = P_SpawnMobj(actor->x, actor->y, actor->z, actor->info->damage);
|
||||||
remains->type = actor->type; // Transfer type information
|
remains->type = actor->type; // Transfer type information
|
||||||
P_UnsetThingPosition(remains);
|
P_UnsetThingPosition(remains);
|
||||||
if (sector_list)
|
if (sector_list)
|
||||||
|
@ -8120,25 +8130,21 @@ void A_ItemPop(mobj_t *actor)
|
||||||
P_DelSeclist(sector_list);
|
P_DelSeclist(sector_list);
|
||||||
sector_list = NULL;
|
sector_list = NULL;
|
||||||
}
|
}
|
||||||
remains->flags = actor->flags; // Transfer flags
|
|
||||||
P_SetThingPosition(remains);
|
P_SetThingPosition(remains);
|
||||||
|
remains->destscale = actor->destscale;
|
||||||
|
P_SetScale(remains, actor->scale);
|
||||||
|
remains->flags = actor->flags; // Transfer flags
|
||||||
remains->flags2 = actor->flags2; // Transfer flags2
|
remains->flags2 = actor->flags2; // Transfer flags2
|
||||||
remains->fuse = actor->fuse; // Transfer respawn timer
|
remains->fuse = actor->fuse; // Transfer respawn timer
|
||||||
remains->threshold = 68;
|
remains->threshold = 68;
|
||||||
remains->skin = NULL;
|
remains->skin = NULL;
|
||||||
|
remains->spawnpoint = actor->spawnpoint;
|
||||||
|
|
||||||
actor->flags2 |= MF2_BOSSNOTRAP; // Dummy flag to mark this as an exploded TV until it respawns
|
P_SetTarget(&tmthing, remains);
|
||||||
tmthing = remains;
|
|
||||||
|
|
||||||
if (actor->info->deathsound)
|
if (actor->info->deathsound)
|
||||||
S_StartSound(remains, actor->info->deathsound);
|
S_StartSound(remains, actor->info->deathsound);
|
||||||
|
|
||||||
if (actor->type != MT_RANDOMITEM)
|
|
||||||
{
|
|
||||||
P_RemoveMobj(actor);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
actor->target->player->kartstuff[k_itemroulette] = 1;
|
actor->target->player->kartstuff[k_itemroulette] = 1;
|
||||||
|
|
||||||
remains->flags2 &= ~MF2_AMBUSH;
|
remains->flags2 &= ~MF2_AMBUSH;
|
||||||
|
@ -8267,20 +8273,11 @@ void A_BobombExplode(mobj_t *actor)
|
||||||
|
|
||||||
type = (mobjtype_t)locvar1;
|
type = (mobjtype_t)locvar1;
|
||||||
|
|
||||||
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), true, false, actor->target); // 32 <-> 64
|
|
||||||
|
|
||||||
if (actor->target->player)
|
|
||||||
K_SpawnBobombExplosion(actor, actor->target->player->skincolor);
|
|
||||||
else
|
|
||||||
K_SpawnBobombExplosion(actor, SKINCOLOR_RED);
|
|
||||||
|
|
||||||
P_SpawnMobj(actor->x, actor->y, actor->z, MT_BOMBEXPLOSIONSOUND);
|
|
||||||
|
|
||||||
//S_StartSound(actor, sfx_prloop);
|
|
||||||
|
|
||||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
||||||
{
|
{
|
||||||
|
if (P_MobjWasRemoved(actor))
|
||||||
|
return; // There's the possibility these can chain react onto themselves after they've already died if there are enough all in one spot
|
||||||
|
|
||||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
|
@ -8307,6 +8304,17 @@ void A_BobombExplode(mobj_t *actor)
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
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), true, false, actor->target); // 32 <-> 64
|
||||||
|
|
||||||
|
if (actor->target && actor->target->player)
|
||||||
|
K_SpawnBobombExplosion(actor, actor->target->player->skincolor);
|
||||||
|
else
|
||||||
|
K_SpawnBobombExplosion(actor, SKINCOLOR_RED);
|
||||||
|
|
||||||
|
P_SpawnMobj(actor->x, actor->y, actor->z, MT_BOMBEXPLOSIONSOUND);
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
//}
|
//}
|
||||||
|
|
|
@ -1787,7 +1787,7 @@ static mobj_t *SearchMarioNode(msecnode_t *node)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
// Ignore popped monitors, too.
|
// Ignore popped monitors, too.
|
||||||
if (node->m_thing->flags & MF_MONITOR
|
if (node->m_thing->flags & MF_MONITOR || node->m_thing->type == MT_RANDOMITEM
|
||||||
&& node->m_thing->threshold == 68)
|
&& node->m_thing->threshold == 68)
|
||||||
continue;
|
continue;
|
||||||
// Okay, we found something valid.
|
// Okay, we found something valid.
|
||||||
|
|
|
@ -161,9 +161,6 @@ boolean P_CanPickupItem(player_t *player, boolean weapon)
|
||||||
if (G_BattleGametype() && player->kartstuff[k_balloon] <= 0) // No balloons in Match
|
if (G_BattleGametype() && player->kartstuff[k_balloon] <= 0) // No balloons in Match
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
if (player->kartstuff[k_magnettimer]) // You should probably collect stuff when you're attracting it :V
|
|
||||||
return true;
|
|
||||||
|
|
||||||
if (player->kartstuff[k_bootaketimer] || player->kartstuff[k_boostolentimer]
|
if (player->kartstuff[k_bootaketimer] || player->kartstuff[k_boostolentimer]
|
||||||
|| player->kartstuff[k_growshrinktimer] > 1 || player->kartstuff[k_goldshroomtimer]) // Item-specific timer going off
|
|| player->kartstuff[k_growshrinktimer] > 1 || player->kartstuff[k_goldshroomtimer]) // Item-specific timer going off
|
||||||
return false;
|
return false;
|
||||||
|
@ -417,7 +414,6 @@ void P_TouchSpecialThing(mobj_t *special, mobj_t *toucher, boolean heightcheck)
|
||||||
switch (special->type)
|
switch (special->type)
|
||||||
{
|
{
|
||||||
case MT_RANDOMITEM: // SRB2kart
|
case MT_RANDOMITEM: // SRB2kart
|
||||||
case MT_FLINGRANDOMITEM:
|
|
||||||
if (G_BattleGametype() && player->kartstuff[k_balloon] <= 0)
|
if (G_BattleGametype() && player->kartstuff[k_balloon] <= 0)
|
||||||
{
|
{
|
||||||
if (player->kartstuff[k_comebackmode] == 0 && !player->kartstuff[k_comebacktimer])
|
if (player->kartstuff[k_comebackmode] == 0 && !player->kartstuff[k_comebacktimer])
|
||||||
|
@ -450,7 +446,7 @@ void P_TouchSpecialThing(mobj_t *special, mobj_t *toucher, boolean heightcheck)
|
||||||
|
|
||||||
special->momx = special->momy = special->momz = 0;
|
special->momx = special->momy = special->momz = 0;
|
||||||
P_SetTarget(&special->target, toucher);
|
P_SetTarget(&special->target, toucher);
|
||||||
P_SetMobjState(special, special->info->deathstate);
|
P_KillMobj(special, toucher, toucher);
|
||||||
break;
|
break;
|
||||||
// ***************************************** //
|
// ***************************************** //
|
||||||
// Rings, coins, spheres, weapon panels, etc //
|
// Rings, coins, spheres, weapon panels, etc //
|
||||||
|
@ -1553,8 +1549,11 @@ void P_TouchSpecialThing(mobj_t *special, mobj_t *toucher, boolean heightcheck)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
S_StartSound(toucher, special->info->deathsound); // was NULL, but changed to player so you could hear others pick up rings
|
if (!P_MobjWasRemoved(special))
|
||||||
P_KillMobj(special, NULL, toucher);
|
{
|
||||||
|
S_StartSound(toucher, special->info->deathsound); // was NULL, but changed to player so you could hear others pick up rings
|
||||||
|
P_KillMobj(special, NULL, toucher);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
|
@ -2125,7 +2124,7 @@ void P_KillMobj(mobj_t *target, mobj_t *inflictor, mobj_t *source)
|
||||||
// if killed by a player
|
// if killed by a player
|
||||||
if (source && source->player)
|
if (source && source->player)
|
||||||
{
|
{
|
||||||
if (target->flags & MF_MONITOR)
|
if (target->flags & MF_MONITOR || target->type == MT_RANDOMITEM)
|
||||||
{
|
{
|
||||||
P_SetTarget(&target->target, source);
|
P_SetTarget(&target->target, source);
|
||||||
source->player->numboxes++;
|
source->player->numboxes++;
|
||||||
|
|
|
@ -388,7 +388,7 @@ static void P_DoTailsCarry(player_t *sonic, player_t *tails)
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (sonic-players == consoleplayer && botingame)
|
if (sonic-players == consoleplayer && botingame)
|
||||||
CV_SetValue(&cv_analog2, false);
|
//CV_SetValue(&cv_analog2, false);
|
||||||
P_ResetPlayer(sonic);
|
P_ResetPlayer(sonic);
|
||||||
P_SetTarget(&sonic->mo->tracer, tails->mo);
|
P_SetTarget(&sonic->mo->tracer, tails->mo);
|
||||||
sonic->pflags |= PF_CARRIED;
|
sonic->pflags |= PF_CARRIED;
|
||||||
|
@ -401,7 +401,7 @@ static void P_DoTailsCarry(player_t *sonic, player_t *tails)
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
if (sonic-players == consoleplayer && botingame)
|
if (sonic-players == consoleplayer && botingame)
|
||||||
CV_SetValue(&cv_analog2, true);
|
//CV_SetValue(&cv_analog2, true);
|
||||||
sonic->pflags &= ~PF_CARRIED;
|
sonic->pflags &= ~PF_CARRIED;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1593,7 +1593,7 @@ static boolean PIT_CheckThing(mobj_t *thing)
|
||||||
}
|
}
|
||||||
else if (thing->player) {
|
else if (thing->player) {
|
||||||
if (thing->player-players == consoleplayer && botingame)
|
if (thing->player-players == consoleplayer && botingame)
|
||||||
CV_SetValue(&cv_analog2, true);
|
//CV_SetValue(&cv_analog2, true);
|
||||||
thing->player->pflags &= ~PF_CARRIED;
|
thing->player->pflags &= ~PF_CARRIED;
|
||||||
}*/
|
}*/
|
||||||
|
|
||||||
|
|
180
src/p_mobj.c
180
src/p_mobj.c
|
@ -47,6 +47,7 @@ consvar_t cv_splats = {"splats", "On", CV_SAVE, CV_OnOff, NULL, 0, NULL, NULL, 0
|
||||||
actioncache_t actioncachehead;
|
actioncache_t actioncachehead;
|
||||||
|
|
||||||
static mobj_t *overlaycap = NULL;
|
static mobj_t *overlaycap = NULL;
|
||||||
|
static mobj_t *shadowcap = NULL;
|
||||||
|
|
||||||
void P_InitCachedActions(void)
|
void P_InitCachedActions(void)
|
||||||
{
|
{
|
||||||
|
@ -1371,7 +1372,6 @@ fixed_t P_GetMobjGravity(mobj_t *mo)
|
||||||
{
|
{
|
||||||
case MT_FLINGRING:
|
case MT_FLINGRING:
|
||||||
case MT_FLINGCOIN:
|
case MT_FLINGCOIN:
|
||||||
case MT_FLINGRANDOMITEM: // SRB2kart
|
|
||||||
case MT_FLINGEMERALD:
|
case MT_FLINGEMERALD:
|
||||||
case MT_BOUNCERING:
|
case MT_BOUNCERING:
|
||||||
case MT_RAILRING:
|
case MT_RAILRING:
|
||||||
|
@ -2357,7 +2357,6 @@ static boolean P_ZMovement(mobj_t *mo)
|
||||||
case MT_BLUETEAMRING:
|
case MT_BLUETEAMRING:
|
||||||
case MT_FLINGRING:
|
case MT_FLINGRING:
|
||||||
case MT_FLINGCOIN:
|
case MT_FLINGCOIN:
|
||||||
case MT_FLINGRANDOMITEM:
|
|
||||||
case MT_FLINGEMERALD:
|
case MT_FLINGEMERALD:
|
||||||
// Remove flinged stuff from death pits.
|
// Remove flinged stuff from death pits.
|
||||||
if (P_CheckDeathPitCollide(mo))
|
if (P_CheckDeathPitCollide(mo))
|
||||||
|
@ -2550,7 +2549,6 @@ static boolean P_ZMovement(mobj_t *mo)
|
||||||
// Flingrings bounce
|
// Flingrings bounce
|
||||||
if (mo->type == MT_FLINGRING
|
if (mo->type == MT_FLINGRING
|
||||||
|| mo->type == MT_FLINGCOIN
|
|| mo->type == MT_FLINGCOIN
|
||||||
|| mo->type == MT_FLINGRANDOMITEM
|
|
||||||
|| P_WeaponOrPanel(mo->type)
|
|| P_WeaponOrPanel(mo->type)
|
||||||
|| mo->type == MT_FLINGEMERALD
|
|| mo->type == MT_FLINGEMERALD
|
||||||
|| mo->type == MT_BIGTUMBLEWEED
|
|| mo->type == MT_BIGTUMBLEWEED
|
||||||
|
@ -5968,9 +5966,6 @@ void P_Attract(mobj_t *source, mobj_t *dest, boolean nightsgrab) // Home in on y
|
||||||
fixed_t ty = dest->y;
|
fixed_t ty = dest->y;
|
||||||
fixed_t tz = dest->z + (dest->height/2); // Aim for center
|
fixed_t tz = dest->z + (dest->height/2); // Aim for center
|
||||||
|
|
||||||
if (source->type == MT_RANDOMITEM || source->type == MT_FLINGRANDOMITEM) // SRB2kart - item boxes are sorta tall
|
|
||||||
tz = dest->z;
|
|
||||||
|
|
||||||
if (!dest || dest->health <= 0 || !dest->player || !source->tracer)
|
if (!dest || dest->health <= 0 || !dest->player || !source->tracer)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
@ -6252,62 +6247,96 @@ static void P_RemoveOverlay(mobj_t *thing)
|
||||||
|
|
||||||
void P_RunShadows(void)
|
void P_RunShadows(void)
|
||||||
{
|
{
|
||||||
thinker_t * th;
|
mobj_t *mobj;
|
||||||
mobj_t * mobj;
|
mobj_t *next;
|
||||||
|
|
||||||
for (th = thinkercap.next; th != &thinkercap; th = th->next)
|
for (mobj = shadowcap; mobj; mobj = next)
|
||||||
{
|
{
|
||||||
if (th->function.acp1 != (actionf_p1)P_MobjThinker)
|
next = mobj->hnext;
|
||||||
continue;
|
P_SetTarget(&mobj->hnext, NULL);
|
||||||
|
|
||||||
mobj = (mobj_t *)th;
|
if (!mobj->target)
|
||||||
|
continue; // shouldn't you already be dead?
|
||||||
|
|
||||||
if (mobj->type != MT_SHADOW)
|
if ((mobj->target->flags2 & MF2_DONTDRAW)
|
||||||
continue;
|
|| (((mobj->target->eflags & MFE_VERTICALFLIP) && mobj->target->z+mobj->target->height > mobj->target->ceilingz)
|
||||||
|
|| (!(mobj->target->eflags & MFE_VERTICALFLIP) && mobj->target->z < mobj->target->floorz)))
|
||||||
|
mobj->flags2 |= MF2_DONTDRAW;
|
||||||
|
else
|
||||||
|
mobj->flags2 &= ~MF2_DONTDRAW;
|
||||||
|
|
||||||
if (mobj->target)
|
// First scale to the same radius
|
||||||
|
P_SetScale(mobj, FixedDiv(mobj->target->radius, mobj->info->radius));
|
||||||
|
|
||||||
|
P_TeleportMove(mobj, mobj->target->x, mobj->target->y, mobj->target->z);
|
||||||
|
|
||||||
|
if (mobj->floorz < mobj->z)
|
||||||
{
|
{
|
||||||
if ((mobj->target->flags2 & MF2_DONTDRAW)
|
INT32 i;
|
||||||
|| (((mobj->target->eflags & MFE_VERTICALFLIP) && mobj->target->z+mobj->target->height > mobj->target->ceilingz)
|
fixed_t prevz;
|
||||||
|| (!(mobj->target->eflags & MFE_VERTICALFLIP) && mobj->target->z < mobj->target->floorz)))
|
|
||||||
mobj->flags2 |= MF2_DONTDRAW;
|
|
||||||
else
|
|
||||||
mobj->flags2 &= ~MF2_DONTDRAW;
|
|
||||||
|
|
||||||
// First scale to the same radius
|
mobj->z = mobj->floorz;
|
||||||
P_SetScale(mobj, FixedDiv(mobj->target->radius, mobj->info->radius));
|
|
||||||
|
|
||||||
P_TeleportMove(mobj, mobj->target->x, mobj->target->y, mobj->target->z);
|
for (i = 0; i < MAXFFLOORS; i++)
|
||||||
|
|
||||||
if (mobj->floorz < mobj->z)
|
|
||||||
{
|
{
|
||||||
INT32 i;
|
prevz = mobj->z;
|
||||||
fixed_t prevz;
|
|
||||||
|
// Now scale again based on height difference
|
||||||
|
P_SetScale(mobj, FixedDiv(mobj->scale, max(FRACUNIT, ((mobj->target->z-mobj->z)/200)+FRACUNIT)));
|
||||||
|
|
||||||
|
// Check new position to see if you should still be on that ledge
|
||||||
|
P_TeleportMove(mobj, mobj->target->x, mobj->target->y, mobj->z);
|
||||||
|
|
||||||
mobj->z = mobj->floorz;
|
mobj->z = mobj->floorz;
|
||||||
|
|
||||||
for (i = 0; i < MAXFFLOORS; i++)
|
if (mobj->z == prevz)
|
||||||
{
|
break;
|
||||||
prevz = mobj->z;
|
|
||||||
|
|
||||||
// Now scale again based on height difference
|
|
||||||
P_SetScale(mobj, FixedDiv(mobj->scale, max(FRACUNIT, ((mobj->target->z-mobj->z)/200)+FRACUNIT)));
|
|
||||||
|
|
||||||
// Check new position to see if you should still be on that ledge
|
|
||||||
P_TeleportMove(mobj, mobj->target->x, mobj->target->y, mobj->z);
|
|
||||||
|
|
||||||
mobj->z = mobj->floorz;
|
|
||||||
|
|
||||||
if (mobj->z == prevz)
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
|
||||||
P_KillMobj(mobj, NULL, NULL);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
P_SetTarget(&shadowcap, NULL);
|
||||||
|
}
|
||||||
|
|
||||||
|
// called whenever shadows think
|
||||||
|
// It must be done this way so that level changes don't break when the shadowcap can't be reset
|
||||||
|
static void P_AddShadow(mobj_t *thing)
|
||||||
|
{
|
||||||
|
I_Assert(thing != NULL);
|
||||||
|
|
||||||
|
if (shadowcap == NULL)
|
||||||
|
P_SetTarget(&shadowcap, thing);
|
||||||
|
else {
|
||||||
|
mobj_t *mo;
|
||||||
|
for (mo = shadowcap; mo && mo->hnext; mo = mo->hnext)
|
||||||
|
;
|
||||||
|
|
||||||
|
I_Assert(mo != NULL);
|
||||||
|
I_Assert(mo->hnext == NULL);
|
||||||
|
|
||||||
|
P_SetTarget(&mo->hnext, thing);
|
||||||
|
}
|
||||||
|
P_SetTarget(&thing->hnext, NULL);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Called only when MT_SHADOW (or anything else in the shadowcap list) is removed.
|
||||||
|
// Keeps the hnext list from corrupting.
|
||||||
|
static void P_RemoveShadow(mobj_t *thing)
|
||||||
|
{
|
||||||
|
mobj_t *mo;
|
||||||
|
if (shadowcap == thing)
|
||||||
|
{
|
||||||
|
P_SetTarget(&shadowcap, thing->hnext);
|
||||||
|
P_SetTarget(&thing->hnext, NULL);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
for (mo = shadowcap; mo; mo = mo->hnext)
|
||||||
|
if (mo->hnext == thing)
|
||||||
|
{
|
||||||
|
P_SetTarget(&mo->hnext, thing->hnext);
|
||||||
|
P_SetTarget(&thing->hnext, NULL);
|
||||||
|
return;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void A_BossDeath(mobj_t *mo);
|
void A_BossDeath(mobj_t *mo);
|
||||||
|
@ -6506,6 +6535,15 @@ void P_MobjThinker(mobj_t *mobj)
|
||||||
else
|
else
|
||||||
P_AddOverlay(mobj);
|
P_AddOverlay(mobj);
|
||||||
break;
|
break;
|
||||||
|
case MT_SHADOW:
|
||||||
|
if (!mobj->target)
|
||||||
|
{
|
||||||
|
P_RemoveMobj(mobj);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
P_AddShadow(mobj);
|
||||||
|
break;
|
||||||
case MT_BLACKORB:
|
case MT_BLACKORB:
|
||||||
case MT_WHITEORB:
|
case MT_WHITEORB:
|
||||||
case MT_GREENORB:
|
case MT_GREENORB:
|
||||||
|
@ -7696,7 +7734,6 @@ void P_MobjThinker(mobj_t *mobj)
|
||||||
case MT_BLUEBALL:
|
case MT_BLUEBALL:
|
||||||
case MT_REDTEAMRING:
|
case MT_REDTEAMRING:
|
||||||
case MT_BLUETEAMRING:
|
case MT_BLUETEAMRING:
|
||||||
case MT_RANDOMITEM:
|
|
||||||
// No need to check water. Who cares?
|
// No need to check water. Who cares?
|
||||||
P_RingThinker(mobj);
|
P_RingThinker(mobj);
|
||||||
if (mobj->flags2 & MF2_NIGHTSPULL)
|
if (mobj->flags2 & MF2_NIGHTSPULL)
|
||||||
|
@ -7707,7 +7744,6 @@ void P_MobjThinker(mobj_t *mobj)
|
||||||
// Flung items
|
// Flung items
|
||||||
case MT_FLINGRING:
|
case MT_FLINGRING:
|
||||||
case MT_FLINGCOIN:
|
case MT_FLINGCOIN:
|
||||||
case MT_FLINGRANDOMITEM:
|
|
||||||
if (mobj->flags2 & MF2_NIGHTSPULL)
|
if (mobj->flags2 & MF2_NIGHTSPULL)
|
||||||
P_NightsItemChase(mobj);
|
P_NightsItemChase(mobj);
|
||||||
else
|
else
|
||||||
|
@ -7934,17 +7970,23 @@ void P_MobjThinker(mobj_t *mobj)
|
||||||
case MT_BOMBITEM:
|
case MT_BOMBITEM:
|
||||||
if (mobj->momx || mobj->momy)
|
if (mobj->momx || mobj->momy)
|
||||||
P_SpawnGhostMobj(mobj);
|
P_SpawnGhostMobj(mobj);
|
||||||
if (mobj->z <= mobj->floorz)
|
if (P_IsObjectOnGround(mobj))
|
||||||
{
|
{
|
||||||
if (mobj->health > mobj->info->spawnhealth-1)
|
if (mobj->reactiontime >= mobj->info->reactiontime)
|
||||||
{
|
{
|
||||||
if (mobj->state == &states[S_BOMBAIR])
|
if (mobj->state == &states[S_BOMBAIR])
|
||||||
P_SetMobjState(mobj, S_BOMBITEM);
|
P_SetMobjState(mobj, S_BOMBITEM);
|
||||||
|
|
||||||
mobj->momx = mobj->momy = 0;
|
mobj->momx = mobj->momy = 0;
|
||||||
S_StartSound(mobj, mobj->info->activesound);
|
S_StartSound(mobj, mobj->info->activesound);
|
||||||
|
mobj->reactiontime--;
|
||||||
}
|
}
|
||||||
mobj->health--;
|
}
|
||||||
|
if (mobj->reactiontime && mobj->reactiontime < mobj->info->reactiontime)
|
||||||
|
{
|
||||||
|
mobj->reactiontime--;
|
||||||
|
if (!mobj->reactiontime)
|
||||||
|
P_KillMobj(mobj, NULL, NULL);
|
||||||
}
|
}
|
||||||
if (mobj->threshold > 0)
|
if (mobj->threshold > 0)
|
||||||
mobj->threshold--;
|
mobj->threshold--;
|
||||||
|
@ -8239,6 +8281,20 @@ for (i = ((mobj->flags2 & MF2_STRONGBOX) ? strongboxamt : weakboxamt); i; --i) s
|
||||||
}
|
}
|
||||||
P_RemoveMobj(mobj); // make sure they disappear
|
P_RemoveMobj(mobj); // make sure they disappear
|
||||||
return;
|
return;
|
||||||
|
case MT_RANDOMITEM:
|
||||||
|
// Respawn from mapthing if you have one!
|
||||||
|
if (mobj->spawnpoint)
|
||||||
|
{
|
||||||
|
P_SpawnMapThing(mobj->spawnpoint);
|
||||||
|
newmobj = mobj->spawnpoint->mobj; // this is set to the new mobj in P_SpawnMapThing
|
||||||
|
}
|
||||||
|
else
|
||||||
|
newmobj = P_SpawnMobj(mobj->x, mobj->y, mobj->z, mobj->type);
|
||||||
|
|
||||||
|
// Transfer flags2 (strongbox, objectflip)
|
||||||
|
newmobj->flags2 = mobj->flags2;
|
||||||
|
P_RemoveMobj(mobj); // make sure they disappear
|
||||||
|
return;
|
||||||
case MT_METALSONIC_BATTLE:
|
case MT_METALSONIC_BATTLE:
|
||||||
break; // don't remove
|
break; // don't remove
|
||||||
case MT_SPIKE:
|
case MT_SPIKE:
|
||||||
|
@ -8293,7 +8349,6 @@ for (i = ((mobj->flags2 & MF2_STRONGBOX) ? strongboxamt : weakboxamt); i; --i) s
|
||||||
#ifdef ESLOPE // Sliding physics for slidey mobjs!
|
#ifdef ESLOPE // Sliding physics for slidey mobjs!
|
||||||
if (mobj->type == MT_FLINGRING
|
if (mobj->type == MT_FLINGRING
|
||||||
|| mobj->type == MT_FLINGCOIN
|
|| mobj->type == MT_FLINGCOIN
|
||||||
|| mobj->type == MT_FLINGRANDOMITEM
|
|
||||||
|| P_WeaponOrPanel(mobj->type)
|
|| P_WeaponOrPanel(mobj->type)
|
||||||
|| mobj->type == MT_FLINGEMERALD
|
|| mobj->type == MT_FLINGEMERALD
|
||||||
|| mobj->type == MT_BIGTUMBLEWEED
|
|| mobj->type == MT_BIGTUMBLEWEED
|
||||||
|
@ -8737,12 +8792,12 @@ mobj_t *P_SpawnMobj(fixed_t x, fixed_t y, fixed_t z, mobjtype_t type)
|
||||||
case MT_BANANAITEM: case MT_BANANASHIELD:
|
case MT_BANANAITEM: case MT_BANANASHIELD:
|
||||||
case MT_TRIPLEBANANASHIELD1: case MT_TRIPLEBANANASHIELD2: case MT_TRIPLEBANANASHIELD3:
|
case MT_TRIPLEBANANASHIELD1: case MT_TRIPLEBANANASHIELD2: case MT_TRIPLEBANANASHIELD3:
|
||||||
case MT_GREENITEM: case MT_GREENSHIELD:
|
case MT_GREENITEM: case MT_GREENSHIELD:
|
||||||
case MT_TRIPLEGREENSHIELD1: case MT_TRIPLEGREENSHIELD2: case MT_TRIPLEGREENSHIELD3:
|
case MT_TRIPLEGREENSHIELD1: case MT_TRIPLEGREENSHIELD2: case MT_TRIPLEGREENSHIELD3:
|
||||||
case MT_REDITEM: case MT_REDSHIELD: case MT_REDITEMDUD:
|
case MT_REDITEM: case MT_REDSHIELD: case MT_REDITEMDUD:
|
||||||
case MT_TRIPLEREDSHIELD1: case MT_TRIPLEREDSHIELD2: case MT_TRIPLEREDSHIELD3:
|
case MT_TRIPLEREDSHIELD1: case MT_TRIPLEREDSHIELD2: case MT_TRIPLEREDSHIELD3:
|
||||||
case MT_BATTLEBALLOON: case MT_FIREBALL:
|
case MT_BATTLEBALLOON: case MT_FIREBALL:
|
||||||
case MT_FAKEITEM: case MT_FAKESHIELD:
|
case MT_FAKEITEM: case MT_FAKESHIELD:
|
||||||
case MT_BOMBITEM: case MT_BOMBSHIELD:
|
case MT_BOMBITEM: case MT_BOMBSHIELD:
|
||||||
P_SpawnShadowMobj(mobj);
|
P_SpawnShadowMobj(mobj);
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
|
@ -8985,7 +9040,6 @@ void P_RemoveMobj(mobj_t *mobj)
|
||||||
if (mobj->spawnpoint &&
|
if (mobj->spawnpoint &&
|
||||||
(mobj->type == MT_RING
|
(mobj->type == MT_RING
|
||||||
|| mobj->type == MT_COIN
|
|| mobj->type == MT_COIN
|
||||||
|| mobj->type == MT_RANDOMITEM
|
|
||||||
|| mobj->type == MT_BLUEBALL
|
|| mobj->type == MT_BLUEBALL
|
||||||
|| mobj->type == MT_REDTEAMRING
|
|| mobj->type == MT_REDTEAMRING
|
||||||
|| mobj->type == MT_BLUETEAMRING
|
|| mobj->type == MT_BLUETEAMRING
|
||||||
|
@ -9003,6 +9057,9 @@ void P_RemoveMobj(mobj_t *mobj)
|
||||||
if (mobj->type == MT_OVERLAY)
|
if (mobj->type == MT_OVERLAY)
|
||||||
P_RemoveOverlay(mobj);
|
P_RemoveOverlay(mobj);
|
||||||
|
|
||||||
|
if (mobj->type == MT_SHADOW)
|
||||||
|
P_RemoveShadow(mobj);
|
||||||
|
|
||||||
mobj->health = 0; // Just because
|
mobj->health = 0; // Just because
|
||||||
|
|
||||||
// unlink from sector and block lists
|
// unlink from sector and block lists
|
||||||
|
@ -9499,7 +9556,7 @@ void P_RespawnBattleSpecials(void)
|
||||||
// pull it from the que
|
// pull it from the que
|
||||||
iquetail = (iquetail+1)&(ITEMQUESIZE-1);
|
iquetail = (iquetail+1)&(ITEMQUESIZE-1);
|
||||||
}
|
}
|
||||||
|
|
||||||
numgotboxes = 0;
|
numgotboxes = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -10963,7 +11020,7 @@ void P_SpawnHoopsAndRings(mapthing_t *mthing)
|
||||||
mthing->mobj = mobj;
|
mthing->mobj = mobj;
|
||||||
}
|
}
|
||||||
// All manners of rings and coins
|
// All manners of rings and coins
|
||||||
else if (mthing->type == mobjinfo[MT_RING].doomednum || mthing->type == mobjinfo[MT_COIN].doomednum || mthing->type == mobjinfo[MT_RANDOMITEM].doomednum ||
|
else if (mthing->type == mobjinfo[MT_RING].doomednum || mthing->type == mobjinfo[MT_COIN].doomednum ||
|
||||||
mthing->type == mobjinfo[MT_REDTEAMRING].doomednum || mthing->type == mobjinfo[MT_BLUETEAMRING].doomednum)
|
mthing->type == mobjinfo[MT_REDTEAMRING].doomednum || mthing->type == mobjinfo[MT_BLUETEAMRING].doomednum)
|
||||||
{
|
{
|
||||||
mobjtype_t ringthing = MT_RING;
|
mobjtype_t ringthing = MT_RING;
|
||||||
|
@ -10984,9 +11041,6 @@ void P_SpawnHoopsAndRings(mapthing_t *mthing)
|
||||||
case 309: // No team rings in non-CTF
|
case 309: // No team rings in non-CTF
|
||||||
ringthing = (gametype == GT_CTF) ? MT_BLUETEAMRING : MT_RING;
|
ringthing = (gametype == GT_CTF) ? MT_BLUETEAMRING : MT_RING;
|
||||||
break;
|
break;
|
||||||
case 2000: // SRB2kart
|
|
||||||
ringthing = MT_RANDOMITEM;
|
|
||||||
break;
|
|
||||||
default:
|
default:
|
||||||
// Spawn rings as blue spheres in special stages, ala S3+K.
|
// Spawn rings as blue spheres in special stages, ala S3+K.
|
||||||
if (G_IsSpecialStage(gamemap) && useNightsSS)
|
if (G_IsSpecialStage(gamemap) && useNightsSS)
|
||||||
|
|
|
@ -827,7 +827,7 @@ void P_ReloadRings(void)
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (!(mo->type == MT_RING || mo->type == MT_NIGHTSWING || mo->type == MT_COIN
|
if (!(mo->type == MT_RING || mo->type == MT_NIGHTSWING || mo->type == MT_COIN
|
||||||
|| mo->type == MT_BLUEBALL || mo->type == MT_RANDOMITEM))
|
|| mo->type == MT_BLUEBALL))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
// Don't auto-disintegrate things being pulled to us
|
// Don't auto-disintegrate things being pulled to us
|
||||||
|
@ -991,7 +991,7 @@ static void P_LoadThings(void)
|
||||||
|| mt->type == 1702) // MT_AXISTRANSFERLINE
|
|| mt->type == 1702) // MT_AXISTRANSFERLINE
|
||||||
continue; // These were already spawned
|
continue; // These were already spawned
|
||||||
|
|
||||||
if (mt->type == 2000) // MT_RANDOMITEM
|
if (mt->type == MT_RANDOMITEM) // MT_RANDOMITEM
|
||||||
nummapboxes++;
|
nummapboxes++;
|
||||||
|
|
||||||
mt->mobj = NULL;
|
mt->mobj = NULL;
|
||||||
|
@ -2477,7 +2477,7 @@ static void P_LoadRecordGhosts(void)
|
||||||
// Guest ghost
|
// Guest ghost
|
||||||
if (cv_ghost_guest.value && FIL_FileExists(va("%s-guest.lmp", gpath)))
|
if (cv_ghost_guest.value && FIL_FileExists(va("%s-guest.lmp", gpath)))
|
||||||
G_AddGhost(va("%s-guest.lmp", gpath));
|
G_AddGhost(va("%s-guest.lmp", gpath));
|
||||||
|
|
||||||
// Staff Attack ghosts
|
// Staff Attack ghosts
|
||||||
if (cv_ghost_staff.value)
|
if (cv_ghost_staff.value)
|
||||||
{
|
{
|
||||||
|
@ -2918,7 +2918,7 @@ boolean P_SetupLevel(boolean skipprecip)
|
||||||
|
|
||||||
if (!cv_cam2_height.changed)
|
if (!cv_cam2_height.changed)
|
||||||
CV_Set(&cv_cam2_height, cv_cam2_height.defaultvalue);
|
CV_Set(&cv_cam2_height, cv_cam2_height.defaultvalue);
|
||||||
|
|
||||||
if (!cv_cam_dist.changed)
|
if (!cv_cam_dist.changed)
|
||||||
CV_Set(&cv_cam_dist, cv_cam_dist.defaultvalue);
|
CV_Set(&cv_cam_dist, cv_cam_dist.defaultvalue);
|
||||||
|
|
||||||
|
@ -2938,14 +2938,14 @@ boolean P_SetupLevel(boolean skipprecip)
|
||||||
if (!cv_cam4_rotate.changed)
|
if (!cv_cam4_rotate.changed)
|
||||||
CV_Set(&cv_cam4_rotate, cv_cam4_rotate.defaultvalue);
|
CV_Set(&cv_cam4_rotate, cv_cam4_rotate.defaultvalue);
|
||||||
|
|
||||||
if (!cv_analog.changed)
|
/*if (!cv_analog.changed)
|
||||||
CV_SetValue(&cv_analog, 0);
|
CV_SetValue(&cv_analog, 0);
|
||||||
if (!cv_analog2.changed)
|
if (!cv_analog2.changed)
|
||||||
CV_SetValue(&cv_analog2, 0);
|
CV_SetValue(&cv_analog2, 0);
|
||||||
if (!cv_analog3.changed)
|
if (!cv_analog3.changed)
|
||||||
CV_SetValue(&cv_analog3, 0);
|
CV_SetValue(&cv_analog3, 0);
|
||||||
if (!cv_analog4.changed)
|
if (!cv_analog4.changed)
|
||||||
CV_SetValue(&cv_analog4, 0);
|
CV_SetValue(&cv_analog4, 0);*/
|
||||||
|
|
||||||
#ifdef HWRENDER
|
#ifdef HWRENDER
|
||||||
if (rendermode != render_soft && rendermode != render_none)
|
if (rendermode != render_soft && rendermode != render_none)
|
||||||
|
@ -2955,7 +2955,7 @@ boolean P_SetupLevel(boolean skipprecip)
|
||||||
displayplayer = consoleplayer; // Start with your OWN view, please!
|
displayplayer = consoleplayer; // Start with your OWN view, please!
|
||||||
}
|
}
|
||||||
|
|
||||||
if (cv_useranalog.value)
|
/*if (cv_useranalog.value)
|
||||||
CV_SetValue(&cv_analog, true);
|
CV_SetValue(&cv_analog, true);
|
||||||
|
|
||||||
if ((splitscreen && cv_useranalog2.value) || botingame)
|
if ((splitscreen && cv_useranalog2.value) || botingame)
|
||||||
|
@ -2973,7 +2973,7 @@ boolean P_SetupLevel(boolean skipprecip)
|
||||||
CV_SetValue(&cv_analog3, false);
|
CV_SetValue(&cv_analog3, false);
|
||||||
CV_SetValue(&cv_analog2, false);
|
CV_SetValue(&cv_analog2, false);
|
||||||
CV_SetValue(&cv_analog, false);
|
CV_SetValue(&cv_analog, false);
|
||||||
}
|
}*/
|
||||||
|
|
||||||
// SRB2Kart: map load variables
|
// SRB2Kart: map load variables
|
||||||
if (modeattacking)
|
if (modeattacking)
|
||||||
|
|
18
src/p_user.c
18
src/p_user.c
|
@ -889,8 +889,8 @@ void P_ResetPlayer(player_t *player)
|
||||||
player->powers[pw_tailsfly] = 0;
|
player->powers[pw_tailsfly] = 0;
|
||||||
player->onconveyor = 0;
|
player->onconveyor = 0;
|
||||||
player->skidtime = 0;
|
player->skidtime = 0;
|
||||||
if (player-players == consoleplayer && botingame)
|
/*if (player-players == consoleplayer && botingame)
|
||||||
CV_SetValue(&cv_analog2, true);
|
CV_SetValue(&cv_analog2, true);*/
|
||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
|
@ -3738,8 +3738,8 @@ void P_DoJump(player_t *player, boolean soundandstate)
|
||||||
{
|
{
|
||||||
player->mo->momz = 9*FRACUNIT;
|
player->mo->momz = 9*FRACUNIT;
|
||||||
player->pflags &= ~PF_CARRIED;
|
player->pflags &= ~PF_CARRIED;
|
||||||
if (player-players == consoleplayer && botingame)
|
/*if (player-players == consoleplayer && botingame)
|
||||||
CV_SetValue(&cv_analog2, true);
|
CV_SetValue(&cv_analog2, true);*/
|
||||||
}
|
}
|
||||||
else if (player->pflags & PF_ITEMHANG)
|
else if (player->pflags & PF_ITEMHANG)
|
||||||
{
|
{
|
||||||
|
@ -8110,7 +8110,7 @@ static void P_DeathThink(player_t *player)
|
||||||
curlap = 0;
|
curlap = 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((G_RaceGametype() || (gametype == GT_COOP && (multiplayer || netgame))) && (player->lives <= 0))
|
if ((G_RaceGametype() || (gametype == GT_COOP && (multiplayer || netgame))) && (player->lives <= 0))
|
||||||
{
|
{
|
||||||
// Return to level music
|
// Return to level music
|
||||||
|
@ -9137,7 +9137,7 @@ static void P_CalcPostImg(player_t *player)
|
||||||
*param = 5;
|
*param = 5;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (mirrormode) // srb2kart
|
if (mirrormode) // srb2kart
|
||||||
*type = postimg_mirror;
|
*type = postimg_mirror;
|
||||||
}
|
}
|
||||||
|
@ -9444,7 +9444,7 @@ void P_PlayerThink(player_t *player)
|
||||||
mo2 = (mobj_t *)th;
|
mo2 = (mobj_t *)th;
|
||||||
|
|
||||||
if (!(mo2->type == MT_NIGHTSWING || mo2->type == MT_RING || mo2->type == MT_COIN
|
if (!(mo2->type == MT_NIGHTSWING || mo2->type == MT_RING || mo2->type == MT_COIN
|
||||||
|| mo2->type == MT_BLUEBALL || mo2->type == MT_RANDOMITEM))
|
|| mo2->type == MT_BLUEBALL))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if (P_AproxDistance(P_AproxDistance(mo2->x - x, mo2->y - y), mo2->z - z) > FixedMul(128*FRACUNIT, player->mo->scale))
|
if (P_AproxDistance(P_AproxDistance(mo2->x - x, mo2->y - y), mo2->z - z) > FixedMul(128*FRACUNIT, player->mo->scale))
|
||||||
|
@ -9971,8 +9971,8 @@ void P_PlayerAfterThink(player_t *player)
|
||||||
|
|
||||||
P_SetPlayerMobjState(player->mo, S_PLAY_CARRY);
|
P_SetPlayerMobjState(player->mo, S_PLAY_CARRY);
|
||||||
|
|
||||||
if (player-players == consoleplayer && botingame)
|
//if (player-players == consoleplayer && botingame)
|
||||||
CV_SetValue(&cv_analog2, !(player->pflags & PF_CARRIED));
|
//CV_SetValue(&cv_analog2, !(player->pflags & PF_CARRIED));
|
||||||
}
|
}
|
||||||
else if (player->pflags & PF_ITEMHANG && player->mo->tracer)
|
else if (player->pflags & PF_ITEMHANG && player->mo->tracer)
|
||||||
{
|
{
|
||||||
|
|
16
src/r_main.c
16
src/r_main.c
|
@ -234,36 +234,36 @@ void SplitScreen_OnChange(void)
|
||||||
|
|
||||||
static void ChaseCam_OnChange(void)
|
static void ChaseCam_OnChange(void)
|
||||||
{
|
{
|
||||||
if (!cv_chasecam.value || !cv_useranalog.value)
|
/*if (!cv_chasecam.value || !cv_useranalog.value)
|
||||||
CV_SetValue(&cv_analog, 0);
|
CV_SetValue(&cv_analog, 0);
|
||||||
else
|
else
|
||||||
CV_SetValue(&cv_analog, 1);
|
CV_SetValue(&cv_analog, 1);*/
|
||||||
}
|
}
|
||||||
|
|
||||||
static void ChaseCam2_OnChange(void)
|
static void ChaseCam2_OnChange(void)
|
||||||
{
|
{
|
||||||
if (botingame)
|
if (botingame)
|
||||||
return;
|
return;
|
||||||
if (!cv_chasecam2.value || !cv_useranalog2.value)
|
/*if (!cv_chasecam2.value || !cv_useranalog2.value)
|
||||||
CV_SetValue(&cv_analog2, 0);
|
CV_SetValue(&cv_analog2, 0);
|
||||||
else
|
else
|
||||||
CV_SetValue(&cv_analog2, 1);
|
CV_SetValue(&cv_analog2, 1);*/
|
||||||
}
|
}
|
||||||
|
|
||||||
static void ChaseCam3_OnChange(void)
|
static void ChaseCam3_OnChange(void)
|
||||||
{
|
{
|
||||||
if (!cv_chasecam3.value || !cv_useranalog3.value)
|
/*if (!cv_chasecam3.value || !cv_useranalog3.value)
|
||||||
CV_SetValue(&cv_analog3, 0);
|
CV_SetValue(&cv_analog3, 0);
|
||||||
else
|
else
|
||||||
CV_SetValue(&cv_analog3, 1);
|
CV_SetValue(&cv_analog3, 1);*/
|
||||||
}
|
}
|
||||||
|
|
||||||
static void ChaseCam4_OnChange(void)
|
static void ChaseCam4_OnChange(void)
|
||||||
{
|
{
|
||||||
if (!cv_chasecam4.value || !cv_useranalog4.value)
|
/*if (!cv_chasecam4.value || !cv_useranalog4.value)
|
||||||
CV_SetValue(&cv_analog4, 0);
|
CV_SetValue(&cv_analog4, 0);
|
||||||
else
|
else
|
||||||
CV_SetValue(&cv_analog4, 1);
|
CV_SetValue(&cv_analog4, 1);*/
|
||||||
}
|
}
|
||||||
|
|
||||||
static void FlipCam_OnChange(void)
|
static void FlipCam_OnChange(void)
|
||||||
|
|
Loading…
Reference in a new issue