- Fixed: Fake floor's validcounts were not initialized.

- Fixed: When loading non-UDMF maps, things did not have their conversation field zero'ed.
- Added an assert for the FAKE3D_REFRESHCLIP case at the end of R_RenderMaskedSegRange(), because Valgrind indicates this is being run
  without ds->bkup being set to something valid. I do not immediately know how this should be fixed.



SVN r3130 (trunk)
This commit is contained in:
Randy Heit 2011-02-02 02:07:36 +00:00
parent 82bac3ad22
commit 060d740275
4 changed files with 16 additions and 7 deletions

View File

@ -57,6 +57,8 @@ foreach( majver ${MAJOR_VERSIONS} )
endforeach( dir ${FMOD_DIR_VERSIONS} )
endforeach( majver ${MAJOR_VERSIONS} )
message( STATUS "${FMOD_DIR_VERSIONS}" )
if( WIN32 )
if( X64 )
set( WIN_TYPE Win64 )

View File

@ -123,8 +123,9 @@ static void P_Add3DFloor(sector_t* sec, sector_t* sec2, line_t* master, int flag
ffloor->top.model = ffloor->bottom.model = ffloor->model = sec2;
ffloor->target = sec;
ffloor->ceilingclip = ffloor->floorclip = NULL;
if (!(flags&FF_THINFLOOR))
ffloor->validcount = 0;
if (!(flags&FF_THINFLOOR))
{
ffloor->bottom.plane = &sec2->floorplane;
ffloor->bottom.texture = &sec2->planes[sector_t::floor].Texture;
@ -898,4 +899,4 @@ int P_Find3DFloor(sector_t * sec, fixed_t x, fixed_t y, fixed_t z, bool above, b
return -1;
}
#endif
#endif

View File

@ -1653,6 +1653,7 @@ void P_LoadThings (MapData * map)
memset (&mti[i], 0, sizeof(mti[i]));
mti[i].Conversation = 0;
mti[i].SkillFilter = MakeSkill(flags);
mti[i].ClassFilter = 0xffff; // Doom map format doesn't have class flags so spawn for all player classes
flags &= ~MTF_SKILLMASK;
@ -1726,6 +1727,7 @@ void P_LoadThings2 (MapData * map)
mti[i].SkillFilter = MakeSkill(mti[i].flags);
mti[i].ClassFilter = (mti[i].flags & MTF_CLASS_MASK) >> MTF_CLASS_SHIFT;
mti[i].flags &= ~(MTF_SKILLMASK|MTF_CLASS_MASK);
mti[i].Conversation = 0;
}
delete[] mtp;
}

View File

@ -279,7 +279,10 @@ void R_RenderMaskedSegRange (drawseg_t *ds, int x1, int x2)
goto clearfog;
}
}
if(ds->bFakeBoundary && !(ds->bFakeBoundary & 4) || drawmode == DontDraw) goto clearfog;
if ((ds->bFakeBoundary && !(ds->bFakeBoundary & 4)) || drawmode == DontDraw)
{
goto clearfog;
}
MaskedSWall = (fixed_t *)(openings + ds->swall) - ds->x1;
MaskedScaleY = ds->yrepeat;
@ -478,6 +481,7 @@ clearfog:
}
if (fake3D & FAKE3D_REFRESHCLIP)
{
assert(ds->bkup >= 0);
memcpy(openings + ds->sprtopclip, openings + ds->bkup, (ds->x2-ds->x1+1) * 2);
}
else
@ -814,7 +818,7 @@ void R_RenderFakeWallRange (drawseg_t *ds, int x1, int x2)
rover->bottom.plane->Zat0() >= sclipTop ||
rover->top.plane->Zat0() <= floorheight)
{
if (i == backsector->e->XFloor.ffloors.Size() - 1)
if ((unsigned)i == backsector->e->XFloor.ffloors.Size() - 1)
{
passed = 1;
}
@ -855,7 +859,7 @@ void R_RenderFakeWallRange (drawseg_t *ds, int x1, int x2)
break;
}
// nothing
if (!fover || j == frontsector->e->XFloor.ffloors.Size())
if (!fover || (unsigned)j == frontsector->e->XFloor.ffloors.Size())
{
break;
}
@ -912,7 +916,7 @@ void R_RenderFakeWallRange (drawseg_t *ds, int x1, int x2)
fover = NULL; // visible
break;
}
if (fover && j != frontsector->e->XFloor.ffloors.Size())
if (fover && (unsigned)j != frontsector->e->XFloor.ffloors.Size())
{ // not visible
break;
}