- Fixed: P_BounceWall() cannot assume that BlockingLine is the line the actor

should bounce off of. Since the order lines in a blockmap cell are checked
  for collision is essentially undefined, there could be another line closer to
  the actor that it should bounce off of instead.

SVN r678 (trunk)
This commit is contained in:
Randy Heit 2008-01-08 03:21:01 +00:00
parent bec0d3438f
commit 2d4b679fcb
3 changed files with 69 additions and 68 deletions

View file

@ -1,4 +1,8 @@
January 7, 2008
- Fixed: P_BounceWall() cannot assume that BlockingLine is the line the actor
should bounce off of. Since the order lines in a blockmap cell are checked
for collision is essentially undefined, there could be another line closer to
the actor that it should bounce off of instead.
- Fixed: Thing_SetTranslation still used a 16-bit word to hold the translation.
- Bumped the maximum resolution up to 2560x1600.
- Fixed: DCanvas::DrawTexture() only expanded virtual screen sizes for widescreen

View file

@ -2423,57 +2423,50 @@ bool P_BounceWall (AActor *mo)
return false;
}
if (BlockingLine != NULL)
{
line = BlockingLine;
}
else
{
slidemo = mo;
slidemo = mo;
//
// trace along the three leading corners
//
if (mo->momx > 0)
{
leadx = mo->x+mo->radius;
}
else
{
leadx = mo->x-mo->radius;
}
if (mo->momy > 0)
{
leady = mo->y+mo->radius;
}
else
{
leady = mo->y-mo->radius;
}
bestslidefrac = FRACUNIT+1;
if (P_PathTraverse(leadx, leady, leadx+mo->momx, leady+mo->momy,
PT_ADDLINES, PTR_BounceTraverse))
{ // Could not find a wall, so bounce off the floor/ceiling instead.
fixed_t floordist = mo->z - mo->floorz;
fixed_t ceildist = mo->ceilingz - mo->z;
if (floordist <= ceildist)
{
mo->FloorBounceMissile (mo->Sector->floorplane);
return true;
}
else
{
mo->FloorBounceMissile (mo->Sector->ceilingplane);
return true;
}
/*
else
{
return (mo->flags2 & MF2_BOUNCE2) != 0;
}
*/
}
line = bestslideline;
if (mo->momx > 0)
{
leadx = mo->x+mo->radius;
}
else
{
leadx = mo->x-mo->radius;
}
if (mo->momy > 0)
{
leady = mo->y+mo->radius;
}
else
{
leady = mo->y-mo->radius;
}
bestslidefrac = FRACUNIT+1;
if (P_PathTraverse(leadx, leady, leadx+mo->momx, leady+mo->momy,
PT_ADDLINES, PTR_BounceTraverse))
{ // Could not find a wall, so bounce off the floor/ceiling instead.
fixed_t floordist = mo->z - mo->floorz;
fixed_t ceildist = mo->ceilingz - mo->z;
if (floordist <= ceildist)
{
mo->FloorBounceMissile (mo->Sector->floorplane);
return true;
}
else
{
mo->FloorBounceMissile (mo->Sector->ceilingplane);
return true;
}
/*
else
{
return (mo->flags2 & MF2_BOUNCE2) != 0;
}
*/
}
line = bestslideline;
if (line->special == Line_Horizon)
{

View file

@ -39,27 +39,6 @@
CompileAsManaged=""
/>
</Configuration>
<Configuration
Name="Release|Win32"
OutputDirectory="Release"
IntermediateDirectory="Release"
ConfigurationType="0"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
>
<Tool
Name="VCNMakeTool"
BuildCommandLine="nmake /nologo RM=&quot;del /f /q&quot; SLASH=\ andcopy"
ReBuildCommandLine="nmake /nologo RM=&quot;del /f /q&quot; SLASH=\ nrebuild"
CleanCommandLine="nmake /nologo RM=&quot;del /f /q&quot; SLASH=\ clean"
Output="zdoom.pk3"
PreprocessorDefinitions=""
IncludeSearchPath=""
ForcedIncludes=""
AssemblySearchPath=""
ForcedUsingAssemblies=""
CompileAsManaged=""
/>
</Configuration>
<Configuration
Name="Debug|x64"
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
@ -81,6 +60,27 @@
CompileAsManaged=""
/>
</Configuration>
<Configuration
Name="Release|Win32"
OutputDirectory="Release"
IntermediateDirectory="Release"
ConfigurationType="0"
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
>
<Tool
Name="VCNMakeTool"
BuildCommandLine="nmake /nologo RM=&quot;del /f /q&quot; SLASH=\ andcopy"
ReBuildCommandLine="nmake /nologo RM=&quot;del /f /q&quot; SLASH=\ nrebuild"
CleanCommandLine="nmake /nologo RM=&quot;del /f /q&quot; SLASH=\ clean"
Output="zdoom.pk3"
PreprocessorDefinitions=""
IncludeSearchPath=""
ForcedIncludes=""
AssemblySearchPath=""
ForcedUsingAssemblies=""
CompileAsManaged=""
/>
</Configuration>
<Configuration
Name="Release|x64"
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
@ -447,6 +447,10 @@
RelativePath=".\decorate\doom\doomplayer.txt"
>
</File>
<File
RelativePath=".\decorate\doom\doomweapons.txt"
>
</File>
<File
RelativePath=".\decorate\doom\fatso.txt"
>