mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2024-11-16 09:42:57 +00:00
Merge branch 'master' of http://git.magicalgirl.moe/STJr/SRB2Internal into repeat-monitors
This commit is contained in:
commit
9ba43e1d01
21 changed files with 120 additions and 62 deletions
|
@ -103,7 +103,8 @@ set(GIT_EXECUTABLE "git" CACHE FILEPATH "Path to git binary")
|
|||
include(GitUtilities)
|
||||
git_describe(SRB2_GIT_DESCRIBE "${CMAKE_SOURCE_DIR}")
|
||||
git_current_branch(SRB2_GIT_BRANCH "${CMAKE_SOURCE_DIR}")
|
||||
set(SRB2_COMP_REVISION "${SRB2_GIT_DESCRIBE}-<${SRB2_GIT_BRANCH}>")
|
||||
set(SRB2_COMP_BRANCH "${SRB2_GIT_BRANCH}")
|
||||
set(SRB2_COMP_REVISION "${SRB2_GIT_DESCRIBE}")
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/src/config.h.in ${CMAKE_CURRENT_BINARY_DIR}/src/config.h)
|
||||
|
||||
##### PACKAGE CONFIGURATION #####
|
||||
|
|
29
comptime.bat
29
comptime.bat
|
@ -1,10 +1,31 @@
|
|||
@ECHO OFF
|
||||
set REV=Unknown
|
||||
set BRA=Unknown
|
||||
set REV=illegal
|
||||
|
||||
copy nul: /b +%1\comptime.c tmp.$$$ > nul
|
||||
move tmp.$$$ %1\comptime.c > nul
|
||||
SET REV=illegal
|
||||
FOR /F "usebackq" %%s IN (`svnversion %1`) DO @SET REV=%%s
|
||||
|
||||
if exist .git goto gitrev
|
||||
if exist .svn goto svnrev
|
||||
goto filwri
|
||||
|
||||
:gitrev
|
||||
set GIT=%2
|
||||
if "%GIT%"=="" set GIT=git
|
||||
FOR /F "usebackq" %%s IN (`%GIT% rev-parse --abbrev-ref HEAD`) DO @SET BRA=%%s
|
||||
FOR /F "usebackq" %%s IN (`%GIT% rev-parse HEAD`) DO @SET REV=%%s
|
||||
set REV=%REV:~0,8%
|
||||
goto filwri
|
||||
|
||||
:svnrev
|
||||
set BRA=Subversion
|
||||
FOR /F "usebackq" %%s IN (`svnversion .`) DO @SET REV=%%s
|
||||
set REV=r%REV%
|
||||
goto filwri
|
||||
|
||||
:filwri
|
||||
ECHO // Do not edit! This file was autogenerated > %1\comptime.h
|
||||
ECHO // by the %0 batch file >> %1\comptime.h
|
||||
ECHO // >> %1\comptime.h
|
||||
ECHO const char* comprevision = "r%REV%"; >> %1\comptime.h
|
||||
ECHO const char* compbranch = "%BRA%"; >> %1\comptime.h
|
||||
ECHO const char* comprevision = "%REV%"; >> %1\comptime.h
|
||||
|
|
10
comptime.sh
10
comptime.sh
|
@ -5,13 +5,15 @@ if [ x"$1" != x ]; then
|
|||
fi
|
||||
|
||||
versiongit() {
|
||||
gitversion=`git describe`
|
||||
gitbranch=`git rev-parse --abbrev-ref HEAD`
|
||||
gitversion=`git rev-parse HEAD`
|
||||
cat <<EOF > $path/comptime.h
|
||||
|
||||
// Do not edit! This file was autogenerated
|
||||
// by the $0 script with git svn
|
||||
// by the $0 script with git
|
||||
//
|
||||
const char* comprevision = "$gitversion";
|
||||
const char* compbranch = "$gitbranch";
|
||||
const char* comprevision = "${gitversion:0:8}";
|
||||
EOF
|
||||
exit 0
|
||||
}
|
||||
|
@ -23,6 +25,7 @@ versionsvn() {
|
|||
// Do not edit! This file was autogenerated
|
||||
// by the $0 script with subversion
|
||||
//
|
||||
const char* compbranch = "Subversion";
|
||||
const char* comprevision = "r$svnrevision";
|
||||
EOF
|
||||
exit 0
|
||||
|
@ -34,6 +37,7 @@ versionfake() {
|
|||
// Do not edit! This file was autogenerated
|
||||
// by the $0 script with an unknown or nonexist SCM
|
||||
//
|
||||
const char* compbranch = "Unknown";
|
||||
const char* comprevision = "illegal";
|
||||
EOF
|
||||
}
|
||||
|
|
|
@ -9,12 +9,14 @@
|
|||
|
||||
#if (defined(CMAKECONFIG))
|
||||
#include "config.h"
|
||||
const char *compbranch = SRB2_COMP_BRANCH;
|
||||
const char *comprevision = SRB2_COMP_REVISION;
|
||||
|
||||
#elif (defined(COMPVERSION))
|
||||
#include "comptime.h"
|
||||
|
||||
#else
|
||||
const char *compbranch = "Unknown";
|
||||
const char *comprevision = "illegal";
|
||||
|
||||
#endif
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
#define ASSET_HASH_PATCH_DTA "${SRB2_ASSET_patch.dta_HASH}"
|
||||
|
||||
#define SRB2_COMP_REVISION "${SRB2_COMP_REVISION}"
|
||||
#define SRB2_COMP_BRANCH "${SRB2_COMP_BRANCH}"
|
||||
#define SRB2_GIT_DESCRIBE "${SRB2_GIT_DESCRIBE}"
|
||||
#define SRB2_GIT_BRANCH "${SRB2_GIT_BRANCH}"
|
||||
|
||||
|
|
|
@ -3179,7 +3179,11 @@ static void Command_ListWADS_f(void)
|
|||
*/
|
||||
static void Command_Version_f(void)
|
||||
{
|
||||
#ifdef DEVELOP
|
||||
CONS_Printf("Sonic Robo Blast 2 %s-%s (%s %s)\n", compbranch, comprevision, compdate, comptime);
|
||||
#else
|
||||
CONS_Printf("Sonic Robo Blast 2 %s (%s %s %s)\n", VERSIONSTRING, compdate, comptime, comprevision);
|
||||
#endif
|
||||
}
|
||||
|
||||
#ifdef UPDATE_ALERT
|
||||
|
|
|
@ -166,7 +166,7 @@ typedef enum
|
|||
PA_RUN,
|
||||
PA_PAIN,
|
||||
PA_ROLL,
|
||||
PA_JUMP,
|
||||
PA_SPRING,
|
||||
PA_FALL,
|
||||
PA_ABILITY,
|
||||
PA_RIDE
|
||||
|
|
|
@ -3762,6 +3762,7 @@ static const char *const STATE_LIST[] = { // array length left dynamic for sanit
|
|||
"S_PLAY_DASH",
|
||||
"S_PLAY_GASP",
|
||||
"S_PLAY_JUMP",
|
||||
"S_PLAY_SPRING",
|
||||
"S_PLAY_FALL",
|
||||
"S_PLAY_EDGE",
|
||||
"S_PLAY_RIDE",
|
||||
|
@ -3786,6 +3787,7 @@ static const char *const STATE_LIST[] = { // array length left dynamic for sanit
|
|||
"S_PLAY_SUPER_SPIN",
|
||||
"S_PLAY_SUPER_GASP",
|
||||
"S_PLAY_SUPER_JUMP",
|
||||
"S_PLAY_SUPER_SPRING",
|
||||
"S_PLAY_SUPER_FALL",
|
||||
"S_PLAY_SUPER_EDGE",
|
||||
"S_PLAY_SUPER_RIDE",
|
||||
|
@ -7690,7 +7692,7 @@ struct {
|
|||
{"PA_RUN",PA_RUN},
|
||||
{"PA_PAIN",PA_PAIN},
|
||||
{"PA_ROLL",PA_ROLL},
|
||||
{"PA_JUMP",PA_JUMP},
|
||||
{"PA_SPRING",PA_SPRING},
|
||||
{"PA_FALL",PA_FALL},
|
||||
{"PA_ABILITY",PA_ABILITY},
|
||||
{"PA_RIDE",PA_RIDE},
|
||||
|
|
|
@ -142,8 +142,10 @@ extern FILE *logstream;
|
|||
#ifdef DEVELOP
|
||||
#define VERSION 0 // Game version
|
||||
#define SUBVERSION 0 // more precise version number
|
||||
#define VERSIONSTRING "Trunk"
|
||||
#define VERSIONSTRINGW L"Trunk"
|
||||
#define VERSIONSTRING "Development EXE"
|
||||
#define VERSIONSTRINGW L"Development EXE"
|
||||
// most interface strings are ignored in development mode.
|
||||
// we use comprevision and compbranch instead.
|
||||
#else
|
||||
#define VERSION 202 // Game version
|
||||
#define SUBVERSION 0 // more precise version number
|
||||
|
@ -430,7 +432,7 @@ INT32 I_GetKey(void);
|
|||
#endif
|
||||
|
||||
// Compile date and time and revision.
|
||||
extern const char *compdate, *comptime, *comprevision;
|
||||
extern const char *compdate, *comptime, *comprevision, *compbranch;
|
||||
|
||||
// Disabled code and code under testing
|
||||
// None of these that are disabled in the normal build are guaranteed to work perfectly
|
||||
|
|
|
@ -1085,7 +1085,7 @@ void HWR_DrawMD2(gr_vissprite_t *spr)
|
|||
if (!cv_grmd2.value)
|
||||
return;
|
||||
|
||||
if (!spr->precip)
|
||||
if (spr->precip)
|
||||
return;
|
||||
|
||||
// MD2 colormap fix
|
||||
|
|
|
@ -69,6 +69,7 @@ char spr2names[NUMPLAYERSPRITES][5] =
|
|||
"DASH",
|
||||
"GASP",
|
||||
"JUMP",
|
||||
"SPNG",
|
||||
"FALL",
|
||||
"EDGE",
|
||||
"RIDE",
|
||||
|
@ -94,6 +95,7 @@ char spr2names[NUMPLAYERSPRITES][5] =
|
|||
"SSPN",
|
||||
"SGSP",
|
||||
"SJMP",
|
||||
"SSPG",
|
||||
"SFAL",
|
||||
"SEDG",
|
||||
"SRID",
|
||||
|
@ -135,7 +137,8 @@ state_t states[NUMSTATES] =
|
|||
{SPR_PLAY, SPR2_SPIN, 1, {NULL}, 0, 0, S_PLAY_SPIN}, // S_PLAY_SPIN
|
||||
{SPR_PLAY, SPR2_DASH, 2, {NULL}, 0, 0, S_PLAY_DASH}, // S_PLAY_DASH
|
||||
{SPR_PLAY, SPR2_GASP, 14, {NULL}, 0, 0, S_PLAY_WALK}, // S_PLAY_GASP
|
||||
{SPR_PLAY, SPR2_JUMP, 2, {NULL}, 0, 0, S_PLAY_JUMP}, // S_PLAY_JUMP
|
||||
{SPR_PLAY, SPR2_JUMP, 1, {NULL}, 0, 0, S_PLAY_JUMP}, // S_PLAY_JUMP
|
||||
{SPR_PLAY, SPR2_SPNG, 2, {NULL}, 0, 0, S_PLAY_SPRING}, // S_PLAY_SPRING
|
||||
{SPR_PLAY, SPR2_FALL, 2, {NULL}, 0, 0, S_PLAY_FALL}, // S_PLAY_FALL
|
||||
{SPR_PLAY, SPR2_EDGE, 12, {NULL}, 0, 0, S_PLAY_EDGE}, // S_PLAY_EDGE
|
||||
{SPR_PLAY, SPR2_RIDE, 4, {NULL}, 0, 0, S_PLAY_RIDE}, // S_PLAY_RIDE
|
||||
|
@ -159,7 +162,8 @@ state_t states[NUMSTATES] =
|
|||
{SPR_PLAY, SPR2_SDRN, 4, {NULL}, 0, 0, S_PLAY_SUPER_DRWN}, // S_PLAY_SUPER_DRWN
|
||||
{SPR_PLAY, SPR2_SSPN, 1, {NULL}, 0, 0, S_PLAY_SUPER_SPIN}, // S_PLAY_SUPER_SPIN
|
||||
{SPR_PLAY, SPR2_SGSP, 14, {NULL}, 0, 0, S_PLAY_SUPER_WALK}, // S_PLAY_SUPER_GASP
|
||||
{SPR_PLAY, SPR2_SJMP, 2, {NULL}, 0, 0, S_PLAY_SUPER_JUMP}, // S_PLAY_SUPER_JUMP
|
||||
{SPR_PLAY, SPR2_SJMP, 1, {NULL}, 0, 0, S_PLAY_SUPER_JUMP}, // S_PLAY_SUPER_JUMP
|
||||
{SPR_PLAY, SPR2_SSPG, 2, {NULL}, 0, 0, S_PLAY_SUPER_SPRING}, // S_PLAY_SUPER_SPRING
|
||||
{SPR_PLAY, SPR2_SFAL, 2, {NULL}, 0, 0, S_PLAY_SUPER_FALL}, // S_PLAY_SUPER_FALL
|
||||
{SPR_PLAY, SPR2_SEDG, 12, {NULL}, 0, 0, S_PLAY_SUPER_EDGE}, // S_PLAY_SUPER_EDGE
|
||||
{SPR_PLAY, SPR2_SRID, 4, {NULL}, 0, 0, S_PLAY_SUPER_RIDE}, // S_PLAY_SUPER_RIDE
|
||||
|
|
|
@ -594,6 +594,7 @@ enum playersprite
|
|||
SPR2_DASH,
|
||||
SPR2_GASP,
|
||||
SPR2_JUMP,
|
||||
SPR2_SPNG, // spring
|
||||
SPR2_FALL,
|
||||
SPR2_EDGE,
|
||||
SPR2_RIDE,
|
||||
|
@ -619,6 +620,7 @@ enum playersprite
|
|||
SPR2_SSPN,
|
||||
SPR2_SGSP,
|
||||
SPR2_SJMP,
|
||||
SPR2_SSPG,
|
||||
SPR2_SFAL,
|
||||
SPR2_SEDG,
|
||||
SPR2_SRID,
|
||||
|
@ -655,7 +657,8 @@ typedef enum state
|
|||
S_PLAY_SPIN,
|
||||
S_PLAY_DASH,
|
||||
S_PLAY_GASP,
|
||||
S_PLAY_JUMP,
|
||||
S_PLAY_JUMP, // spin jump (todo: make jump separate from spring up for non-spin chars too?)
|
||||
S_PLAY_SPRING,
|
||||
S_PLAY_FALL,
|
||||
S_PLAY_EDGE,
|
||||
S_PLAY_RIDE,
|
||||
|
@ -679,7 +682,8 @@ typedef enum state
|
|||
S_PLAY_SUPER_DRWN,
|
||||
S_PLAY_SUPER_SPIN,
|
||||
S_PLAY_SUPER_GASP,
|
||||
S_PLAY_SUPER_JUMP,
|
||||
S_PLAY_SUPER_JUMP, // see note above
|
||||
S_PLAY_SUPER_SPRING,
|
||||
S_PLAY_SUPER_FALL,
|
||||
S_PLAY_SUPER_EDGE,
|
||||
S_PLAY_SUPER_RIDE,
|
||||
|
|
|
@ -2463,11 +2463,14 @@ void M_Drawer(void)
|
|||
V_DrawThinString(vid.dupx, vid.height - 9*vid.dupy, V_NOSCALESTART|V_TRANSLUCENT|V_ALLOWLOWERCASE, customversionstring);
|
||||
}
|
||||
else
|
||||
#if VERSION > 0 || SUBVERSION > 0
|
||||
{
|
||||
#ifdef DEVELOP // Development -- show revision / branch info
|
||||
V_DrawThinString(vid.dupx, vid.height - 17*vid.dupy, V_NOSCALESTART|V_TRANSLUCENT|V_ALLOWLOWERCASE, compbranch);
|
||||
V_DrawThinString(vid.dupx, vid.height - 9*vid.dupy, V_NOSCALESTART|V_TRANSLUCENT|V_ALLOWLOWERCASE, comprevision);
|
||||
#else // Regular build
|
||||
V_DrawThinString(vid.dupx, vid.height - 9*vid.dupy, V_NOSCALESTART|V_TRANSLUCENT|V_ALLOWLOWERCASE, va("%s", VERSIONSTRING));
|
||||
#else // Trunk build, show revision info
|
||||
V_DrawThinString(vid.dupx, vid.height - 9*vid.dupy, V_NOSCALESTART|V_TRANSLUCENT|V_ALLOWLOWERCASE, va("%s (%s)", VERSIONSTRING, comprevision));
|
||||
#endif
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
10
src/m_misc.c
10
src/m_misc.c
|
@ -1800,16 +1800,14 @@ UINT8 M_HighestBit(UINT32 num)
|
|||
|
||||
const char *GetRevisionString(void)
|
||||
{
|
||||
INT32 vinfo;
|
||||
static char rev[8] = {0};
|
||||
static char rev[9] = {0};
|
||||
if (rev[0])
|
||||
return rev;
|
||||
|
||||
vinfo = atoi(&comprevision[1]);
|
||||
if (vinfo)
|
||||
snprintf(rev, 7, "r%d", vinfo);
|
||||
if (comprevision[0] == 'r')
|
||||
strncpy(rev, comprevision, 7);
|
||||
else
|
||||
strcpy(rev, "rNULL");
|
||||
snprintf(rev, 7, "r%s", comprevision);
|
||||
rev[7] = '\0';
|
||||
|
||||
return rev;
|
||||
|
|
|
@ -199,7 +199,7 @@ boolean P_DoSpring(mobj_t *spring, mobj_t *object)
|
|||
P_ResetPlayer(object->player);
|
||||
|
||||
if (P_MobjFlip(object)*vertispeed > 0)
|
||||
P_SetPlayerMobjState(object, S_PLAY_JUMP);
|
||||
P_SetPlayerMobjState(object, S_PLAY_SPRING);
|
||||
else if (P_MobjFlip(object)*vertispeed < 0)
|
||||
P_SetPlayerMobjState(object, S_PLAY_FALL);
|
||||
else // horizontal spring
|
||||
|
@ -213,7 +213,7 @@ boolean P_DoSpring(mobj_t *spring, mobj_t *object)
|
|||
if (spring->info->painchance)
|
||||
{
|
||||
object->player->pflags |= PF_JUMPED;
|
||||
P_SetPlayerMobjState(object, S_PLAY_SPIN);
|
||||
P_SetPlayerMobjState(object, S_PLAY_JUMP);
|
||||
}
|
||||
}
|
||||
return true;
|
||||
|
@ -1929,7 +1929,7 @@ boolean P_TryMove(mobj_t *thing, fixed_t x, fixed_t y, boolean allowdropoff)
|
|||
|
||||
// Don't 'step up' while springing,
|
||||
// Only step up "if needed".
|
||||
if (thing->player->panim == PA_JUMP
|
||||
if (thing->player->panim == PA_SPRING
|
||||
&& P_MobjFlip(thing)*thing->momz > FixedMul(FRACUNIT, thing->scale))
|
||||
maxstep = 0;
|
||||
}
|
||||
|
|
22
src/p_mobj.c
22
src/p_mobj.c
|
@ -163,7 +163,11 @@ boolean P_SetPlayerMobjState(mobj_t *mobj, statenum_t state)
|
|||
case S_PLAY_GASP:
|
||||
return P_SetPlayerMobjState(mobj, S_PLAY_SUPER_GASP);
|
||||
case S_PLAY_JUMP:
|
||||
if (!(player->charflags & SF_SUPERSPIN))
|
||||
return true;
|
||||
return P_SetPlayerMobjState(mobj, S_PLAY_SUPER_JUMP);
|
||||
case S_PLAY_SPRING:
|
||||
return P_SetPlayerMobjState(mobj, S_PLAY_SUPER_SPRING);
|
||||
case S_PLAY_FALL:
|
||||
return P_SetPlayerMobjState(mobj, S_PLAY_SUPER_FALL);
|
||||
case S_PLAY_EDGE:
|
||||
|
@ -209,12 +213,14 @@ boolean P_SetPlayerMobjState(mobj_t *mobj, statenum_t state)
|
|||
break;
|
||||
case S_PLAY_SPIN:
|
||||
case S_PLAY_DASH:
|
||||
case S_PLAY_JUMP:
|
||||
case S_PLAY_SUPER_SPIN:
|
||||
case S_PLAY_SUPER_JUMP:
|
||||
player->panim = PA_ROLL;
|
||||
break;
|
||||
case S_PLAY_JUMP:
|
||||
case S_PLAY_SUPER_JUMP:
|
||||
player->panim = PA_JUMP;
|
||||
case S_PLAY_SPRING:
|
||||
case S_PLAY_SUPER_SPRING:
|
||||
player->panim = PA_SPRING;
|
||||
break;
|
||||
case S_PLAY_FALL:
|
||||
case S_PLAY_SUPER_FALL:
|
||||
|
@ -317,9 +323,12 @@ boolean P_SetPlayerMobjState(mobj_t *mobj, statenum_t state)
|
|||
spr2 = SPR2_SPIN;
|
||||
break;
|
||||
case SPR2_GASP:
|
||||
spr2 = SPR2_JUMP;
|
||||
spr2 = SPR2_SPNG;
|
||||
break;
|
||||
case SPR2_JUMP:
|
||||
spr2 = SPR2_SPIN;
|
||||
break;
|
||||
case SPR2_SPNG: // spring
|
||||
spr2 = SPR2_FALL;
|
||||
break;
|
||||
case SPR2_FALL:
|
||||
|
@ -330,7 +339,7 @@ boolean P_SetPlayerMobjState(mobj_t *mobj, statenum_t state)
|
|||
break;
|
||||
|
||||
case SPR2_FLY:
|
||||
spr2 = SPR2_JUMP;
|
||||
spr2 = SPR2_SPNG;
|
||||
break;
|
||||
case SPR2_TIRE:
|
||||
spr2 = SPR2_FLY;
|
||||
|
@ -379,6 +388,9 @@ boolean P_SetPlayerMobjState(mobj_t *mobj, statenum_t state)
|
|||
case SPR2_SJMP:
|
||||
spr2 = SPR2_JUMP;
|
||||
break;
|
||||
case SPR2_SSPG:
|
||||
spr2 = SPR2_SPNG;
|
||||
break;
|
||||
case SPR2_SFAL:
|
||||
spr2 = SPR2_FALL;
|
||||
break;
|
||||
|
|
43
src/p_user.c
43
src/p_user.c
|
@ -1598,7 +1598,7 @@ void P_DoPlayerExit(player_t *player)
|
|||
{
|
||||
player->climbing = 0;
|
||||
player->pflags |= PF_JUMPED;
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_SPIN);
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_JUMP);
|
||||
}
|
||||
player->powers[pw_underwater] = 0;
|
||||
player->powers[pw_spacetime] = 0;
|
||||
|
@ -2666,21 +2666,21 @@ static void P_DoClimbing(player_t *player)
|
|||
|
||||
player->climbing = 0;
|
||||
player->pflags |= PF_JUMPED;
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_SPIN);
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_JUMP);
|
||||
}
|
||||
|
||||
if (skyclimber)
|
||||
{
|
||||
player->climbing = 0;
|
||||
player->pflags |= PF_JUMPED;
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_SPIN);
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_JUMP);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
player->climbing = 0;
|
||||
player->pflags |= PF_JUMPED;
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_SPIN);
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_JUMP);
|
||||
}
|
||||
|
||||
if (cmd->sidemove != 0 || cmd->forwardmove != 0)
|
||||
|
@ -2698,7 +2698,7 @@ static void P_DoClimbing(player_t *player)
|
|||
{
|
||||
player->climbing = 0;
|
||||
player->pflags |= PF_JUMPED;
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_SPIN);
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_JUMP);
|
||||
P_SetObjectMomZ(player->mo, 4*FRACUNIT, false);
|
||||
P_InstaThrust(player->mo, player->mo->angle, FixedMul(-4*FRACUNIT, player->mo->scale));
|
||||
}
|
||||
|
@ -2709,7 +2709,7 @@ static void P_DoClimbing(player_t *player)
|
|||
localangle2 = player->mo->angle;
|
||||
|
||||
if (player->climbing == 0)
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_SPIN);
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_JUMP);
|
||||
|
||||
if (player->climbing && P_IsObjectOnGround(player->mo))
|
||||
{
|
||||
|
@ -3497,8 +3497,9 @@ static void P_DoSuperStuff(player_t *player)
|
|||
|
||||
if (player->mo->health > 0)
|
||||
{
|
||||
if ((player->pflags & PF_JUMPED || player->pflags & PF_SPINNING)
|
||||
&& player->mo->state-states != S_PLAY_DASH)
|
||||
if (player->pflags & PF_JUMPED)
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_JUMP);
|
||||
else if (player->pflags & PF_SPINNING && player->mo->state-states != S_PLAY_DASH)
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_SPIN);
|
||||
else switch (player->mo->state-states)
|
||||
{
|
||||
|
@ -3516,8 +3517,8 @@ static void P_DoSuperStuff(player_t *player)
|
|||
case S_PLAY_SUPER_PAIN:
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_PAIN);
|
||||
break;
|
||||
case S_PLAY_SUPER_JUMP:
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_JUMP);
|
||||
case S_PLAY_SUPER_SPRING:
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_SPRING);
|
||||
break;
|
||||
case S_PLAY_SUPER_FALL:
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_FALL);
|
||||
|
@ -3737,9 +3738,9 @@ void P_DoJump(player_t *player, boolean soundandstate)
|
|||
S_StartSound(player->mo, sfx_jump); // Play jump sound!
|
||||
|
||||
if (!(player->charability2 == CA2_SPINDASH))
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_JUMP);
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_SPRING);
|
||||
else
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_SPIN);
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_JUMP);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -6516,10 +6517,10 @@ static void P_MovePlayer(player_t *player)
|
|||
}
|
||||
|
||||
// If Springing, but travelling DOWNWARD, change back!
|
||||
if (player->panim == PA_JUMP && P_MobjFlip(player->mo)*player->mo->momz < 0)
|
||||
if (player->panim == PA_SPRING && P_MobjFlip(player->mo)*player->mo->momz < 0)
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_FALL);
|
||||
// If Springing but on the ground, change back!
|
||||
else if (onground && (player->panim == PA_JUMP || player->panim == PA_FALL || player->panim == PA_RIDE) && !player->mo->momz)
|
||||
else if (onground && (player->panim == PA_SPRING || player->panim == PA_FALL || player->panim == PA_RIDE) && !player->mo->momz)
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_STND);
|
||||
|
||||
// If you are stopped and are still walking, stand still!
|
||||
|
@ -6558,7 +6559,7 @@ static void P_MovePlayer(player_t *player)
|
|||
else
|
||||
{
|
||||
player->pflags |= PF_JUMPED;
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_SPIN);
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_JUMP);
|
||||
}
|
||||
}
|
||||
player->pflags &= ~PF_GLIDING;
|
||||
|
@ -6616,7 +6617,7 @@ static void P_MovePlayer(player_t *player)
|
|||
|| (player->powers[pw_super] && ALL7EMERALDS(player->powers[pw_emeralds]) && player->charability == CA_GLIDEANDCLIMB))
|
||||
{
|
||||
player->pflags |= PF_JUMPED;
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_SPIN);
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_JUMP);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -6686,7 +6687,7 @@ static void P_MovePlayer(player_t *player)
|
|||
else
|
||||
{
|
||||
player->pflags |= PF_JUMPED;
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_SPIN);
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_JUMP);
|
||||
}
|
||||
}
|
||||
player->powers[pw_tailsfly] = 0;
|
||||
|
@ -7266,7 +7267,7 @@ static void P_DoRopeHang(player_t *player)
|
|||
|
||||
if (!(player->pflags & PF_SLIDING) && (player->pflags & PF_JUMPED)
|
||||
&& !(player->panim == PA_ROLL) && player->charability2 == CA2_SPINDASH)
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_SPIN);
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_JUMP);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -7383,7 +7384,7 @@ static void P_DoRopeHang(player_t *player)
|
|||
|
||||
if (!(player->pflags & PF_SLIDING) && (player->pflags & PF_JUMPED)
|
||||
&& !(player->panim == PA_ROLL) && player->charability2 == CA2_SPINDASH)
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_SPIN);
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_JUMP);
|
||||
}
|
||||
|
||||
P_SetTarget(&player->mo->tracer, NULL);
|
||||
|
@ -8699,7 +8700,7 @@ void P_PlayerThink(player_t *player)
|
|||
P_SetPlayerMobjState(player->mo, S_PLAY_GLIDE);
|
||||
}
|
||||
else if ((player->pflags & PF_JUMPED) && !player->powers[pw_super] && player->panim != PA_ROLL && player->charability2 == CA2_SPINDASH)
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_SPIN);
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_JUMP);
|
||||
|
||||
if (player->flashcount)
|
||||
player->flashcount--;
|
||||
|
@ -9327,7 +9328,7 @@ void P_PlayerAfterThink(player_t *player)
|
|||
&& ((!player->powers[pw_super] && player->panim != PA_ROLL)
|
||||
|| player->mo->state == &states[player->mo->info->painstate])
|
||||
&& player->charability2 == CA2_SPINDASH)
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_SPIN);
|
||||
P_SetPlayerMobjState(player->mo, S_PLAY_JUMP);
|
||||
|
||||
if (player->pflags & PF_CARRIED && player->mo->tracer)
|
||||
{
|
||||
|
|
|
@ -2665,9 +2665,6 @@ next_token:
|
|||
}
|
||||
free(buf2);
|
||||
|
||||
if (skin != &skins[0])
|
||||
skin->flags &= ~SF_SUPER;
|
||||
|
||||
// Add sprites
|
||||
{
|
||||
UINT16 z;
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
#ifdef CMAKECONFIG
|
||||
#include "config.h"
|
||||
#else
|
||||
#include "config.h.in"
|
||||
#include "../config.h.in"
|
||||
#endif
|
||||
|
||||
#ifndef _WIN32_WCE
|
||||
|
|
|
@ -217,10 +217,12 @@ static void SDLSetMode(INT32 width, INT32 height, SDL_bool fullscreen)
|
|||
}
|
||||
}
|
||||
|
||||
#ifdef HWRENDER
|
||||
if (rendermode == render_opengl)
|
||||
{
|
||||
OglSdlSurface(vid.width, vid.height);
|
||||
}
|
||||
#endif
|
||||
|
||||
if (rendermode == render_soft)
|
||||
{
|
||||
|
@ -401,9 +403,11 @@ static INT32 Impl_SDL_Scancode_To_Keycode(SDL_Scancode code)
|
|||
default:
|
||||
break;
|
||||
}
|
||||
#ifdef HWRENDER
|
||||
DBG_Printf("Unknown incoming scancode: %d, represented %c\n",
|
||||
code,
|
||||
SDL_GetKeyName(SDL_GetKeyFromScancode(code)));
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
|
@ -16,8 +16,6 @@
|
|||
|
||||
#ifdef HWRENDER
|
||||
#include "hardware/hw_data.h"
|
||||
#else
|
||||
typedef void GLPatch_t;
|
||||
#endif
|
||||
|
||||
#ifdef __GNUG__
|
||||
|
|
Loading…
Reference in a new issue