(svn r16561) -Fix [NoAI]: AIMarine::AreWaterTilesConnected didn't return true for bridge head<>neighbouring water tile

This commit is contained in:
yexo 2009-06-11 14:15:18 +00:00
parent c756fdd6da
commit 176e55a8a3
4 changed files with 34 additions and 4 deletions

View File

@ -211,6 +211,21 @@
/> />
</FileConfiguration> </FileConfiguration>
</File> </File>
<File
RelativePath="..\src\lang\english_rev.txt"
>
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCustomBuildTool"
Description="Generating english_rev language file"
CommandLine="..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang &quot;$(InputPath)&quot;&#x0D;&#x0A;"
AdditionalDependencies=""
Outputs="..\bin\lang\english_rev.lng"
/>
</FileConfiguration>
</File>
<File <File
RelativePath="..\src\lang\esperanto.txt" RelativePath="..\src\lang\esperanto.txt"
> >

View File

@ -212,6 +212,21 @@
/> />
</FileConfiguration> </FileConfiguration>
</File> </File>
<File
RelativePath="..\src\lang\english_rev.txt"
>
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCustomBuildTool"
Description="Generating english_rev language file"
CommandLine="..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang &quot;$(InputPath)&quot;&#x0D;&#x0A;"
AdditionalDependencies=""
Outputs="..\bin\lang\english_rev.lng"
/>
</FileConfiguration>
</File>
<File <File
RelativePath="..\src\lang\esperanto.txt" RelativePath="..\src\lang\esperanto.txt"
> >

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="Windows-1252"?> <?xml version="1.0" encoding="Windows-1252"?>
<VisualStudioProject <VisualStudioProject
ProjectType="Visual C++" ProjectType="Visual C++"
Version="9.00" Version="9,00"
Name="openttd" Name="openttd"
ProjectGUID="{668328A0-B40E-4CDB-BD72-D0064424414A}" ProjectGUID="{668328A0-B40E-4CDB-BD72-D0064424414A}"
RootNamespace="openttd" RootNamespace="openttd"
@ -61,7 +61,7 @@
FavorSizeOrSpeed="2" FavorSizeOrSpeed="2"
OmitFramePointers="true" OmitFramePointers="true"
AdditionalIncludeDirectories="..\objs\langs;..\src\3rdparty\squirrel\include" AdditionalIncludeDirectories="..\objs\langs;..\src\3rdparty\squirrel\include"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;WITH_ICU;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;;WITH_ASSERT" PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;WIN32_EXCEPTION_TRACKER;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;WITH_ICU;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;;WITH_ASSERT"
StringPooling="true" StringPooling="true"
ExceptionHandling="1" ExceptionHandling="1"
RuntimeLibrary="0" RuntimeLibrary="0"
@ -166,7 +166,7 @@
AdditionalOptions="/MP" AdditionalOptions="/MP"
Optimization="0" Optimization="0"
AdditionalIncludeDirectories="..\objs\langs;..\src\3rdparty\squirrel\include" AdditionalIncludeDirectories="..\objs\langs;..\src\3rdparty\squirrel\include"
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;WITH_ICU;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;" PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;WITH_ZLIB;WITH_PNG;WITH_FREETYPE;WITH_ICU;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR=\&quot;OpenTTD\&quot;"
BasicRuntimeChecks="3" BasicRuntimeChecks="3"
RuntimeLibrary="1" RuntimeLibrary="1"
UsePrecompiledHeader="0" UsePrecompiledHeader="0"

View File

@ -54,7 +54,7 @@
DiagDirection to_other_tile = ::DiagdirBetweenTiles(t1, t2); DiagDirection to_other_tile = ::DiagdirBetweenTiles(t1, t2);
/* Determine the reachable tracks from the shared edge */ /* Determine the reachable tracks from the shared edge */
TrackBits gtts2 = ::TrackStatusToTrackBits(::GetTileTrackStatus(t2, TRANSPORT_WATER, 0, to_other_tile)) & ::DiagdirReachesTracks(to_other_tile); TrackBits gtts2 = ::TrackStatusToTrackBits(::GetTileTrackStatus(t2, TRANSPORT_WATER, 0, ::ReverseDiagDir(to_other_tile))) & ::DiagdirReachesTracks(to_other_tile);
if (gtts2 == TRACK_BIT_NONE) return false; if (gtts2 == TRACK_BIT_NONE) return false;
to_other_tile = ReverseDiagDir(to_other_tile); to_other_tile = ReverseDiagDir(to_other_tile);