mirror of
https://github.com/ZDoom/raze-gles.git
synced 2025-01-26 08:50:55 +00:00
- removed pointless BOUND_4PIX macro
This commit is contained in:
parent
3220a6d786
commit
cc912fbf93
2 changed files with 9 additions and 16 deletions
|
@ -65,9 +65,6 @@ Prepared for public release: 03/28/2005 - Charlie Wiederhold, 3D Realms
|
||||||
|
|
||||||
#define TRUNC4(x) ((x) & ~3)
|
#define TRUNC4(x) ((x) & ~3)
|
||||||
|
|
||||||
// moves value to closest power of 2 pixel boundry
|
|
||||||
|
|
||||||
#define BOUND_4PIX(x) ( TRUNC4((x) + MOD4(x)) )
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
===========================
|
===========================
|
||||||
|
|
|
@ -53,10 +53,6 @@ ANIMATOR NinjaJumpActionFunc;
|
||||||
#define ACTOR_STD_JUMP (-384)
|
#define ACTOR_STD_JUMP (-384)
|
||||||
int GlobSpeedSO;
|
int GlobSpeedSO;
|
||||||
|
|
||||||
#undef BOUND_4PIX
|
|
||||||
//#define BOUND_4PIX(x) ( TRUNC4((x) + MOD4(x)) )
|
|
||||||
#define BOUND_4PIX(x) (x)
|
|
||||||
|
|
||||||
// determine if moving down the track will get you closer to the player
|
// determine if moving down the track will get you closer to the player
|
||||||
short
|
short
|
||||||
TrackTowardPlayer(SPRITEp sp, TRACKp t, TRACK_POINTp start_point)
|
TrackTowardPlayer(SPRITEp sp, TRACKp t, TRACK_POINTp start_point)
|
||||||
|
@ -1636,8 +1632,8 @@ MovePlayer(PLAYERp pp, SECTOR_OBJECTp sop, int nx, int ny)
|
||||||
pp->RevolveDeltaAng = 0;
|
pp->RevolveDeltaAng = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
pp->posx += BOUND_4PIX(nx);
|
pp->posx += nx;
|
||||||
pp->posy += BOUND_4PIX(ny);
|
pp->posy += ny;
|
||||||
|
|
||||||
if (TEST(sop->flags, SOBJ_DONT_ROTATE))
|
if (TEST(sop->flags, SOBJ_DONT_ROTATE))
|
||||||
{
|
{
|
||||||
|
@ -1664,8 +1660,8 @@ MovePlayer(PLAYERp pp, SECTOR_OBJECTp sop, int nx, int ny)
|
||||||
// Player is NOT moving
|
// Player is NOT moving
|
||||||
|
|
||||||
// Move saved x&y variables
|
// Move saved x&y variables
|
||||||
pp->RevolveX += BOUND_4PIX(nx);
|
pp->RevolveX += nx;
|
||||||
pp->RevolveY += BOUND_4PIX(ny);
|
pp->RevolveY += ny;
|
||||||
|
|
||||||
// Last known angle is now adjusted by the delta angle
|
// Last known angle is now adjusted by the delta angle
|
||||||
pp->RevolveAng = pp->angle.ang - buildang(pp->RevolveDeltaAng);
|
pp->RevolveAng = pp->angle.ang - buildang(pp->RevolveDeltaAng);
|
||||||
|
@ -1705,8 +1701,8 @@ MovePoints(SECTOR_OBJECTp sop, short delta_ang, int nx, int ny)
|
||||||
PlayerMove = false;
|
PlayerMove = false;
|
||||||
|
|
||||||
// move along little midpoint
|
// move along little midpoint
|
||||||
sop->xmid += BOUND_4PIX(nx);
|
sop->xmid += nx;
|
||||||
sop->ymid += BOUND_4PIX(ny);
|
sop->ymid += ny;
|
||||||
|
|
||||||
if (sop->xmid >= MAXSO)
|
if (sop->xmid >= MAXSO)
|
||||||
PlayerMove = false;
|
PlayerMove = false;
|
||||||
|
@ -1738,12 +1734,12 @@ MovePoints(SECTOR_OBJECTp sop, short delta_ang, int nx, int ny)
|
||||||
|
|
||||||
if (wp->extra && TEST(wp->extra, WALLFX_LOOP_OUTER))
|
if (wp->extra && TEST(wp->extra, WALLFX_LOOP_OUTER))
|
||||||
{
|
{
|
||||||
dragpoint(k, wp->x += BOUND_4PIX(nx), wp->y += BOUND_4PIX(ny), 0);
|
dragpoint(k, wp->x += nx, wp->y += ny, 0);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
wp->x += BOUND_4PIX(nx);
|
wp->x += nx;
|
||||||
wp->y += BOUND_4PIX(ny);
|
wp->y += ny;
|
||||||
}
|
}
|
||||||
|
|
||||||
rot_ang = delta_ang;
|
rot_ang = delta_ang;
|
||||||
|
|
Loading…
Reference in a new issue