mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-12-25 19:20:46 +00:00
Fix editor clipping issue
git-svn-id: https://svn.eduke32.com/eduke32@7467 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
25236d3d74
commit
1ea1f525d9
1 changed files with 12 additions and 15 deletions
|
@ -909,22 +909,19 @@ static int32_t get_floorspr_clipyou(int32_t x1, int32_t x2, int32_t x3, int32_t
|
||||||
return clipyou;
|
return clipyou;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int sectoradjacent(int const sect1, int const sect2)
|
#if 0
|
||||||
{
|
static int sectoradjacent(int sect1, int sect2)
|
||||||
if (sector[sect1].wallnum < sector[sect2].wallnum)
|
|
||||||
{
|
{
|
||||||
|
if (sector[sect1].wallnum > sector[sect2].wallnum)
|
||||||
|
swaplong(§1, §2);
|
||||||
|
|
||||||
for (int i = 0; i < sector[sect1].wallnum; i++)
|
for (int i = 0; i < sector[sect1].wallnum; i++)
|
||||||
if (wall[sector[sect1].wallptr+i].nextsector == sect2)
|
if (wall[sector[sect1].wallptr+i].nextsector == sect2)
|
||||||
return 1;
|
return 1;
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
for (int i = 0; i < sector[sect2].wallnum; i++)
|
|
||||||
if (wall[sector[sect2].wallptr+i].nextsector == sect1)
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
//
|
//
|
||||||
// clipmove
|
// clipmove
|
||||||
|
@ -1147,7 +1144,7 @@ int32_t clipmove(vec3_t *pos, int16_t *sectnum, int32_t xvect, int32_t yvect,
|
||||||
if (clipsprite_try(spr, clipMin.x, clipMin.y, clipMax.x, clipMax.y))
|
if (clipsprite_try(spr, clipMin.x, clipMin.y, clipMax.x, clipMax.y))
|
||||||
continue;
|
continue;
|
||||||
#endif
|
#endif
|
||||||
vec2_t p1 = *(vec2_t *)spr;
|
vec2_t p1 = *(vec2_t const *)spr;
|
||||||
|
|
||||||
switch (cstat & (CSTAT_SPRITE_ALIGNMENT_WALL | CSTAT_SPRITE_ALIGNMENT_FLOOR))
|
switch (cstat & (CSTAT_SPRITE_ALIGNMENT_WALL | CSTAT_SPRITE_ALIGNMENT_FLOOR))
|
||||||
{
|
{
|
||||||
|
@ -1307,7 +1304,7 @@ int32_t clipmove(vec3_t *pos, int16_t *sectnum, int32_t xvect, int32_t yvect,
|
||||||
int const osectnum = *sectnum;
|
int const osectnum = *sectnum;
|
||||||
updatesectorz(vec.x, vec.y, pos->z, sectnum);
|
updatesectorz(vec.x, vec.y, pos->z, sectnum);
|
||||||
|
|
||||||
if (*sectnum == osectnum || (*sectnum != -1 && !check_floor_curb(osectnum, *sectnum, flordist, pos->z, vec.x, vec.y)))
|
if (*sectnum == osectnum || editstatus || (*sectnum != -1 && !check_floor_curb(osectnum, *sectnum, flordist, pos->z, vec.x, vec.y)))
|
||||||
{
|
{
|
||||||
pos->x = vec.x;
|
pos->x = vec.x;
|
||||||
pos->y = vec.y;
|
pos->y = vec.y;
|
||||||
|
|
Loading…
Reference in a new issue