Merge branch 'master' of http://git.magicalgirl.moe/STJr/SRB2Internal.git into Deez_NewUserXperiences

This commit is contained in:
toasterbabe 2017-04-19 23:03:47 +01:00
commit bef9520556
22 changed files with 335 additions and 237 deletions

View file

@ -1563,8 +1563,6 @@ static void CL_LoadReceivedSavegame(void)
automapactive = false;
// load a base level
playerdeadview = false;
if (P_LoadNetGame())
{
const INT32 actnum = mapheaderinfo[gamemap-1]->actnum;

View file

@ -720,7 +720,6 @@ void D_StartTitle(void)
maptol = 0;
gameaction = ga_nothing;
playerdeadview = false;
displayplayer = consoleplayer = 0;
//demosequence = -1;
gametype = GT_COOP;

View file

@ -34,7 +34,7 @@ void D_SRB2Loop(void) FUNCNORETURN;
// D_SRB2Main()
// Not a globally visible function, just included for source reference,
// calls all startup code, parses command line options.
// If not overrided by user input, calls N_AdvanceDemo.
// If not overrided by user input, calls D_AdvanceDemo.
//
void D_SRB2Main(void);
@ -51,9 +51,6 @@ const char *D_Home(void);
//
// BASE LEVEL
//
void D_PageTicker(void);
// pagename is lumpname of a 320x200 patch to fill the screen
void D_PageDrawer(const char *pagename);
void D_AdvanceDemo(void);
void D_StartTitle(void);

View file

@ -49,7 +49,9 @@ doomcom_t *doomcom = NULL;
/// \brief network packet data, points inside doomcom
doomdata_t *netbuffer = NULL;
#ifdef DEBUGFILE
FILE *debugfile = NULL; // put some net info in a file during the game
#endif
#define MAXREBOUND 8
static doomdata_t reboundstore[MAXREBOUND];

View file

@ -20,6 +20,12 @@
// console vars
extern consvar_t cv_playername;
extern consvar_t cv_playercolor;
extern consvar_t cv_skin;
// secondary splitscreen player
extern consvar_t cv_playername2;
extern consvar_t cv_playercolor2;
extern consvar_t cv_skin2;
#ifdef SEENAMES
extern consvar_t cv_seenames, cv_allowseenames;
#endif
@ -32,7 +38,6 @@ extern consvar_t cv_joyport2;
#endif
extern consvar_t cv_joyscale;
extern consvar_t cv_joyscale2;
extern consvar_t cv_controlperkey;
// splitscreen with second mouse
extern consvar_t cv_mouse2port;
@ -40,11 +45,6 @@ extern consvar_t cv_usemouse2;
#if (defined (__unix__) && !defined (MSDOS)) || defined (UNIXCOMMON)
extern consvar_t cv_mouse2opt;
#endif
extern consvar_t cv_invertmouse2;
extern consvar_t cv_alwaysfreelook2;
extern consvar_t cv_mousemove2;
extern consvar_t cv_mousesens2;
extern consvar_t cv_mouseysens2;
// normally in p_mobj but the .h is not read
extern consvar_t cv_itemrespawntime;
@ -52,13 +52,6 @@ extern consvar_t cv_itemrespawn;
extern consvar_t cv_flagtime;
extern consvar_t cv_skin;
// secondary splitscreen player
extern consvar_t cv_playername2;
extern consvar_t cv_playercolor2;
extern consvar_t cv_skin2;
extern consvar_t cv_touchtag;
extern consvar_t cv_hidetime;
@ -76,9 +69,6 @@ extern consvar_t cv_autobalance;
extern consvar_t cv_teamscramble;
extern consvar_t cv_scrambleonchange;
extern consvar_t cv_useranalog, cv_useranalog2;
extern consvar_t cv_analog, cv_analog2;
extern consvar_t cv_netstat;
#ifdef WALLSPLATS
extern consvar_t cv_splats;
@ -118,17 +108,7 @@ extern consvar_t cv_maxping;
extern consvar_t cv_skipmapcheck;
extern consvar_t cv_sleep, cv_screenshot_option, cv_screenshot_folder;
extern consvar_t cv_moviemode;
extern consvar_t cv_zlib_level, cv_zlib_memory, cv_zlib_strategy;
extern consvar_t cv_zlib_window_bits, cv_zlib_levela, cv_zlib_memorya;
extern consvar_t cv_zlib_strategya, cv_zlib_window_bitsa;
extern consvar_t cv_apng_delay;
extern consvar_t cv_sleep;
typedef enum
{
@ -209,7 +189,6 @@ void Command_ExitGame_f(void);
void Command_Retry_f(void);
void D_GameTypeChanged(INT32 lastgametype); // not a real _OnChange function anymore
void D_MapChange(INT32 pmapnum, INT32 pgametype, boolean pultmode, boolean presetplayers, INT32 pdelay, boolean pskipprecutscene, boolean pfromlevelselect);
void ObjectPlace_OnChange(void);
void ItemFinder_OnChange(void);
void D_SetPassword(const char *pw);

View file

@ -5195,6 +5195,7 @@ static const char *const STATE_LIST[] = { // array length left dynamic for sanit
// Deep Sea Gargoyle
"S_GARGOYLE",
"S_BIGGARGOYLE",
// DSZ Seaweed
"S_SEAWEED1",
@ -5353,7 +5354,14 @@ static const char *const STATE_LIST[] = { // array length left dynamic for sanit
// Xmas-specific stuff
"S_XMASPOLE",
"S_CANDYCANE",
"S_SNOWMAN",
"S_SNOWMAN", // normal
"S_SNOWMANHAT", // with hat + scarf
"S_LAMPPOST1", // normal
"S_LAMPPOST2", // with snow
"S_HANGSTAR",
// Xmas GFZ bushes
"S_XMASBERRYBUSH",
"S_XMASBUSH",
// Botanic Serenity's loads of scenery states
"S_BSZTALLFLOWER_RED",
@ -5545,10 +5553,6 @@ static const char *const STATE_LIST[] = { // array length left dynamic for sanit
"S_PITY4",
"S_PITY5",
"S_PITY6",
"S_PITY7",
"S_PITY8",
"S_PITY9",
"S_PITY10",
"S_FIRS1",
"S_FIRS2",
@ -6567,6 +6571,7 @@ static const char *const MOBJTYPE_LIST[] = { // array length left dynamic for s
// Deep Sea Scenery
"MT_GARGOYLE", // Deep Sea Gargoyle
"MT_BIGGARGOYLE", // Deep Sea Gargoyle (Big)
"MT_SEAWEED", // DSZ Seaweed
"MT_WATERDRIP", // Dripping Water source
"MT_WATERDROP", // Water drop from dripping water
@ -6635,7 +6640,14 @@ static const char *const MOBJTYPE_LIST[] = { // array length left dynamic for s
// Christmas Scenery
"MT_XMASPOLE",
"MT_CANDYCANE",
"MT_SNOWMAN",
"MT_SNOWMAN", // normal
"MT_SNOWMANHAT", // with hat + scarf
"MT_LAMPPOST1", // normal
"MT_LAMPPOST2", // with snow
"MT_HANGSTAR",
// Xmas GFZ bushes
"MT_XMASBERRYBUSH",
"MT_XMASBUSH",
// Botanic Serenity
"MT_BSZTALLFLOWER_RED",

View file

@ -452,19 +452,17 @@ extern mapthing_t *redctfstarts[MAXPLAYERS]; // CTF
#if defined (macintosh)
#define DEBFILE(msg) I_OutputMsg(msg)
extern FILE *debugfile;
#else
#define DEBUGFILE
#ifdef DEBUGFILE
#define DEBFILE(msg) { if (debugfile) { fputs(msg, debugfile); fflush(debugfile); } }
extern FILE *debugfile;
#else
#define DEBFILE(msg) {}
extern FILE *debugfile;
#endif
#endif
#ifdef DEBUGFILE
extern FILE *debugfile;
extern INT32 debugload;
#endif

View file

@ -434,7 +434,6 @@ void F_StartIntro(void)
G_SetGamestate(GS_INTRO);
gameaction = ga_nothing;
playerdeadview = false;
paused = false;
CON_ToggleOff();
CON_ClearHUD();
@ -1125,7 +1124,6 @@ void F_StartCredits(void)
}
gameaction = ga_nothing;
playerdeadview = false;
paused = false;
CON_ToggleOff();
CON_ClearHUD();
@ -1272,7 +1270,6 @@ void F_StartGameEvaluation(void)
G_SaveGame((UINT32)cursaveslot);
gameaction = ga_nothing;
playerdeadview = false;
paused = false;
CON_ToggleOff();
CON_ClearHUD();
@ -1383,7 +1380,6 @@ void F_StartGameEnd(void)
G_SetGamestate(GS_GAMEEND);
gameaction = ga_nothing;
playerdeadview = false;
paused = false;
CON_ToggleOff();
CON_ClearHUD();
@ -1586,7 +1582,6 @@ void F_StartContinue(void)
gameaction = ga_nothing;
keypressed = false;
playerdeadview = false;
paused = false;
CON_ToggleOff();
CON_ClearHUD();
@ -1755,7 +1750,6 @@ void F_StartCustomCutscene(INT32 cutscenenum, boolean precutscene, boolean reset
G_SetGamestate(GS_CUTSCENE);
gameaction = ga_nothing;
playerdeadview = false;
paused = false;
CON_ToggleOff();

View file

@ -3636,7 +3636,6 @@ void G_InitNew(UINT8 pultmode, const char *mapname, boolean resetplayer, boolean
mapmusflags |= MUSIC_RELOADRESET;
ultimatemode = pultmode;
playerdeadview = false;
automapactive = false;
imcontinuing = false;

View file

@ -56,6 +56,9 @@ extern INT16 rw_maximums[NUM_WEAPONS];
// used in game menu
extern consvar_t cv_crosshair, cv_crosshair2;
extern consvar_t cv_invertmouse, cv_alwaysfreelook, cv_mousemove;
extern consvar_t cv_invertmouse2, cv_alwaysfreelook2, cv_mousemove2;
extern consvar_t cv_useranalog, cv_useranalog2;
extern consvar_t cv_analog, cv_analog2;
extern consvar_t cv_sideaxis,cv_turnaxis,cv_moveaxis,cv_lookaxis,cv_fireaxis,cv_firenaxis;
extern consvar_t cv_sideaxis2,cv_turnaxis2,cv_moveaxis2,cv_lookaxis2,cv_fireaxis2,cv_firenaxis2;
extern consvar_t cv_ghost_bestscore, cv_ghost_besttime, cv_ghost_bestrings, cv_ghost_last, cv_ghost_guest;

View file

@ -124,6 +124,8 @@ typedef enum
// mouse values are used once
extern consvar_t cv_mousesens, cv_mouseysens;
extern consvar_t cv_mousesens2, cv_mouseysens2;
extern consvar_t cv_controlperkey;
extern INT32 mousex, mousey;
extern INT32 mlooky; //mousey with mlookSensitivity

View file

@ -564,8 +564,6 @@ static inline void HWR_SubsecPoly(INT32 num, poly_t *poly)
subsector_t *sub;
seg_t *lseg;
sscount++;
sub = &subsectors[num];
count = sub->numlines;
lseg = &segs[sub->firstline];

View file

@ -3367,7 +3367,6 @@ static void HWR_Subsector(size_t num)
if (num < numsubsectors)
{
sscount++;
// subsector
sub = &subsectors[num];
// sector

View file

@ -78,9 +78,6 @@ extern boolean chat_on;
// set true whenever the tab rankings are being shown for any reason
extern boolean hu_showscores;
// P_DeathThink sets this true to show scores while dead, in multiplayer
extern boolean playerdeadview;
// init heads up data at game startup.
void HU_Init(void);

View file

@ -219,9 +219,11 @@ char sprnames[NUMSPRITES + 1][5] =
// Egg Rock Scenery
// Christmas Scenery
"XMS1",
"XMS2",
"XMS3",
"XMS1", // Christmas Pole
"XMS2", // Candy Cane
"XMS3", // Snowman
"XMS4", // Lamppost
"XMS5", // Hanging Star
// Botanic Serenity Scenery
"BSZ1", // Tall flowers
@ -1767,6 +1769,7 @@ state_t states[NUMSTATES] =
// Deep Sea Gargoyle
{SPR_GARG, 0, -1, {NULL}, 0, 0, S_NULL}, // S_GARGOYLE
{SPR_GARG, 1, -1, {NULL}, 0, 0, S_NULL}, // S_BIGGARGOYLE
// DSZ Seaweed
{SPR_SEWE, 0, -1, {NULL}, 0, 0, S_SEAWEED2}, // S_SEAWEED1
@ -1933,6 +1936,13 @@ state_t states[NUMSTATES] =
{SPR_XMS1, 0, -1, {NULL}, 0, 0, S_NULL}, // S_XMASPOLE
{SPR_XMS2, 0, -1, {NULL}, 0, 0, S_NULL}, // S_CANDYCANE
{SPR_XMS3, 0, -1, {NULL}, 0, 0, S_NULL}, // S_SNOWMAN
{SPR_XMS3, 1, -1, {NULL}, 0, 0, S_NULL}, // S_SNOWMANHAT
{SPR_XMS4, 0, -1, {NULL}, 0, 0, S_NULL}, // S_LAMPPOST1
{SPR_XMS4, 1, -1, {NULL}, 0, 0, S_NULL}, // S_LAMPPOST2
{SPR_XMS5, 0, -1, {NULL}, 0, 0, S_NULL}, // S_HANGSTAR
// Xmas GFZ bushes
{SPR_BUS1, 1, -1, {NULL}, 0, 0, S_NULL}, // S_BERRYBUSH
{SPR_BUS2, 1, -1, {NULL}, 0, 0, S_NULL}, // S_BUSH
// Loads of Botanic Serenity bullshit
{SPR_BSZ1, 0, -1, {NULL}, 0, 0, S_NULL}, // S_BSZTALLFLOWER_RED
@ -2122,16 +2132,12 @@ state_t states[NUMSTATES] =
{SPR_ELEM, FF_FULLBRIGHT|20, 1, {NULL}, 0, 0, S_ELEMF10}, // S_ELEMF9
{SPR_NULL, 0, 1, {NULL}, 0, 0, S_ELEMF1 }, // S_ELEMF10
{SPR_PITY, FF_TRANS20 , 1, {NULL}, 0, 0, S_PITY2 }, // S_PITY1
{SPR_PITY, FF_TRANS20|1, 1, {NULL}, 0, 0, S_PITY3 }, // S_PITY2
{SPR_PITY, FF_TRANS20 , 1, {NULL}, 0, 0, S_PITY4 }, // S_PITY3
{SPR_PITY, FF_TRANS20|2, 1, {NULL}, 0, 0, S_PITY5 }, // S_PITY4
{SPR_PITY, FF_TRANS20 , 1, {NULL}, 0, 0, S_PITY6 }, // S_PITY5
{SPR_PITY, FF_TRANS20|3, 1, {NULL}, 0, 0, S_PITY7 }, // S_PITY6
{SPR_PITY, FF_TRANS20 , 1, {NULL}, 0, 0, S_PITY8 }, // S_PITY7
{SPR_PITY, FF_TRANS20|4, 1, {NULL}, 0, 0, S_PITY9 }, // S_PITY8
{SPR_PITY, FF_TRANS20 , 1, {NULL}, 0, 0, S_PITY10}, // S_PITY9
{SPR_PITY, FF_TRANS20|5, 1, {NULL}, 0, 0, S_PITY1 }, // S_PITY10
{SPR_PITY, FF_TRANS30 , 2, {NULL}, 0, 0, S_PITY2}, // S_PITY1
{SPR_PITY, FF_TRANS30|1, 2, {NULL}, 0, 0, S_PITY3}, // S_PITY2
{SPR_PITY, FF_TRANS30|2, 2, {NULL}, 0, 0, S_PITY4}, // S_PITY3
{SPR_PITY, FF_TRANS20|3, 2, {NULL}, 0, 0, S_PITY5}, // S_PITY4
{SPR_PITY, FF_TRANS30|4, 2, {NULL}, 0, 0, S_PITY6}, // S_PITY5
{SPR_PITY, FF_TRANS20|5, 2, {NULL}, 0, 0, S_PITY1}, // S_PITY6
{SPR_FIRS, FF_FULLBRIGHT|FF_TRANS40 , 2, {NULL}, 0, 0, S_FIRS2}, // S_FIRS1
{SPR_FIRS, FF_FULLBRIGHT|FF_TRANS40|1, 2, {NULL}, 0, 0, S_FIRS3}, // S_FIRS2
@ -8147,6 +8153,33 @@ mobjinfo_t mobjinfo[NUMMOBJTYPES] =
S_NULL // raisestate
},
{ // MT_BIGGARGOYLE
1009, // doomednum
S_BIGGARGOYLE, // spawnstate
1000, // spawnhealth
S_NULL, // seestate
sfx_None, // seesound
8, // reactiontime
sfx_None, // attacksound
S_NULL, // painstate
0, // painchance
sfx_None, // painsound
S_NULL, // meleestate
S_NULL, // missilestate
S_NULL, // deathstate
S_NULL, // xdeathstate
sfx_None, // deathsound
12*FRACUNIT, // speed
32*FRACUNIT, // radius
80*FRACUNIT, // height
0, // display offset
100, // mass
1, // damage
sfx_statu2, // activesound
MF_SLIDEME|MF_SOLID|MF_PUSHABLE, // flags
S_NULL // raisestate
},
{ // MT_SEAWEED
1001, // doomednum
S_SEAWEED1, // spawnstate
@ -9515,7 +9548,7 @@ mobjinfo_t mobjinfo[NUMMOBJTYPES] =
sfx_None, // deathsound
25*FRACUNIT, // speed
16*FRACUNIT, // radius
40*FRACUNIT, // height
64*FRACUNIT, // height
0, // display offset
100, // mass
1, // damage
@ -9524,6 +9557,168 @@ mobjinfo_t mobjinfo[NUMMOBJTYPES] =
S_NULL // raisestate
},
{ // MT_SNOWMANHAT
1853, // doomednum
S_SNOWMANHAT, // spawnstate
1000, // spawnhealth
S_NULL, // seestate
sfx_None, // seesound
8, // reactiontime
sfx_None, // attacksound
S_NULL, // painstate
0, // painchance
sfx_None, // painsound
S_NULL, // meleestate
S_NULL, // missilestate
S_NULL, // deathstate
S_NULL, // xdeathstate
sfx_None, // deathsound
25*FRACUNIT, // speed
16*FRACUNIT, // radius
80*FRACUNIT, // height
0, // display offset
100, // mass
1, // damage
sfx_None, // activesound
MF_SLIDEME|MF_SOLID|MF_PUSHABLE, // flags
S_NULL // raisestate
},
{ // MT_LAMPPOST1
1854, // doomednum
S_LAMPPOST1, // spawnstate
1000, // spawnhealth
S_NULL, // seestate
sfx_None, // seesound
8, // reactiontime
sfx_None, // attacksound
S_NULL, // painstate
0, // painchance
sfx_None, // painsound
S_NULL, // meleestate
S_NULL, // missilestate
S_NULL, // deathstate
S_NULL, // xdeathstate
sfx_None, // deathsound
0, // speed
8*FRACUNIT, // radius
120*FRACUNIT, // height
0, // display offset
100, // mass
1, // damage
sfx_None, // activesound
MF_SOLID, // flags
S_NULL // raisestate
},
{ // MT_LAMPPOST2
1855, // doomednum
S_LAMPPOST2, // spawnstate
1000, // spawnhealth
S_NULL, // seestate
sfx_None, // seesound
8, // reactiontime
sfx_None, // attacksound
S_NULL, // painstate
0, // painchance
sfx_None, // painsound
S_NULL, // meleestate
S_NULL, // missilestate
S_NULL, // deathstate
S_NULL, // xdeathstate
sfx_None, // deathsound
0, // speed
8*FRACUNIT, // radius
120*FRACUNIT, // height
0, // display offset
100, // mass
1, // damage
sfx_None, // activesound
MF_SOLID, // flags
S_NULL // raisestate
},
{ // MT_HANGSTAR
1856, // doomednum
S_HANGSTAR, // spawnstate
1000, // spawnhealth
S_NULL, // seestate
sfx_None, // seesound
8, // reactiontime
sfx_None, // attacksound
S_NULL, // painstate
0, // painchance
sfx_None, // painsound
S_NULL, // meleestate
S_NULL, // missilestate
S_NULL, // deathstate
S_NULL, // xdeathstate
sfx_None, // deathsound
0, // speed
4*FRACUNIT, // radius
80*FRACUNIT, // height
0, // display offset
100, // mass
1, // damage
sfx_None, // activesound
MF_NOBLOCKMAP|MF_NOCLIP|MF_SPAWNCEILING|MF_NOGRAVITY|MF_SCENERY, // flags
S_NULL // raisestate
},
{ // MT_XMASBERRYBUSH
1857, // doomednum
S_XMASBERRYBUSH, // spawnstate
1000, // spawnhealth
S_NULL, // seestate
sfx_None, // seesound
8, // reactiontime
sfx_None, // attacksound
S_NULL, // painstate
0, // painchance
sfx_None, // painsound
S_NULL, // meleestate
S_NULL, // missilestate
S_NULL, // deathstate
S_NULL, // xdeathstate
sfx_None, // deathsound
0, // speed
16*FRACUNIT, // radius
32*FRACUNIT, // height
0, // display offset
100, // mass
0, // damage
sfx_None, // activesound
MF_NOTHINK|MF_NOBLOCKMAP|MF_NOCLIP|MF_SCENERY, // flags
S_NULL // raisestate
},
{ // MT_XMASBUSH
1858, // doomednum
S_XMASBUSH, // spawnstate
1000, // spawnhealth
S_NULL, // seestate
sfx_None, // seesound
8, // reactiontime
sfx_None, // attacksound
S_NULL, // painstate
0, // painchance
sfx_None, // painsound
S_NULL, // meleestate
S_NULL, // missilestate
S_NULL, // deathstate
S_NULL, // xdeathstate
sfx_None, // deathsound
0, // speed
16*FRACUNIT, // radius
32*FRACUNIT, // height
0, // display offset
100, // mass
0, // damage
sfx_None, // activesound
MF_NOTHINK|MF_NOBLOCKMAP|MF_NOCLIP|MF_SCENERY, // flags
S_NULL // raisestate
},
// No, I did not do all of this by hand.
// I made a script to make all of these for me.
// Ha HA. ~Inuyasha

View file

@ -425,9 +425,11 @@ typedef enum sprite
// Egg Rock Scenery
// Christmas Scenery
SPR_XMS1,
SPR_XMS2,
SPR_XMS3,
SPR_XMS1, // Christmas Pole
SPR_XMS2, // Candy Cane
SPR_XMS3, // Snowman
SPR_XMS4, // Lamppost
SPR_XMS5, // Hanging Star
// Botanic Serenity Scenery
SPR_BSZ1, // Tall flowers
@ -1975,6 +1977,7 @@ typedef enum state
// Deep Sea Gargoyle
S_GARGOYLE,
S_BIGGARGOYLE,
// DSZ Seaweed
S_SEAWEED1,
@ -2133,7 +2136,14 @@ typedef enum state
// Xmas-specific stuff
S_XMASPOLE,
S_CANDYCANE,
S_SNOWMAN,
S_SNOWMAN, // normal
S_SNOWMANHAT, // with hat + scarf
S_LAMPPOST1, // normal
S_LAMPPOST2, // with snow
S_HANGSTAR,
// Xmas GFZ bushes
S_XMASBERRYBUSH,
S_XMASBUSH,
// Botanic Serenity's loads of scenery states
S_BSZTALLFLOWER_RED,
@ -2325,10 +2335,6 @@ typedef enum state
S_PITY4,
S_PITY5,
S_PITY6,
S_PITY7,
S_PITY8,
S_PITY9,
S_PITY10,
S_FIRS1,
S_FIRS2,
@ -3366,6 +3372,7 @@ typedef enum mobj_type
// Deep Sea Scenery
MT_GARGOYLE, // Deep Sea Gargoyle
MT_BIGGARGOYLE, // Deep Sea Gargoyle (Big)
MT_SEAWEED, // DSZ Seaweed
MT_WATERDRIP, // Dripping Water source
MT_WATERDROP, // Water drop from dripping water
@ -3434,7 +3441,14 @@ typedef enum mobj_type
// Christmas Scenery
MT_XMASPOLE,
MT_CANDYCANE,
MT_SNOWMAN,
MT_SNOWMAN, // normal
MT_SNOWMANHAT, // with hat + scarf
MT_LAMPPOST1, // normal
MT_LAMPPOST2, // with snow
MT_HANGSTAR,
// Xmas GFZ bushes
MT_XMASBERRYBUSH,
MT_XMASBUSH,
// Botanic Serenity scenery
MT_BSZTALLFLOWER_RED,

View file

@ -19,6 +19,7 @@
#include "tables.h"
#include "d_event.h" // Screenshot responder
#include "command.h"
typedef enum {
MM_OFF = 0,
@ -28,6 +29,12 @@ typedef enum {
} moviemode_t;
extern moviemode_t moviemode;
extern consvar_t cv_screenshot_option, cv_screenshot_folder;
extern consvar_t cv_moviemode;
extern consvar_t cv_zlib_memory, cv_zlib_level, cv_zlib_strategy, cv_zlib_window_bits;
extern consvar_t cv_zlib_memorya, cv_zlib_levela, cv_zlib_strategya, cv_zlib_window_bitsa;
extern consvar_t cv_apng_delay;
void M_StartMovie(void);
void M_SaveFrame(void);
void M_StopMovie(void);

View file

@ -72,7 +72,6 @@
// both the head and tail of the thinker list
extern thinker_t thinkercap;
extern INT32 runcount;
void P_InitThinkers(void);
void P_AddThinker(thinker_t *thinker);

View file

@ -8434,6 +8434,10 @@ mobj_t *P_SpawnMobj(fixed_t x, fixed_t y, fixed_t z, mobjtype_t type)
case MT_SPIKE:
mobj->flags2 |= MF2_STANDONME;
break;
case MT_LAMPPOST1:
case MT_LAMPPOST2:
mobj->flags2 |= MF2_STANDONME;
break;
case MT_DETON:
mobj->movedir = 0;
break;

View file

@ -9071,8 +9071,6 @@ void P_DoPityCheck(player_t *player)
// P_PlayerThink
//
boolean playerdeadview; // show match/chaos/tag/capture the flag rankings while in death view
void P_PlayerThink(player_t *player)
{
ticcmd_t *cmd;
@ -9268,10 +9266,6 @@ void P_PlayerThink(player_t *player)
if (player->playerstate == PST_DEAD)
{
player->mo->flags2 &= ~MF2_SHADOW;
// show the multiplayer rankings while dead
if (player == &players[displayplayer])
playerdeadview = true;
P_DeathThink(player);
return;
@ -9292,9 +9286,6 @@ void P_PlayerThink(player_t *player)
player->lives = cv_startinglives.value;
}
if (player == &players[displayplayer])
playerdeadview = false;
if ((gametype == GT_RACE || gametype == GT_COMPETITION) && leveltime < 4*TICRATE)
{
cmd->buttons &= BT_USE; // Remove all buttons except BT_USE

View file

@ -60,7 +60,6 @@ fixed_t projectiony; // aspect ratio
// just for profiling purposes
size_t framecount;
size_t sscount;
size_t loopcount;
fixed_t viewx, viewy, viewz;
@ -491,9 +490,6 @@ static void R_InitTextureMapping(void)
// Take out the fencepost cases from viewangletox.
for (i = 0; i < FINEANGLES/2; i++)
{
t = FixedMul(FINETANGENT(i), focallength);
t = centerx - t;
if (viewangletox[i] == -1)
viewangletox[i] = 0;
else if (viewangletox[i] == viewwidth+1)
@ -806,27 +802,43 @@ void R_SkyboxFrame(player_t *player)
if (viewmobj->spawnpoint)
viewz = ((fixed_t)viewmobj->spawnpoint->angle)<<FRACBITS;
viewx += quake.x;
viewy += quake.y;
viewz += quake.z;
if (mapheaderinfo[gamemap-1])
{
mapheader_t *mh = mapheaderinfo[gamemap-1];
if (player->awayviewtics)
{
if (skyboxmo[1])
vector3_t campos = {0,0,0}; // Position of player's actual view point
if (player->awayviewtics) {
campos.x = player->awayviewmobj->x;
campos.y = player->awayviewmobj->y;
campos.z = player->awayviewmobj->z + 20*FRACUNIT;
} else if (thiscam->chase) {
campos.x = thiscam->x;
campos.y = thiscam->y;
campos.z = thiscam->z + (thiscam->height>>1);
} else {
campos.x = player->mo->x;
campos.y = player->mo->y;
campos.z = player->viewz;
}
// Earthquake effects should be scaled in the skybox
// (if an axis isn't used, the skybox won't shake in that direction)
campos.x += quake.x;
campos.y += quake.y;
campos.z += quake.z;
if (skyboxmo[1]) // Is there a viewpoint?
{
fixed_t x = 0, y = 0;
if (mh->skybox_scalex > 0)
x = (player->awayviewmobj->x - skyboxmo[1]->x) / mh->skybox_scalex;
x = (campos.x - skyboxmo[1]->x) / mh->skybox_scalex;
else if (mh->skybox_scalex < 0)
x = (player->awayviewmobj->x - skyboxmo[1]->x) * -mh->skybox_scalex;
x = (campos.x - skyboxmo[1]->x) * -mh->skybox_scalex;
if (mh->skybox_scaley > 0)
y = (player->awayviewmobj->y - skyboxmo[1]->y) / mh->skybox_scaley;
y = (campos.y - skyboxmo[1]->y) / mh->skybox_scaley;
else if (mh->skybox_scaley < 0)
y = (player->awayviewmobj->y - skyboxmo[1]->y) * -mh->skybox_scaley;
y = (campos.y - skyboxmo[1]->y) * -mh->skybox_scaley;
if (viewmobj->angle == 0)
{
@ -856,103 +868,9 @@ void R_SkyboxFrame(player_t *player)
}
}
if (mh->skybox_scalez > 0)
viewz += (player->awayviewmobj->z + 20*FRACUNIT) / mh->skybox_scalez;
viewz += campos.z / mh->skybox_scalez;
else if (mh->skybox_scalez < 0)
viewz += (player->awayviewmobj->z + 20*FRACUNIT) * -mh->skybox_scalez;
}
else if (thiscam->chase)
{
if (skyboxmo[1])
{
fixed_t x = 0, y = 0;
if (mh->skybox_scalex > 0)
x = (thiscam->x - skyboxmo[1]->x) / mh->skybox_scalex;
else if (mh->skybox_scalex < 0)
x = (thiscam->x - skyboxmo[1]->x) * -mh->skybox_scalex;
if (mh->skybox_scaley > 0)
y = (thiscam->y - skyboxmo[1]->y) / mh->skybox_scaley;
else if (mh->skybox_scaley < 0)
y = (thiscam->y - skyboxmo[1]->y) * -mh->skybox_scaley;
if (viewmobj->angle == 0)
{
viewx += x;
viewy += y;
}
else if (viewmobj->angle == ANGLE_90)
{
viewx -= y;
viewy += x;
}
else if (viewmobj->angle == ANGLE_180)
{
viewx -= x;
viewy -= y;
}
else if (viewmobj->angle == ANGLE_270)
{
viewx += y;
viewy -= x;
}
else
{
angle_t ang = viewmobj->angle>>ANGLETOFINESHIFT;
viewx += FixedMul(x,FINECOSINE(ang)) - FixedMul(y, FINESINE(ang));
viewy += FixedMul(x, FINESINE(ang)) + FixedMul(y,FINECOSINE(ang));
}
}
if (mh->skybox_scalez > 0)
viewz += (thiscam->z + (thiscam->height>>1)) / mh->skybox_scalez;
else if (mh->skybox_scalez < 0)
viewz += (thiscam->z + (thiscam->height>>1)) * -mh->skybox_scalez;
}
else
{
if (skyboxmo[1])
{
fixed_t x = 0, y = 0;
if (mh->skybox_scalex > 0)
x = (player->mo->x - skyboxmo[1]->x) / mh->skybox_scalex;
else if (mh->skybox_scalex < 0)
x = (player->mo->x - skyboxmo[1]->x) * -mh->skybox_scalex;
if (mh->skybox_scaley > 0)
y = (player->mo->y - skyboxmo[1]->y) / mh->skybox_scaley;
else if (mh->skybox_scaley < 0)
y = (player->mo->y - skyboxmo[1]->y) * -mh->skybox_scaley;
if (viewmobj->angle == 0)
{
viewx += x;
viewy += y;
}
else if (viewmobj->angle == ANGLE_90)
{
viewx -= y;
viewy += x;
}
else if (viewmobj->angle == ANGLE_180)
{
viewx -= x;
viewy -= y;
}
else if (viewmobj->angle == ANGLE_270)
{
viewx += y;
viewy -= x;
}
else
{
angle_t ang = viewmobj->angle>>ANGLETOFINESHIFT;
viewx += FixedMul(x,FINECOSINE(ang)) - FixedMul(y, FINESINE(ang));
viewy += FixedMul(x, FINESINE(ang)) + FixedMul(y,FINECOSINE(ang));
}
}
if (mh->skybox_scalez > 0)
viewz += player->viewz / mh->skybox_scalez;
else if (mh->skybox_scalez < 0)
viewz += player->viewz * -mh->skybox_scalez;
}
viewz += campos.z * -mh->skybox_scalez;
}
if (viewmobj->subsector)
@ -963,8 +881,6 @@ void R_SkyboxFrame(player_t *player)
viewsin = FINESINE(viewangle>>ANGLETOFINESHIFT);
viewcos = FINECOSINE(viewangle>>ANGLETOFINESHIFT);
sscount = 0;
// recalc necessary stuff for mouseaiming
// slopes are already calculated for the full possible view (which is 4*viewheight).
@ -1088,8 +1004,6 @@ void R_SetupFrame(player_t *player, boolean skybox)
viewsin = FINESINE(viewangle>>ANGLETOFINESHIFT);
viewcos = FINECOSINE(viewangle>>ANGLETOFINESHIFT);
sscount = 0;
// recalc necessary stuff for mouseaiming
// slopes are already calculated for the full possible view (which is 4*viewheight).

View file

@ -108,7 +108,4 @@ extern angle_t rw_normalangle;
// angle to line origin
extern angle_t rw_angle1;
// Segs count?
extern size_t sscount;
#endif