clipmove/pushmove parameter const correctness

git-svn-id: https://svn.eduke32.com/eduke32@7567 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
terminx 2019-04-10 09:30:41 +00:00 committed by Christoph Oelckers
parent 1ab7175c90
commit b7d06c0bd8
2 changed files with 13 additions and 13 deletions

View file

@ -92,12 +92,12 @@ int sectoradjacent(int sect1, int sect2);
extern int32_t clipmoveboxtracenum;
int32_t clipmove(vec3_t *pos, int16_t *sectnum, int32_t xvect, int32_t yvect, int32_t walldist, int32_t ceildist,
int32_t flordist, uint32_t cliptype) ATTRIBUTE((nonnull(1, 2)));
int32_t clipmovex(vec3_t *pos, int16_t *sectnum, int32_t xvect, int32_t yvect, int32_t walldist, int32_t ceildist,
int32_t flordist, uint32_t cliptype, uint8_t noslidep) ATTRIBUTE((nonnull(1, 2)));
int32_t pushmove(vec3_t *vect, int16_t *sectnum, int32_t walldist, int32_t ceildist, int32_t flordist,
uint32_t cliptype) ATTRIBUTE((nonnull(1, 2)));
int32_t clipmove(vec3_t * const pos, int16_t * const sectnum, int32_t xvect, int32_t yvect, int32_t const walldist, int32_t const ceildist,
int32_t const flordist, uint32_t const cliptype) ATTRIBUTE((nonnull(1, 2)));
int32_t clipmovex(vec3_t * const pos, int16_t * const sectnum, int32_t xvect, int32_t yvect, int32_t const walldist, int32_t const ceildist,
int32_t const flordist, uint32_t const cliptype, uint8_t const noslidep) ATTRIBUTE((nonnull(1, 2)));
int32_t pushmove(vec3_t * const vect, int16_t * const sectnum, int32_t const walldist, int32_t const ceildist, int32_t const flordist,
uint32_t const cliptype) ATTRIBUTE((nonnull(1, 2)));
#ifdef __cplusplus
}

View file

@ -790,8 +790,8 @@ static int32_t check_floor_curb(int32_t dasect, int32_t nextsect, int32_t flordi
int32_t clipmovex(vec3_t *pos, int16_t *sectnum,
int32_t xvect, int32_t yvect,
int32_t walldist, int32_t ceildist, int32_t flordist, uint32_t cliptype,
uint8_t noslidep)
int32_t const walldist, int32_t const ceildist, int32_t const flordist, uint32_t const cliptype,
uint8_t const noslidep)
{
const int32_t oboxtracenum = clipmoveboxtracenum;
@ -921,7 +921,7 @@ int sectoradjacent(int sect1, int sect2)
return 0;
}
static void clipupdatesector(int32_t const x, int32_t const y, int16_t *const sectnum)
static void clipupdatesector(int32_t const x, int32_t const y, int16_t * const sectnum)
{
if (inside_p(x, y, *sectnum))
return;
@ -959,8 +959,8 @@ static void clipupdatesector(int32_t const x, int32_t const y, int16_t *const se
//
// clipmove
//
int32_t clipmove(vec3_t *pos, int16_t *sectnum, int32_t xvect, int32_t yvect,
int32_t walldist, int32_t ceildist, int32_t flordist, uint32_t cliptype)
int32_t clipmove(vec3_t * const pos, int16_t * const sectnum, int32_t xvect, int32_t yvect,
int32_t const walldist, int32_t const ceildist, int32_t const flordist, uint32_t const cliptype)
{
if ((xvect|yvect) == 0 || *sectnum < 0)
return 0;
@ -1352,8 +1352,8 @@ int32_t clipmove(vec3_t *pos, int16_t *sectnum, int32_t xvect, int32_t yvect,
//
// pushmove
//
int32_t pushmove(vec3_t *vect, int16_t *sectnum,
int32_t walldist, int32_t ceildist, int32_t flordist, uint32_t cliptype)
int32_t pushmove(vec3_t * const vect, int16_t * const sectnum,
int32_t const walldist, int32_t const ceildist, int32_t const flordist, uint32_t const cliptype)
{
int32_t i, j, k, t, dx, dy, dax, day, daz;
int32_t dir, bad, bad2;