mirror of
https://github.com/1dot13/source.git
synced 2026-07-22 13:40:22 +02:00
************************************************************
* Merged Source Code from Development Trunk: Revision 4063 * ************************************************************ - Source Code is merged from: https://81.169.133.124/source/ja2/branches/Wanne/JA2%201.13%20MP - This will be the Source for the Beta 2011 Test git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@4064 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -0,0 +1,679 @@
|
||||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="8,00"
|
||||
Name="Console"
|
||||
ProjectGUID="{F962CFA1-2215-4124-938F-253973A27591}"
|
||||
RootNamespace="Console"
|
||||
>
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Win32"
|
||||
/>
|
||||
</Platforms>
|
||||
<ToolFiles>
|
||||
</ToolFiles>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
OutputDirectory="..\lib\VS2005\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2005\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2.vsprops;..\ja2_Debug.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
CharacterSet="0"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
PreprocessorDefinitions="_DEBUG"
|
||||
MkTypLibCompatible="true"
|
||||
SuppressStartupBanner="true"
|
||||
TargetEnvironment="1"
|
||||
TypeLibraryName=".\Debug/Console.tlb"
|
||||
HeaderFileName=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions="/D "_CRT_SECURE_NO_DEPRECATE""
|
||||
Optimization="0"
|
||||
FavorSizeOrSpeed="0"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
RuntimeTypeInfo="true"
|
||||
UsePrecompiledHeader="0"
|
||||
PrecompiledHeaderThrough="stdafx.h"
|
||||
PrecompiledHeaderFile=".\Debug/Console.pch"
|
||||
AssemblerListingLocation=".\Debug/"
|
||||
ObjectFile=".\Debug/"
|
||||
ProgramDataBaseFileName=".\Debug/"
|
||||
WarningLevel="3"
|
||||
SuppressStartupBanner="true"
|
||||
DebugInformationFormat="4"
|
||||
DisableSpecificWarnings="4100"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
PreprocessorDefinitions="_DEBUG"
|
||||
Culture="1050"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="comctl32.lib"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
SuppressStartupBanner="true"
|
||||
OutputFile=".\Debug/Console.bsc"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
OutputDirectory="..\lib\VS2005\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2005\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
CharacterSet="0"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
PreprocessorDefinitions="NDEBUG"
|
||||
MkTypLibCompatible="true"
|
||||
SuppressStartupBanner="true"
|
||||
TargetEnvironment="1"
|
||||
TypeLibraryName=".\Release/Console.tlb"
|
||||
HeaderFileName=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions="/D "_CRT_SECURE_NO_DEPRECATE""
|
||||
Optimization="2"
|
||||
InlineFunctionExpansion="1"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_LIB;"
|
||||
StringPooling="true"
|
||||
RuntimeLibrary="0"
|
||||
EnableFunctionLevelLinking="true"
|
||||
RuntimeTypeInfo="true"
|
||||
UsePrecompiledHeader="0"
|
||||
PrecompiledHeaderThrough="stdafx.h"
|
||||
PrecompiledHeaderFile=".\Release/Console.pch"
|
||||
AssemblerListingLocation=".\Release/"
|
||||
ObjectFile=".\Release/"
|
||||
ProgramDataBaseFileName=".\Release/"
|
||||
WarningLevel="3"
|
||||
SuppressStartupBanner="true"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
PreprocessorDefinitions="NDEBUG"
|
||||
Culture="1050"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="comctl32.lib"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
SuppressStartupBanner="true"
|
||||
OutputFile=".\Release/Console.bsc"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="MapEditor|Win32"
|
||||
OutputDirectory="..\lib\VS2005\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2005\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2.vsprops;..\ja2_Editor.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
CharacterSet="0"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
PreprocessorDefinitions="NDEBUG"
|
||||
MkTypLibCompatible="true"
|
||||
SuppressStartupBanner="true"
|
||||
TargetEnvironment="1"
|
||||
TypeLibraryName=".\Release/Console.tlb"
|
||||
HeaderFileName=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions="/D "_CRT_SECURE_NO_DEPRECATE""
|
||||
Optimization="2"
|
||||
InlineFunctionExpansion="1"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_LIB;"
|
||||
StringPooling="true"
|
||||
RuntimeLibrary="0"
|
||||
EnableFunctionLevelLinking="true"
|
||||
RuntimeTypeInfo="true"
|
||||
UsePrecompiledHeader="0"
|
||||
PrecompiledHeaderThrough="stdafx.h"
|
||||
PrecompiledHeaderFile=".\Release/Console.pch"
|
||||
AssemblerListingLocation=".\Release/"
|
||||
ObjectFile=".\Release/"
|
||||
ProgramDataBaseFileName=".\Release/"
|
||||
WarningLevel="3"
|
||||
SuppressStartupBanner="true"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
PreprocessorDefinitions="NDEBUG"
|
||||
Culture="1050"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="comctl32.lib"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
SuppressStartupBanner="true"
|
||||
OutputFile=".\Release/Console.bsc"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="MapEditorD|Win32"
|
||||
OutputDirectory="..\lib\VS2005\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2005\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2.vsprops;..\ja2_Editor.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
CharacterSet="0"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
PreprocessorDefinitions="_DEBUG"
|
||||
MkTypLibCompatible="true"
|
||||
SuppressStartupBanner="true"
|
||||
TargetEnvironment="1"
|
||||
TypeLibraryName=".\Debug/Console.tlb"
|
||||
HeaderFileName=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions="/D "_CRT_SECURE_NO_DEPRECATE""
|
||||
Optimization="0"
|
||||
FavorSizeOrSpeed="0"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
RuntimeTypeInfo="true"
|
||||
UsePrecompiledHeader="0"
|
||||
PrecompiledHeaderThrough="stdafx.h"
|
||||
PrecompiledHeaderFile=".\Debug/Console.pch"
|
||||
AssemblerListingLocation=".\Debug/"
|
||||
ObjectFile=".\Debug/"
|
||||
ProgramDataBaseFileName=".\Debug/"
|
||||
WarningLevel="3"
|
||||
SuppressStartupBanner="true"
|
||||
DebugInformationFormat="4"
|
||||
DisableSpecificWarnings="4100"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
PreprocessorDefinitions="_DEBUG"
|
||||
Culture="1050"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="comctl32.lib"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
SuppressStartupBanner="true"
|
||||
OutputFile=".\Debug/Console.bsc"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release_WithDebugInfo|Win32"
|
||||
OutputDirectory="..\lib\VS2005\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2005\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
CharacterSet="0"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
PreprocessorDefinitions="NDEBUG"
|
||||
MkTypLibCompatible="true"
|
||||
SuppressStartupBanner="true"
|
||||
TargetEnvironment="1"
|
||||
TypeLibraryName=".\Release/Console.tlb"
|
||||
HeaderFileName=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions="/D "_CRT_SECURE_NO_DEPRECATE""
|
||||
Optimization="0"
|
||||
InlineFunctionExpansion="0"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_LIB;"
|
||||
StringPooling="true"
|
||||
RuntimeLibrary="0"
|
||||
EnableFunctionLevelLinking="true"
|
||||
RuntimeTypeInfo="true"
|
||||
UsePrecompiledHeader="0"
|
||||
PrecompiledHeaderThrough="stdafx.h"
|
||||
PrecompiledHeaderFile=".\Release/Console.pch"
|
||||
AssemblerListingLocation=".\Release/"
|
||||
ObjectFile=".\Release/"
|
||||
ProgramDataBaseFileName=".\Release/"
|
||||
WarningLevel="3"
|
||||
SuppressStartupBanner="true"
|
||||
DebugInformationFormat="4"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
PreprocessorDefinitions="NDEBUG"
|
||||
Culture="1050"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="comctl32.lib"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
SuppressStartupBanner="true"
|
||||
OutputFile=".\Release/Console.bsc"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<References>
|
||||
</References>
|
||||
<Files>
|
||||
<Filter
|
||||
Name="Source Files"
|
||||
Filter="cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
|
||||
>
|
||||
<File
|
||||
RelativePath="Console.cpp"
|
||||
>
|
||||
<FileConfiguration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions=""
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
PreprocessorDefinitions=""
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="MapEditor|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
PreprocessorDefinitions=""
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="MapEditorD|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions=""
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="Release_WithDebugInfo|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
PreprocessorDefinitions=""
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="Cursors.cpp"
|
||||
>
|
||||
<FileConfiguration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions=""
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
PreprocessorDefinitions=""
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="MapEditor|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
PreprocessorDefinitions=""
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="MapEditorD|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions=""
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="Release_WithDebugInfo|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
PreprocessorDefinitions=""
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="Dialogs.cpp"
|
||||
>
|
||||
<FileConfiguration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions=""
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
PreprocessorDefinitions=""
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="MapEditor|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
PreprocessorDefinitions=""
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="MapEditorD|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions=""
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="Release_WithDebugInfo|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
PreprocessorDefinitions=""
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="FileStream.cpp"
|
||||
>
|
||||
<FileConfiguration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions=""
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
PreprocessorDefinitions=""
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="MapEditor|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
PreprocessorDefinitions=""
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="MapEditorD|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions=""
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="Release_WithDebugInfo|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
PreprocessorDefinitions=""
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Header Files"
|
||||
Filter="h;hpp;hxx;hm;inl"
|
||||
>
|
||||
<File
|
||||
RelativePath="ComBSTROut.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="ComVariantOut.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="Console.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="Cursors.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="Dialogs.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="FileStream.h"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Resource Files"
|
||||
Filter="ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
|
||||
>
|
||||
<File
|
||||
RelativePath="Console.ico"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
</VisualStudioProject>
|
||||
@@ -21,7 +21,7 @@
|
||||
OutputDirectory="..\lib\VS2008\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2008\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2_VS2008.vsprops;..\ja2_VS2008Debug.vsprops"
|
||||
InheritedPropertySheets="..\ja2.vsprops;..\ja2_Debug.vsprops"
|
||||
CharacterSet="0"
|
||||
>
|
||||
<Tool
|
||||
@@ -84,7 +84,7 @@
|
||||
OutputDirectory="..\lib\VS2008\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2008\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2_VS2008.vsprops"
|
||||
InheritedPropertySheets="..\ja2.vsprops"
|
||||
CharacterSet="0"
|
||||
WholeProgramOptimization="0"
|
||||
>
|
||||
@@ -149,7 +149,7 @@
|
||||
OutputDirectory="..\lib\VS2008\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2008\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2_VS2008.vsprops;..\ja2_VS2008Editor.vsprops"
|
||||
InheritedPropertySheets="..\ja2.vsprops;..\ja2_Editor.vsprops"
|
||||
CharacterSet="0"
|
||||
WholeProgramOptimization="0"
|
||||
>
|
||||
@@ -214,7 +214,7 @@
|
||||
OutputDirectory="..\lib\VS2008\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2008\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2_VS2008.vsprops;..\ja2_VS2008Editor.vsprops"
|
||||
InheritedPropertySheets="..\ja2.vsprops;..\ja2_Editor.vsprops"
|
||||
CharacterSet="0"
|
||||
>
|
||||
<Tool
|
||||
@@ -277,7 +277,7 @@
|
||||
OutputDirectory="..\lib\VS2008\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2008\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2_VS2008.vsprops"
|
||||
InheritedPropertySheets="..\ja2.vsprops"
|
||||
CharacterSet="0"
|
||||
WholeProgramOptimization="0"
|
||||
>
|
||||
|
||||
@@ -0,0 +1,227 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="MapEditorD|Win32">
|
||||
<Configuration>MapEditorD</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="MapEditor|Win32">
|
||||
<Configuration>MapEditor</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Relese_WithDebugInfo|Win32">
|
||||
<Configuration>Relese_WithDebugInfo</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="ComBSTROut.h" />
|
||||
<ClInclude Include="ComVariantOut.h" />
|
||||
<ClInclude Include="Console.h" />
|
||||
<ClInclude Include="Cursors.h" />
|
||||
<ClInclude Include="Dialogs.h" />
|
||||
<ClInclude Include="FileStream.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="Console.cpp" />
|
||||
<ClCompile Include="Cursors.cpp" />
|
||||
<ClCompile Include="Dialogs.cpp" />
|
||||
<ClCompile Include="FileStream.cpp" />
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{A32479BF-C284-4C40-99A5-4F6B5933D1C0}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>Console</RootNamespace>
|
||||
<ProjectName>Console</ProjectName>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='MapEditorD|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>false</WholeProgramOptimization>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='MapEditor|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>false</WholeProgramOptimization>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Relese_WithDebugInfo|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>false</WholeProgramOptimization>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="..\ja2.props" />
|
||||
<Import Project="..\ja2_Debug.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='MapEditorD|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="..\ja2.props" />
|
||||
<Import Project="..\ja2_Debug.props" />
|
||||
<Import Project="..\ja2_Editor.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="..\ja2.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='MapEditor|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="..\ja2.props" />
|
||||
<Import Project="..\ja2_Editor.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Relese_WithDebugInfo|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="..\ja2.props" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<OutDir>..\lib\VS2010\$(Configuration)\</OutDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='MapEditorD|Win32'">
|
||||
<OutDir>..\lib\VS2010\$(Configuration)\</OutDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<IntDir>..\build\VS2010\$(ProjectName)_$(Configuration)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='MapEditorD|Win32'">
|
||||
<IntDir>..\build\VS2010\$(ProjectName)_$(Configuration)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<OutDir>..\lib\VS2010\$(Configuration)\</OutDir>
|
||||
<IntDir>..\build\VS2010\$(ProjectName)_$(Configuration)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='MapEditor|Win32'">
|
||||
<OutDir>..\lib\VS2010\$(Configuration)\</OutDir>
|
||||
<IntDir>..\build\VS2010\$(ProjectName)_$(Configuration)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Relese_WithDebugInfo|Win32'">
|
||||
<OutDir>..\lib\VS2010\$(Configuration)\</OutDir>
|
||||
<IntDir>..\build\VS2010\$(ProjectName)_$(Configuration)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
|
||||
<PrecompiledHeaderFile>
|
||||
</PrecompiledHeaderFile>
|
||||
<PrecompiledHeaderOutputFile>
|
||||
</PrecompiledHeaderOutputFile>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='MapEditorD|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
|
||||
<PrecompiledHeaderFile>
|
||||
</PrecompiledHeaderFile>
|
||||
<PrecompiledHeaderOutputFile>
|
||||
</PrecompiledHeaderOutputFile>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>
|
||||
</PrecompiledHeaderFile>
|
||||
<PrecompiledHeaderOutputFile>
|
||||
</PrecompiledHeaderOutputFile>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='MapEditor|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>
|
||||
</PrecompiledHeaderFile>
|
||||
<PrecompiledHeaderOutputFile>
|
||||
</PrecompiledHeaderOutputFile>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Relese_WithDebugInfo|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>
|
||||
</PrecompiledHeaderFile>
|
||||
<PrecompiledHeaderOutputFile>
|
||||
</PrecompiledHeaderOutputFile>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
<DebugInformationFormat>EditAndContinue</DebugInformationFormat>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
</Project>
|
||||
@@ -0,0 +1,45 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<ClInclude Include="ComBSTROut.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="ComVariantOut.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Console.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Cursors.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Dialogs.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="FileStream.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Filter Include="Header Files">
|
||||
<UniqueIdentifier>{abfafc0c-c637-4524-960d-bddcb96d0913}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Source Files">
|
||||
<UniqueIdentifier>{680812ee-68a6-4c84-a9aa-615d9523b3b1}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="Console.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Cursors.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Dialogs.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="FileStream.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
+1
-7
@@ -1575,13 +1575,7 @@ UINT32 GetAndHandleCreditCodeFromCodeString( STR16 pzCode )
|
||||
{
|
||||
return( CRDT_FLAG__END_SECTION );
|
||||
}
|
||||
|
||||
//else its an error
|
||||
else
|
||||
{
|
||||
Assert( 0 );
|
||||
}
|
||||
|
||||
|
||||
return( CRDT_NODE_NONE );
|
||||
}
|
||||
|
||||
|
||||
@@ -33,6 +33,8 @@
|
||||
#include "EditorMapInfo.h"
|
||||
#endif
|
||||
|
||||
#include "LoadScreen.h"
|
||||
|
||||
extern SOLDIERINITNODE *gpSelected;
|
||||
extern SCHEDULENODE gCurrSchedule;
|
||||
extern void ExtractAndUpdateMercSchedule();
|
||||
@@ -648,8 +650,17 @@ void BtnChangeTilesetCallback(GUI_BUTTON *btn,INT32 reason)
|
||||
{
|
||||
if(reason & MSYS_CALLBACK_REASON_LBUTTON_DWN)
|
||||
{
|
||||
btn->uiFlags |= BUTTON_CLICKED_ON;
|
||||
iEditorToolbarState = TBAR_MODE_CHANGE_TILESET;
|
||||
// WANNE: Check if map has been saved when we have a new map that has not been saved before!
|
||||
if (fNewMapSaved)
|
||||
{
|
||||
btn->uiFlags |= BUTTON_CLICKED_ON;
|
||||
iEditorToolbarState = TBAR_MODE_CHANGE_TILESET;
|
||||
}
|
||||
else
|
||||
{
|
||||
swprintf(gzErrorCatchString, L"Before changing tilesets you have to save the new map!");
|
||||
InitErrorCatchDialog();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -708,7 +708,7 @@ void InitEditorOptionsToolbar()
|
||||
//dnl ch33 160909
|
||||
iEditorButton[OPTIONS_VANILLA_MODE] =
|
||||
CreateCheckBoxButton(iScreenWidthOffset+71, SCREEN_HEIGHT-119, "EDITOR//smcheckbox.sti", MSYS_PRIORITY_NORMAL, VanillaModeCallback);
|
||||
SetButtonFastHelpText(iEditorButton[OPTIONS_VANILLA_MODE],L"Set save map as v1.12");
|
||||
SetButtonFastHelpText(iEditorButton[OPTIONS_VANILLA_MODE],L"When checked, the map will be saved in original JA2 format (Version: 5.00 / 25)");
|
||||
}
|
||||
|
||||
void InitEditorTerrainToolbar()
|
||||
|
||||
@@ -906,7 +906,7 @@ void RenderEditorInfo( )
|
||||
switch( iCurrentTaskbar )
|
||||
{
|
||||
case TASK_OPTIONS:
|
||||
mprintf(iScreenWidthOffset+71+15, SCREEN_HEIGHT-117, L"v1.12");//dnl ch33 160909
|
||||
mprintf(iScreenWidthOffset+71+15, SCREEN_HEIGHT-117, L"Save map in original JA2 map format (Version: 5.00 / 25)");//dnl ch33 160909
|
||||
if( !gfWorldLoaded || giCurrentTilesetID < 0 )
|
||||
mprintf( iScreenWidthOffset + 260, 2 * iScreenHeightOffset + 445, L"No map currently loaded." );
|
||||
else
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
#include "InterfaceItemImages.h"
|
||||
#endif
|
||||
|
||||
#include "VFS/Tools/Log.h"
|
||||
#include <vfs/Tools/vfs_log.h>
|
||||
|
||||
#define NUMBER_TRIGGERS 27
|
||||
#define PRESSURE_ACTION_ID (NUMBER_TRIGGERS - 1)
|
||||
@@ -557,10 +557,10 @@ void InitEditorItemsInfo(UINT32 uiItemType)
|
||||
}
|
||||
else
|
||||
{
|
||||
static CLog& editorLog = *CLog::create(L"EditorItems.log");
|
||||
static vfs::Log& editorLog = *vfs::Log::create(L"EditorItems.log");
|
||||
editorLog << L"Tried to access item ["
|
||||
<< item->ubGraphicNum << L"/" << hVObject->usNumberOfObjects
|
||||
<< L"]" << CLog::ENDL;
|
||||
<< L"]" << vfs::Log::endl;
|
||||
}
|
||||
}
|
||||
usCounter++;
|
||||
|
||||
@@ -141,7 +141,7 @@ void SetupTextInputForMapInfo()
|
||||
swprintf( str, L"%d", gExitGrid.ubGotoSectorZ );
|
||||
AddTextInputField( iScreenWidthOffset + 338, 2 * iScreenHeightOffset + 383, 30, 18, MSYS_PRIORITY_NORMAL, str, 1, INPUTTYPE_NUMERICSTRICT );
|
||||
swprintf( str, L"%d", gExitGrid.usGridNo );
|
||||
AddTextInputField( iScreenWidthOffset + 338, 2 * iScreenHeightOffset + 403, 40, 18, MSYS_PRIORITY_NORMAL, str, 5, INPUTTYPE_NUMERICSTRICT );
|
||||
AddTextInputField( iScreenWidthOffset + 338, 2 * iScreenHeightOffset + 403, 45, 18, MSYS_PRIORITY_NORMAL, str, 6, INPUTTYPE_NUMERICSTRICT );
|
||||
}
|
||||
|
||||
void UpdateMapInfo()
|
||||
@@ -183,8 +183,8 @@ void UpdateMapInfo()
|
||||
mprintf( iScreenWidthOffset + 368, 2 * iScreenHeightOffset + 372, L"Sector" );
|
||||
mprintf( iScreenWidthOffset + 368, 2 * iScreenHeightOffset + 383, L"Destination");
|
||||
mprintf( iScreenWidthOffset + 368, 2 * iScreenHeightOffset + 392, L"Bsmt. Level" );
|
||||
mprintf( iScreenWidthOffset + 378, 2 * iScreenHeightOffset + 403, L"Dest." );
|
||||
mprintf( iScreenWidthOffset + 378, 2 * iScreenHeightOffset + 412, L"GridNo" );
|
||||
mprintf( iScreenWidthOffset + 383, 2 * iScreenHeightOffset + 403, L"Dest." );
|
||||
mprintf( iScreenWidthOffset + 383, 2 * iScreenHeightOffset + 412, L"GridNo" );
|
||||
SetFontForeground( FONT_RED );
|
||||
}
|
||||
|
||||
|
||||
+66
-3
@@ -77,6 +77,11 @@ extern void GetSoldierAboveGuyPositions( SOLDIERTYPE *pSoldier, INT16 *psX, INT1
|
||||
// SANMONA_ARMS_GROUP,
|
||||
// ANGELS_GROUP,
|
||||
// NUM_CIV_GROUPS
|
||||
|
||||
CHAR16 gszCivGroupNames[ NUM_CIV_GROUPS ][ 128 ];
|
||||
|
||||
|
||||
/*
|
||||
CHAR16 gszCivGroupNames[ NUM_CIV_GROUPS ][ 20 ] =
|
||||
{
|
||||
L"NONE",
|
||||
@@ -102,7 +107,7 @@ CHAR16 gszCivGroupNames[ NUM_CIV_GROUPS ][ 20 ] =
|
||||
L"UNUSED18",
|
||||
L"UNUSED19",
|
||||
};
|
||||
|
||||
*/
|
||||
//--------------------------------------------------
|
||||
|
||||
// SCHEDULE_ACTION_NONE,
|
||||
@@ -311,6 +316,27 @@ extern SOLDIERCREATE_STRUCT gSaveBufferDetailedPlacement;
|
||||
//void CopyMercPlacement(); // moved to header (jonathanl)
|
||||
//void PasteMercPlacement(); // moved to header (jonathanl)
|
||||
|
||||
|
||||
//legion2 jazz
|
||||
|
||||
wchar_t *GetGrupaString( SOLDIERTYPE *pSoldier ) //Legion 2
|
||||
{
|
||||
INT32 cnt, cntStart,par;
|
||||
|
||||
cntStart = 0;
|
||||
for ( cnt = cntStart; cnt < NUM_CIV_GROUPS; cnt ++ )
|
||||
{
|
||||
if (pSoldier->ubCivilianGroup == cnt)
|
||||
{
|
||||
par = cnt;
|
||||
}
|
||||
|
||||
}
|
||||
return gszCivGroupNames[ par ];
|
||||
}
|
||||
//------------
|
||||
|
||||
|
||||
void GameInitEditorMercsInfo()
|
||||
{
|
||||
INT32 i;
|
||||
@@ -3106,7 +3132,7 @@ void RenderMercStrings()
|
||||
SOLDIERTYPE *pSoldier;
|
||||
INT16 sXPos, sYPos;
|
||||
INT16 sX, sY;
|
||||
STR16 pStr;
|
||||
STR16 pStr, pStr2;
|
||||
SOLDIERINITNODE *curr;
|
||||
CHAR16 str[50];
|
||||
|
||||
@@ -3154,6 +3180,24 @@ void RenderMercStrings()
|
||||
mprintf( sX, sY, str );
|
||||
}
|
||||
sYPos += 10;
|
||||
|
||||
|
||||
if (pSoldier->bTeam == CIV_TEAM )
|
||||
{
|
||||
//legion2
|
||||
pStr2 = GetGrupaString( pSoldier );
|
||||
|
||||
SetFontBackground( FONT_MCOLOR_BLACK );
|
||||
SetFontForeground( FONT_YELLOW ); //FONT_MCOLOR_WHITE
|
||||
FindFontCenterCoordinates( sXPos, sYPos, 80, 1, pStr2, TINYFONT1, &sX, &sY );
|
||||
if( sY < (2 * iScreenHeightOffset + 352 ))
|
||||
{
|
||||
gprintfdirty( sX, sY, pStr2 );
|
||||
mprintf( sX, sY, pStr2 );
|
||||
}
|
||||
sYPos += 10;
|
||||
}
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -3180,6 +3224,25 @@ void RenderMercStrings()
|
||||
mprintf( sX, sY, str );
|
||||
}
|
||||
sYPos += 10;
|
||||
|
||||
//legion
|
||||
if (pSoldier->bTeam == CIV_TEAM ) //(pSoldier->bTeam == ENEMY_TEAM || pSoldier->bTeam == CREATURE_TEAM || pSoldier->bTeam == MILITIA_TEAM)
|
||||
{
|
||||
//legion 2
|
||||
pStr2 = GetGrupaString( pSoldier );
|
||||
|
||||
//SetFont( TINYFONT1 );
|
||||
SetFontBackground( FONT_MCOLOR_BLACK );
|
||||
SetFontForeground( FONT_YELLOW ); //FONT_MCOLOR_WHITE
|
||||
FindFontCenterCoordinates( sXPos, sYPos, 80, 1, pStr2, TINYFONT1, &sX, &sY );
|
||||
if( sY < (2 * iScreenHeightOffset + 352 ))
|
||||
{
|
||||
gprintfdirty( sX, sY, pStr2 );
|
||||
mprintf( sX, sY, pStr2 );
|
||||
}
|
||||
sYPos += 10;
|
||||
}
|
||||
|
||||
}
|
||||
if( curr->pBasicPlacement->bOrders == RNDPTPATROL || curr->pBasicPlacement->bOrders == POINTPATROL )
|
||||
{ //make sure the placement has at least one waypoint.
|
||||
@@ -3302,7 +3365,7 @@ void CancelCurrentScheduleAction()
|
||||
|
||||
void RegisterCurrentScheduleAction( INT32 iMapIndex )
|
||||
{
|
||||
CHAR16 str[6];
|
||||
CHAR16 str[10];
|
||||
MarkWorldDirty();
|
||||
swprintf( str, L"%d", iMapIndex );
|
||||
if( gfUseScheduleData2 )
|
||||
|
||||
@@ -0,0 +1,559 @@
|
||||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="8,00"
|
||||
Name="Editor"
|
||||
ProjectGUID="{60D793F2-90B4-43C9-83B5-221EE11B37E6}"
|
||||
RootNamespace="Editor"
|
||||
Keyword="Win32Proj"
|
||||
>
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Win32"
|
||||
/>
|
||||
</Platforms>
|
||||
<ToolFiles>
|
||||
</ToolFiles>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
OutputDirectory="..\lib\VS2005\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2005\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2.vsprops;..\ja2_Debug.vsprops"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions="/D "_CRT_SECURE_NO_DEPRECATE""
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
RuntimeTypeInfo="true"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
DebugInformationFormat="4"
|
||||
DisableSpecificWarnings="4100"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
OutputDirectory="..\lib\VS2005\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2005\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2.vsprops"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions="/D "_CRT_SECURE_NO_DEPRECATE""
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_LIB;"
|
||||
RuntimeLibrary="0"
|
||||
RuntimeTypeInfo="true"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
DebugInformationFormat="3"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="MapEditor|Win32"
|
||||
OutputDirectory="..\lib\VS2005\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2005\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2.vsprops;..\ja2_Editor.vsprops"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions="/D "_CRT_SECURE_NO_DEPRECATE""
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_LIB;"
|
||||
RuntimeLibrary="0"
|
||||
RuntimeTypeInfo="true"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
DebugInformationFormat="3"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="MapEditorD|Win32"
|
||||
OutputDirectory="..\lib\VS2005\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2005\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2.vsprops;..\ja2_Editor.vsprops"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions="/D "_CRT_SECURE_NO_DEPRECATE""
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
RuntimeTypeInfo="true"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
DebugInformationFormat="4"
|
||||
DisableSpecificWarnings="4100"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release_WithDebugInfo|Win32"
|
||||
OutputDirectory="..\lib\VS2005\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2005\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2.vsprops"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions="/D "_CRT_SECURE_NO_DEPRECATE""
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_LIB;"
|
||||
RuntimeLibrary="0"
|
||||
RuntimeTypeInfo="true"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
DebugInformationFormat="4"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<References>
|
||||
</References>
|
||||
<Files>
|
||||
<Filter
|
||||
Name="Header Files"
|
||||
Filter="h;hpp;hxx;hm;inl;inc;xsd"
|
||||
UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
|
||||
>
|
||||
<File
|
||||
RelativePath=".\Button Defines.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Cursor Modes.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\edit_sys.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Editor All.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Editor Callback Prototypes.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Editor Modes.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Editor Taskbar Creation.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Editor Taskbar Utils.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Editor Undo.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\EditorBuildings.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\EditorDefines.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\EditorItems.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\EditorMapInfo.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\EditorMercs.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\EditorTerrain.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\editscreen.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Item Statistics.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\LoadScreen.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\messagebox.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\newsmooth.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\popupmenu.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Road Smoothing.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Sector Summary.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\selectwin.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\SmartMethod.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\smooth.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Smoothing Utils.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Summary Info.h"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Source Files"
|
||||
Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
|
||||
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
|
||||
>
|
||||
<File
|
||||
RelativePath=".\Cursor Modes.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\edit_sys.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Editor Callbacks.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Editor Modes.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Editor Taskbar Creation.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Editor Taskbar Utils.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Editor Undo.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\EditorBuildings.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\EditorItems.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\EditorMapInfo.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\EditorMercs.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\EditorTerrain.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\editscreen.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Item Statistics.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\LoadScreen.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\messagebox.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\newsmooth.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\popupmenu.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Road Smoothing.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Sector Summary.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\selectwin.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\SmartMethod.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\smooth.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Smoothing Utils.cpp"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
</VisualStudioProject>
|
||||
@@ -21,7 +21,7 @@
|
||||
OutputDirectory="..\lib\VS2008\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2008\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2_VS2008.vsprops;..\ja2_VS2008Debug.vsprops"
|
||||
InheritedPropertySheets="..\ja2.vsprops;..\ja2_Debug.vsprops"
|
||||
CharacterSet="0"
|
||||
>
|
||||
<Tool
|
||||
@@ -83,7 +83,7 @@
|
||||
OutputDirectory="..\lib\VS2008\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2008\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2_VS2008.vsprops"
|
||||
InheritedPropertySheets="..\ja2.vsprops"
|
||||
CharacterSet="0"
|
||||
WholeProgramOptimization="0"
|
||||
>
|
||||
@@ -147,7 +147,7 @@
|
||||
OutputDirectory="..\lib\VS2008\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2008\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2_VS2008.vsprops;..\ja2_VS2008Editor.vsprops"
|
||||
InheritedPropertySheets="..\ja2.vsprops;..\ja2_Editor.vsprops"
|
||||
CharacterSet="0"
|
||||
WholeProgramOptimization="0"
|
||||
>
|
||||
@@ -211,7 +211,7 @@
|
||||
OutputDirectory="..\lib\VS2008\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2008\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2_VS2008.vsprops;..\ja2_VS2008Editor.vsprops"
|
||||
InheritedPropertySheets="..\ja2.vsprops;..\ja2_Editor.vsprops"
|
||||
CharacterSet="0"
|
||||
>
|
||||
<Tool
|
||||
@@ -273,7 +273,7 @@
|
||||
OutputDirectory="..\lib\VS2008\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2008\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2_VS2008.vsprops"
|
||||
InheritedPropertySheets="..\ja2.vsprops"
|
||||
CharacterSet="0"
|
||||
WholeProgramOptimization="0"
|
||||
>
|
||||
|
||||
@@ -0,0 +1,265 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="MapEditorD|Win32">
|
||||
<Configuration>MapEditorD</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="MapEditor|Win32">
|
||||
<Configuration>MapEditor</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Relese_WithDebugInfo|Win32">
|
||||
<Configuration>Relese_WithDebugInfo</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="Button Defines.h" />
|
||||
<ClInclude Include="Cursor Modes.h" />
|
||||
<ClInclude Include="Editor All.h" />
|
||||
<ClInclude Include="Editor Callback Prototypes.h" />
|
||||
<ClInclude Include="Editor Modes.h" />
|
||||
<ClInclude Include="Editor Taskbar Creation.h" />
|
||||
<ClInclude Include="Editor Taskbar Utils.h" />
|
||||
<ClInclude Include="Editor Undo.h" />
|
||||
<ClInclude Include="EditorBuildings.h" />
|
||||
<ClInclude Include="EditorDefines.h" />
|
||||
<ClInclude Include="EditorItems.h" />
|
||||
<ClInclude Include="EditorMapInfo.h" />
|
||||
<ClInclude Include="EditorMercs.h" />
|
||||
<ClInclude Include="EditorTerrain.h" />
|
||||
<ClInclude Include="editscreen.h" />
|
||||
<ClInclude Include="edit_sys.h" />
|
||||
<ClInclude Include="Item Statistics.h" />
|
||||
<ClInclude Include="LoadScreen.h" />
|
||||
<ClInclude Include="messagebox.h" />
|
||||
<ClInclude Include="newsmooth.h" />
|
||||
<ClInclude Include="popupmenu.h" />
|
||||
<ClInclude Include="Road Smoothing.h" />
|
||||
<ClInclude Include="Sector Summary.h" />
|
||||
<ClInclude Include="selectwin.h" />
|
||||
<ClInclude Include="SmartMethod.h" />
|
||||
<ClInclude Include="smooth.h" />
|
||||
<ClInclude Include="Smoothing Utils.h" />
|
||||
<ClInclude Include="Summary Info.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="Cursor Modes.cpp" />
|
||||
<ClCompile Include="Editor Callbacks.cpp" />
|
||||
<ClCompile Include="Editor Modes.cpp" />
|
||||
<ClCompile Include="Editor Taskbar Creation.cpp" />
|
||||
<ClCompile Include="Editor Taskbar Utils.cpp" />
|
||||
<ClCompile Include="Editor Undo.cpp" />
|
||||
<ClCompile Include="EditorBuildings.cpp" />
|
||||
<ClCompile Include="EditorItems.cpp" />
|
||||
<ClCompile Include="EditorMapInfo.cpp" />
|
||||
<ClCompile Include="EditorMercs.cpp" />
|
||||
<ClCompile Include="EditorTerrain.cpp" />
|
||||
<ClCompile Include="editscreen.cpp" />
|
||||
<ClCompile Include="edit_sys.cpp" />
|
||||
<ClCompile Include="Item Statistics.cpp" />
|
||||
<ClCompile Include="LoadScreen.cpp" />
|
||||
<ClCompile Include="messagebox.cpp" />
|
||||
<ClCompile Include="newsmooth.cpp" />
|
||||
<ClCompile Include="popupmenu.cpp" />
|
||||
<ClCompile Include="Road Smoothing.cpp" />
|
||||
<ClCompile Include="Sector Summary.cpp" />
|
||||
<ClCompile Include="selectwin.cpp" />
|
||||
<ClCompile Include="SmartMethod.cpp" />
|
||||
<ClCompile Include="smooth.cpp" />
|
||||
<ClCompile Include="Smoothing Utils.cpp" />
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{23EA0500-038A-4EB8-B753-0C709B25470D}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>Editor</RootNamespace>
|
||||
<ProjectName>Editor</ProjectName>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='MapEditorD|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>false</WholeProgramOptimization>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='MapEditor|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>false</WholeProgramOptimization>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Relese_WithDebugInfo|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>false</WholeProgramOptimization>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="..\ja2.props" />
|
||||
<Import Project="..\ja2_Debug.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='MapEditorD|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="..\ja2.props" />
|
||||
<Import Project="..\ja2_Debug.props" />
|
||||
<Import Project="..\ja2_Editor.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="..\ja2.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='MapEditor|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="..\ja2.props" />
|
||||
<Import Project="..\ja2_Editor.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Relese_WithDebugInfo|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="..\ja2.props" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<OutDir>..\lib\VS2010\$(Configuration)\</OutDir>
|
||||
<IntDir>..\build\VS2010\$(ProjectName)_$(Configuration)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='MapEditorD|Win32'">
|
||||
<OutDir>..\lib\VS2010\$(Configuration)\</OutDir>
|
||||
<IntDir>..\build\VS2010\$(ProjectName)_$(Configuration)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<OutDir>..\lib\VS2010\$(Configuration)\</OutDir>
|
||||
<IntDir>..\build\VS2010\$(ProjectName)_$(Configuration)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='MapEditor|Win32'">
|
||||
<OutDir>..\lib\VS2010\$(Configuration)\</OutDir>
|
||||
<IntDir>..\build\VS2010\$(ProjectName)_$(Configuration)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Relese_WithDebugInfo|Win32'">
|
||||
<OutDir>..\lib\VS2010\$(Configuration)\</OutDir>
|
||||
<IntDir>..\build\VS2010\$(ProjectName)_$(Configuration)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
|
||||
<PrecompiledHeaderFile>
|
||||
</PrecompiledHeaderFile>
|
||||
<PrecompiledHeaderOutputFile>
|
||||
</PrecompiledHeaderOutputFile>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='MapEditorD|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
|
||||
<PrecompiledHeaderFile>
|
||||
</PrecompiledHeaderFile>
|
||||
<PrecompiledHeaderOutputFile>
|
||||
</PrecompiledHeaderOutputFile>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>
|
||||
</PrecompiledHeaderFile>
|
||||
<PrecompiledHeaderOutputFile>
|
||||
</PrecompiledHeaderOutputFile>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='MapEditor|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>
|
||||
</PrecompiledHeaderFile>
|
||||
<PrecompiledHeaderOutputFile>
|
||||
</PrecompiledHeaderOutputFile>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Relese_WithDebugInfo|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile>
|
||||
</PrecompiledHeaderFile>
|
||||
<PrecompiledHeaderOutputFile>
|
||||
</PrecompiledHeaderOutputFile>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
<DebugInformationFormat>EditAndContinue</DebugInformationFormat>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
</Project>
|
||||
@@ -0,0 +1,171 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<Filter Include="Header Files">
|
||||
<UniqueIdentifier>{1305164a-0ad7-4d96-af15-765647f97f27}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Source Files">
|
||||
<UniqueIdentifier>{02bb6629-3e96-4c7d-931f-fb1ec12b8ef5}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="Button Defines.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Cursor Modes.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="edit_sys.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Editor All.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Editor Callback Prototypes.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Editor Modes.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Editor Taskbar Creation.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Editor Taskbar Utils.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Editor Undo.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="EditorBuildings.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="EditorDefines.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="EditorItems.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="EditorMapInfo.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="EditorMercs.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="EditorTerrain.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="editscreen.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Item Statistics.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="LoadScreen.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="messagebox.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="newsmooth.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="popupmenu.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Road Smoothing.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Sector Summary.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="selectwin.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="SmartMethod.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="smooth.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Smoothing Utils.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Summary Info.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="Cursor Modes.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="edit_sys.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Editor Callbacks.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Editor Modes.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Editor Taskbar Creation.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Editor Taskbar Utils.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Editor Undo.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="EditorBuildings.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="EditorItems.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="EditorMapInfo.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="EditorMercs.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="EditorTerrain.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="editscreen.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Item Statistics.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="LoadScreen.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="messagebox.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="newsmooth.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="popupmenu.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Road Smoothing.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Sector Summary.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="selectwin.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="SmartMethod.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="smooth.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Smoothing Utils.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
@@ -671,7 +671,7 @@ void SetupGunGUI()
|
||||
//for a particular weapon. Show only the ones that we can apply to this gun.
|
||||
yp = 2 * iScreenHeightOffset + 383;
|
||||
guiAttachmentButton[ SILENCER_ATTACHMENT_BUTTON ] = -1;
|
||||
if( ValidAttachment( SILENCER, gpItem->usItem ) )
|
||||
if( ValidAttachment( SILENCER, gpItem ) )
|
||||
{
|
||||
guiAttachmentButton[ SILENCER_ATTACHMENT_BUTTON ] =
|
||||
CreateTextButton( L"SILENCER", SMALLCOMPFONT, FONT_YELLOW, FONT_BLACK, BUTTON_USE_DEFAULT,
|
||||
@@ -684,7 +684,7 @@ void SetupGunGUI()
|
||||
}
|
||||
}
|
||||
guiAttachmentButton[ SNIPERSCOPE_ATTACHMENT_BUTTON ] = -1;
|
||||
if( ValidAttachment( SNIPERSCOPE, gpItem->usItem ) )
|
||||
if( ValidAttachment( SNIPERSCOPE, gpItem ) )
|
||||
{
|
||||
guiAttachmentButton[ SNIPERSCOPE_ATTACHMENT_BUTTON ] =
|
||||
CreateTextButton( L"SNIPERSCOPE", SMALLCOMPFONT, FONT_YELLOW, FONT_BLACK, BUTTON_USE_DEFAULT,
|
||||
@@ -697,7 +697,7 @@ void SetupGunGUI()
|
||||
}
|
||||
}
|
||||
guiAttachmentButton[ LASERSCOPE_ATTACHMENT_BUTTON ] = -1;
|
||||
if( ValidAttachment( LASERSCOPE, gpItem->usItem ) )
|
||||
if( ValidAttachment( LASERSCOPE, gpItem ) )
|
||||
{
|
||||
guiAttachmentButton[ LASERSCOPE_ATTACHMENT_BUTTON ] =
|
||||
CreateTextButton( L"LASERSCOPE", SMALLCOMPFONT, FONT_YELLOW, FONT_BLACK, BUTTON_USE_DEFAULT,
|
||||
@@ -710,7 +710,7 @@ void SetupGunGUI()
|
||||
}
|
||||
}
|
||||
guiAttachmentButton[ BIPOD_ATTACHMENT_BUTTON ] = -1;
|
||||
if( ValidAttachment( BIPOD, gpItem->usItem ) )
|
||||
if( ValidAttachment( BIPOD, gpItem ) )
|
||||
{
|
||||
guiAttachmentButton[ BIPOD_ATTACHMENT_BUTTON ] =
|
||||
CreateTextButton( L"BIPOD", SMALLCOMPFONT, FONT_YELLOW, FONT_BLACK, BUTTON_USE_DEFAULT,
|
||||
@@ -723,7 +723,7 @@ void SetupGunGUI()
|
||||
}
|
||||
}
|
||||
guiAttachmentButton[ DUCKBILL_ATTACHMENT_BUTTON ] = -1;
|
||||
if( ValidAttachment( DUCKBILL, gpItem->usItem ) )
|
||||
if( ValidAttachment( DUCKBILL, gpItem ) )
|
||||
{
|
||||
guiAttachmentButton[ DUCKBILL_ATTACHMENT_BUTTON ] =
|
||||
CreateTextButton( L"DUCKBILL", SMALLCOMPFONT, FONT_YELLOW, FONT_BLACK, BUTTON_USE_DEFAULT,
|
||||
@@ -736,7 +736,7 @@ void SetupGunGUI()
|
||||
}
|
||||
}
|
||||
guiAttachmentButton[ GLAUNCHER_ATTACHMENT_BUTTON ] = -1;
|
||||
if( ValidAttachment( UNDER_GLAUNCHER, gpItem->usItem ) )
|
||||
if( ValidAttachment( UNDER_GLAUNCHER, gpItem ) )
|
||||
{
|
||||
guiAttachmentButton[ GLAUNCHER_ATTACHMENT_BUTTON ] =
|
||||
CreateTextButton( L"G-LAUNCHER", SMALLCOMPFONT, FONT_YELLOW, FONT_BLACK, BUTTON_USE_DEFAULT,
|
||||
@@ -855,7 +855,7 @@ void SetupArmourGUI()
|
||||
}
|
||||
|
||||
guiCeramicPlatesButton = -1;
|
||||
if( ValidAttachment( CERAMIC_PLATES, gpItem->usItem ) )
|
||||
if( ValidAttachment( CERAMIC_PLATES, gpItem ) )
|
||||
{
|
||||
guiCeramicPlatesButton =
|
||||
CreateTextButton( L"CERAMIC PLATES", SMALLCOMPFONT, FONT_YELLOW, FONT_BLACK, BUTTON_USE_DEFAULT,
|
||||
@@ -1012,7 +1012,7 @@ void SetupExplosivesGUI()
|
||||
yp = 375;
|
||||
gfDetonator = FALSE;
|
||||
guiDetonatorButton = -1;
|
||||
if( ValidAttachment( DETONATOR, gpItem->usItem ) )
|
||||
if( ValidAttachment( DETONATOR, gpItem ) )
|
||||
{
|
||||
guiDetonatorButton =
|
||||
CreateTextButton( L"DETONATOR", SMALLCOMPFONT, FONT_YELLOW, FONT_BLACK, BUTTON_USE_DEFAULT,
|
||||
|
||||
@@ -43,9 +43,11 @@
|
||||
#include "Item Statistics.h"
|
||||
#include "Scheduling.h"
|
||||
#include "MessageBoxScreen.h"
|
||||
#include "VFS/vfs.h"//dnl ch37 110909
|
||||
#include <vfs/Core/vfs.h>//dnl ch37 110909
|
||||
#endif
|
||||
|
||||
INT16 gsMouseWheelDeltaValue;
|
||||
|
||||
//===========================================================================
|
||||
|
||||
BOOLEAN gfErrorCatch = FALSE;
|
||||
@@ -190,7 +192,7 @@ void LoadSaveScreenEntry()
|
||||
vfs::CVirtualProfile::FileIterator fit = prof->files(L"MAPS/*");
|
||||
while(!fit.end())
|
||||
{
|
||||
utf8string fname = fit.value()->getName().c_str();
|
||||
vfs::String fname = fit.value()->getName().c_str();
|
||||
memset(&FileInfo, 0, sizeof(GETFILESTRUCT));
|
||||
strcpy(FileInfo.zFileName, fname.utf8().c_str());
|
||||
FileInfo.uiFileSize = fname.length();
|
||||
@@ -1013,8 +1015,7 @@ UINT32 ProcessFileIO()
|
||||
return(EDIT_SCREEN);
|
||||
}
|
||||
gbCurrentFileIOStatus = IOSTATUS_NONE;
|
||||
utf8string msg = utf8string(" Error saving ") + ubNewFilename + utf8string(" file. Try another filename? ");
|
||||
CreateMessageBox((STR16)msg.c_wcs().c_str());
|
||||
CreateMessageBox((STR16)(_BS(L" Error saving ") << (const char*)ubNewFilename << L" file. Try another filename? " << _BS::wget).c_str() );
|
||||
return(guiCurrentScreen);
|
||||
}
|
||||
if( gfShowPits )
|
||||
@@ -1035,6 +1036,9 @@ UINT32 ProcessFileIO()
|
||||
InitErrorCatchDialog();
|
||||
return EDIT_SCREEN;
|
||||
}
|
||||
|
||||
fNewMapSaved = TRUE;
|
||||
|
||||
return EDIT_SCREEN;
|
||||
case INITIATE_MAP_LOAD: //draw load message
|
||||
SaveFontSettings();
|
||||
@@ -1056,8 +1060,7 @@ UINT32 ProcessFileIO()
|
||||
gbCurrentFileIOStatus = IOSTATUS_NONE;
|
||||
gfGlobalError = FALSE;
|
||||
gfLoadError = TRUE;
|
||||
utf8string msg = utf8string(" Error loading ") + ubNewFilename + utf8string(" file. Try another filename? ");
|
||||
CreateMessageBox((STR16)msg.c_wcs().c_str());
|
||||
CreateMessageBox((STR16)(_BS(L" Error loading ") << (const char*)ubNewFilename << L" file. Try another filename? " << _BS::wget).c_str());
|
||||
return(guiCurrentScreen);
|
||||
}
|
||||
//ADB these are NOT set yet! but they need to be, duh
|
||||
|
||||
@@ -42,6 +42,8 @@ BOOLEAN ValidMapFileName(STR16 szFilename);
|
||||
BOOLEAN ExternalLoadMap(STR16 szFilename);
|
||||
BOOLEAN ExternalSaveMap(STR16 szFilename);
|
||||
|
||||
void InitErrorCatchDialog();
|
||||
|
||||
extern BOOLEAN gfErrorCatch;
|
||||
extern CHAR16 gzErrorCatchString[ 256 ];
|
||||
|
||||
|
||||
+18
-10
@@ -39,10 +39,11 @@
|
||||
#include "Soldier Create.h"
|
||||
#include "GameVersion.h"
|
||||
#include "Campaign Types.h"
|
||||
#include "GameSettings.h"
|
||||
#endif
|
||||
|
||||
#include "VFS/vfs.h"
|
||||
#include "VFS/vfs_file_raii.h"
|
||||
#include <vfs/Core/vfs.h>
|
||||
#include <vfs/Core/vfs_file_raii.h>
|
||||
|
||||
extern BOOLEAN gfOverheadMapDirty;
|
||||
|
||||
@@ -416,9 +417,10 @@ void CreateSummaryWindow()
|
||||
if( gfAutoLoadA9 )
|
||||
{
|
||||
gfAutoLoadA9++;
|
||||
gsSelSectorX = 9;
|
||||
gsSelSectorY = 1;
|
||||
gpCurrentSectorSummary = gpSectorSummary[ 8 ][ 0 ][ 0 ];
|
||||
gsSelSectorX = gGameExternalOptions.ubDefaultArrivalSectorX;//9;
|
||||
gsSelSectorY = gGameExternalOptions.ubDefaultArrivalSectorY;//1;
|
||||
//gpCurrentSectorSummary = gpSectorSummary[ 8 ][ 0 ][ 0 ];
|
||||
gpCurrentSectorSummary = gpSectorSummary[ gGameExternalOptions.ubDefaultArrivalSectorX - 1 ][ gGameExternalOptions.ubDefaultArrivalSectorY - 1 ][ 0 ];
|
||||
ButtonList[ iSummaryButton[ SUMMARY_LOAD ] ]->uiFlags |= BUTTON_CLICKED_ON;
|
||||
}
|
||||
}
|
||||
@@ -761,6 +763,7 @@ void RenderItemDetails()
|
||||
pItem = &gpWorldItemsSummaryArray[ i ].object;
|
||||
uiExistChance += (100 - gpWorldItemsSummaryArray[ i ].ubNonExistChance) * pItem->ubNumberOfObjects;
|
||||
uiStatus += (*pItem)[0]->data.objectStatus;
|
||||
uiQuantity += pItem->ubNumberOfObjects;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1965,7 +1968,7 @@ void CreateGlobalSummary()
|
||||
vfs::COpenWriteFile wfile(L"DevInfo\\readme.txt",true,true);
|
||||
std::string str = "This information is used in conjunction with the editor.\n";
|
||||
str += "This directory or it's contents shouldn't be included with final release.\n";
|
||||
TRYCATCH_RETHROW( wfile.file().write(str.c_str(), str.length()), L"" );
|
||||
SGP_TRYCATCH_RETHROW( wfile->write(str.c_str(), str.length()), L"" );
|
||||
#endif
|
||||
|
||||
// Snap: Restore the data directory once we are finished.
|
||||
@@ -2155,6 +2158,8 @@ void SummaryLoadMapCallback( GUI_BUTTON *btn, INT32 reason )
|
||||
SetFontForeground( FONT_LTKHAKI );
|
||||
SetFontShadow( FONT_NEARBLACK );
|
||||
|
||||
fNewMapSaved = TRUE;
|
||||
|
||||
//swprintf( str, L"Loading map: %s...", gszDisplayName );
|
||||
//mprintf( MAP_LEFT, MAP_BOTTOM+100, str );
|
||||
//InvalidateRegion( MAP_LEFT, MAP_BOTTOM+100, MAP_LEFT+150, MAP_BOTTOM+110 );
|
||||
@@ -2640,11 +2645,11 @@ void GenerateSummaryList()
|
||||
vfs::COpenWriteFile wfile(L"DevInfo/readme.txt",true,true);
|
||||
std::string str = "This information is used in conjunction with the editor.\n";
|
||||
str += "This directory or it's contents shouldn't be included with final release.\n";
|
||||
TRYCATCH_RETHROW( wfile.file().write(str.c_str(), str.length()), L"");
|
||||
SGP_TRYCATCH_RETHROW( wfile->write(str.c_str(), str.length()), L"");
|
||||
}
|
||||
catch(CBasicException &ex)
|
||||
catch(std::exception &ex)
|
||||
{
|
||||
RETHROWEXCEPTION(L"Could not create readme.txt",&ex);
|
||||
SGP_RETHROW(L"Could not create readme.txt", ex);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
@@ -3220,6 +3225,9 @@ void SetupItemDetailsMode( BOOLEAN fAllowRecursion )
|
||||
OBJECTTYPE *pItem;
|
||||
UINT16 usPEnemyIndex, usNEnemyIndex;
|
||||
|
||||
SUMMARYFILE *s = gpCurrentSectorSummary;
|
||||
MAPCREATE_STRUCT *m = &gpCurrentSectorSummary->MapInfo;
|
||||
|
||||
//Clear memory for all the item summaries loaded
|
||||
if( gpWorldItemsSummaryArray )
|
||||
{
|
||||
@@ -3291,7 +3299,7 @@ void SetupItemDetailsMode( BOOLEAN fAllowRecursion )
|
||||
gusWorldItemsSummaryArraySize = gpCurrentSectorSummary->usNumItems;
|
||||
for (unsigned int x = 0; x < uiNumItems; ++x)
|
||||
{
|
||||
gpWorldItemsSummaryArray[x].Load(hfile);
|
||||
gpWorldItemsSummaryArray[x].Load(hfile, s->dMajorMapVersion, m->ubMapVersion);
|
||||
}
|
||||
|
||||
//NOW, do the enemy's items!
|
||||
|
||||
+2
-1
@@ -365,8 +365,9 @@ void PasteSingleWallCommon( INT32 iMapIndex )
|
||||
// TEMP STUFF FOR ONROOF THINGS!
|
||||
if ( (usUseObjIndex >= FIRSTONROOF) && (usUseObjIndex <= SECONDONROOF ) )
|
||||
{
|
||||
// WANNE: Disabled the next line, because if makes placing sandbags on rooftops impossible!
|
||||
//dnl Remove all onroof things before placing new one to avoid stacking problems of same element
|
||||
RemoveAllOnRoofsOfTypeRange( iMapIndex, FIRSTONROOF, SECONDONROOF );
|
||||
//RemoveAllOnRoofsOfTypeRange( iMapIndex, FIRSTONROOF, SECONDONROOF );
|
||||
|
||||
// Add to onroof section!
|
||||
AddOnRoofToTail( iMapIndex, (UINT16)(gTileTypeStartIndex[ usUseObjIndex ] + usUseIndex) );
|
||||
|
||||
@@ -214,6 +214,7 @@ BOOLEAN gfRealGunNut = TRUE;
|
||||
INT16 sGridX, sGridY;
|
||||
INT32 iMapIndex;
|
||||
BOOLEAN fNewMap = FALSE;
|
||||
BOOLEAN fNewMapSaved = TRUE;
|
||||
|
||||
INT32 iPrevDrawMode = DRAW_MODE_NOTHING;
|
||||
UINT16 PrevCurrentPaste = FIRSTTEXTURE;
|
||||
@@ -297,7 +298,8 @@ BOOLEAN EditModeInit( void )
|
||||
|
||||
//dnl after multiplayer stuff was implemeted, editor goes to assertion when you leave editor mode, because InitGameOption() is not called anymore from InitializeGame()
|
||||
is_networked = FALSE;
|
||||
InitGameOptions();
|
||||
//InitGameOptions();
|
||||
GameInitOptionsScreenInit();
|
||||
|
||||
ResetCustomFileSectorSummary();//dnl ch30 150909
|
||||
|
||||
@@ -375,6 +377,7 @@ BOOLEAN EditModeInit( void )
|
||||
|
||||
gfEditMode = TRUE;
|
||||
fNewMap = FALSE;
|
||||
fNewMapSaved = TRUE;
|
||||
|
||||
gfEditingDoor = FALSE;
|
||||
|
||||
@@ -2483,6 +2486,8 @@ void CreateNewMap()
|
||||
ResetCustomFileSectorSummary();//dnl ch30 150909
|
||||
SetRenderCenter(WORLD_COLS/2, WORLD_ROWS/2);//dnl ch43 280909
|
||||
InitRenderParams(gMapInformation.ubRestrictedScrollID);//dnl ch54 101009
|
||||
|
||||
fNewMapSaved = FALSE;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -14,6 +14,9 @@ extern GUI_BUTTON *gpPersistantButton;
|
||||
|
||||
extern UINT16 GenericButtonFillColors[40];
|
||||
|
||||
// WANNE: 05.10.2010
|
||||
extern BOOLEAN fNewMapSaved;
|
||||
|
||||
void DisplayWayPoints(void);
|
||||
|
||||
BOOLEAN CheckForSlantRoofs( void );
|
||||
|
||||
@@ -185,36 +185,36 @@ void CreateJA2SelectionWindow( INT16 sWhat )
|
||||
DisableEditorTaskbar( );
|
||||
|
||||
// Load up the button images
|
||||
iButtonIcons[ CANCEL_ICON ] = LoadGenericButtonIcon( "EDITOR//bigX.sti" );
|
||||
iButtonIcons[ UP_ICON ] = LoadGenericButtonIcon( "EDITOR//lgUpArrow.sti" );
|
||||
iButtonIcons[ DOWN_ICON ] = LoadGenericButtonIcon( "EDITOR//lgDownArrow.sti" );
|
||||
iButtonIcons[ OK_ICON ] = LoadGenericButtonIcon( "EDITOR//checkmark.sti" );
|
||||
iButtonIcons[ SEL_WIN_CANCEL_ICON ] = LoadGenericButtonIcon( "EDITOR//bigX.sti" );
|
||||
iButtonIcons[ SEL_WIN_UP_ICON ] = LoadGenericButtonIcon( "EDITOR//lgUpArrow.sti" );
|
||||
iButtonIcons[ SEL_WIN_DOWN_ICON ] = LoadGenericButtonIcon( "EDITOR//lgDownArrow.sti" );
|
||||
iButtonIcons[ SEL_WIN_OK_ICON ] = LoadGenericButtonIcon( "EDITOR//checkmark.sti" );
|
||||
|
||||
iSelectWin = CreateHotSpot(0, 0, 600, 360, MSYS_PRIORITY_HIGH,
|
||||
DEFAULT_MOVE_CALLBACK, SelWinClkCallback);
|
||||
|
||||
iCancelWin = CreateIconButton((INT16)iButtonIcons[CANCEL_ICON], 0,
|
||||
iCancelWin = CreateIconButton((INT16)iButtonIcons[SEL_WIN_CANCEL_ICON], 0,
|
||||
BUTTON_USE_DEFAULT, 600, 40,
|
||||
40, 40, BUTTON_TOGGLE,
|
||||
MSYS_PRIORITY_HIGH,
|
||||
DEFAULT_MOVE_CALLBACK, CnclClkCallback);
|
||||
SetButtonFastHelpText(iCancelWin,L"Cancel selections");
|
||||
|
||||
iOkWin = CreateIconButton((INT16)iButtonIcons[OK_ICON], 0,
|
||||
iOkWin = CreateIconButton((INT16)iButtonIcons[SEL_WIN_OK_ICON], 0,
|
||||
BUTTON_USE_DEFAULT, 600, 0,
|
||||
40, 40, BUTTON_TOGGLE,
|
||||
MSYS_PRIORITY_HIGH,
|
||||
DEFAULT_MOVE_CALLBACK, OkClkCallback);
|
||||
SetButtonFastHelpText(iOkWin,L"Accept selections");
|
||||
|
||||
iScrollUp = CreateIconButton((INT16)iButtonIcons[UP_ICON], 0,
|
||||
iScrollUp = CreateIconButton((INT16)iButtonIcons[SEL_WIN_UP_ICON], 0,
|
||||
BUTTON_USE_DEFAULT, 600, 80,
|
||||
40, 160, BUTTON_NO_TOGGLE,
|
||||
MSYS_PRIORITY_HIGH,
|
||||
DEFAULT_MOVE_CALLBACK, UpClkCallback);
|
||||
SetButtonFastHelpText(iScrollUp,L"Scroll window up");
|
||||
|
||||
iScrollDown = CreateIconButton((INT16)iButtonIcons[DOWN_ICON], 0,
|
||||
iScrollDown = CreateIconButton((INT16)iButtonIcons[SEL_WIN_DOWN_ICON], 0,
|
||||
BUTTON_USE_DEFAULT, 600, 240,
|
||||
40, 160, BUTTON_NO_TOGGLE,
|
||||
MSYS_PRIORITY_HIGH,
|
||||
|
||||
+4
-4
@@ -10,10 +10,10 @@
|
||||
#include "mousesystem.h"
|
||||
#include "Button System.h"
|
||||
|
||||
#define CANCEL_ICON 0
|
||||
#define UP_ICON 1
|
||||
#define DOWN_ICON 2
|
||||
#define OK_ICON 3
|
||||
#define SEL_WIN_CANCEL_ICON 0
|
||||
#define SEL_WIN_UP_ICON 1
|
||||
#define SEL_WIN_DOWN_ICON 2
|
||||
#define SEL_WIN_OK_ICON 3
|
||||
|
||||
extern INT32 iButtonIcons[4];
|
||||
extern INT32 iSelectWin,iCancelWin,iScrollUp,iScrollDown;
|
||||
|
||||
+4
-2
@@ -30,7 +30,8 @@ INT32 giX1, giX2, giY1, giY2;
|
||||
INT16 gsFadeRealCount;
|
||||
BOOLEAN gfFadeInVideo;
|
||||
|
||||
UINT32 uiOldMusicMode;
|
||||
// unused
|
||||
//UINT32 uiOldMusicMode;
|
||||
|
||||
FADE_FUNCTION gFadeFunction = NULL;
|
||||
|
||||
@@ -154,7 +155,8 @@ void BeginFade( UINT32 uiExitScreen, INT8 bFadeValue, INT8 bType, UINT32 uiDelay
|
||||
gfFadeIn = FALSE;
|
||||
gfFadeInVideo = TRUE;
|
||||
|
||||
uiOldMusicMode = uiMusicHandle;
|
||||
// unused
|
||||
//uiOldMusicMode = uiMusicHandle;
|
||||
|
||||
|
||||
// Calculate step;
|
||||
|
||||
+1548
-865
File diff suppressed because it is too large
Load Diff
@@ -6,7 +6,7 @@ UINT32 GameInitOptionsScreenInit( void );
|
||||
UINT32 GameInitOptionsScreenHandle( void );
|
||||
UINT32 GameInitOptionsScreenShutdown( void );
|
||||
|
||||
|
||||
BOOLEAN SpIniExists();
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
+735
-101
File diff suppressed because it is too large
Load Diff
+541
-26
@@ -38,9 +38,9 @@ enum
|
||||
|
||||
//Madd:
|
||||
TOPTION_GL_BURST_CURSOR,
|
||||
TOPTION_DROP_ALL,
|
||||
TOPTION_ALLOW_TAUNTS, // changed from drop all - SANDRO
|
||||
TOPTION_GL_HIGH_ANGLE,
|
||||
TOPTION_AIM_LEVEL_RESTRICTION,
|
||||
TOPTION_ALLOW_REAL_TIME_SNEAK, // changed from aim levels restriction - SANDRO
|
||||
|
||||
//lalien
|
||||
TOPTION_SPACE_SELECTS_NEXT_SQUAD,
|
||||
@@ -49,7 +49,7 @@ enum
|
||||
TOPTION_TRACERS_FOR_SINGLE_FIRE,
|
||||
TOPTION_RAIN_SOUND,
|
||||
TOPTION_ALLOW_CROWS,
|
||||
TOPTION_ALLOW_SOLDIER_TOOLTIPS, // Changed from TOPTION_USE_RANDOM_PERSONALITY - SANDRO
|
||||
TOPTION_ALLOW_SOLDIER_TOOLTIPS,
|
||||
TOPTION_USE_AUTO_SAVE,
|
||||
TOPTION_SILENT_SKYRIDER,
|
||||
TOPTION_LOW_CPU_USAGE,
|
||||
@@ -61,6 +61,15 @@ enum
|
||||
// HEADROCK HAM 3.6:
|
||||
TOPTION_STAT_PROGRESS_BARS,
|
||||
|
||||
// HEADROCK HAM 4:
|
||||
TOPTION_REPORT_MISS_MARGIN,
|
||||
|
||||
// HEADROCK HAM 4:
|
||||
TOPTION_ALT_MAP_COLOR,
|
||||
|
||||
// WANNE: Moved alternate bullets graphics (tracers) to options
|
||||
TOPTION_ALTERNATE_BULLET_GRAPHICS,
|
||||
|
||||
// arynn: Debug/Cheat
|
||||
TOPTION_CHEAT_MODE_OPTIONS_HEADER,
|
||||
TOPTION_FORCE_BOBBY_RAY_SHIPMENTS, // force all pending Bobby Ray shipments
|
||||
@@ -113,7 +122,13 @@ typedef struct
|
||||
enum
|
||||
{
|
||||
INVENTORY_OLD = 0,
|
||||
INVENTORY_NEW = 1
|
||||
INVENTORY_NEW = 1,
|
||||
};
|
||||
|
||||
enum
|
||||
{
|
||||
ATTACHMENT_OLD = 0,
|
||||
ATTACHMENT_NEW = 1,
|
||||
};
|
||||
|
||||
|
||||
@@ -144,6 +159,16 @@ enum
|
||||
BR_AWESOME = 10,
|
||||
};
|
||||
|
||||
// Added by SANDRO
|
||||
enum
|
||||
{
|
||||
ITEM_PROGRESS_VERY_SLOW = 0,
|
||||
ITEM_PROGRESS_SLOW,
|
||||
ITEM_PROGRESS_NORMAL,
|
||||
ITEM_PROGRESS_FAST,
|
||||
ITEM_PROGRESS_VERY_FAST,
|
||||
};
|
||||
|
||||
typedef struct
|
||||
{
|
||||
BOOLEAN fGunNut;
|
||||
@@ -154,11 +179,21 @@ typedef struct
|
||||
BOOLEAN fIronManMode;
|
||||
UINT8 ubBobbyRay;
|
||||
UINT8 ubInventorySystem;
|
||||
UINT8 ubFiller[6];
|
||||
UINT8 ubAttachmentSystem;
|
||||
// SANDRO - added variables
|
||||
UINT8 ubMaxIMPCharacters;
|
||||
BOOLEAN fNewTraitSystem;
|
||||
BOOLEAN fEnableAllTerrorists;
|
||||
BOOLEAN fEnemiesDropAllItems;
|
||||
UINT8 ubProgressSpeedOfItemsChoices;
|
||||
BOOLEAN fEnableAllWeaponCaches;
|
||||
//UINT8 ubFiller[];
|
||||
|
||||
} GAME_OPTIONS;
|
||||
|
||||
bool UsingNewInventorySystem();
|
||||
bool UsingNewAttachmentSystem();
|
||||
bool UsingNewCTHSystem();
|
||||
BOOLEAN IsNIVModeValid(bool checkRes = true);
|
||||
|
||||
// Snap: Options read from an INI file in the default of custom Data directory
|
||||
@@ -178,19 +213,20 @@ typedef struct
|
||||
// WDS: Allow flexible numbers of IMPs of each sex
|
||||
INT32 iIMPMaleCharacterCount; // Count of how many there are
|
||||
INT32 iIMPFemaleCharacterCount;
|
||||
INT32 iMaxIMPCharacters; // Limit of how many to allow
|
||||
//INT32 iMaxIMPCharacters; // Limit of how many to allow
|
||||
//
|
||||
// iaIMPSlots is an array of the slots (in prof.dat) to use for IMPs.
|
||||
//
|
||||
INT32 *iaIMPSlots;
|
||||
|
||||
// SANDRO was here - some changes done
|
||||
INT32 iIMPProfileCost;
|
||||
BOOLEAN fDynamicIMPProfileCost;
|
||||
INT32 iMinAttribute;
|
||||
INT32 iMaxAttribute;
|
||||
INT32 iImpAttributePoints;
|
||||
INT32 iMaxZeroBonus;
|
||||
INT32 iStartAttribute;
|
||||
|
||||
// These 3 added - SANDRO
|
||||
INT32 iIMPStartingLevelCostMultiplier;
|
||||
INT32 iBonusPointsForDisability;
|
||||
INT32 iBonusPointsPerSkillNotTaken;
|
||||
@@ -225,22 +261,49 @@ typedef struct
|
||||
|
||||
BOOLEAN fMercDayOne;
|
||||
BOOLEAN fAllMercsAvailable;
|
||||
|
||||
//BOOLEAN fPers_att;
|
||||
|
||||
// These 2 removed - SANDRO
|
||||
//INT8 iCustomPersonality;
|
||||
//INT8 iCustomAttitude;
|
||||
|
||||
// tais: Any AIM merc on assignment?
|
||||
UINT8 fMercsOnAssignment;
|
||||
// tais: Soldiers wear any armour
|
||||
UINT8 fSoldiersWearAnyArmour;
|
||||
|
||||
INT8 iEasyAPBonus;
|
||||
INT8 iExperiencedAPBonus;
|
||||
INT8 iExpertAPBonus;
|
||||
INT8 iInsaneAPBonus;
|
||||
INT8 iPlayerAPBonus;
|
||||
|
||||
////////////////////////////////////
|
||||
// added by SANDRO
|
||||
INT16 sEnemyAdminCtHBonusPercent;
|
||||
INT16 sEnemyRegularCtHBonusPercent;
|
||||
INT16 sEnemyEliteCtHBonusPercent;
|
||||
|
||||
INT8 sEnemyAdminDamageResistance;
|
||||
INT8 sEnemyRegularDamageResistance;
|
||||
INT8 sEnemyEliteDamageResistance;
|
||||
|
||||
BOOLEAN fAssignTraitsToEnemy;
|
||||
BOOLEAN fAssignTraitsToMilitia;
|
||||
INT8 bAssignedTraitsRarity;
|
||||
|
||||
BOOLEAN fCamoRemoving;
|
||||
BOOLEAN fEnhancedCloseCombatSystem;
|
||||
|
||||
UINT16 usAwardSpecialExpForQuests;
|
||||
////////////////////////////////////
|
||||
|
||||
// Kaiden: Vehicle Inventory change - Added for INI Option
|
||||
BOOLEAN fVehicleInventory;
|
||||
|
||||
BOOLEAN fEnableChanceOfEnemyAmbushesOnInsaneDifficult;
|
||||
///////////////////////////////////////
|
||||
// changed/added these - SANDRO
|
||||
UINT8 sMercsAutoresolveOffenseBonus;
|
||||
UINT8 sMercsAutoresolveDeffenseBonus;
|
||||
BOOLEAN fEnableChanceOfEnemyAmbushes;
|
||||
INT8 bChanceModifierEnemyAmbushes;
|
||||
UINT8 usSpecialNPCStronger;
|
||||
///////////////////////////////////////
|
||||
|
||||
// System settings
|
||||
UINT8 gubDeadLockDelay;
|
||||
@@ -285,7 +348,22 @@ typedef struct
|
||||
//UINT32 guiMaxMilitiaSquadSize;
|
||||
//UINT32 guiMaxMilitiaSquadSizeBattle;
|
||||
|
||||
//BOOLEAN gfAllowSoldierToolTips; // moved to prefereces - SANDRO
|
||||
// SANDRO - added some variables
|
||||
INT16 sGreenMilitiaAutoresolveStrength;
|
||||
INT16 sRegularMilitiaAutoresolveStrength;
|
||||
INT16 sVeteranMilitiaAutoresolveStrength;
|
||||
INT8 bGreenMilitiaAPsBonus;
|
||||
INT8 bRegularMilitiaAPsBonus;
|
||||
INT8 bVeteranMilitiaAPsBonus;
|
||||
INT16 sGreenMilitiaCtHBonusPercent;
|
||||
INT16 sRegularMilitiaCtHBonusPercent;
|
||||
INT16 sVeteranMilitiaCtHBonusPercent;
|
||||
INT8 bGreenMilitiaDamageResistance;
|
||||
INT8 bRegularMilitiaDamageResistance;
|
||||
INT8 bVeteranMilitiaDamageResistance;
|
||||
INT8 bGreenMilitiaEquipmentQualityModifier;
|
||||
INT8 bRegularMilitiaEquipmentQualityModifier;
|
||||
INT8 bVeteranMilitiaEquipmentQualityModifier;
|
||||
|
||||
// WDS - Improve Tony's and Devin's inventory like BR's
|
||||
BOOLEAN tonyUsesBRSetting;
|
||||
@@ -335,9 +413,6 @@ typedef struct
|
||||
UINT32 ubGameProgressMinimum;
|
||||
INT32 bGameProgressModifier;
|
||||
|
||||
// WDS - Advanced start
|
||||
//UINT32 ubIMPStartingLevel; // removed - SANDRO
|
||||
|
||||
// Event settings
|
||||
UINT32 ubGameProgressStartMadlabQuest;
|
||||
UINT32 ubGameProgressMikeAvailable;
|
||||
@@ -357,6 +432,7 @@ typedef struct
|
||||
|
||||
INT32 iExplosivesDamageModifier;
|
||||
INT32 iGunDamageModifier;
|
||||
INT32 iGunRangeModifier;
|
||||
INT32 iMeleeDamageModifier;
|
||||
|
||||
UINT32 ubEasyEnemyStartingAlertLevel;
|
||||
@@ -414,6 +490,10 @@ typedef struct
|
||||
|
||||
BOOLEAN gfUseExternalLoadscreens;
|
||||
|
||||
//tais: nsgi
|
||||
BOOLEAN gfUseNewStartingGearInterface;
|
||||
// DBrot: Seperate Starting items for Experts
|
||||
BOOLEAN fExpertsGetDifferentChoices;
|
||||
BOOLEAN gfUseAutoSave;
|
||||
|
||||
//Merc Assignment settings
|
||||
@@ -448,8 +528,9 @@ typedef struct
|
||||
//Misc settings
|
||||
BOOLEAN fAmmoDynamicWeight; //Pulmu
|
||||
BOOLEAN fEnableCrepitus;
|
||||
BOOLEAN fEnableAllWeaponCaches;
|
||||
BOOLEAN fEnableAllTerrorists;
|
||||
// SANDRO was here - removed these two
|
||||
//BOOLEAN fEnableAllWeaponCaches;
|
||||
//BOOLEAN fEnableAllTerrorists;
|
||||
BOOLEAN gfRevealItems;
|
||||
BOOLEAN fEnableArmorCoverage; // ShadoWarrior for Captain J's armor coverage
|
||||
|
||||
@@ -465,6 +546,7 @@ typedef struct
|
||||
BOOLEAN fEnableSoldierTooltipAttitude;
|
||||
BOOLEAN fEnableSoldierTooltipActionPoints;
|
||||
BOOLEAN fEnableSoldierTooltipHealth;
|
||||
BOOLEAN fEnableSoldierTooltipTraits; // added by SANDRO
|
||||
BOOLEAN fEnableSoldierTooltipHelmet;
|
||||
BOOLEAN fEnableSoldierTooltipVest;
|
||||
BOOLEAN fEnableSoldierTooltipLeggings;
|
||||
@@ -495,8 +577,8 @@ typedef struct
|
||||
// Lesh: slow enemy items choice progress
|
||||
BOOLEAN fSlowProgressForEnemyItemsChoice;
|
||||
|
||||
//afp - use bullet tracers
|
||||
BOOLEAN gbBulletTracer;
|
||||
//afp - use bullet tracers
|
||||
BOOLEAN gbBulletTracer;
|
||||
|
||||
// CHRISL: option to allow Slay to remain as a hired PC
|
||||
BOOLEAN fEnableSlayForever;
|
||||
@@ -510,10 +592,42 @@ BOOLEAN gbBulletTracer;
|
||||
// HEADROCK: Enhanced Item Description Box ON/OFF
|
||||
// WANNE: Changed from BOOLEAN to INT32!
|
||||
INT32 iEnhancedDescriptionBox;
|
||||
|
||||
//WarmSteel - New Attachment System?
|
||||
BOOLEAN fUseDefaultSlots;
|
||||
UINT32 usAttachmentDropRate;
|
||||
INT16 iMaxEnemyAttachments;
|
||||
|
||||
//** ddd
|
||||
//enable ext mouse key
|
||||
BOOLEAN fExtMouseKeyEnabled;
|
||||
// for small progress bar
|
||||
BOOLEAN fSmallSizeProgressbar;
|
||||
// stamina multiplier (for all weapons eg knife fist gun
|
||||
INT32 uStaminaHit;
|
||||
//enable ext mouse key
|
||||
BOOLEAN bAltAimEnabled;
|
||||
BOOLEAN bAimedBurstEnabled;
|
||||
INT16 uAimedBurstPenalty;
|
||||
BOOLEAN bWeSeeWhatMilitiaSeesAndViceVersa;
|
||||
BOOLEAN bAllowWearSuppressor;
|
||||
BOOLEAN bLazyCivilians;
|
||||
INT16 iChanceSayAnnoyingPhrase;
|
||||
BOOLEAN bNewTacticalAIBehavior;
|
||||
FLOAT uShotHeadPenalty;
|
||||
FLOAT fShotHeadDivisor;
|
||||
INT16 iPenaltyShootUnSeen;
|
||||
|
||||
FLOAT fOutOfGunRangeOrSight;
|
||||
// WANNE: Always use "prof.dat".
|
||||
BOOLEAN fUseDifficultyBasedProfDat;
|
||||
|
||||
// 2Points: Use new repair algorithm
|
||||
BOOLEAN fAdditionalRepairMode;
|
||||
|
||||
// CHRISL: Skyrider and enemy occupied sectors
|
||||
UINT8 ubSkyriderHotLZ;
|
||||
|
||||
// CPT: Cover System Settings
|
||||
UINT8 ubStealthTraitCoverValue;
|
||||
UINT8 ubStealthEffectiveness;
|
||||
@@ -566,12 +680,26 @@ BOOLEAN gbBulletTracer;
|
||||
// HEADROCK HAM B2.5: Realistic tracers - CTH increased by this amount whenever a tracer is fired. 0 = off.
|
||||
UINT8 ubCTHBumpPerTracer;
|
||||
|
||||
// CHRISL: Exeternalize the minimum range at which tracers can improve autofire hit chance
|
||||
UINT16 ubMinRangeTracerEffect;
|
||||
|
||||
// HEADROCK HAM B2.6: Increased aiming costs?
|
||||
BOOLEAN fIncreasedAimingCost;
|
||||
|
||||
// added by SANDRO
|
||||
BOOLEAN fAimLevelRestriction;
|
||||
|
||||
// HEADROCK HAM B2.6: Dynamically determine Max-Aiming based also on weapon, bipod, etc?
|
||||
BOOLEAN fDynamicAimingTime;
|
||||
|
||||
// allow old behaviour
|
||||
BOOLEAN fAimLevelsDependOnDistance;
|
||||
|
||||
//WarmSteel - These determine in which group each scope belongs. Needed for dynamic aiming limits.
|
||||
INT16 sVeryHighPowerScope;
|
||||
INT16 sHighPowerScope;
|
||||
INT16 sMediumPowerScope;
|
||||
|
||||
// HEADROCK HAM B2.6: Controls how much effect target movement has on aiming
|
||||
FLOAT iMovementEffectOnAiming;
|
||||
|
||||
@@ -661,6 +789,9 @@ BOOLEAN gbBulletTracer;
|
||||
// HEADROCK HAM 3: If enabled, tooltipping over Bobby Ray's weapons will show a list of possible attachments to those weapons.
|
||||
BOOLEAN fBobbyRayTooltipsShowAttachments;
|
||||
|
||||
// CHRISL: Converts the AutoFireToHitBonus value to a percentage for CTH calculations
|
||||
UINT8 ubFlatAFTHBtoPrecentMultiplier;
|
||||
|
||||
// HEADROCK HAM 3.1: Divisor for the AP-to-Ready cost charge on first aiming click, when extra aiming costs are enabled. 0 = No ready-time-based charge.
|
||||
UINT8 ubFirstAimReadyCostDivisor;
|
||||
|
||||
@@ -706,6 +837,9 @@ BOOLEAN gbBulletTracer;
|
||||
// HEADROCK HAM 3.3: Externalized maximum possible penalty for hitting a moving target. JA2 Default = 30.
|
||||
UINT16 usMaxCTHPenaltyForMovingTarget;
|
||||
|
||||
// CHRISL: HAM4-NCTH
|
||||
BOOLEAN fUseNCTH;
|
||||
|
||||
// HEADROCK HAM 3.3: Increases tolerance while moving.
|
||||
UINT8 ubTilesMovedPerBonusTolerancePoint;
|
||||
|
||||
@@ -800,15 +934,388 @@ BOOLEAN gbBulletTracer;
|
||||
// HEADROCK HAM 3.6: If activated, the game does not switch focus to a merc who spots an enemy in real-time mode. This fixes issues with Real-Time Sneak.
|
||||
BOOLEAN fNoAutoFocusChangeInRealtimeSneak;
|
||||
|
||||
UINT8 ubEarlyRebelsRecruitment[4]; // early recruitment of Miguel and Carlos
|
||||
// silversurfer: don't play quote when merc spots a mine? TRUE = shut up! FALSE = tell me that you found a mine!
|
||||
BOOLEAN fMineSpottedNoTalk;
|
||||
|
||||
// The_Bob - real time sneaking code 01/06/09
|
||||
// Suport disabling/silencing real time sneaking via external .ini file
|
||||
BOOLEAN fAllowRealTimeSneak;
|
||||
//BOOLEAN fAllowRealTimeSneak; // SANDRO - moved to preferences
|
||||
BOOLEAN fQuietRealTimeSneak;
|
||||
|
||||
//dnl ch51 081009 JA2 Debug Settings
|
||||
BOOLEAN fEnableInventoryPoolQ;
|
||||
//legion by Jazz
|
||||
BOOLEAN fCanJumpThroughWindows;
|
||||
BOOLEAN fCanClimbOnWalls;
|
||||
|
||||
//legion by Jazz
|
||||
BOOLEAN fIndividualHiddenPersonNames;
|
||||
|
||||
//SAveGame Slot by Jazz
|
||||
BOOLEAN fSaveGameSlot;
|
||||
|
||||
//dnl ch51 081009 JA2 Debug Settings
|
||||
BOOLEAN fEnableInventoryPoolQ;
|
||||
|
||||
//legion by Jazz
|
||||
BOOLEAN fShowTacticalFaceGear; //legion 2
|
||||
BOOLEAN fShowTacticalFaceIcons; //legion 2
|
||||
INT8 bTacticalFaceIconStyle;
|
||||
|
||||
//Enemy Names Group Legion 2 by Jazz
|
||||
BOOLEAN fEnemyNames;
|
||||
|
||||
//Civ Names Group Legion 2 by Jazz
|
||||
BOOLEAN fCivGroupName;
|
||||
|
||||
//Enemy Rank Legion 2 by Jazz
|
||||
BOOLEAN fEnemyRank;
|
||||
|
||||
BOOLEAN fShowCamouflageFaces;
|
||||
|
||||
FLOAT gMercLevelUpSalaryIncreasePercentage;
|
||||
|
||||
UINT8 ubChanceTonyAvailable; // silversurfer/SANDRO
|
||||
|
||||
BOOLEAN fStandUpAfterBattle;
|
||||
} GAME_EXTERNAL_OPTIONS;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
UINT8 ubMaxNumberOfTraits;
|
||||
UINT8 ubNumberOfMajorTraitsAllowed;
|
||||
|
||||
// GENERIC SETTINGS
|
||||
INT8 bCtHModifierAssaultRifles;
|
||||
INT8 bCtHModifierSniperRifles;
|
||||
INT8 bCtHModifierRifles;
|
||||
INT8 bCtHModifierSMGs;
|
||||
INT8 bCtHModifierLMGs;
|
||||
INT8 bCtHModifierShotguns;
|
||||
INT8 bCtHModifierPistols;
|
||||
INT8 bCtHModifierMachinePistols;
|
||||
INT8 bCtHModifierRocketLaunchers;
|
||||
INT8 bCtHModifierGrenadeLaunchers;
|
||||
INT16 sCtHModifierMortar;
|
||||
INT8 bCtHModifierThrowingKnives;
|
||||
INT8 bCtHModifierThrowingGrenades;
|
||||
INT8 bCtHModifierHtHAttack;
|
||||
INT8 bModifierDodgeHtHChance;
|
||||
INT8 bCtHModifierKnifeAttack;
|
||||
INT8 bModifierDodgeKnifeChance;
|
||||
INT8 bCtHModifierRobot;
|
||||
UINT8 ubCtHPenaltyDualShot;
|
||||
INT8 bPercentModifierHtHBreathLoss;
|
||||
INT8 bPercentModifierBladesBreathLoss;
|
||||
INT8 bPercentModifierBluntBreathLoss;
|
||||
UINT8 ubModifierForAPsAddedOnAimedPunches;
|
||||
UINT8 ubModifierForAPsAddedOnAimedBladedAttackes;
|
||||
INT8 bSpeedModifierDoctoring;
|
||||
INT8 bSpeedModifierBandaging;
|
||||
INT8 bSpeedModifierRepairing;
|
||||
INT8 bSpeedModifierTrainingMilitia;
|
||||
INT8 bSpeedModifierTeachingOthers;
|
||||
INT8 bCheckModifierLockpicking;
|
||||
INT8 bCheckModifierAttachDetonators;
|
||||
INT8 bCheckModifierSetExplosives;
|
||||
INT8 bCheckModifierDisarmExplosiveTraps;
|
||||
INT8 bCheckModifierDisarmElectronicTraps;
|
||||
INT8 bCheckModifierAttachSpecialItems;
|
||||
INT8 bTanksDamageResistanceModifier;
|
||||
UINT8 ubDamageNeededToLoseStats;
|
||||
|
||||
// AUTO WEAPONS
|
||||
UINT8 ubAWBonusCtHAssaultRifles;
|
||||
UINT8 ubAWBonusCtHSMGs;
|
||||
UINT8 ubAWBonusCtHLMGs;
|
||||
UINT8 ubAWAutoFirePenaltyReduction;
|
||||
UINT8 ubAWUnwantedBulletsReduction;
|
||||
UINT8 ubAWFiringSpeedBonusLMGs;
|
||||
UINT8 ubAWPercentReadyLMGReduction;
|
||||
|
||||
// HEAVY WEAPONS
|
||||
UINT8 ubHWGrenadeLaunchersAPsReduction;
|
||||
UINT8 ubHWRocketLaunchersAPsReduction;
|
||||
UINT8 ubHWBonusCtHGrenadeLaunchers;
|
||||
UINT8 ubHWBonusCtHRocketLaunchers;
|
||||
UINT8 ubHWMortarAPsReduction;
|
||||
UINT8 ubHWMortarCtHPenaltyReduction;
|
||||
UINT8 ubHWDamageTanksBonusPercent;
|
||||
UINT8 ubHWDamageBonusPercentForHW;
|
||||
|
||||
// SNIPER
|
||||
UINT8 ubSNBonusCtHRifles;
|
||||
UINT8 ubSNBonusCtHSniperRifles;
|
||||
UINT8 ubSNEffRangeToTargetReduction;
|
||||
UINT8 ubSNAimingBonusPerClick;
|
||||
UINT8 ubSNDamageBonusPerClick;
|
||||
UINT8 ubSNDamageBonusFromNumClicks;
|
||||
UINT8 ubSNChamberRoundAPsReduction;
|
||||
UINT8 ubSNAimClicksAdded;
|
||||
|
||||
// RANGER
|
||||
UINT8 ubRABonusCtHRifles;
|
||||
UINT8 ubRABonusCtHShotguns;
|
||||
UINT8 ubRAPumpShotgunsAPsReduction;
|
||||
UINT8 ubRAGroupTimeSpentForTravellingFoot;
|
||||
UINT8 ubRAGroupTimeSpentForTravellingVehicle;
|
||||
UINT8 ubRAMaxBonusesToTravelSpeed;
|
||||
UINT8 ubRABreathForTravellingReduction;
|
||||
UINT8 ubRAWeatherPenaltiesReduction;
|
||||
//UINT8 ubRACamoEffectivenessBonus;
|
||||
UINT8 ubRACamoWornountSpeedReduction;
|
||||
|
||||
// GUNSLINGER
|
||||
UINT8 ubGSFiringSpeedBonusPistols;
|
||||
UINT8 ubGSEffectiveRangeBonusPistols;
|
||||
UINT8 ubGSBonusCtHPistols;
|
||||
UINT8 ubGSBonusCtHMachinePistols;
|
||||
UINT8 ubGSCtHMPExcludeAuto;
|
||||
UINT8 ubGSAimingBonusPerClick;
|
||||
UINT8 ubGSPercentReadyPistolsReduction;
|
||||
UINT8 ubGSRealoadSpeedHandgunsBonus;
|
||||
UINT8 ubGSAimClicksAdded;
|
||||
|
||||
// MARTIAL ARTS
|
||||
UINT8 ubMABonusCtHBareHands;
|
||||
UINT8 ubMABonusCtHBrassKnuckles;
|
||||
UINT8 ubMAPunchAPsReduction;
|
||||
UINT8 ubMABonusDamageHandToHand;
|
||||
UINT8 ubMABonusBreathDamageHandToHand;
|
||||
UINT16 usMALostBreathRegainPenalty;
|
||||
UINT16 usMAAimedPunchDamageBonus;
|
||||
INT8 bMAAimedPunchCtHModifier;
|
||||
UINT8 ubMAChanceToDodgeHtH;
|
||||
UINT8 ubMAOnTopCTDHtHBareHanded;
|
||||
UINT8 ubMAOnTopCTDHtHBrassKnuckles;
|
||||
UINT8 ubMAChanceToDodgeMelee;
|
||||
UINT8 ubMAReducedAPsToSteal;
|
||||
UINT8 ubMAAPsChangeStanceReduction;
|
||||
UINT8 ubMAApsTurnAroundReduction;
|
||||
UINT8 ubMAAPsClimbOrJumpReduction;
|
||||
UINT8 ubMAChanceToCkickDoors;
|
||||
BOOLEAN fPermitExtraAnimationsOnlyToMA;
|
||||
|
||||
// SQUADLEADER
|
||||
UINT16 usSLRadiusNormal;
|
||||
UINT16 usSLRadiusExtendedEar;
|
||||
UINT8 ubSLMaxBonuses;
|
||||
UINT8 ubSLBonusAPsPercent;
|
||||
UINT8 ubSLEffectiveLevelInRadius;
|
||||
UINT8 ubSLEffectiveLevelAsStandby;
|
||||
UINT8 ubSLOverallSuppresionBonusPercent;
|
||||
UINT8 ubSLMoraleGainBonus;
|
||||
UINT8 ubSLMoraleLossReduction;
|
||||
UINT8 ubSLFearResistance;
|
||||
UINT8 ubSLDeathMoralelossMultiplier;
|
||||
|
||||
// TECHNICIAN
|
||||
UINT16 usTERepairSpeedBonus;
|
||||
UINT16 usTELockpickingBonus;
|
||||
UINT16 usTEDisarmElTrapBonus;
|
||||
UINT16 usTEAttachingItemsBonus;
|
||||
UINT8 ubTEUnjamGunBonus;
|
||||
UINT8 ubTERepairElectronicsPenaltyReduction;
|
||||
UINT8 ubTEChanceToDetectTrapsBonus;
|
||||
UINT8 ubTECtHControlledRobotBonus;
|
||||
UINT8 ubTERepairRobotPenaltyReduction;
|
||||
UINT8 ubTETraitsNumToRepairRobot;
|
||||
|
||||
// DOCTOR
|
||||
UINT8 ubDONumberTraitsNeededForSurgery;
|
||||
UINT8 ubDOSurgeryHealPercentBase;
|
||||
UINT8 ubDOSurgeryHealPercentOnTop;
|
||||
UINT16 usDOSurgeryMedBagConsumption;
|
||||
UINT16 usDOSurgeryMaxBreathLoss;
|
||||
UINT16 usDORepairStatsRateBasic;
|
||||
UINT16 usDORepairStatsRateOnTop;
|
||||
UINT8 ubDORepStPenaltyIfAlsoHealing;
|
||||
UINT8 ubDOHealingPenaltyIfAlsoStatRepair;
|
||||
BOOLEAN fDORepStShouldThrowMessage;
|
||||
UINT8 ubDOBandagingSpeedPercent;
|
||||
UINT16 usDODoctorAssignmentBonus;
|
||||
UINT8 ubDONaturalRegenBonus;
|
||||
UINT8 ubDOMaxRegenBonuses;
|
||||
|
||||
// AMBIDEXTROUS
|
||||
UINT8 ubAMPenaltyDoubleReduction;
|
||||
UINT8 ubAMReloadSpeedMagazines;
|
||||
UINT8 ubAMReloadSpeedLoose;
|
||||
UINT8 ubAMPickItemsAPsReduction;
|
||||
UINT8 ubAMWorkBackpackAPsReduction;
|
||||
UINT8 ubAMHandleDoorsAPsReduction;
|
||||
UINT8 ubAMHandleBombsAPsReduction;
|
||||
UINT8 ubAMAttachingItemsAPsReduction;
|
||||
|
||||
// MELEE
|
||||
UINT8 ubMEBladesAPsReduction;
|
||||
UINT8 ubMECtHBladesBonus;
|
||||
UINT8 ubMECtHBluntBonus;
|
||||
UINT8 ubMEDamageBonusBlades;
|
||||
UINT8 ubMEDamageBonusBlunt;
|
||||
UINT16 usMEAimedMeleeAttackDamageBonus;
|
||||
UINT8 ubMEDodgeBladesBonus;
|
||||
UINT8 ubMECtDBladesOnTopWithBladeInHands;
|
||||
UINT8 ubMEDodgeBluntBonus;
|
||||
UINT8 ubMECtDBluntOnTopWithBladeInHands;
|
||||
|
||||
// THROWING
|
||||
UINT8 ubTHBladesAPsReduction;
|
||||
UINT8 ubTHBladesMaxRange;
|
||||
UINT8 ubTHBladesCtHBonus;
|
||||
UINT8 ubTHBladesCtHBonusPerClick;
|
||||
UINT8 ubTHBladesDamageBonus;
|
||||
UINT8 ubTHBladesDamageBonusPerClick;
|
||||
UINT8 ubTHBladesSilentCriticalHitChance;
|
||||
UINT8 ubTHBladesCriticalHitMultiplierBonus;
|
||||
UINT8 ubTHBladesAimClicksAdded;
|
||||
|
||||
// NIGHT OPS
|
||||
UINT8 ubNOeSightRangeBonusInDark;
|
||||
UINT8 ubNOHearingRangeBonus;
|
||||
UINT8 ubNOHearingRangeBonusInDark;
|
||||
UINT8 ubNOIterruptsBonusInDark;
|
||||
UINT8 ubNONeedForSleepReduction;
|
||||
|
||||
// STEALTHY
|
||||
UINT8 ubSTStealthModeSpeedBonus;
|
||||
UINT8 ubSTBonusToMoveQuietly;
|
||||
UINT8 ubSTStealthBonus;
|
||||
UINT8 ubSTStealthPenaltyForMovingReduction;
|
||||
|
||||
// ATHLETICS
|
||||
UINT8 ubATAPsMovementReduction;
|
||||
UINT8 ubATBPsMovementReduction;
|
||||
|
||||
// BODYBUILDING
|
||||
UINT8 ubBBDamageResistance;
|
||||
UINT8 ubBBCarryWeightBonus;
|
||||
UINT8 ubBBBreathLossForHtHImpactReduction;
|
||||
UINT16 usBBIncreasedNeededDamageToFallDown;
|
||||
|
||||
// DEMOLITIONS
|
||||
UINT8 ubDEAPsNeededToThrowGrenadesReduction;
|
||||
UINT8 ubDEMaxRangeToThrowGrenades;
|
||||
UINT8 ubDECtHWhenThrowingGrenades;
|
||||
UINT8 ubDEDamageOfBombsAndMines;
|
||||
UINT8 ubDEAttachDetonatorCheckBonus;
|
||||
UINT8 ubDEPlantAndRemoveBombCheckBonus;
|
||||
UINT8 ubDEPlacedBombLevelBonus;
|
||||
UINT8 ubDEShapedChargeDamageMultiplier;
|
||||
|
||||
// TEACHING
|
||||
UINT8 ubTGBonusToTrainMilitia;
|
||||
UINT8 ubTGEffectiveLDRToTrainMilitia;
|
||||
UINT8 ubTGBonusToTeachOtherMercs;
|
||||
UINT8 ubTGEffectiveSkillValueForTeaching;
|
||||
UINT8 ubTGBonusOnPractising;
|
||||
|
||||
// SCOUTING
|
||||
UINT8 ubSCSightRangebonusWithScopes;
|
||||
UINT16 usSCSightRangebonusWithBinoculars;
|
||||
UINT8 ubSCTunnelVisionReducedWithBinoculars;
|
||||
BOOLEAN fSCCanDetectEnemyPresenseAround;
|
||||
BOOLEAN fSCCanDetermineEnemyNumbersAround;
|
||||
BOOLEAN fSCDetectionInDiagonalSectors;
|
||||
BOOLEAN fSCPreventsTheEnemyToAmbushMercs;
|
||||
BOOLEAN fSCPreventsBloodcatsAmbushes;
|
||||
BOOLEAN fSCThrowMessageIfAmbushPrevented;
|
||||
|
||||
} SKILL_TRAIT_VALUES;
|
||||
|
||||
// HEADROCK HAM 4: Constants used as coefficients by the various parts of the new CTH system.
|
||||
typedef struct
|
||||
{
|
||||
UINT32 NORMAL_SHOOTING_DISTANCE; // Distance at which 1x magnification is 100% effective. This is a major component of the entire shooting mechanism.
|
||||
FLOAT DEGREES_MAXIMUM_APERTURE; // Maximum possible aperture for a 100% muzzle sway shot. Decrease to make all shots more accurate.
|
||||
FLOAT GRAVITY_COEFFICIENT; // Changes the way gravity works in the game. Higher values mean bullets don't drop as quickly after reaching max range.
|
||||
FLOAT VERTICAL_BIAS; // This float can be used to reduce the chance of missing too far upwards or downwards (compared to left/right).
|
||||
FLOAT SCOPE_RANGE_MULTIPLIER; // Adjusts the minimum effective range of scopes
|
||||
|
||||
FLOAT BASE_EXP; // Importance of Experience for BASE CTH
|
||||
FLOAT BASE_MARKS; // Importance of Marksmanship for BASE CTH
|
||||
FLOAT BASE_WIS; // Importance of Wisdom for BASE CTH
|
||||
FLOAT BASE_DEX; // Importance of Dexterity for BASE CTH
|
||||
|
||||
FLOAT BASE_LOW_MORALE; // Applied gradually when morale is below 50.
|
||||
FLOAT BASE_HIGH_MORALE; // Applied gradually when morale is above 50.
|
||||
FLOAT BASE_PSYCHO; // Applied for each level of PSYCHO trait
|
||||
FLOAT BASE_SHOOTING_UPWARDS; // Applied gradually for shooting at a higher target. Decreases with distance.
|
||||
FLOAT BASE_INJURY; // Applied gradually for injuries
|
||||
FLOAT BASE_DRUNK[4]; // Applied for drunkness levels
|
||||
FLOAT BASE_FATIGUE; // Applied gradually for fatigue
|
||||
FLOAT BASE_SAME_TARGET; // Applied for shooting at the same target again
|
||||
FLOAT BASE_GASSED; // Applied for shooting while breathing gas
|
||||
FLOAT BASE_BEING_BANDAGED; // Applied for shooting while being bandaged
|
||||
FLOAT BASE_SHOCK; // Applied gradually for shock points
|
||||
FLOAT BASE_AGILE_TARGET; // Applied gradually for agile or experienced target
|
||||
FLOAT BASE_TARGET_INVISIBLE; // Applied for shooting at a target you can't see
|
||||
FLOAT BASE_DRAW_COST; // Applied per 1 AP of the weapon's Ready Cost, under 100AP.
|
||||
FLOAT BASE_TWO_GUNS; // Gun Difficulty Multiplier for shooting two guns
|
||||
FLOAT BASE_ONE_HANDED; // Gun Difficulty Multiplier for shooting a pistol with one hand.
|
||||
FLOAT BASE_CROUCHING_STANCE; // Gun Difficulty Multiplier for shooting from a crouched stance
|
||||
FLOAT BASE_PRONE_STANCE; // Gun Difficulty Multiplier for shooting from a prone stance
|
||||
FLOAT BASE_HEAVY_WEAPON; // Gun Difficulty Multiplier for shooting a launcher
|
||||
FLOAT BASE_DIFFICULTY[6]; // Applied for game difficulty
|
||||
|
||||
FLOAT AIM_EXP; // Importance of Experience for AIMING CTH
|
||||
FLOAT AIM_MARKS; // Importance of Marksmanship for AIMING CTH
|
||||
FLOAT AIM_WIS; // Importance of Wisdom for AIMING CTH
|
||||
FLOAT AIM_DEX; // Importance of Dexterity for AIMING CTH
|
||||
|
||||
FLOAT AIM_TOO_CLOSE_SCOPE; // Applied per tile closer than the scope's minimum range.
|
||||
FLOAT AIM_GUN_CONDITION; // Applied per point of condition below 50.
|
||||
FLOAT AIM_LOW_MORALE; // Applied gradually when morale is below 50.
|
||||
FLOAT AIM_HIGH_MORALE; // Applied gradually when morale is above 50.
|
||||
FLOAT AIM_PSYCHO; // Applied for each level of PSYCHO trait
|
||||
FLOAT AIM_VISIBILITY; // Applied for bad visibility
|
||||
FLOAT AIM_SHOOTING_UPWARDS; // Applied gradually for shooting at a higher target. Decreases with distance.
|
||||
FLOAT AIM_INJURY; // Applied gradually for injuries
|
||||
FLOAT AIM_DRUNK[4]; // Applied for drunkness levels
|
||||
FLOAT AIM_FATIGUE; // Applied gradually for fatigue
|
||||
FLOAT AIM_GASSED; // Applied for shooting while breathing gas
|
||||
FLOAT AIM_BEING_BANDAGED; // Applied for shooting while being bandaged
|
||||
FLOAT AIM_SHOCK; // Applied gradually for shock points
|
||||
FLOAT AIM_TARGET_INVISIBLE; // Applied for shooting at a target you can't see
|
||||
FLOAT AIM_SNIPER_SKILL; // Applied as percentage bonus to CTH cap, once per each level.
|
||||
FLOAT AIM_DRAW_COST; // Applied per 1 AP of the weapon's Ready Cost, under 100AP.
|
||||
FLOAT AIM_STANDING_STANCE; // Gun Difficulty multiplier for shooting a heavy gun when standing
|
||||
FLOAT AIM_CROUCHING_STANCE; // Gun Difficulty multiplier for shooting a heavy gun from a crouched stance
|
||||
FLOAT AIM_PRONE_STANCE; // Gun Difficulty multiplier for shooting a heavy gun when prone, before bipod bonuses
|
||||
FLOAT AIM_TWO_GUNS; // Gun Difficulty multiplier for shooting two guns (halved for each Ambidextrous level)
|
||||
FLOAT AIM_ONE_HANDED; // Gun Difficulty multiplier for firing a pistol with one hand.
|
||||
FLOAT AIM_HEAVY_WEAPON; // Gun Difficulty multiplier for shooting a launcher (halved for each Heavy Weapons level)
|
||||
FLOAT AIM_DIFFICULTY[6]; // Applied for game difficulty
|
||||
|
||||
FLOAT MOVEMENT_MRK;
|
||||
FLOAT MOVEMENT_WIS;
|
||||
FLOAT MOVEMENT_DEX;
|
||||
FLOAT MOVEMENT_EXP_LEVEL;
|
||||
UINT32 MOVEMENT_TRACKING_DIFFICULTY;
|
||||
FLOAT MOVEMENT_PENALTY_PER_TILE;
|
||||
|
||||
FLOAT PRE_RECOIL_WIS;
|
||||
FLOAT PRE_RECOIL_EXP_LEVEL;
|
||||
FLOAT PRE_RECOIL_AUTO_WEAPONS_SKILL;
|
||||
|
||||
FLOAT RECOIL_MAX_COUNTER_STR;
|
||||
FLOAT RECOIL_MAX_COUNTER_AGI;
|
||||
FLOAT RECOIL_MAX_COUNTER_EXP_LEVEL;
|
||||
FLOAT RECOIL_MAX_COUNTER_FORCE;
|
||||
FLOAT RECOIL_COUNTER_ACCURACY_MIN_ERROR;
|
||||
FLOAT RECOIL_COUNTER_ACCURACY_DEX;
|
||||
FLOAT RECOIL_COUNTER_ACCURACY_WIS;
|
||||
FLOAT RECOIL_COUNTER_ACCURACY_AGI;
|
||||
FLOAT RECOIL_COUNTER_ACCURACY_EXP_LEVEL;
|
||||
FLOAT RECOIL_COUNTER_ACCURACY_AUTO_WEAPONS_DIVISOR;
|
||||
FLOAT RECOIL_COUNTER_ACCURACY_TRACER_BONUS;
|
||||
FLOAT RECOIL_COUNTER_FREQUENCY_AGI;
|
||||
FLOAT RECOIL_COUNTER_FREQUENCY_EXP_LEVEL;
|
||||
FLOAT RECOIL_COUNTER_FREQUENCY_AUTO_WEAPONS_DIVISOR;
|
||||
|
||||
FLOAT MAX_BULLET_DEV;
|
||||
|
||||
} CTH_CONSTANTS;
|
||||
|
||||
//This structure will contain general Ja2 settings NOT individual game settings.
|
||||
extern GAME_SETTINGS gGameSettings;
|
||||
|
||||
@@ -818,6 +1325,11 @@ extern GAME_OPTIONS gGameOptions;
|
||||
// Snap: Options read from an INI file in the default of custom Data directory
|
||||
extern GAME_EXTERNAL_OPTIONS gGameExternalOptions;
|
||||
|
||||
extern SKILL_TRAIT_VALUES gSkillTraitValues; // SANDRO - added this one
|
||||
|
||||
// HEADROCK HAM 4: CTH constants read from a separate INI file
|
||||
extern CTH_CONSTANTS gGameCTHConstants;
|
||||
|
||||
// WDS - Automatically try to save when an assertion failure occurs
|
||||
extern bool alreadySaving;
|
||||
|
||||
@@ -825,7 +1337,10 @@ BOOLEAN SaveGameSettings();
|
||||
BOOLEAN LoadGameSettings();
|
||||
// Snap: Read options from an INI file in the default of custom Data directory
|
||||
void LoadGameExternalOptions();
|
||||
void LoadSkillTraitsExternalSettings(); // SANDRO - added this one
|
||||
void LoadGameAPBPConstants();
|
||||
// HEADROCK HAM 4: Read CTH/Shooting coefficients from file
|
||||
void LoadCTHConstants();
|
||||
void FreeGameExternalOptions();
|
||||
|
||||
void InitGameOptions();
|
||||
|
||||
+4
-7
@@ -13,13 +13,11 @@
|
||||
#ifdef JA2EDITOR
|
||||
|
||||
//MAP EDITOR BUILD VERSION
|
||||
CHAR16 zVersionLabel[256] = { L"Map Editor v1.13.3356" };
|
||||
|
||||
CHAR16 zVersionLabel[256] = { L"Map Editor v1.13.4063" };
|
||||
#elif defined JA2BETAVERSION
|
||||
|
||||
//BETA/TEST BUILD VERSION
|
||||
CHAR16 zVersionLabel[256] = { L"Debug v1.13.3356" };
|
||||
|
||||
CHAR16 zVersionLabel[256] = { L"Debug v1.13.4063" };
|
||||
#elif defined CRIPPLED_VERSION
|
||||
|
||||
//RELEASE BUILD VERSION s
|
||||
@@ -28,11 +26,10 @@ CHAR16 zVersionLabel[256] = { L"Beta v. 0.98" };
|
||||
#else
|
||||
|
||||
//RELEASE BUILD VERSION
|
||||
CHAR16 zVersionLabel[256] = { L"Release v1.13.3356" };
|
||||
|
||||
CHAR16 zVersionLabel[256] = { L"Release v1.13.4063" };
|
||||
#endif
|
||||
|
||||
CHAR8 czVersionNumber[16] = { "Build 10.03.13" }; //YY.MM.DD
|
||||
CHAR8 czVersionNumber[16] = { "Build 11.01.18" }; //YY.MM.DD
|
||||
CHAR16 zTrackingNumber[16] = { L"Z" };
|
||||
|
||||
|
||||
|
||||
+14
-3
@@ -20,10 +20,21 @@ extern CHAR16 zTrackingNumber[16];
|
||||
//
|
||||
// Keeps track of the saved game version. Increment the saved game version whenever
|
||||
// you will invalidate the saved game file
|
||||
#define SAVE_GAME_VERSION 107 //106 //105 //104 //103 //102 //101 //100 // 99
|
||||
#define SAVE_GAME_VERSION 117 //114 //113 //112 //111 //110 //109 //108 //107 //106 //105 //104 //103 //102 //101 //100 // 99
|
||||
|
||||
#define CURRENT_SAVEGAME_DATATYPE_VERSION 107
|
||||
#define BIG_MAPS_PROJECT_SAVEGAME_DATATYPE_CHANGE 107 // Before this, we did not had big maps project
|
||||
#define CURRENT_SAVEGAME_DATATYPE_VERSION 116
|
||||
|
||||
#define NCTH_DATATYPE_CHANGE 117 // Before this, we did not have HAM 4.0 NCTH
|
||||
#define NEW_GENERAL_SAVE_INFO_DATA 116 // Before this, we did not have HAM 4.0 general info
|
||||
#define IMP_TRAIT_EXPERT_ITEMS_CHANGE 115 // Before this, we did not have additional expert items defined in IMPItemChoices.xml
|
||||
#define LUA_SAVEGAME_CHANGE 114 // Before this, we did not have additional lua script files (e.g: Intro.lua, ...)
|
||||
#define STOMP12_SAVEGAME_DATATYPE_CHANGE2 113 // Before this, STOMP did not allow to have up to 30 traits
|
||||
#define NAS_SAVEGAME_DATATYPE_CHANGE 112 // Before this, NAS settings (ON/OFF) was not saved to the savegame
|
||||
#define STOMP12_SAVEGAME_DATATYPE_CHANGE 111 // Before this, STOMP v1.2 was not included in the source
|
||||
#define BUGFIX_NPC_DATA_FOR_BIG_MAPS 110 // Before this, we had a bug in the NPC Data for Big Maps (this fix was introduced in the Closed Beta)
|
||||
#define STRATEGIC_MINES_DATATYPE_CHANGE 109 // Before this, we did not have strategic mines initialization via lua script
|
||||
#define HIDE_NPC_NAMES_FOR_UNKNOWN_PERSONS 108 // Before this, we did not have hiding of npc names for unknown persons included (by jazz)
|
||||
#define BIG_MAPS_PROJECT_SAVEGAME_DATATYPE_CHANGE 107 // Before this, we did not have big maps project
|
||||
#define AIRPORT_SAVEGAME_DATATYPE_CHANGE 106 // Before this, we did not have airport externalized
|
||||
#define AP100_SAVEGAME_DATATYPE_CHANGE 105 // Before this, we didn't have the 100AP structure changes
|
||||
#define NIV_SAVEGAME_DATATYPE_CHANGE 102 // Before this, we used the old structure system
|
||||
|
||||
@@ -60,10 +60,22 @@
|
||||
#include "Vehicles.h"
|
||||
#include "Multilingual Text Code Generator.h"
|
||||
#include "editscreen.h"
|
||||
#include "Arms Dealer Init.h"
|
||||
#endif
|
||||
#include "MPXmlTeams.hpp"
|
||||
#include "Strategic Mines LUA.h"
|
||||
#include "UndergroundInit.h"
|
||||
#include "lua_state.h"
|
||||
|
||||
#include "Interface.h"
|
||||
#include "Strategic Town Loyalty.h"
|
||||
#include "Soldier Profile.h"
|
||||
#include "aim.h"
|
||||
|
||||
#include "Civ Quotes.h"
|
||||
#include "Sector Summary.h"
|
||||
#include "LuaInitNPCs.h"
|
||||
|
||||
extern INT16 APBPConstants[TOTAL_APBP_VALUES] = {0};
|
||||
extern INT16 gubMaxActionPoints[28];//MAXBODYTYPES = 28... JUST GETTING IT TO WORK NOW. GOTTHARD 7/2/08
|
||||
extern BOOLEAN GetCDromDriveLetter( STR8 pString );
|
||||
@@ -123,34 +135,62 @@ static void AddLanguagePrefix(STR fileName, const STR language)
|
||||
memmove( fileComponent, language, strlen( language) );
|
||||
}
|
||||
|
||||
static void AddLanguagePrefix(STR fileName)
|
||||
static const STR GetLanguagePrefix()
|
||||
{
|
||||
#ifdef ENGLISH
|
||||
return "";
|
||||
#endif
|
||||
#ifdef GERMAN
|
||||
AddLanguagePrefix( fileName, GERMAN_PREFIX);
|
||||
return GERMAN_PREFIX;
|
||||
#endif
|
||||
#ifdef RUSSIAN
|
||||
AddLanguagePrefix( fileName, RUSSIAN_PREFIX);
|
||||
return RUSSIAN_PREFIX;
|
||||
#endif
|
||||
#ifdef DUTCH
|
||||
AddLanguagePrefix( fileName, DUTCH_PREFIX);
|
||||
return DUTCH_PREFIX;
|
||||
#endif
|
||||
#ifdef POLISH
|
||||
AddLanguagePrefix( fileName, POLISH_PREFIX);
|
||||
return POLISH_PREFIX;
|
||||
#endif
|
||||
#ifdef FRENCH
|
||||
AddLanguagePrefix( fileName, FRENCH_PREFIX);
|
||||
return FRENCH_PREFIX;
|
||||
#endif
|
||||
#ifdef ITALIAN
|
||||
AddLanguagePrefix( fileName, ITALIAN_PREFIX);
|
||||
return ITALIAN_PREFIX;
|
||||
#endif
|
||||
#ifdef TAIWANESE
|
||||
AddLanguagePrefix( fileName, TAIWANESE_PREFIX);
|
||||
return TAIWANESE_PREFIX;
|
||||
#endif
|
||||
#ifdef CHINESE
|
||||
AddLanguagePrefix( fileName, CHINESE_PREFIX);
|
||||
return CHINESE_PREFIX;
|
||||
#endif
|
||||
}
|
||||
|
||||
static void AddLanguagePrefix(STR fileName)
|
||||
{
|
||||
AddLanguagePrefix( fileName, GetLanguagePrefix());
|
||||
}
|
||||
|
||||
void ResetEmptyRPCFaceSlots()
|
||||
{
|
||||
//legion by jazz (load small faces from rpcs)
|
||||
// reset empty slots with "-1"
|
||||
for (UINT8 i = 0; i < 200; i++)
|
||||
{
|
||||
if (i == 0 &&
|
||||
gRPCSmallFaceValues[i].bEyesX == 0 && gRPCSmallFaceValues[i].bEyesY == 0 &&
|
||||
gRPCSmallFaceValues[i].bMouthX == 0 && gRPCSmallFaceValues[i].bMouthY == 0 &&
|
||||
gRPCSmallFaceValues[i].FaceIndex == 0 && gRPCSmallFaceValues[i].uiIndex == 0)
|
||||
{
|
||||
gRPCSmallFaceValues[i].uiIndex = -1; // -1 -> 65535
|
||||
}
|
||||
else if (i > 0 && gRPCSmallFaceValues[i].uiIndex == 0)
|
||||
{
|
||||
gRPCSmallFaceValues[i].uiIndex = -1; // -1 -> 65535
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
BOOLEAN LoadExternalGameplayData(STR directoryName)
|
||||
{
|
||||
char fileName[MAX_PATH];
|
||||
@@ -167,27 +207,27 @@ BOOLEAN LoadExternalGameplayData(STR directoryName)
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, ENEMYMISCDROPSFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInEnemyMiscDropsStats(gEnemyMiscDrops, fileName), ENEMYMISCDROPSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInEnemyMiscDropsStats(gEnemyMiscDrops, fileName), ENEMYMISCDROPSFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, ENEMYEXPLOSIVEDROPSFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInEnemyExplosiveDropsStats(gEnemyExplosiveDrops, fileName),ENEMYEXPLOSIVEDROPSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInEnemyExplosiveDropsStats(gEnemyExplosiveDrops, fileName),ENEMYEXPLOSIVEDROPSFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, ENEMYWEAPONDROPSFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInEnemyWeaponDropsStats(gEnemyWeaponDrops, fileName),ENEMYWEAPONDROPSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInEnemyWeaponDropsStats(gEnemyWeaponDrops, fileName),ENEMYWEAPONDROPSFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, ENEMYAMMODROPSFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInEnemyAmmoDropsStats(gEnemyAmmoDrops, fileName),ENEMYAMMODROPSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInEnemyAmmoDropsStats(gEnemyAmmoDrops, fileName),ENEMYAMMODROPSFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, ENEMYARMOURDROPSFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInEnemyArmourDropsStats(gEnemyArmourDrops, fileName),ENEMYARMOURDROPSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInEnemyArmourDropsStats(gEnemyArmourDrops, fileName),ENEMYARMOURDROPSFILENAME);
|
||||
// WANNE: Enemy drops - end
|
||||
|
||||
// WANNE: Sector Loadscreens [2007-05-18]
|
||||
@@ -197,7 +237,7 @@ BOOLEAN LoadExternalGameplayData(STR directoryName)
|
||||
if ( FileExists(fileName) )
|
||||
{
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInSectorLoadscreensStats(gSectorLoadscreens, fileName),SECTORLOADSCREENSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInSectorLoadscreensStats(gSectorLoadscreens, fileName),SECTORLOADSCREENSFILENAME);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -209,7 +249,7 @@ BOOLEAN LoadExternalGameplayData(STR directoryName)
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, AMMOTYPESFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInAmmoTypeStats(fileName),AMMOTYPESFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInAmmoTypeStats(fileName),AMMOTYPESFILENAME);
|
||||
|
||||
//Madd: Simple Localization
|
||||
//Read in the correct ammostring file for the given language
|
||||
@@ -245,7 +285,7 @@ BOOLEAN LoadExternalGameplayData(STR directoryName)
|
||||
//CHRISL: If we fail to load, try loading just the default english
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, AMMOFILENAME);
|
||||
THROWIFFALSE(!ReadInAmmoStats(fileName),AMMOFILENAME);
|
||||
SGP_THROW_IFFALSE(!ReadInAmmoStats(fileName),AMMOFILENAME);
|
||||
}
|
||||
|
||||
|
||||
@@ -253,13 +293,13 @@ BOOLEAN LoadExternalGameplayData(STR directoryName)
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, BURSTSOUNDSFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInBurstSoundArray(fileName),BURSTSOUNDSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInBurstSoundArray(fileName),BURSTSOUNDSFILENAME);
|
||||
// Lesh: end
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, ITEMSFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInItemStats(fileName,FALSE),ITEMSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInItemStats(fileName,FALSE),ITEMSFILENAME);
|
||||
|
||||
//Madd: Simple localization
|
||||
// The idea here is that we can have a separate xml file that's named differently
|
||||
@@ -286,57 +326,57 @@ BOOLEAN LoadExternalGameplayData(STR directoryName)
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, SOUNDSFILENAME);
|
||||
THROWIFFALSE(ReadInSoundArray(fileName),SOUNDSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInSoundArray(fileName),SOUNDSFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, MAGAZINESFILENAME);
|
||||
THROWIFFALSE(ReadInMagazineStats(fileName),MAGAZINESFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInMagazineStats(fileName),MAGAZINESFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, ATTACHMENTSFILENAME);
|
||||
THROWIFFALSE(ReadInAttachmentStats(fileName),ATTACHMENTSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInAttachmentStats(fileName),ATTACHMENTSFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, ATTACHMENTINFOFILENAME);
|
||||
THROWIFFALSE(ReadInAttachmentInfoStats(fileName),ATTACHMENTINFOFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInAttachmentInfoStats(fileName),ATTACHMENTINFOFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, LAUNCHABLESFILENAME);
|
||||
THROWIFFALSE(ReadInLaunchableStats(fileName),LAUNCHABLESFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInLaunchableStats(fileName),LAUNCHABLESFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, COMPATIBLEFACEITEMSFILENAME);
|
||||
THROWIFFALSE(ReadInCompatibleFaceItemStats(fileName),COMPATIBLEFACEITEMSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInCompatibleFaceItemStats(fileName),COMPATIBLEFACEITEMSFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, MERGESFILENAME);
|
||||
THROWIFFALSE(ReadInMergeStats(fileName),MERGESFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInMergeStats(fileName),MERGESFILENAME);
|
||||
|
||||
//if(!WriteMergeStats())
|
||||
// return FALSE;
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, ATTACHMENTCOMBOMERGESFILENAME);
|
||||
THROWIFFALSE(ReadInAttachmentComboMergeStats(fileName),ATTACHMENTCOMBOMERGESFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInAttachmentComboMergeStats(fileName),ATTACHMENTCOMBOMERGESFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, EXPLOSIVESFILENAME);
|
||||
THROWIFFALSE(ReadInExplosiveStats(fileName),EXPLOSIVESFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInExplosiveStats(fileName),EXPLOSIVESFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, ARMOURSFILENAME);
|
||||
THROWIFFALSE(ReadInArmourStats(fileName),ARMOURSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInArmourStats(fileName),ARMOURSFILENAME);
|
||||
|
||||
// CHRISL:
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, LOADBEARINGEQUIPMENTFILENAME);
|
||||
THROWIFFALSE(ReadInlbeStats(fileName),LOADBEARINGEQUIPMENTFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInlbeStats(fileName),LOADBEARINGEQUIPMENTFILENAME);
|
||||
|
||||
// CHRISL:
|
||||
LBEPocketType.clear();
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, LBEPOCKETFILENAME);
|
||||
THROWIFFALSE(ReadInLBEPocketStats(fileName,FALSE),LBEPOCKETFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInLBEPocketStats(fileName,FALSE),LBEPOCKETFILENAME);
|
||||
|
||||
//CHRISL: Simple localization
|
||||
// Same setup as what Madd used for items.xml
|
||||
@@ -354,108 +394,117 @@ BOOLEAN LoadExternalGameplayData(STR directoryName)
|
||||
// CHRISL:
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, MERCSTARTINGGEARFILENAME);
|
||||
THROWIFFALSE(ReadInMercStartingGearStats(fileName),MERCSTARTINGGEARFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInMercStartingGearStats(fileName),MERCSTARTINGGEARFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, WEAPONSFILENAME);
|
||||
THROWIFFALSE(ReadInWeaponStats(fileName),WEAPONSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInWeaponStats(fileName),WEAPONSFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, INCOMPATIBLEATTACHMENTSFILENAME);
|
||||
THROWIFFALSE(ReadInIncompatibleAttachmentStats(fileName),INCOMPATIBLEATTACHMENTSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInIncompatibleAttachmentStats(fileName),INCOMPATIBLEATTACHMENTSFILENAME);
|
||||
|
||||
//WarmSteel - Attachment slots related xml's
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, ATTACHMENTSLOTSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInAttachmentSlotsStats(fileName),ATTACHMENTSLOTSFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, ENEMYGUNCHOICESFILENAME);
|
||||
THROWIFFALSE(ReadInExtendedArmyGunChoicesStats (fileName),ENEMYGUNCHOICESFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInExtendedArmyGunChoicesStats (fileName),ENEMYGUNCHOICESFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, ENEMYITEMCHOICESFILENAME);
|
||||
THROWIFFALSE(ReadInArmyItemChoicesStats(fileName),ENEMYITEMCHOICESFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInArmyItemChoicesStats(fileName),ENEMYITEMCHOICESFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, IMPITEMCHOICESFILENAME);
|
||||
THROWIFFALSE(ReadInIMPItemChoicesStats(fileName),IMPITEMCHOICESFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInIMPItemChoicesStats(fileName),IMPITEMCHOICESFILENAME);
|
||||
|
||||
std::copy(DefaultarmsDealerInfo,
|
||||
DefaultarmsDealerInfo + sizeof(DefaultarmsDealerInfo)/sizeof(*DefaultarmsDealerInfo),
|
||||
armsDealerInfo.begin());
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, TONYINVENTORYFILENAME);
|
||||
THROWIFFALSE(ReadInInventoryStats(gTonyInventory,fileName),TONYINVENTORYFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInInventoryStats(gTonyInventory,fileName),TONYINVENTORYFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, DEVININVENTORYFILENAME);
|
||||
THROWIFFALSE(ReadInInventoryStats(gDevinInventory,fileName),DEVININVENTORYFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInInventoryStats(gDevinInventory,fileName),DEVININVENTORYFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, FRANZINVENTORYFILENAME);
|
||||
THROWIFFALSE(ReadInInventoryStats(gFranzInventory,fileName),FRANZINVENTORYFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInInventoryStats(gFranzInventory,fileName),FRANZINVENTORYFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, KEITHINVENTORYFILENAME);
|
||||
THROWIFFALSE(ReadInInventoryStats(gKeithInventory,fileName),KEITHINVENTORYFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInInventoryStats(gKeithInventory,fileName),KEITHINVENTORYFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, SAMINVENTORYFILENAME);
|
||||
THROWIFFALSE(ReadInInventoryStats(gSamInventory,fileName),SAMINVENTORYFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInInventoryStats(gSamInventory,fileName),SAMINVENTORYFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, JAKEINVENTORYFILENAME);
|
||||
THROWIFFALSE(ReadInInventoryStats(gJakeInventory,fileName),JAKEINVENTORYFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInInventoryStats(gJakeInventory,fileName),JAKEINVENTORYFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, HOWARDINVENTORYFILENAME);
|
||||
THROWIFFALSE(ReadInInventoryStats(gHowardInventory,fileName),HOWARDINVENTORYFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInInventoryStats(gHowardInventory,fileName),HOWARDINVENTORYFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, GABBYINVENTORYFILENAME);
|
||||
THROWIFFALSE(ReadInInventoryStats(gGabbyInventory,fileName),GABBYINVENTORYFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInInventoryStats(gGabbyInventory,fileName),GABBYINVENTORYFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, FRANKINVENTORYFILENAME);
|
||||
THROWIFFALSE(ReadInInventoryStats(gFrankInventory,fileName),FRANKINVENTORYFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInInventoryStats(gFrankInventory,fileName),FRANKINVENTORYFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, ELGININVENTORYFILENAME);
|
||||
THROWIFFALSE(ReadInInventoryStats(gElginInventory,fileName),ELGININVENTORYFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInInventoryStats(gElginInventory,fileName),ELGININVENTORYFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, MANNYINVENTORYFILENAME);
|
||||
THROWIFFALSE(ReadInInventoryStats(gMannyInventory,fileName),MANNYINVENTORYFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInInventoryStats(gMannyInventory,fileName),MANNYINVENTORYFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, HERVEINVENTORYFILENAME);
|
||||
THROWIFFALSE(ReadInInventoryStats(gHerveInventory,fileName),HERVEINVENTORYFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInInventoryStats(gHerveInventory,fileName),HERVEINVENTORYFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, PETERINVENTORYFILENAME);
|
||||
THROWIFFALSE(ReadInInventoryStats(gPeterInventory,fileName),PETERINVENTORYFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInInventoryStats(gPeterInventory,fileName),PETERINVENTORYFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, ALBERTOINVENTORYFILENAME);
|
||||
THROWIFFALSE(ReadInInventoryStats(gAlbertoInventory,fileName),ALBERTOINVENTORYFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInInventoryStats(gAlbertoInventory,fileName),ALBERTOINVENTORYFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, CARLOINVENTORYFILENAME);
|
||||
THROWIFFALSE(ReadInInventoryStats(gCarloInventory,fileName),CARLOINVENTORYFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInInventoryStats(gCarloInventory,fileName),CARLOINVENTORYFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, MICKEYINVENTORYFILENAME);
|
||||
THROWIFFALSE(ReadInInventoryStats(gMickyInventory,fileName),MICKEYINVENTORYFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInInventoryStats(gMickyInventory,fileName),MICKEYINVENTORYFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, ARNIEINVENTORYFILENAME);
|
||||
THROWIFFALSE(ReadInInventoryStats(gArnieInventory,fileName),ARNIEINVENTORYFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInInventoryStats(gArnieInventory,fileName),ARNIEINVENTORYFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, PERKOINVENTORYFILENAME);
|
||||
THROWIFFALSE(ReadInInventoryStats(gPerkoInventory,fileName),PERKOINVENTORYFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInInventoryStats(gPerkoInventory,fileName),PERKOINVENTORYFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, FREDOINVENTORYFILENAME);
|
||||
THROWIFFALSE(ReadInInventoryStats(gFredoInventory,fileName),FREDOINVENTORYFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInInventoryStats(gFredoInventory,fileName),FREDOINVENTORYFILENAME);
|
||||
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, CITYTABLEFILENAME);
|
||||
THROWIFFALSE(ReadInMapStructure(fileName, FALSE),CITYTABLEFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInMapStructure(fileName, FALSE),CITYTABLEFILENAME);
|
||||
|
||||
#ifndef ENGLISH
|
||||
AddLanguagePrefix(fileName);
|
||||
@@ -474,113 +523,365 @@ BOOLEAN LoadExternalGameplayData(STR directoryName)
|
||||
// Lesh: load altsectors list
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, ALTSECTORSFILENAME);
|
||||
THROWIFFALSE(ReadInAltSectors(fileName),ALTSECTORSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInAltSectors(fileName),ALTSECTORSFILENAME);
|
||||
|
||||
// Lesh: load samsites - must be after cities.xml
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, SAMSITESFILENAME);
|
||||
THROWIFFALSE(ReadInSAMInfo(fileName),SAMSITESFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInSAMInfo(fileName),SAMSITESFILENAME);
|
||||
|
||||
// Lesh: army externalization
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, GARRISONFILENAME);
|
||||
THROWIFFALSE(ReadInGarrisonInfo(fileName),GARRISONFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInGarrisonInfo(fileName),GARRISONFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, PATROLFILENAME);
|
||||
THROWIFFALSE(ReadInPatrolInfo(fileName),PATROLFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInPatrolInfo(fileName),PATROLFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, COMPOSITIONFILENAME);
|
||||
THROWIFFALSE(ReadInArmyCompositionInfo(fileName),COMPOSITIONFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInArmyCompositionInfo(fileName),COMPOSITIONFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, EXPLOSIONDATAFILENAME);
|
||||
THROWIFFALSE(ReadInExplosionDataStats(fileName),EXPLOSIONDATAFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInExplosionDataStats(fileName),EXPLOSIONDATAFILENAME);
|
||||
|
||||
// Kaiden: Read in Restricted Sectors for Mobile Militia
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, ROAMINGMILITIAFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInRoamingInfo(fileName),ROAMINGMILITIAFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInRoamingInfo(fileName),ROAMINGMILITIAFILENAME);
|
||||
|
||||
// Dealtar: Read in shipping destinations and delivery methods
|
||||
gPostalService.Clear();
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, SHIPPINGDESTINATIONSFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInShippingDestinations(fileName, FALSE),SHIPPINGDESTINATIONSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInShippingDestinations(fileName, FALSE),SHIPPINGDESTINATIONSFILENAME);
|
||||
|
||||
#ifndef ENGLISH
|
||||
AddLanguagePrefix(fileName);
|
||||
if ( FileExists(fileName) )
|
||||
{
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInShippingDestinations(fileName, TRUE),SHIPPINGDESTINATIONSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInShippingDestinations(fileName, TRUE),SHIPPINGDESTINATIONSFILENAME);
|
||||
}
|
||||
#endif
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, DELIVERYMETHODSFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInDeliveryMethods(fileName),DELIVERYMETHODSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInDeliveryMethods(fileName),DELIVERYMETHODSFILENAME);
|
||||
|
||||
// HEADROCK HAM 3.5: Read in facility types
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, FACILITYTYPESFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInFacilityTypes(fileName), FACILITYTYPESFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInFacilityTypes(fileName,FALSE), FACILITYTYPESFILENAME);
|
||||
|
||||
#ifndef ENGLISH
|
||||
AddLanguagePrefix(fileName);
|
||||
if ( FileExists(fileName) )
|
||||
{
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
if(!ReadInFacilityTypes(fileName,TRUE))
|
||||
return FALSE;
|
||||
}
|
||||
#endif
|
||||
|
||||
// HEADROCK HAM 3.4: Read in facility locations
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, SECTORFACILITIESFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInSectorFacilities(fileName), SECTORFACILITIESFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInSectorFacilities(fileName), SECTORFACILITIESFILENAME);
|
||||
|
||||
// HEADROCK HAM 3.4: Read in dynamic roaming restrictions
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, DYNAMICROAMINGFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInDynamicRoamingRestrictions(fileName), DYNAMICROAMINGFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInDynamicRoamingRestrictions(fileName), DYNAMICROAMINGFILENAME);
|
||||
|
||||
// HEADROCK HAM 3.6: Read in customized sector names
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, SECTORNAMESFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInSectorNames(fileName), SECTORNAMESFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInSectorNames(fileName,FALSE,0), SECTORNAMESFILENAME);
|
||||
#ifndef ENGLISH
|
||||
AddLanguagePrefix(fileName);
|
||||
if ( FileExists(fileName) )
|
||||
{
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
if(!ReadInSectorNames(fileName,TRUE,0))
|
||||
return FALSE;
|
||||
}
|
||||
#endif
|
||||
|
||||
// moved to lua
|
||||
//strcpy(fileName, directoryName);
|
||||
//strcat(fileName, SECTORLEVEL1NAMESFILENAME);
|
||||
//DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
//SGP_THROW_IFFALSE(ReadInSectorNames(fileName,FALSE,1), SECTORLEVEL1NAMESFILENAME);
|
||||
//
|
||||
//#ifndef ENGLISH
|
||||
//AddLanguagePrefix(fileName);
|
||||
//if ( FileExists(fileName) )
|
||||
//{
|
||||
// DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
// if(!ReadInSectorNames(fileName,TRUE,1))
|
||||
// return FALSE;
|
||||
//}
|
||||
//#endif
|
||||
|
||||
//strcpy(fileName, directoryName);
|
||||
//strcat(fileName, SECTORLEVEL2NAMESFILENAME);
|
||||
//DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
//SGP_THROW_IFFALSE(ReadInSectorNames(fileName,FALSE,2), SECTORLEVEL2NAMESFILENAME);
|
||||
//
|
||||
//#ifndef ENGLISH
|
||||
//AddLanguagePrefix(fileName);
|
||||
//if ( FileExists(fileName) )
|
||||
//{
|
||||
// DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
// if(!ReadInSectorNames(fileName,TRUE,2))
|
||||
// return FALSE;
|
||||
//}
|
||||
//#endif
|
||||
|
||||
//strcpy(fileName, directoryName);
|
||||
//strcat(fileName, SECTORLEVEL3NAMESFILENAME);
|
||||
//DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
//SGP_THROW_IFFALSE(ReadInSectorNames(fileName,FALSE,3), SECTORLEVEL3NAMESFILENAME);
|
||||
//
|
||||
//#ifndef ENGLISH
|
||||
//AddLanguagePrefix(fileName);
|
||||
//if ( FileExists(fileName) )
|
||||
//{
|
||||
// DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
// if(!ReadInSectorNames(fileName,TRUE,3))
|
||||
// return FALSE;
|
||||
//}
|
||||
//#endif
|
||||
|
||||
|
||||
// code duplication?
|
||||
#ifndef ENGLISH
|
||||
AddLanguagePrefix(fileName);
|
||||
if ( FileExists(fileName) )
|
||||
{
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
if(!ReadInSectorNames(fileName,TRUE,0))
|
||||
return FALSE;
|
||||
}
|
||||
#endif
|
||||
|
||||
// WANNE: Why do we need it. It should also run without that file!!
|
||||
// SANDRO - always initialize those files, we need it on game start
|
||||
if (gGameExternalOptions.fReadProfileDataFromXML)
|
||||
{
|
||||
// HEADROCK PROFEX: Read in Merc Profile data to replace PROF.DAT data
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, MERCPROFILESFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInMercProfiles(fileName), MERCPROFILESFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInMercProfiles(fileName, FALSE), MERCPROFILESFILENAME);
|
||||
|
||||
#ifndef ENGLISH
|
||||
AddLanguagePrefix(fileName);
|
||||
if ( FileExists(fileName) )
|
||||
{
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
if(!ReadInMercProfiles(fileName,TRUE))
|
||||
return FALSE;
|
||||
}
|
||||
#endif
|
||||
|
||||
// HEADROCK PROFEX: Read in Merc Opinion data to replace PROF.DAT data
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, MERCOPINIONSFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInMercOpinions(fileName), MERCOPINIONSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInMercOpinions(fileName), MERCOPINIONSFILENAME);
|
||||
}
|
||||
|
||||
// HEADROCK HAM 3.6: Read in customized Bloodcat Placements
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, BLOODCATPLACEMENTSFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInBloodcatPlacements(fileName), BLOODCATPLACEMENTSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInBloodcatPlacements(fileName), BLOODCATPLACEMENTSFILENAME);
|
||||
|
||||
// HEADROCK HAM 3.6: Read in customized Uniform Colors
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, UNIFORMCOLORSFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
THROWIFFALSE(ReadInUniforms(fileName), UNIFORMCOLORSFILENAME);
|
||||
SGP_THROW_IFFALSE(ReadInUniforms(fileName), UNIFORMCOLORSFILENAME);
|
||||
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, MULTIPLAYERTEAMSFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
mpTeams.ReadInMPTeams(fileName);
|
||||
|
||||
//legion by jazz (load small faces from rpcs)
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, RPCFACESSMALLFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
SGP_THROW_IFFALSE(ReadInSmallFacesStats(gRPCSmallFaceValues,fileName), RPCFACESSMALLFILENAME);
|
||||
ResetEmptyRPCFaceSlots();
|
||||
|
||||
//Hidden Names by Jazz
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, HIDDENNAMESFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
SGP_THROW_IFFALSE(ReadInHiddenNamesStats(zHiddenNames,fileName), HIDDENNAMESFILENAME);
|
||||
|
||||
|
||||
|
||||
if (gGameExternalOptions.fEnemyNames == TRUE && gGameExternalOptions.fEnemyRank == FALSE)
|
||||
{
|
||||
// Enemy Names Group by Jazz
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, ENEMYNAMESFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
SGP_THROW_IFFALSE(ReadInEnemyNames(fileName,FALSE), ENEMYNAMESFILENAME);
|
||||
|
||||
#ifndef ENGLISH
|
||||
AddLanguagePrefix(fileName);
|
||||
if ( FileExists(fileName) )
|
||||
{
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
if(!ReadInEnemyNames(fileName,TRUE))
|
||||
return FALSE;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
if (gGameExternalOptions.fCivGroupName == TRUE)
|
||||
{
|
||||
// Civ Names Group by Jazz
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, CIVGROUPNAMESFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
SGP_THROW_IFFALSE(ReadInCivGroupNamesStats(fileName,FALSE), CIVGROUPNAMESFILENAME);
|
||||
|
||||
#ifndef ENGLISH
|
||||
AddLanguagePrefix(fileName);
|
||||
if ( FileExists(fileName) )
|
||||
{
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
if(!ReadInCivGroupNamesStats(fileName,TRUE))
|
||||
return FALSE;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
// Sender Name List by Jazz
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, SENDERNAMELISTFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
SGP_THROW_IFFALSE(ReadInSenderNameList(fileName,FALSE), SENDERNAMELISTFILENAME);
|
||||
|
||||
#ifndef ENGLISH
|
||||
AddLanguagePrefix(fileName);
|
||||
if ( FileExists(fileName) )
|
||||
{
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
if(!ReadInSenderNameList(fileName,TRUE))
|
||||
return FALSE;
|
||||
}
|
||||
#endif
|
||||
|
||||
if (gGameExternalOptions.fEnemyNames == FALSE && gGameExternalOptions.fEnemyRank == TRUE)
|
||||
{
|
||||
// Enemy Rank by Jazz
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, ENEMYRANKFILENAME);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
SGP_THROW_IFFALSE(ReadInEnemyRank(fileName,FALSE), ENEMYRANKFILENAME);
|
||||
|
||||
#ifndef ENGLISH
|
||||
AddLanguagePrefix(fileName);
|
||||
if ( FileExists(fileName) )
|
||||
{
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
if(!ReadInEnemyRank(fileName,TRUE))
|
||||
return FALSE;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
// IMP Portraits List by Jazz
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, IMPPORTRAITS);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
SGP_THROW_IFFALSE(ReadInIMPPortraits(fileName,FALSE), IMPPORTRAITS);
|
||||
|
||||
#ifndef ENGLISH
|
||||
AddLanguagePrefix(fileName);
|
||||
if ( FileExists(fileName) )
|
||||
{
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
if(!ReadInIMPPortraits(fileName,TRUE))
|
||||
return FALSE;
|
||||
}
|
||||
#endif
|
||||
|
||||
LoadIMPPortraitsTEMP();
|
||||
|
||||
//Sound profile by jazz
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, SOUNDPROFILE);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
SGP_THROW_IFFALSE(ReadInSoundProfile(fileName), SOUNDPROFILE);
|
||||
|
||||
//Random stats by jazz
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, RANDOMSTATS);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
SGP_THROW_IFFALSE(ReadInRandomStats(fileName), RANDOMSTATS);
|
||||
//new profiles by Jazz
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, MERCAVAILABILITY);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
SGP_THROW_IFFALSE(ReadInMercAvailability(fileName,FALSE), MERCAVAILABILITY);
|
||||
|
||||
#ifndef ENGLISH
|
||||
AddLanguagePrefix(fileName);
|
||||
if ( FileExists(fileName) )
|
||||
{
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
if(!ReadInMercAvailability(fileName,TRUE))
|
||||
return FALSE;
|
||||
}
|
||||
#endif
|
||||
UINT32 i;
|
||||
for(i=0; i<NUM_PROFILES; i++)
|
||||
{
|
||||
gAimAvailability[i].ProfilId = -1;
|
||||
}
|
||||
|
||||
|
||||
//new profiles by Jazz
|
||||
strcpy(fileName, directoryName);
|
||||
strcat(fileName, AIMAVAILABILITY);
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
SGP_THROW_IFFALSE(ReadInAimAvailability(fileName,FALSE), AIMAVAILABILITY);
|
||||
|
||||
#ifndef ENGLISH
|
||||
AddLanguagePrefix(fileName);
|
||||
if ( FileExists(fileName) )
|
||||
{
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("LoadExternalGameplayData, fileName = %s", fileName));
|
||||
if(!ReadInAimAvailability(fileName,TRUE))
|
||||
return FALSE;
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
LuaState::INIT(lua::LUA_STATE_STRATEGIC_MINES_AND_UNDERGROUND, true);
|
||||
g_luaUnderground.LoadScript(GetLanguagePrefix());
|
||||
// load Lua for Strategic Mines initialization
|
||||
g_luaMines.LoadScript();
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
@@ -601,7 +902,7 @@ UINT32 InitializeJA2(void)
|
||||
//{
|
||||
// return( ERROR_SCREEN );
|
||||
//}
|
||||
TRYCATCH_RETHROW(LoadExternalGameplayData(TABLEDATA_DIRECTORY),L"Loading external data failed");
|
||||
SGP_TRYCATCH_RETHROW(LoadExternalGameplayData(TABLEDATA_DIRECTORY),L"Loading external data failed");
|
||||
|
||||
// Load external text
|
||||
LoadAllExternalText();
|
||||
@@ -612,7 +913,7 @@ UINT32 InitializeJA2(void)
|
||||
//dnl ch54 111009
|
||||
//gsRenderCenterX = 805;
|
||||
//gsRenderCenterY = 805;
|
||||
|
||||
|
||||
// Init data
|
||||
InitializeSystemVideoObjects( );
|
||||
|
||||
@@ -685,7 +986,7 @@ UINT32 InitializeJA2(void)
|
||||
//ADB When a merc calcs CTGT for a thrown item he uses a GLOCK temp item
|
||||
//but we don't want to recreate it every single time CTGT is called, so init the GLOCK here
|
||||
CreateItem(GLOCK_17, 100, &GLOCK_17_ForUseWithLOS);
|
||||
|
||||
|
||||
|
||||
#ifdef JA2BETAVERSION
|
||||
#ifdef JA2EDITOR
|
||||
@@ -777,6 +1078,9 @@ UINT32 InitializeJA2(void)
|
||||
#endif
|
||||
#endif
|
||||
|
||||
//Lua
|
||||
IniLuaGlobal();
|
||||
|
||||
return( INIT_SCREEN );
|
||||
}
|
||||
|
||||
|
||||
@@ -157,7 +157,7 @@ BP_JUMP_OVER,
|
||||
BP_BACK_PACK,
|
||||
BP_WORK_ZIPPER,
|
||||
BP_UNJAM,
|
||||
|
||||
AP_JUMPWINDOW, //jump window
|
||||
TOTAL_APBP_VALUES
|
||||
};
|
||||
#endif
|
||||
|
||||
@@ -22,6 +22,7 @@
|
||||
#include "Line.h"
|
||||
#include "Intro.h"
|
||||
#include "Cinematics.h"
|
||||
#include "Cinematics Bink.h"
|
||||
#include "mainmenuscreen.h"
|
||||
#include "Music Control.h"
|
||||
#include "LibraryDataBase.h"
|
||||
@@ -30,9 +31,163 @@
|
||||
#include "Soldier Profile.h"
|
||||
#include "soldier profile type.h"
|
||||
#include "MessageBoxScreen.h"
|
||||
#include "sgp_logger.h"
|
||||
#include "INIReader.h"
|
||||
#endif
|
||||
|
||||
#include "VFS/vfs.h"
|
||||
#include <vfs/Core/vfs.h>
|
||||
|
||||
#include "Luaglobal.h"
|
||||
#include "LuaInitNPCs.h"
|
||||
#include "XML.h"
|
||||
|
||||
BOOLEAN Style_JA = TRUE;
|
||||
extern INT8 Test = 0;
|
||||
|
||||
UINT32 iStringToUseLua = -1;
|
||||
// BF
|
||||
class VideoPlayer
|
||||
{
|
||||
public:
|
||||
enum VideoType
|
||||
{
|
||||
VT_NONE = 0,
|
||||
VT_SMK = 1,
|
||||
VT_BINK = 2,
|
||||
};
|
||||
VideoPlayer(UINT32 type) : _type(type), _smk(NULL), _bink(NULL), _current(VT_NONE)
|
||||
{
|
||||
}
|
||||
void Initialize()
|
||||
{
|
||||
if(_type & VT_SMK)
|
||||
{
|
||||
SmkInitialize( ghWindow, SCREEN_WIDTH, SCREEN_HEIGHT);
|
||||
}
|
||||
if(_type & VT_BINK)
|
||||
{
|
||||
BinkInitialize(ghWindow, SCREEN_WIDTH, SCREEN_HEIGHT);
|
||||
}
|
||||
}
|
||||
void Shutdown()
|
||||
{
|
||||
if(_type & VT_SMK)
|
||||
{
|
||||
SmkShutdown();
|
||||
}
|
||||
if(_type & VT_BINK)
|
||||
{
|
||||
BinkShutdownVideo();
|
||||
}
|
||||
}
|
||||
|
||||
bool isValid()
|
||||
{
|
||||
if( (_current == VT_SMK && _smk && !_bink) || (_current == VT_BINK && !_smk && _bink) )
|
||||
{
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
bool isPlaying()
|
||||
{
|
||||
if( _current == VT_SMK && _smk && !_bink )
|
||||
{
|
||||
return SmkPollFlics() != 0;
|
||||
}
|
||||
else if(_current == VT_BINK && !_smk && _bink)
|
||||
{
|
||||
return BinkPollFlics() != 0;
|
||||
}
|
||||
else if(_current == VT_NONE && !_smk && !_bink)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
SGP_THROW(L"Invalid Video Player state!");
|
||||
}
|
||||
|
||||
void stopVideo()
|
||||
{
|
||||
if(_current == VT_SMK && _smk && !_bink)
|
||||
{
|
||||
SmkCloseFlic(_smk);
|
||||
_smk = NULL;
|
||||
}
|
||||
else if(_current == VT_BINK && !_smk && _bink)
|
||||
{
|
||||
BinkCloseFlic(_bink);
|
||||
_bink = NULL;
|
||||
}
|
||||
_current = VT_NONE;
|
||||
}
|
||||
|
||||
bool startVideo(std::string const& filename)
|
||||
{
|
||||
if(isPlaying())
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
/// check file extension
|
||||
std::string ext;
|
||||
std::string::size_type pos = filename.find_last_of(".");
|
||||
if(pos != std::string::npos)
|
||||
{
|
||||
ext = filename.substr(pos, filename.size() - pos);
|
||||
}
|
||||
if(vfs::StrCmp::Equal(ext, ".smk"))
|
||||
{
|
||||
return startSmkVideo(filename);
|
||||
}
|
||||
else if(vfs::StrCmp::Equal(ext, ".bik"))
|
||||
{
|
||||
return startBinkVideo(filename);
|
||||
}
|
||||
else if(ext.empty())
|
||||
{
|
||||
// try .bik first
|
||||
if(!startBinkVideo(filename + ".bik"))
|
||||
{
|
||||
return startSmkVideo(filename + ".smk");
|
||||
}
|
||||
return true;
|
||||
}
|
||||
else
|
||||
{
|
||||
SGP_INFO(L"Unknown video file format");
|
||||
}
|
||||
return false;
|
||||
}
|
||||
private:
|
||||
bool startSmkVideo(std::string const& filename)
|
||||
{
|
||||
_smk = SmkPlayFlic( filename.c_str(), (SCREEN_WIDTH-640)/2, (SCREEN_HEIGHT-480)/2, TRUE );
|
||||
if(_smk)
|
||||
{
|
||||
_current = VT_SMK;
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
bool startBinkVideo(std::string const& filename)
|
||||
{
|
||||
_bink = BinkPlayFlic( filename.c_str(), (SCREEN_WIDTH-640)/2, (SCREEN_HEIGHT-480)/2, BINK_FLIC_AUTOCLOSE | BINK_FLIC_CENTER_VERTICAL);
|
||||
if(_bink)
|
||||
{
|
||||
_current = VT_BINK;
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
private:
|
||||
UINT32 _type;
|
||||
SMKFLIC* _smk;
|
||||
BINKFLIC* _bink;
|
||||
VideoType _current;
|
||||
};
|
||||
|
||||
static VideoPlayer s_VP(VideoPlayer::VT_SMK | VideoPlayer::VT_BINK);
|
||||
|
||||
extern STR16 gzIntroScreen[];
|
||||
extern HVSURFACE ghFrameBuffer;
|
||||
@@ -54,37 +209,37 @@ UINT32 guiIntroExitScreen = INTRO_SCREEN;
|
||||
|
||||
extern BOOLEAN gfDoneWithSplashScreen;
|
||||
|
||||
SMKFLIC *gpSmackFlic = NULL;
|
||||
|
||||
#define SMKINTRO_FIRST_VIDEO 255
|
||||
#define SMKINTRO_NO_VIDEO -1
|
||||
//BF SMKFLIC *gpSmackFlic = NULL;
|
||||
|
||||
//enums for the various smacker files
|
||||
enum
|
||||
enum EGameVideos
|
||||
{
|
||||
SMKINTRO_REBEL_CRDT,
|
||||
SMKINTRO_OMERTA,
|
||||
SMKINTRO_PRAGUE_CRDT,
|
||||
SMKINTRO_PRAGUE,
|
||||
INTRO_NO_VIDEO = -1,
|
||||
INTRO_REBEL_CRDT = 0,
|
||||
INTRO_OMERTA,
|
||||
INTRO_PRAGUE_CRDT,
|
||||
INTRO_PRAGUE,
|
||||
|
||||
//there are no more videos shown for the begining
|
||||
|
||||
|
||||
SMKINTRO_END_END_SPEECH_MIGUEL,
|
||||
SMKINTRO_END_END_SPEECH_NO_MIGUEL,
|
||||
SMKINTRO_END_HELI_FLYBY,
|
||||
SMKINTRO_END_SKYRIDER_HELICOPTER,
|
||||
SMKINTRO_END_NOSKYRIDER_HELICOPTER,
|
||||
INTRO_END_END_SPEECH_MIGUEL,
|
||||
INTRO_END_END_SPEECH_NO_MIGUEL,
|
||||
INTRO_END_HELI_FLYBY,
|
||||
INTRO_END_SKYRIDER_HELICOPTER,
|
||||
INTRO_END_NOSKYRIDER_HELICOPTER,
|
||||
|
||||
SMKINTRO_SPLASH_SCREEN,
|
||||
SMKINTRO_SPLASH_TALONSOFT,
|
||||
INTRO_SPLASH_SCREEN,
|
||||
INTRO_SPLASH_TALONSOFT,
|
||||
|
||||
//there are no more videos shown for the endgame
|
||||
SMKINTRO_LAST_END_GAME,
|
||||
INTRO_LAST_END_GAME,
|
||||
|
||||
INTRO_FIRST_VIDEO = 255
|
||||
};
|
||||
|
||||
INT32 giCurrentIntroBeingPlayed = SMKINTRO_NO_VIDEO;
|
||||
|
||||
EGameVideos giCurrentIntroBeingPlayed = INTRO_NO_VIDEO;
|
||||
/*
|
||||
CHAR *gpzSmackerFileNames[] =
|
||||
{
|
||||
//begining of the game
|
||||
@@ -104,7 +259,9 @@ CHAR *gpzSmackerFileNames[] =
|
||||
"INTRO\\SplashScreen.smk",
|
||||
"INTRO\\TalonSoftid_endhold.smk",
|
||||
};
|
||||
|
||||
*/
|
||||
typedef std::map<EGameVideos,std::string> VideoFileNames_t;
|
||||
static VideoFileNames_t s_VFN;
|
||||
|
||||
//enums used for when the intro screen can come up, either begining game intro, or end game cinematic
|
||||
INT8 gbIntroScreenMode=-1;
|
||||
@@ -112,15 +269,15 @@ INT8 gbIntroScreenMode=-1;
|
||||
|
||||
extern void CDromEjectionErrorMessageBoxCallBack( UINT8 bExitValue );
|
||||
|
||||
void GetIntroScreenUserInput();
|
||||
BOOLEAN EnterIntroScreen();
|
||||
void RenderIntroScreen();
|
||||
void ExitIntroScreen();
|
||||
void HandleIntroScreen();
|
||||
void PrepareToExitIntroScreen();
|
||||
INT32 GetNextIntroVideo( UINT32 uiCurrentVideo );
|
||||
void StartPlayingIntroFlic( INT32 iIndexOfFlicToPlay );
|
||||
void DisplaySirtechSplashScreen();
|
||||
void GetIntroScreenUserInput();
|
||||
BOOLEAN EnterIntroScreen();
|
||||
void RenderIntroScreen();
|
||||
void ExitIntroScreen();
|
||||
void HandleIntroScreen();
|
||||
void PrepareToExitIntroScreen();
|
||||
EGameVideos GetNextIntroVideo( EGameVideos uiCurrentVideo );
|
||||
void StartPlayingIntroFlic( EGameVideos iIndexOfFlicToPlay );
|
||||
void DisplaySirtechSplashScreen();
|
||||
|
||||
|
||||
//ppp
|
||||
@@ -131,6 +288,24 @@ UINT32 IntroScreenInit( void )
|
||||
//Set so next time we come in, we can set up
|
||||
gfIntroScreenEntry = TRUE;
|
||||
|
||||
CIniReader inireader("IntroVideos.ini");
|
||||
s_VFN[INTRO_REBEL_CRDT] = inireader.ReadString("INTRO_BEGINNING","INTRO_REBEL_CRDT","INTRO\\Rebel_cr");
|
||||
s_VFN[INTRO_OMERTA] = inireader.ReadString("INTRO_BEGINNING","INTRO_OMERTA","INTRO\\Omerta");
|
||||
s_VFN[INTRO_PRAGUE_CRDT] = inireader.ReadString("INTRO_BEGINNING","INTRO_PRAGUE_CRDT","INTRO\\Prague_cr");
|
||||
s_VFN[INTRO_PRAGUE] = inireader.ReadString("INTRO_BEGINNING","INTRO_PRAGUE","INTRO\\Prague");
|
||||
|
||||
//there are no more videos shown for the begining
|
||||
s_VFN[INTRO_END_END_SPEECH_MIGUEL] = inireader.ReadString("INTRO_ENDING","INTRO_END_END_SPEECH_MIGUEL","INTRO\\Throne_Mig");
|
||||
s_VFN[INTRO_END_END_SPEECH_NO_MIGUEL] = inireader.ReadString("INTRO_ENDING","INTRO_END_END_SPEECH_NO_MIGUEL","INTRO\\Throne_NoMig");
|
||||
s_VFN[INTRO_END_HELI_FLYBY] = inireader.ReadString("INTRO_ENDING","INTRO_END_HELI_FLYBY","INTRO\\Heli_FlyBy");
|
||||
s_VFN[INTRO_END_SKYRIDER_HELICOPTER] = inireader.ReadString("INTRO_ENDING","INTRO_END_SKYRIDER_HELICOPTER","INTRO\\Heli_Sky");
|
||||
s_VFN[INTRO_END_NOSKYRIDER_HELICOPTER] = inireader.ReadString("INTRO_ENDING","INTRO_END_NOSKYRIDER_HELICOPTER","INTRO\\Heli_NoSky");
|
||||
|
||||
s_VFN[INTRO_SPLASH_SCREEN] = inireader.ReadString("INTRO_SPLASH","INTRO_SPLASH_SCREEN","INTRO\\SplashScreen");
|
||||
s_VFN[INTRO_SPLASH_TALONSOFT] = inireader.ReadString("INTRO_SPLASH","INTRO_SPLASH_TALONSOFT","INTRO\\TalonSoftid_endhold");
|
||||
|
||||
//there are no more videos shown for the endgame
|
||||
|
||||
return( 1 );
|
||||
}
|
||||
|
||||
@@ -176,11 +351,11 @@ UINT32 IntroScreenHandle( void )
|
||||
|
||||
BOOLEAN EnterIntroScreen()
|
||||
{
|
||||
INT32 iFirstVideoID = -1;
|
||||
|
||||
Test = 0;
|
||||
|
||||
ClearMainMenu();
|
||||
|
||||
|
||||
SetCurrentCursorFromDatabase( VIDEO_NO_CURSOR );
|
||||
|
||||
// Don't play music....
|
||||
@@ -193,28 +368,11 @@ BOOLEAN EnterIntroScreen()
|
||||
return( TRUE );
|
||||
}
|
||||
|
||||
//#ifdef JA2BETAVERSION
|
||||
// if( FileExists( "..\\NoIntro.txt" ) )
|
||||
// {
|
||||
// PrepareToExitIntroScreen();
|
||||
// return( TRUE );
|
||||
// }
|
||||
//#endif
|
||||
#ifndef USE_VFS
|
||||
//if the library doesnt exist, exit
|
||||
if( !IsLibraryOpened( LIBRARY_INTRO ) )
|
||||
{
|
||||
PrepareToExitIntroScreen();
|
||||
return( TRUE );
|
||||
}
|
||||
#endif
|
||||
|
||||
//initialize smacker
|
||||
SmkInitialize( ghWindow, SCREEN_WIDTH, SCREEN_HEIGHT);
|
||||
|
||||
//initialize video player
|
||||
s_VP.Initialize();
|
||||
|
||||
//get the index opf the first video to watch
|
||||
iFirstVideoID = GetNextIntroVideo( SMKINTRO_FIRST_VIDEO );
|
||||
EGameVideos iFirstVideoID = GetNextIntroVideo( INTRO_FIRST_VIDEO );
|
||||
|
||||
if( iFirstVideoID != -1 )
|
||||
{
|
||||
@@ -239,29 +397,23 @@ void RenderIntroScreen()
|
||||
|
||||
void ExitIntroScreen()
|
||||
{
|
||||
|
||||
//shutdown smaker
|
||||
SmkShutdown();
|
||||
//shutdown video player
|
||||
s_VP.Shutdown();
|
||||
}
|
||||
|
||||
void HandleIntroScreen()
|
||||
{
|
||||
BOOLEAN fFlicStillPlaying = FALSE;
|
||||
|
||||
//if we are exiting this screen, this frame, dont update the screen
|
||||
if( gfIntroScreenExit )
|
||||
return;
|
||||
|
||||
|
||||
//handle smaker each frame
|
||||
fFlicStillPlaying = SmkPollFlics();
|
||||
//handle video in each frame
|
||||
BOOLEAN fFlicStillPlaying = s_VP.isPlaying();
|
||||
|
||||
//if the flic is not playing
|
||||
if( !fFlicStillPlaying )
|
||||
{
|
||||
INT32 iNextVideoToPlay = -1;
|
||||
|
||||
iNextVideoToPlay = GetNextIntroVideo( giCurrentIntroBeingPlayed );
|
||||
EGameVideos iNextVideoToPlay = GetNextIntroVideo( giCurrentIntroBeingPlayed );
|
||||
|
||||
if( iNextVideoToPlay != -1 )
|
||||
{
|
||||
@@ -270,7 +422,7 @@ void HandleIntroScreen()
|
||||
else
|
||||
{
|
||||
PrepareToExitIntroScreen();
|
||||
giCurrentIntroBeingPlayed = -1;
|
||||
giCurrentIntroBeingPlayed = INTRO_NO_VIDEO;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -279,12 +431,11 @@ void HandleIntroScreen()
|
||||
|
||||
|
||||
|
||||
void GetIntroScreenUserInput()
|
||||
void GetIntroScreenUserInput()
|
||||
{
|
||||
InputAtom Event;
|
||||
POINT MousePos;
|
||||
|
||||
|
||||
GetCursorPos(&MousePos);
|
||||
ScreenToClient(ghWindow, &MousePos); // In window coords!
|
||||
|
||||
@@ -292,7 +443,7 @@ void GetIntroScreenUserInput()
|
||||
{
|
||||
// HOOK INTO MOUSE HOOKS
|
||||
switch( Event.usEvent)
|
||||
{
|
||||
{
|
||||
case LEFT_BUTTON_DOWN:
|
||||
MouseSystemHook(LEFT_BUTTON_DOWN, (INT16)MousePos.x, (INT16)MousePos.y,_LeftButtonDown, _RightButtonDown);
|
||||
break;
|
||||
@@ -313,16 +464,16 @@ void GetIntroScreenUserInput()
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
if( Event.usEvent == KEY_UP )
|
||||
{
|
||||
switch( Event.usParam )
|
||||
{
|
||||
case ESC:
|
||||
s_VP.stopVideo();
|
||||
PrepareToExitIntroScreen();
|
||||
break;
|
||||
case SPACE:
|
||||
SmkCloseFlic( gpSmackFlic );
|
||||
s_VP.stopVideo();
|
||||
break;
|
||||
|
||||
#ifdef JA2TESTVERSION
|
||||
@@ -343,15 +494,18 @@ void GetIntroScreenUserInput()
|
||||
if( gfLeftButtonState || gfRightButtonState )
|
||||
{
|
||||
//advance to the next flic
|
||||
SmkCloseFlic( gpSmackFlic );
|
||||
s_VP.stopVideo();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void PrepareToExitIntroScreen()
|
||||
{
|
||||
#ifdef LUA_INTRO
|
||||
LuaIntro(0, 0, 0, 0);
|
||||
#else
|
||||
//if its the intro at the begining of the game
|
||||
if( gbIntroScreenMode == INTRO_BEGINING )
|
||||
if( gbIntroScreenMode == INTRO_BEGINNING )
|
||||
{
|
||||
//go to the init screen
|
||||
guiIntroExitScreen = INIT_SCREEN;
|
||||
@@ -374,110 +528,121 @@ void PrepareToExitIntroScreen()
|
||||
}
|
||||
|
||||
gfIntroScreenExit = TRUE;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
INT32 GetNextIntroVideo( UINT32 uiCurrentVideo )
|
||||
EGameVideos GetNextIntroVideo( EGameVideos uiCurrentVideo )
|
||||
{
|
||||
INT32 iStringToUse = -1;
|
||||
|
||||
EGameVideos iStringToUse = INTRO_NO_VIDEO;
|
||||
#ifdef LUA_INTRO
|
||||
switch( Test )
|
||||
{
|
||||
case 0:
|
||||
LuaIntro(1, uiCurrentVideo, 0, 0);
|
||||
iStringToUse = (EGameVideos)iStringToUseLua;
|
||||
//Test = 1;
|
||||
break;
|
||||
}
|
||||
#else
|
||||
//switch on whether it is the beginging or the end game video
|
||||
switch( gbIntroScreenMode )
|
||||
{
|
||||
//the video at the begining of the game
|
||||
case INTRO_BEGINING:
|
||||
case INTRO_BEGINNING:
|
||||
{
|
||||
switch( uiCurrentVideo )
|
||||
{
|
||||
case SMKINTRO_FIRST_VIDEO:
|
||||
iStringToUse = SMKINTRO_REBEL_CRDT;
|
||||
case INTRO_FIRST_VIDEO:
|
||||
iStringToUse = INTRO_REBEL_CRDT;
|
||||
break;
|
||||
case SMKINTRO_REBEL_CRDT:
|
||||
iStringToUse = SMKINTRO_OMERTA;
|
||||
case INTRO_REBEL_CRDT:
|
||||
iStringToUse = INTRO_OMERTA;
|
||||
break;
|
||||
case SMKINTRO_OMERTA:
|
||||
iStringToUse = SMKINTRO_PRAGUE_CRDT;
|
||||
case INTRO_OMERTA:
|
||||
iStringToUse = INTRO_PRAGUE_CRDT;
|
||||
break;
|
||||
case SMKINTRO_PRAGUE_CRDT:
|
||||
iStringToUse = SMKINTRO_PRAGUE;
|
||||
case INTRO_PRAGUE_CRDT:
|
||||
iStringToUse = INTRO_PRAGUE;
|
||||
break;
|
||||
case SMKINTRO_PRAGUE:
|
||||
iStringToUse = -1;
|
||||
case INTRO_PRAGUE:
|
||||
iStringToUse = INTRO_NO_VIDEO;
|
||||
break;
|
||||
// case SMKINTRO_LAST_INTRO:
|
||||
// case INTRO_LAST_INTRO:
|
||||
// iStringToUse = -1;
|
||||
// break;
|
||||
}
|
||||
break;
|
||||
}
|
||||
break;
|
||||
|
||||
//end game
|
||||
case INTRO_ENDING:
|
||||
{
|
||||
switch( uiCurrentVideo )
|
||||
{
|
||||
case SMKINTRO_FIRST_VIDEO:
|
||||
case INTRO_FIRST_VIDEO:
|
||||
{
|
||||
//if Miguel is dead, play the flic with out him in it
|
||||
if( gMercProfiles[ MIGUEL ].bMercStatus == MERC_IS_DEAD )
|
||||
iStringToUse = SMKINTRO_END_END_SPEECH_NO_MIGUEL;
|
||||
iStringToUse = INTRO_END_END_SPEECH_NO_MIGUEL;
|
||||
else
|
||||
iStringToUse = SMKINTRO_END_END_SPEECH_MIGUEL;
|
||||
iStringToUse = INTRO_END_END_SPEECH_MIGUEL;
|
||||
break;
|
||||
|
||||
case SMKINTRO_END_END_SPEECH_MIGUEL:
|
||||
case SMKINTRO_END_END_SPEECH_NO_MIGUEL:
|
||||
iStringToUse = SMKINTRO_END_HELI_FLYBY;
|
||||
}
|
||||
case INTRO_END_END_SPEECH_MIGUEL:
|
||||
case INTRO_END_END_SPEECH_NO_MIGUEL:
|
||||
{
|
||||
iStringToUse = INTRO_END_HELI_FLYBY;
|
||||
break;
|
||||
|
||||
}
|
||||
//if SkyRider is dead, play the flic without him
|
||||
case SMKINTRO_END_HELI_FLYBY:
|
||||
case INTRO_END_HELI_FLYBY:
|
||||
{
|
||||
if( gMercProfiles[ SKYRIDER ].bMercStatus == MERC_IS_DEAD )
|
||||
iStringToUse = SMKINTRO_END_NOSKYRIDER_HELICOPTER;
|
||||
iStringToUse = INTRO_END_NOSKYRIDER_HELICOPTER;
|
||||
else
|
||||
iStringToUse = SMKINTRO_END_SKYRIDER_HELICOPTER;
|
||||
iStringToUse = INTRO_END_SKYRIDER_HELICOPTER;
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
break;
|
||||
|
||||
case INTRO_SPLASH:
|
||||
switch( uiCurrentVideo )
|
||||
{
|
||||
case SMKINTRO_FIRST_VIDEO:
|
||||
iStringToUse = SMKINTRO_SPLASH_SCREEN;
|
||||
case INTRO_FIRST_VIDEO:
|
||||
iStringToUse = INTRO_SPLASH_SCREEN;
|
||||
break;
|
||||
case SMKINTRO_SPLASH_SCREEN:
|
||||
case INTRO_SPLASH_SCREEN:
|
||||
//iStringToUse = SMKINTRO_SPLASH_TALONSOFT;
|
||||
break;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
#endif
|
||||
return( iStringToUse );
|
||||
}
|
||||
|
||||
|
||||
void StartPlayingIntroFlic( INT32 iIndexOfFlicToPlay )
|
||||
void StartPlayingIntroFlic( EGameVideos iIndexOfFlicToPlay )
|
||||
{
|
||||
|
||||
if( iIndexOfFlicToPlay != -1 )
|
||||
{
|
||||
giCurrentIntroBeingPlayed = iIndexOfFlicToPlay;
|
||||
//start playing a flic
|
||||
gpSmackFlic = SmkPlayFlic( gpzSmackerFileNames[ iIndexOfFlicToPlay ], (SCREEN_WIDTH-640)/2, (SCREEN_HEIGHT-480)/2, TRUE );
|
||||
|
||||
if( gpSmackFlic != NULL )
|
||||
if(s_VP.startVideo( s_VFN[iIndexOfFlicToPlay] ))
|
||||
{
|
||||
giCurrentIntroBeingPlayed = iIndexOfFlicToPlay;
|
||||
}
|
||||
else
|
||||
{
|
||||
//do a check
|
||||
if(!s_VP.isValid())
|
||||
{
|
||||
//do a check
|
||||
#ifdef JA2BETAVERSION
|
||||
PrepareToExitIntroScreen();
|
||||
PrepareToExitIntroScreen();
|
||||
#else
|
||||
|
||||
DoScreenIndependantMessageBox( gzIntroScreen[INTRO_TXT__CANT_FIND_INTRO], MSG_BOX_FLAG_OK, CDromEjectionErrorMessageBoxCallBack );
|
||||
DoScreenIndependantMessageBox( gzIntroScreen[INTRO_TXT__CANT_FIND_INTRO], MSG_BOX_FLAG_OK, CDromEjectionErrorMessageBoxCallBack );
|
||||
#endif
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -485,9 +650,12 @@ void StartPlayingIntroFlic( INT32 iIndexOfFlicToPlay )
|
||||
|
||||
void SetIntroType( INT8 bIntroType )
|
||||
{
|
||||
if( bIntroType == INTRO_BEGINING )
|
||||
#ifdef LUA_INTRO
|
||||
LuaIntro(2, 0, bIntroType, 0);
|
||||
#else
|
||||
if( bIntroType == INTRO_BEGINNING )
|
||||
{
|
||||
gbIntroScreenMode = INTRO_BEGINING;
|
||||
gbIntroScreenMode = INTRO_BEGINNING;
|
||||
}
|
||||
else if( bIntroType == INTRO_ENDING )
|
||||
{
|
||||
@@ -497,58 +665,53 @@ void SetIntroType( INT8 bIntroType )
|
||||
{
|
||||
gbIntroScreenMode = INTRO_SPLASH;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
void DisplaySirtechSplashScreen()
|
||||
{
|
||||
HVOBJECT hPixHandle;
|
||||
VOBJECT_DESC VObjectDesc;
|
||||
UINT32 uiLogoID;
|
||||
|
||||
UINT32 uiDestPitchBYTES;
|
||||
UINT8 *pDestBuf;
|
||||
|
||||
|
||||
// CLEAR THE FRAME BUFFER
|
||||
pDestBuf = LockVideoSurface( FRAME_BUFFER, &uiDestPitchBYTES );
|
||||
UINT32 uiDestPitchBYTES;
|
||||
UINT8* pDestBuf = LockVideoSurface( FRAME_BUFFER, &uiDestPitchBYTES );
|
||||
memset(pDestBuf, 0, SCREEN_HEIGHT * uiDestPitchBYTES );
|
||||
UnLockVideoSurface( FRAME_BUFFER );
|
||||
|
||||
|
||||
VOBJECT_DESC VObjectDesc;
|
||||
memset( &VObjectDesc, 0, sizeof( VOBJECT_DESC ) );
|
||||
VObjectDesc.fCreateFlags=VOBJECT_CREATE_FROMFILE;
|
||||
FilenameForBPP("INTERFACE\\SirtechSplash.sti", VObjectDesc.ImageFile);
|
||||
|
||||
// FilenameForBPP("INTERFACE\\TShold.sti", VObjectDesc.ImageFile);
|
||||
|
||||
UINT32 uiLogoID;
|
||||
if( !AddVideoObject(&VObjectDesc, &uiLogoID) )
|
||||
{
|
||||
FilenameForBPP("GERMAN\\SPLASH_GERMAN.sti", VObjectDesc.ImageFile);
|
||||
if( !AddVideoObject(&VObjectDesc, &uiLogoID) )
|
||||
{
|
||||
/*
|
||||
* This is the place, where most non english coders stranding.
|
||||
* Don't hesitate, don't give up!
|
||||
* I'll now tell You what You made wrong
|
||||
* (2006-10-10, Sergeant_Kolja)
|
||||
*/
|
||||
#ifdef _DEBUG
|
||||
# if defined(ENGLISH)
|
||||
AssertMsg( 0, String( "Wheter English nor German works. May be You built English - but have only German or other foreign Disk?" ) );
|
||||
# elif defined(GERMAN)
|
||||
AssertMsg( 0, String( "Weder Englisch noch Deutsch geht. Deutsche Version kompiliert und mit englischer CDs gestartet? Das geht nicht!" ) );
|
||||
# endif
|
||||
#endif
|
||||
AssertMsg( 0, String( "Failed to load %s", VObjectDesc.ImageFile ) );
|
||||
return;
|
||||
}
|
||||
if( !AddVideoObject(&VObjectDesc, &uiLogoID) )
|
||||
{
|
||||
/*
|
||||
* This is the place, where most non english coders stranding.
|
||||
* Don't hesitate, don't give up!
|
||||
* I'll now tell You what You made wrong
|
||||
* (2006-10-10, Sergeant_Kolja)
|
||||
*/
|
||||
#ifdef _DEBUG
|
||||
# if defined(ENGLISH)
|
||||
AssertMsg( 0, String( "Wheter English nor German works. May be You built English - but have only German or other foreign Disk?" ) );
|
||||
# elif defined(GERMAN)
|
||||
AssertMsg( 0, String( "Weder Englisch noch Deutsch geht. Deutsche Version kompiliert und mit englischer CDs gestartet? Das geht nicht!" ) );
|
||||
# endif
|
||||
#endif
|
||||
AssertMsg( 0, String( "Failed to load %s", VObjectDesc.ImageFile ) );
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
HVOBJECT hPixHandle;
|
||||
GetVideoObject(&hPixHandle, uiLogoID);
|
||||
BltVideoObject(FRAME_BUFFER, hPixHandle, 0,(SCREEN_WIDTH-640)/2, (SCREEN_HEIGHT-480)/2, VO_BLT_SRCTRANSPARENCY,NULL);
|
||||
DeleteVideoObjectFromIndex(uiLogoID);
|
||||
|
||||
|
||||
InvalidateScreen();
|
||||
RefreshScreen( NULL );
|
||||
}
|
||||
|
||||
@@ -9,9 +9,9 @@ UINT32 IntroScreenInit( void );
|
||||
|
||||
|
||||
//enums used for when the intro screen can come up, used with 'gbIntroScreenMode'
|
||||
enum
|
||||
enum EIntroType
|
||||
{
|
||||
INTRO_BEGINING, //set when viewing the intro at the begining of the game
|
||||
INTRO_BEGINNING, //set when viewing the intro at the begining of the game
|
||||
INTRO_ENDING, //set when viewing the end game video.
|
||||
|
||||
INTRO_SPLASH,
|
||||
@@ -22,5 +22,9 @@ extern UINT32 guiSmackerSurface;
|
||||
|
||||
|
||||
void SetIntroType( INT8 bIntroType );
|
||||
extern void DisplaySirtechSplashScreen();
|
||||
extern UINT32 guiIntroExitScreen;
|
||||
extern BOOLEAN gfIntroScreenExit;
|
||||
extern INT8 gbIntroScreenMode;
|
||||
|
||||
#endif
|
||||
+36
-36
@@ -24,39 +24,39 @@ void InitJA2SplashScreen()
|
||||
UINT32 uiLogoID = 0;
|
||||
HVSURFACE hVSurface; // unused jonathanl // lalien reenabled for international versions
|
||||
VSURFACE_DESC VSurfaceDesc; //unused jonathanl // lalien reenabled for international versions
|
||||
#ifdef JA2TESTVERSION
|
||||
INT32 i = 0;
|
||||
# ifdef JA2TESTVERSION
|
||||
INT32 i = 0;
|
||||
|
||||
memset( &VSurfaceDesc, 0, sizeof( VSURFACE_DESC ) );
|
||||
VSurfaceDesc.fCreateFlags = VSURFACE_CREATE_FROMFILE | VSURFACE_SYSTEM_MEM_USAGE;
|
||||
sprintf( VSurfaceDesc.ImageFile, "LOADSCREENS\\Notification.sti" );
|
||||
if( !AddVideoSurface( &VSurfaceDesc, &uiLogoID ) )
|
||||
{
|
||||
//AssertMsg( 0, String( "Failed to load %s", VSurfaceDesc.ImageFile ) );
|
||||
return;
|
||||
}
|
||||
GetVideoSurface(&hVSurface, uiLogoID );
|
||||
//BltVideoSurfaceToVideoSurface( ghFrameBuffer, hVSurface, 0, 0, 0, 0, NULL );
|
||||
BltVideoSurfaceToVideoSurface( ghFrameBuffer, hVSurface, 0, iScreenWidthOffset, iScreenHeightOffset, 0, NULL );
|
||||
DeleteVideoSurfaceFromIndex( uiLogoID );
|
||||
|
||||
|
||||
InvalidateScreen();
|
||||
RefreshScreen( NULL );
|
||||
|
||||
guiSplashStartTime = GetJA2Clock();
|
||||
while( i < 60 * 15 )//guiSplashStartTime + 15000 > GetJA2Clock() )
|
||||
{
|
||||
//Allow the user to pick his bum.
|
||||
InvalidateScreen();
|
||||
RefreshScreen( NULL );
|
||||
i++;
|
||||
}
|
||||
# endif // JA2TESTVERSION
|
||||
|
||||
memset( &VSurfaceDesc, 0, sizeof( VSURFACE_DESC ) );
|
||||
VSurfaceDesc.fCreateFlags = VSURFACE_CREATE_FROMFILE | VSURFACE_SYSTEM_MEM_USAGE;
|
||||
sprintf( VSurfaceDesc.ImageFile, "LOADSCREENS\\Notification.sti" );
|
||||
if( !AddVideoSurface( &VSurfaceDesc, &uiLogoID ) )
|
||||
{
|
||||
//AssertMsg( 0, String( "Failed to load %s", VSurfaceDesc.ImageFile ) );
|
||||
return;
|
||||
}
|
||||
GetVideoSurface(&hVSurface, uiLogoID );
|
||||
//BltVideoSurfaceToVideoSurface( ghFrameBuffer, hVSurface, 0, 0, 0, 0, NULL );
|
||||
BltVideoSurfaceToVideoSurface( ghFrameBuffer, hVSurface, 0, iScreenWidthOffset, iScreenHeightOffset, 0, NULL );
|
||||
DeleteVideoSurfaceFromIndex( uiLogoID );
|
||||
|
||||
|
||||
InvalidateScreen();
|
||||
RefreshScreen( NULL );
|
||||
|
||||
guiSplashStartTime = GetJA2Clock();
|
||||
while( i < 60 * 15 )//guiSplashStartTime + 15000 > GetJA2Clock() )
|
||||
{
|
||||
//Allow the user to pick his bum.
|
||||
InvalidateScreen();
|
||||
RefreshScreen( NULL );
|
||||
i++;
|
||||
}
|
||||
#endif
|
||||
|
||||
memset( &VSurfaceDesc, 0, sizeof( VSURFACE_DESC ) );
|
||||
VSurfaceDesc.fCreateFlags = VSURFACE_CREATE_FROMFILE | VSURFACE_SYSTEM_MEM_USAGE;
|
||||
GetMLGFilename( VSurfaceDesc.ImageFile, MLG_SPLASH );
|
||||
GetMLGFilename( VSurfaceDesc.ImageFile, MLG_SPLASH );
|
||||
try
|
||||
{
|
||||
if( !AddVideoSurface( &VSurfaceDesc, &uiLogoID ) )
|
||||
@@ -65,15 +65,15 @@ void InitJA2SplashScreen()
|
||||
return;
|
||||
}
|
||||
}
|
||||
catch(CBasicException &ex)
|
||||
catch(std::exception &ex)
|
||||
{
|
||||
RETHROWEXCEPTION(L"Failed loading splash screen", &ex);
|
||||
SGP_RETHROW(L"Failed loading splash screen", ex);
|
||||
}
|
||||
|
||||
GetVideoSurface( &hVSurface, uiLogoID );
|
||||
BltVideoSurfaceToVideoSurface( ghFrameBuffer, hVSurface, 0, iScreenWidthOffset, iScreenHeightOffset, 0, NULL );
|
||||
DeleteVideoSurfaceFromIndex( uiLogoID );
|
||||
#endif
|
||||
GetVideoSurface( &hVSurface, uiLogoID );
|
||||
BltVideoSurfaceToVideoSurface( ghFrameBuffer, hVSurface, 0, iScreenWidthOffset, iScreenHeightOffset, 0, NULL );
|
||||
DeleteVideoSurfaceFromIndex( uiLogoID );
|
||||
#endif // ENGLISH
|
||||
|
||||
InvalidateScreen();
|
||||
RefreshScreen( NULL );
|
||||
|
||||
+5
-1
@@ -37,7 +37,11 @@
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
//**ddd direct link libraries
|
||||
#pragma comment (lib, "user32.lib")
|
||||
#pragma comment (lib, "gdi32.lib")
|
||||
#pragma comment (lib, "advapi32.lib")
|
||||
#pragma comment (lib, "shell32.lib")
|
||||
|
||||
/* ====================================================================
|
||||
* Regardless of if we did it Workspace wide or by uncommenting above,
|
||||
|
||||
+169
-37
@@ -23,12 +23,15 @@ extern UINT8 gbCurrentIndex;
|
||||
|
||||
|
||||
UINT32 guiMugShotBorder;
|
||||
UINT32 guiAimFiFace[ MAX_NUMBER_MERCS ];
|
||||
UINT32 guiAimFiFace[ NUM_PROFILES ]; //MAX_NUMBER_MERCS
|
||||
|
||||
BOOLEAN gAimProfiles[ NUM_PROFILES ];
|
||||
|
||||
#define AIM_FI_NUM_MUGSHOTS_X 8
|
||||
#define AIM_FI_NUM_MUGSHOTS_Y 5
|
||||
|
||||
#define AIM_FI_NUM_MUHSHOTS_X 8
|
||||
#define AIM_FI_NUM_MUHSHOTS_Y 5
|
||||
UINT8 START_MERC =0;
|
||||
UINT8 END_MERC =0;
|
||||
|
||||
#define AIM_FI_PORTRAIT_WIDTH 52
|
||||
#define AIM_FI_PORTRAIT_HEIGHT 48
|
||||
@@ -46,6 +49,9 @@ UINT32 guiAimFiFace[ MAX_NUMBER_MERCS ];
|
||||
#define AIM_FI_MEMBER_TEXT_X IMAGE_OFFSET_X + 155
|
||||
#define AIM_FI_MEMBER_TEXT_Y AIM_SYMBOL_Y + AIM_SYMBOL_SIZE_Y + 1
|
||||
#define AIM_FI_MEMBER_TEXT_WIDTH 190
|
||||
//tais: nsgi, move member text up
|
||||
#define AIM_FI_MEMBER_TEXT_Y_NSGI AIM_SYMBOL_SMALL_Y + 35
|
||||
|
||||
|
||||
#define AIM_FI_AWAY_TEXT_OFFSET_X 3
|
||||
#define AIM_FI_AWAY_TEXT_OFFSET_Y 23//3//36
|
||||
@@ -55,7 +61,7 @@ UINT32 guiAimFiFace[ MAX_NUMBER_MERCS ];
|
||||
//Mouse Regions
|
||||
|
||||
//Face regions
|
||||
MOUSE_REGION gMercFaceMouseRegions[ MAX_NUMBER_MERCS ];
|
||||
MOUSE_REGION gMercFaceMouseRegions[ NUM_PROFILES ]; //MAX_NUMBER_MERCS
|
||||
void SelectMercFaceRegionCallBack(MOUSE_REGION * pRegion, INT32 iReason );
|
||||
void SelectMercFaceMoveRegionCallBack(MOUSE_REGION * pRegion, INT32 iReason );
|
||||
|
||||
@@ -66,12 +72,74 @@ void SelectScreenRegionCallBack(MOUSE_REGION * pRegion, INT32 iReason );
|
||||
|
||||
BOOLEAN DrawMercsFaceToScreen(UINT8 ubMercID, UINT16 usPosX, UINT16 usPosY, UINT8 ubImage);
|
||||
|
||||
//New profiles
|
||||
INT32 guiPreviousNewProfilesNextButtonImage;
|
||||
void BtnNewProfilesButtonCallback(GUI_BUTTON *btn,INT32 reason);
|
||||
|
||||
INT32 PAGE_BUTTON;
|
||||
|
||||
void GameInitAimFacialIndex()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
/// Calculates the needed string for the page button based on number of mercs
|
||||
/// and currently displayed page.
|
||||
static STR16 GetPageButtonText()
|
||||
{
|
||||
const int MERCS_PER_PAGE = AIM_FI_NUM_MUGSHOTS_X * AIM_FI_NUM_MUGSHOTS_Y;
|
||||
|
||||
int baseTextIndex;
|
||||
// Display three pages of mercs (strings from gszAimPages[2] to gszAimPages[4])
|
||||
if (MAX_NUMBER_MERCS > MERCS_PER_PAGE * 2)
|
||||
baseTextIndex = 2;
|
||||
// Display two pages of mercs (strings from gszAimPages[0] to gszAimPages[1])
|
||||
else if (MAX_NUMBER_MERCS > MERCS_PER_PAGE)
|
||||
{
|
||||
Assert(START_MERC < MERCS_PER_PAGE * 2);
|
||||
baseTextIndex = 0;
|
||||
}
|
||||
// Display one page of mercs (string gszAimPages[5])
|
||||
else
|
||||
{
|
||||
Assert(START_MERC < MERCS_PER_PAGE);
|
||||
baseTextIndex = 5;
|
||||
}
|
||||
|
||||
int currentPage = START_MERC / MERCS_PER_PAGE;
|
||||
int stringIndex = baseTextIndex + currentPage;
|
||||
return gszAimPages[ stringIndex ];
|
||||
}
|
||||
|
||||
void BtnNewProfilesButtonCallback(GUI_BUTTON *btn,INT32 reason)
|
||||
{
|
||||
UINT32 i;
|
||||
|
||||
for(i=0; i<MAX_NUMBER_MERCS; i++)
|
||||
{
|
||||
gAimProfiles[i] = TRUE;
|
||||
}
|
||||
|
||||
if ( START_MERC == 0 )
|
||||
{
|
||||
START_MERC = 40;
|
||||
}
|
||||
else if ( START_MERC == 40 )
|
||||
{
|
||||
if ( MAX_NUMBER_MERCS > 80 )
|
||||
START_MERC = 80;
|
||||
else
|
||||
START_MERC = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
START_MERC = 0;
|
||||
}
|
||||
|
||||
ExitAimFacialIndex();
|
||||
EnterAimFacialIndex();
|
||||
}
|
||||
|
||||
BOOLEAN EnterAimFacialIndex()
|
||||
{
|
||||
VOBJECT_DESC VObjectDesc;
|
||||
@@ -79,41 +147,66 @@ BOOLEAN EnterAimFacialIndex()
|
||||
UINT16 usPosX, usPosY, x,y;
|
||||
STR sFaceLoc = "FACES\\";
|
||||
char sTemp[100];
|
||||
|
||||
UINT8 p = 0;
|
||||
|
||||
for(i=0; i<MAX_NUMBER_MERCS; i++)
|
||||
{
|
||||
gAimProfiles[i] = TRUE;
|
||||
}
|
||||
|
||||
// load the Portait graphic and add it
|
||||
VObjectDesc.fCreateFlags=VOBJECT_CREATE_FROMFILE;
|
||||
FilenameForBPP("LAPTOP\\MugShotBorder3.sti", VObjectDesc.ImageFile);
|
||||
CHECKF(AddVideoObject(&VObjectDesc, &guiMugShotBorder));
|
||||
|
||||
|
||||
//Page button
|
||||
guiPreviousNewProfilesNextButtonImage = LoadButtonImage("LAPTOP\\BottomButtons2.sti", -1,0,-1,1,-1 ); //New profiles
|
||||
|
||||
STR16 buttonText = GetPageButtonText();
|
||||
PAGE_BUTTON = CreateIconAndTextButton( guiPreviousNewProfilesNextButtonImage, buttonText, FONT14ARIAL,
|
||||
FONT_MCOLOR_DKWHITE, DEFAULT_SHADOW,
|
||||
138, DEFAULT_SHADOW,
|
||||
TEXT_CJUSTIFIED,
|
||||
IMAGE_OFFSET_X + 6, IMAGE_OFFSET_Y + 35, BUTTON_TOGGLE, MSYS_PRIORITY_HIGH,
|
||||
DEFAULT_MOVE_CALLBACK, BtnNewProfilesButtonCallback);
|
||||
SetButtonCursor(PAGE_BUTTON, CURSOR_WWW );
|
||||
|
||||
usPosX = AIM_FI_FIRST_MUGSHOT_X;
|
||||
usPosY = AIM_FI_FIRST_MUGSHOT_Y;
|
||||
i=0;
|
||||
for(y=0; y<AIM_FI_NUM_MUHSHOTS_Y; y++)
|
||||
for(y=0; y<AIM_FI_NUM_MUGSHOTS_Y; y++)
|
||||
{
|
||||
for(x=0; x<AIM_FI_NUM_MUHSHOTS_X; x++)
|
||||
for(x=0; x<AIM_FI_NUM_MUGSHOTS_X; x++)
|
||||
{
|
||||
|
||||
MSYS_DefineRegion( &gMercFaceMouseRegions[ i ], usPosX, usPosY, (INT16)(usPosX + AIM_FI_PORTRAIT_WIDTH), (INT16)(usPosY + AIM_FI_PORTRAIT_HEIGHT), MSYS_PRIORITY_HIGH,
|
||||
CURSOR_WWW, SelectMercFaceMoveRegionCallBack, SelectMercFaceRegionCallBack);
|
||||
// Add region
|
||||
MSYS_AddRegion( &gMercFaceMouseRegions[ i ] );
|
||||
MSYS_SetRegionUserData( &gMercFaceMouseRegions[ i ], 0, i);
|
||||
|
||||
if ( gAimProfiles[i+START_MERC] == TRUE ) //new profiles
|
||||
{
|
||||
|
||||
MSYS_DefineRegion( &gMercFaceMouseRegions[ i ], usPosX, usPosY, (INT16)(usPosX + AIM_FI_PORTRAIT_WIDTH), (INT16)(usPosY + AIM_FI_PORTRAIT_HEIGHT), MSYS_PRIORITY_HIGH,
|
||||
CURSOR_WWW, SelectMercFaceMoveRegionCallBack, SelectMercFaceRegionCallBack);
|
||||
// Add region
|
||||
MSYS_AddRegion( &gMercFaceMouseRegions[ i ] );
|
||||
MSYS_SetRegionUserData( &gMercFaceMouseRegions[ i ], 0, i);
|
||||
|
||||
if (gGameExternalOptions.fReadProfileDataFromXML)
|
||||
{
|
||||
// HEADROCK PROFEX: Do not read direct profile number, instead, look inside the profile for a ubFaceIndex value.
|
||||
sprintf(sTemp, "%s%02d.sti", sFaceLoc, gMercProfiles[AimMercArray[i]].ubFaceIndex);
|
||||
//sprintf(sTemp, "%s%02d.sti", sFaceLoc, gMercProfiles[AimMercArray[i]].ubFaceIndex);
|
||||
sprintf(sTemp, "%s%02d.sti", sFaceLoc, gMercProfiles[gAimAvailability[AimMercArray[i + START_MERC]].ProfilId].ubFaceIndex);
|
||||
//sprintf(sTemp, "%s%02d.sti", sFaceLoc, gAimAvailability[AimMercArray[i]].ProfilId);
|
||||
}
|
||||
else
|
||||
{
|
||||
sprintf(sTemp, "%s%02d.sti", sFaceLoc, AimMercArray[i]);
|
||||
//sprintf(sTemp, "%s%02d.sti", sFaceLoc, AimMercArray[i]);
|
||||
sprintf(sTemp, "%s%02d.sti", sFaceLoc, gAimAvailability[AimMercArray[i + START_MERC]].ProfilId );
|
||||
}
|
||||
VObjectDesc.fCreateFlags=VOBJECT_CREATE_FROMFILE;
|
||||
FilenameForBPP(sTemp, VObjectDesc.ImageFile);
|
||||
if( !AddVideoObject(&VObjectDesc, &guiAimFiFace[i]) )
|
||||
return( FALSE );
|
||||
|
||||
|
||||
}
|
||||
|
||||
usPosX += AIM_FI_PORTRAIT_WIDTH + AIM_FI_MUGSHOT_GAP_X;
|
||||
i++;
|
||||
}
|
||||
@@ -144,11 +237,18 @@ void ExitAimFacialIndex()
|
||||
DeleteVideoObjectFromIndex(guiMugShotBorder);
|
||||
|
||||
|
||||
for(i=0; i<MAX_NUMBER_MERCS; i++)
|
||||
for(i=0; i<NUM_PROFILES; i++) //MAX_NUMBER_MERCS
|
||||
{
|
||||
DeleteVideoObjectFromIndex( guiAimFiFace[i]);
|
||||
MSYS_RemoveRegion( &gMercFaceMouseRegions[ i ]);
|
||||
if ( gAimProfiles[i] == TRUE )
|
||||
{
|
||||
DeleteVideoObjectFromIndex( guiAimFiFace[i]);
|
||||
MSYS_RemoveRegion( &gMercFaceMouseRegions[ i ]);
|
||||
}
|
||||
}
|
||||
|
||||
RemoveButton( PAGE_BUTTON );
|
||||
|
||||
|
||||
ExitAimMenuBar();
|
||||
|
||||
MSYS_RemoveRegion( &gScreenMouseRegions);
|
||||
@@ -166,6 +266,17 @@ BOOLEAN RenderAimFacialIndex()
|
||||
UINT16 usPosX, usPosY, x,y;
|
||||
CHAR16 sString[150];
|
||||
UINT8 i;
|
||||
|
||||
SpecifyButtonText( PAGE_BUTTON, GetPageButtonText() );
|
||||
|
||||
if ( MAX_NUMBER_MERCS > 40 )
|
||||
{
|
||||
ShowButton( PAGE_BUTTON );
|
||||
}
|
||||
else
|
||||
{
|
||||
HideButton( PAGE_BUTTON );
|
||||
}
|
||||
|
||||
DrawAimDefaults();
|
||||
|
||||
@@ -175,21 +286,25 @@ BOOLEAN RenderAimFacialIndex()
|
||||
else
|
||||
swprintf(sString, AimFiText[ AIM_FI_AIM_MEMBERS_SORTED_DESCENDING ], AimFiText[gubCurrentSortMode] );
|
||||
|
||||
DrawTextToScreen(sString, AIM_FI_MEMBER_TEXT_X, AIM_FI_MEMBER_TEXT_Y, AIM_FI_MEMBER_TEXT_WIDTH, AIM_MAINTITLE_FONT, AIM_MAINTITLE_COLOR, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
|
||||
if(gGameExternalOptions.gfUseNewStartingGearInterface) DrawTextToScreen(sString, AIM_FI_MEMBER_TEXT_X, AIM_FI_MEMBER_TEXT_Y_NSGI, AIM_FI_MEMBER_TEXT_WIDTH, AIM_MAINTITLE_FONT, AIM_MAINTITLE_COLOR, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
else DrawTextToScreen(sString, AIM_FI_MEMBER_TEXT_X, AIM_FI_MEMBER_TEXT_Y, AIM_FI_MEMBER_TEXT_WIDTH, AIM_MAINTITLE_FONT, AIM_MAINTITLE_COLOR, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
|
||||
|
||||
//Draw the mug shot border and face
|
||||
usPosX = AIM_FI_FIRST_MUGSHOT_X;
|
||||
usPosY = AIM_FI_FIRST_MUGSHOT_Y;
|
||||
|
||||
i=0;
|
||||
for(y=0; y<AIM_FI_NUM_MUHSHOTS_Y; y++)
|
||||
for(y=0; y<AIM_FI_NUM_MUGSHOTS_Y; y++)
|
||||
{
|
||||
for(x=0; x<AIM_FI_NUM_MUHSHOTS_X; x++)
|
||||
for(x=0; x<AIM_FI_NUM_MUGSHOTS_X; x++)
|
||||
{
|
||||
DrawMercsFaceToScreen(i, usPosX, usPosY, 1);
|
||||
DrawTextToScreen(gMercProfiles[AimMercArray[i]].zNickname, (UINT16)(usPosX - AIM_FI_NNAME_OFFSET_X), (UINT16)(usPosY + AIM_FI_NNAME_OFFSET_Y), AIM_FI_NNAME_WIDTH, AIM_FONT12ARIAL, AIM_FONT_MCOLOR_WHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
|
||||
if ( gAimProfiles[i+START_MERC] == TRUE ) //new profiles
|
||||
{
|
||||
DrawMercsFaceToScreen(i, usPosX, usPosY, 1);
|
||||
// DrawTextToScreen(gMercProfiles[AimMercArray[i]].zNickname, (UINT16)(usPosX - AIM_FI_NNAME_OFFSET_X), (UINT16)(usPosY + AIM_FI_NNAME_OFFSET_Y), AIM_FI_NNAME_WIDTH, AIM_FONT12ARIAL, AIM_FONT_MCOLOR_WHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
DrawTextToScreen(gMercProfiles[gAimAvailability[AimMercArray[i+START_MERC]].ProfilId].zNickname, (UINT16)(usPosX - AIM_FI_NNAME_OFFSET_X), (UINT16)(usPosY + AIM_FI_NNAME_OFFSET_Y), AIM_FI_NNAME_WIDTH, AIM_FONT12ARIAL, AIM_FONT_MCOLOR_WHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
}
|
||||
usPosX += AIM_FI_PORTRAIT_WIDTH + AIM_FI_MUGSHOT_GAP_X;
|
||||
i++;
|
||||
}
|
||||
@@ -200,8 +315,16 @@ BOOLEAN RenderAimFacialIndex()
|
||||
DisableAimButton();
|
||||
|
||||
//display the 'left and right click' onscreen help msg
|
||||
DrawTextToScreen(AimFiText[AIM_FI_LEFT_CLICK], AIM_FI_LEFT_CLICK_TEXT_X, AIM_FI_LEFT_CLICK_TEXT_Y, AIM_FI_CLICK_TEXT_WIDTH, AIM_FI_HELP_TITLE_FONT, AIM_FONT_MCOLOR_WHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
DrawTextToScreen(AimFiText[AIM_FI_TO_SELECT], AIM_FI_LEFT_CLICK_TEXT_X, AIM_FI_LEFT_CLICK_TEXT_Y+AIM_FI_CLICK_DESC_TEXT_Y_OFFSET, AIM_FI_CLICK_TEXT_WIDTH, AIM_FI_HELP_FONT, AIM_FONT_MCOLOR_WHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
if(gGameExternalOptions.gfUseNewStartingGearInterface)
|
||||
{
|
||||
DrawTextToScreen(AimFiText[AIM_FI_LEFT_CLICK], AIM_FI_LEFT_CLICK_TEXT_X_NSGI, AIM_FI_LEFT_CLICK_TEXT_Y_NSGI, AIM_FI_CLICK_TEXT_WIDTH, AIM_FI_HELP_TITLE_FONT, AIM_FONT_MCOLOR_WHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
DrawTextToScreen(AimFiText[AIM_FI_TO_SELECT], AIM_FI_LEFT_CLICK_TEXT_X_NSGI, AIM_FI_LEFT_CLICK_TEXT_Y_NSGI+AIM_FI_CLICK_DESC_TEXT_Y_OFFSET, AIM_FI_CLICK_TEXT_WIDTH, AIM_FI_HELP_FONT, AIM_FONT_MCOLOR_WHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
}
|
||||
else
|
||||
{
|
||||
DrawTextToScreen(AimFiText[AIM_FI_LEFT_CLICK], AIM_FI_LEFT_CLICK_TEXT_X, AIM_FI_LEFT_CLICK_TEXT_Y, AIM_FI_CLICK_TEXT_WIDTH, AIM_FI_HELP_TITLE_FONT, AIM_FONT_MCOLOR_WHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
DrawTextToScreen(AimFiText[AIM_FI_TO_SELECT], AIM_FI_LEFT_CLICK_TEXT_X, AIM_FI_LEFT_CLICK_TEXT_Y+AIM_FI_CLICK_DESC_TEXT_Y_OFFSET, AIM_FI_CLICK_TEXT_WIDTH, AIM_FI_HELP_FONT, AIM_FONT_MCOLOR_WHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
}
|
||||
|
||||
DrawTextToScreen(AimFiText[AIM_FI_RIGHT_CLICK], AIM_FI_RIGHT_CLICK_TEXT_X, AIM_FI_LEFT_CLICK_TEXT_Y, AIM_FI_CLICK_TEXT_WIDTH, AIM_FI_HELP_TITLE_FONT, AIM_FONT_MCOLOR_WHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
DrawTextToScreen(AimFiText[AIM_FI_TO_ENTER_SORT_PAGE], AIM_FI_RIGHT_CLICK_TEXT_X, AIM_FI_LEFT_CLICK_TEXT_Y+AIM_FI_CLICK_DESC_TEXT_Y_OFFSET, AIM_FI_CLICK_TEXT_WIDTH, AIM_FI_HELP_FONT, AIM_FONT_MCOLOR_WHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
@@ -222,7 +345,7 @@ void SelectMercFaceRegionCallBack(MOUSE_REGION * pRegion, INT32 iReason )
|
||||
else if(iReason & MSYS_CALLBACK_REASON_LBUTTON_UP)
|
||||
{
|
||||
guiCurrentLaptopMode = LAPTOP_MODE_AIM_MEMBERS;
|
||||
gbCurrentIndex = (UINT8) MSYS_GetRegionUserData( pRegion, 0 );
|
||||
gbCurrentIndex = (UINT8) MSYS_GetRegionUserData( pRegion, 0 ) + START_MERC;
|
||||
}
|
||||
else if (iReason & MSYS_CALLBACK_REASON_RBUTTON_UP)
|
||||
{
|
||||
@@ -257,14 +380,15 @@ void SelectMercFaceMoveRegionCallBack(MOUSE_REGION * pRegion, INT32 reason )
|
||||
tx1 = AIM_FI_FIRST_MUGSHOT_X;
|
||||
tx2 = (AIM_FI_PORTRAIT_WIDTH + AIM_FI_MUGSHOT_GAP_X);
|
||||
|
||||
usPosY = ubMercNum / AIM_FI_NUM_MUHSHOTS_X;
|
||||
usPosY = ubMercNum / AIM_FI_NUM_MUGSHOTS_X;
|
||||
usPosY = AIM_FI_FIRST_MUGSHOT_Y + (AIM_FI_PORTRAIT_HEIGHT + AIM_FI_MUGSHOT_GAP_Y) * usPosY;
|
||||
|
||||
usPosX = ubMercNum % AIM_FI_NUM_MUHSHOTS_X;
|
||||
usPosX = ubMercNum % AIM_FI_NUM_MUGSHOTS_X;
|
||||
usPosX = AIM_FI_FIRST_MUGSHOT_X + (AIM_FI_PORTRAIT_WIDTH + AIM_FI_MUGSHOT_GAP_X) * usPosX;
|
||||
|
||||
// fReDrawNewMailFlag = TRUE;
|
||||
|
||||
if ( gAimProfiles[ubMercNum + START_MERC] == TRUE ) //new profiles
|
||||
{
|
||||
if( reason & MSYS_CALLBACK_REASON_LOST_MOUSE )
|
||||
{
|
||||
pRegion->uiFlags &= (~BUTTON_CLICKED_ON );
|
||||
@@ -277,6 +401,8 @@ void SelectMercFaceMoveRegionCallBack(MOUSE_REGION * pRegion, INT32 reason )
|
||||
DrawMercsFaceToScreen(ubMercNum, usPosX, usPosY, 0);
|
||||
InvalidateRegion(pRegion->RegionTopLeftX, pRegion->RegionTopLeftY, pRegion->RegionBottomRightX, pRegion->RegionBottomRightY);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
BOOLEAN DrawMercsFaceToScreen(UINT8 ubMercID, UINT16 usPosX, UINT16 usPosY, UINT8 ubImage)
|
||||
@@ -285,7 +411,10 @@ BOOLEAN DrawMercsFaceToScreen(UINT8 ubMercID, UINT16 usPosX, UINT16 usPosY, UINT
|
||||
HVOBJECT hFaceHandle;
|
||||
SOLDIERTYPE *pSoldier=NULL;
|
||||
|
||||
pSoldier = FindSoldierByProfileID( AimMercArray[ubMercID], TRUE );
|
||||
//pSoldier = FindSoldierByProfileID( AimMercArray[ubMercID], TRUE );
|
||||
pSoldier = FindSoldierByProfileID( gAimAvailability[AimMercArray[ubMercID + START_MERC]].ProfilId, TRUE );
|
||||
|
||||
|
||||
|
||||
|
||||
//Blt the portrait background
|
||||
@@ -296,7 +425,8 @@ BOOLEAN DrawMercsFaceToScreen(UINT8 ubMercID, UINT16 usPosX, UINT16 usPosY, UINT
|
||||
GetVideoObject(&hFaceHandle, guiAimFiFace[ubMercID]);
|
||||
BltVideoObject(FRAME_BUFFER, hFaceHandle, 0,usPosX+AIM_FI_FACE_OFFSET, usPosY+AIM_FI_FACE_OFFSET, VO_BLT_SRCTRANSPARENCY,NULL);
|
||||
|
||||
if( IsMercDead( AimMercArray[ubMercID] ) )
|
||||
//if( IsMercDead( AimMercArray[ubMercID] ) )
|
||||
if( IsMercDead( gAimAvailability[AimMercArray[ubMercID + START_MERC]].ProfilId ) )
|
||||
{
|
||||
//get the face object
|
||||
GetVideoObject(&hFaceHandle, guiAimFiFace[ubMercID]);
|
||||
@@ -315,7 +445,8 @@ BOOLEAN DrawMercsFaceToScreen(UINT8 ubMercID, UINT16 usPosX, UINT16 usPosY, UINT
|
||||
}
|
||||
|
||||
//else if the merc is currently a POW or, the merc was fired as a pow
|
||||
else if( gMercProfiles[ AimMercArray[ubMercID] ].bMercStatus == MERC_FIRED_AS_A_POW || ( pSoldier && pSoldier->bAssignment == ASSIGNMENT_POW ) )
|
||||
//else if( gMercProfiles[ AimMercArray[ubMercID] ].bMercStatus == MERC_FIRED_AS_A_POW || ( pSoldier && pSoldier->bAssignment == ASSIGNMENT_POW ) )
|
||||
else if( gMercProfiles[ gAimAvailability[AimMercArray[ubMercID + START_MERC]].ProfilId ].bMercStatus == MERC_FIRED_AS_A_POW || ( pSoldier && pSoldier->bAssignment == ASSIGNMENT_POW ) )
|
||||
{
|
||||
ShadowVideoSurfaceRect( FRAME_BUFFER, usPosX+AIM_FI_FACE_OFFSET, usPosY+AIM_FI_FACE_OFFSET, usPosX + 48+AIM_FI_FACE_OFFSET, usPosY + 43+AIM_FI_FACE_OFFSET);
|
||||
DrawTextToScreen( pPOWStrings[0], (UINT16)(usPosX+AIM_FI_AWAY_TEXT_OFFSET_X), (UINT16)(usPosY+AIM_FI_AWAY_TEXT_OFFSET_Y), AIM_FI_AWAY_TEXT_OFFSET_WIDTH, FONT10ARIAL, 145, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
@@ -329,7 +460,8 @@ BOOLEAN DrawMercsFaceToScreen(UINT8 ubMercID, UINT16 usPosX, UINT16 usPosY, UINT
|
||||
}
|
||||
|
||||
//if the merc is away, shadow his/her face and blit 'away' over top
|
||||
else if( !IsMercHireable( AimMercArray[ubMercID] ) )
|
||||
//else if( !IsMercHireable( AimMercArray[ubMercID] ) )
|
||||
else if( !IsMercHireable( gAimAvailability[AimMercArray[ubMercID + START_MERC ]].ProfilId ) )
|
||||
{
|
||||
ShadowVideoSurfaceRect( FRAME_BUFFER, usPosX+AIM_FI_FACE_OFFSET, usPosY+AIM_FI_FACE_OFFSET, usPosX + 48+AIM_FI_FACE_OFFSET, usPosY + 43+AIM_FI_FACE_OFFSET);
|
||||
DrawTextToScreen( AimFiText[AIM_FI_DEAD+1], (UINT16)(usPosX+AIM_FI_AWAY_TEXT_OFFSET_X), (UINT16)(usPosY+AIM_FI_AWAY_TEXT_OFFSET_Y), AIM_FI_AWAY_TEXT_OFFSET_WIDTH, FONT10ARIAL, 145, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
|
||||
@@ -4,6 +4,11 @@
|
||||
#define AIM_FI_LEFT_CLICK_TEXT_X (SCREEN_WIDTH - 640) / 2 + 116
|
||||
#define AIM_FI_LEFT_CLICK_TEXT_Y (SCREEN_HEIGHT - 480) / 2 + 35 + LAPTOP_SCREEN_WEB_DELTA_Y
|
||||
|
||||
//tais: nsgi, left click text moved a bit to create space for small logo
|
||||
#define AIM_FI_LEFT_CLICK_TEXT_X_NSGI (SCREEN_WIDTH - 640) / 2 + 200
|
||||
#define AIM_FI_LEFT_CLICK_TEXT_Y_NSGI (SCREEN_HEIGHT - 480) / 2 + 35 + LAPTOP_SCREEN_WEB_DELTA_Y
|
||||
|
||||
|
||||
#define AIM_FI_CLICK_DESC_TEXT_Y_OFFSET 16
|
||||
|
||||
#define AIM_FI_RIGHT_CLICK_TEXT_X (SCREEN_WIDTH - 640) / 2 + 500
|
||||
@@ -22,6 +27,8 @@ BOOLEAN RenderAimFacialIndex();
|
||||
|
||||
BOOLEAN DisplayAimFIMugShot();
|
||||
|
||||
extern UINT8 START_MERC;
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
+85
-34
@@ -11,7 +11,7 @@
|
||||
#include "Text.h"
|
||||
#endif
|
||||
|
||||
|
||||
#include "LocalizedStrings.h"
|
||||
|
||||
// Defines
|
||||
|
||||
@@ -171,7 +171,6 @@ void HandleAimHistory()
|
||||
void RenderAimHistory()
|
||||
{
|
||||
CHAR16 sText[400];
|
||||
UINT32 uiStartLoc=0;
|
||||
UINT16 usPosY;
|
||||
|
||||
DrawAimDefaults();
|
||||
@@ -210,8 +209,15 @@ void RenderAimHistory()
|
||||
|
||||
// display coloniel Mohanned...
|
||||
usPosY = AIM_HISTORY_PARAGRAPH_Y + (GetFontHeight(AIM_HISTORY_TEXT_FONT) + 2)* 5 + LAPTOP_SCREEN_WEB_DELTA_Y;
|
||||
uiStartLoc = AIM_HISTORY_LINE_SIZE * COLONEL_MOHANNED;
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sText, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
if(!g_bUseXML_Strings)
|
||||
{
|
||||
UINT32 uiStartLoc = AIM_HISTORY_LINE_SIZE * COLONEL_MOHANNED;
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sText, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
}
|
||||
else
|
||||
{
|
||||
Loc::GetString(Loc::AIM_HISTORY, L"Line", COLONEL_MOHANNED, sText, 400);
|
||||
}
|
||||
DisplayWrappedString(AIM_HISTORY_PARAGRAPH_X, iScreenHeightOffset + 210+LAPTOP_SCREEN_WEB_DELTA_Y, AIM_HISTORY_PARAGRAPH_WIDTH, 2, AIM_HISTORY_TEXT_FONT, AIM_HISTORY_TEXT_COLOR, sText, FONT_MCOLOR_BLACK, FALSE, RIGHT_JUSTIFIED);
|
||||
break;
|
||||
|
||||
@@ -220,13 +226,27 @@ void RenderAimHistory()
|
||||
DisplayAimHistoryParagraph(INCORPORATION, 2);
|
||||
|
||||
// display dunn and bradbord...
|
||||
uiStartLoc = AIM_HISTORY_LINE_SIZE * DUNN_AND_BRADROAD;
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sText, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
if(!g_bUseXML_Strings)
|
||||
{
|
||||
UINT32 uiStartLoc = AIM_HISTORY_LINE_SIZE * DUNN_AND_BRADROAD;
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sText, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
}
|
||||
else
|
||||
{
|
||||
Loc::GetString(Loc::AIM_HISTORY, L"Line", DUNN_AND_BRADROAD, sText, 400);
|
||||
}
|
||||
DisplayWrappedString(AIM_HISTORY_PARAGRAPH_X, iScreenHeightOffset + 270+LAPTOP_SCREEN_WEB_DELTA_Y, AIM_HISTORY_PARAGRAPH_WIDTH, 2, AIM_HISTORY_TEXT_FONT, AIM_HISTORY_TEXT_COLOR, sText, FONT_MCOLOR_BLACK, FALSE, RIGHT_JUSTIFIED);
|
||||
|
||||
//AIM_HISTORY_PARAGRAPH_Y
|
||||
uiStartLoc = AIM_HISTORY_LINE_SIZE * INCORPORATION_3;
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sText, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
if(!g_bUseXML_Strings)
|
||||
{
|
||||
UINT32 uiStartLoc = AIM_HISTORY_LINE_SIZE * INCORPORATION_3;
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sText, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
}
|
||||
else
|
||||
{
|
||||
Loc::GetString(Loc::AIM_HISTORY, L"Line", INCORPORATION_3, sText, 400);
|
||||
}
|
||||
DisplayWrappedString(AIM_HISTORY_PARAGRAPH_X, iScreenHeightOffset + 290+LAPTOP_SCREEN_WEB_DELTA_Y, AIM_HISTORY_PARAGRAPH_WIDTH, 2, AIM_HISTORY_TEXT_FONT, AIM_HISTORY_TEXT_COLOR, sText, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED);
|
||||
break;
|
||||
}
|
||||
@@ -360,21 +380,34 @@ void SelectHistoryMenuButtonsRegionCallBack(MOUSE_REGION * pRegion, INT32 iReaso
|
||||
BOOLEAN DisplayAimHistoryParagraph(UINT8 ubPageNum, UINT8 ubNumParagraphs)
|
||||
{
|
||||
CHAR16 sText[400];
|
||||
UINT32 uiStartLoc=0;
|
||||
UINT16 usPosY=0;
|
||||
UINT16 usNumPixels=0;
|
||||
|
||||
//title
|
||||
uiStartLoc = AIM_HISTORY_LINE_SIZE * ubPageNum;
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sText, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
if(!g_bUseXML_Strings)
|
||||
{
|
||||
UINT32 uiStartLoc = AIM_HISTORY_LINE_SIZE * ubPageNum;
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sText, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
}
|
||||
else
|
||||
{
|
||||
Loc::GetString(Loc::AIM_HISTORY, L"Line", ubPageNum, sText, 400);
|
||||
}
|
||||
DrawTextToScreen(sText, AIM_HISTORY_PARAGRAPH_X, AIM_HISTORY_SUBTITLE_Y, 0, AIM_HISTORY_PARAGRAPH_TITLE_FONT, AIM_HISTORY_PARAGRAPH_TITLE_COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED);
|
||||
|
||||
if(ubNumParagraphs >= 1)
|
||||
{
|
||||
usPosY = AIM_HISTORY_PARAGRAPH_Y;
|
||||
//1st paragraph
|
||||
uiStartLoc = AIM_HISTORY_LINE_SIZE * (ubPageNum + 1 );
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sText, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
if(!g_bUseXML_Strings)
|
||||
{
|
||||
UINT32 uiStartLoc = AIM_HISTORY_LINE_SIZE * (ubPageNum + 1 );
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sText, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
}
|
||||
else
|
||||
{
|
||||
Loc::GetString(Loc::AIM_HISTORY, L"Line", ubPageNum+1, sText, 400);
|
||||
}
|
||||
usNumPixels = DisplayWrappedString(AIM_HISTORY_PARAGRAPH_X, usPosY, AIM_HISTORY_PARAGRAPH_WIDTH, 2, AIM_HISTORY_TEXT_FONT, AIM_HISTORY_TEXT_COLOR, sText, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED);
|
||||
}
|
||||
|
||||
@@ -382,8 +415,15 @@ BOOLEAN DisplayAimHistoryParagraph(UINT8 ubPageNum, UINT8 ubNumParagraphs)
|
||||
{
|
||||
//2nd paragraph
|
||||
usPosY += usNumPixels + AIM_HISTORY_SPACE_BETWEEN_PARAGRAPHS;
|
||||
uiStartLoc = AIM_HISTORY_LINE_SIZE * (ubPageNum + 2 );
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sText, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
if(!g_bUseXML_Strings)
|
||||
{
|
||||
UINT32 uiStartLoc = AIM_HISTORY_LINE_SIZE * (ubPageNum + 2 );
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sText, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
}
|
||||
else
|
||||
{
|
||||
Loc::GetString(Loc::AIM_HISTORY, L"Line", ubPageNum+2, sText, 400);
|
||||
}
|
||||
DisplayWrappedString(AIM_HISTORY_PARAGRAPH_X, usPosY, AIM_HISTORY_PARAGRAPH_WIDTH, 2, AIM_HISTORY_TEXT_FONT, AIM_HISTORY_TEXT_COLOR, sText, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED);
|
||||
}
|
||||
|
||||
@@ -391,9 +431,15 @@ BOOLEAN DisplayAimHistoryParagraph(UINT8 ubPageNum, UINT8 ubNumParagraphs)
|
||||
{
|
||||
//3rd paragraph
|
||||
usPosY += usNumPixels + AIM_HISTORY_SPACE_BETWEEN_PARAGRAPHS;
|
||||
|
||||
uiStartLoc = AIM_HISTORY_LINE_SIZE * (ubPageNum + 3 );
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sText, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
if(!g_bUseXML_Strings)
|
||||
{
|
||||
UINT32 uiStartLoc = AIM_HISTORY_LINE_SIZE * (ubPageNum + 3 );
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sText, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
}
|
||||
else
|
||||
{
|
||||
Loc::GetString(Loc::AIM_HISTORY, L"Line", ubPageNum+3, sText, 400);
|
||||
}
|
||||
DisplayWrappedString(AIM_HISTORY_PARAGRAPH_X, usPosY, AIM_HISTORY_PARAGRAPH_WIDTH, 2, AIM_HISTORY_TEXT_FONT, AIM_HISTORY_TEXT_COLOR, sText, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED);
|
||||
}
|
||||
|
||||
@@ -404,19 +450,18 @@ BOOLEAN DisplayAimHistoryParagraph(UINT8 ubPageNum, UINT8 ubNumParagraphs)
|
||||
|
||||
BOOLEAN InitTocMenu()
|
||||
{
|
||||
UINT16 i, usPosY;
|
||||
UINT16 usHeight;
|
||||
UINT16 usWidth=0;
|
||||
UINT32 uiStartLoc=0;
|
||||
CHAR16 sText[400];
|
||||
UINT8 ubLocInFile[]=
|
||||
{IN_THE_BEGINNING,
|
||||
THE_ISLAND_METAVIRA,
|
||||
GUS_TARBALLS,
|
||||
WORD_FROM_FOUNDER,
|
||||
INCORPORATION};
|
||||
UINT16 i, usPosY;
|
||||
UINT16 usHeight;
|
||||
UINT16 usWidth=0;
|
||||
CHAR16 sText[400];
|
||||
UINT8 ubLocInFile[] = {
|
||||
IN_THE_BEGINNING,
|
||||
THE_ISLAND_METAVIRA,
|
||||
GUS_TARBALLS,
|
||||
WORD_FROM_FOUNDER,
|
||||
INCORPORATION};
|
||||
|
||||
HVOBJECT hContentButtonHandle;
|
||||
HVOBJECT hContentButtonHandle;
|
||||
|
||||
GetVideoObject(&hContentButtonHandle, guiContentButton);
|
||||
|
||||
@@ -424,9 +469,15 @@ BOOLEAN InitTocMenu()
|
||||
usPosY = AIM_HISTORY_CONTENTBUTTON_Y;
|
||||
for(i=0; i<NUM_AIM_HISTORY_PAGES; i++)
|
||||
{
|
||||
uiStartLoc = AIM_HISTORY_LINE_SIZE * ubLocInFile[i];
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sText, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
|
||||
if(!g_bUseXML_Strings)
|
||||
{
|
||||
UINT32 uiStartLoc = AIM_HISTORY_LINE_SIZE * ubLocInFile[i];
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sText, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
}
|
||||
else
|
||||
{
|
||||
Loc::GetString(Loc::AIM_HISTORY, L"Line", ubLocInFile[i], sText, 400);
|
||||
}
|
||||
usWidth = StringPixLength(sText, AIM_HISTORY_TOC_TEXT_FONT);
|
||||
|
||||
//if the mouse regions havent been inited, init them
|
||||
@@ -439,7 +490,7 @@ BOOLEAN InitTocMenu()
|
||||
MSYS_SetRegionUserData( &gSelectedHistoryTocMenuRegion[i], 0, i+1);
|
||||
}
|
||||
|
||||
BltVideoObject(FRAME_BUFFER, hContentButtonHandle, 0,AIM_HISTORY_TOC_X, usPosY, VO_BLT_SRCTRANSPARENCY,NULL);
|
||||
BltVideoObject(FRAME_BUFFER, hContentButtonHandle, 0,AIM_HISTORY_TOC_X, usPosY, VO_BLT_SRCTRANSPARENCY,NULL);
|
||||
DrawTextToScreen(sText, AIM_HISTORY_TOC_X, (UINT16)(usPosY + AIM_HISTORY_TOC_Y), AIM_CONTENTBUTTON_WIDTH, AIM_HISTORY_TOC_TEXT_FONT, AIM_HISTORY_TOC_TEXT_COLOR, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED);
|
||||
|
||||
|
||||
|
||||
+1307
-330
File diff suppressed because it is too large
Load Diff
+87
-43
@@ -9,8 +9,11 @@
|
||||
#include "WordWrap.h"
|
||||
#include "Encrypted File.h"
|
||||
#include "Text.h"
|
||||
#include "GameSettings.h"
|
||||
#endif
|
||||
|
||||
#include "LocalizedStrings.h"
|
||||
|
||||
#define NUM_AIM_POLICY_PAGES 11
|
||||
#define NUM_AIM_POLICY_TOC_BUTTONS 9
|
||||
#define AIMPOLICYFILE "BINARYDATA\\AimPol.edt"
|
||||
@@ -38,6 +41,9 @@
|
||||
#define AIM_POLICY_TITLE_Y AIM_SYMBOL_Y + AIM_SYMBOL_SIZE_Y + 11
|
||||
#define AIM_POLICY_TITLE_WIDTH AIM_SYMBOL_WIDTH
|
||||
|
||||
//tais: nsgi, move title up
|
||||
#define AIM_POLICY_TITLE_Y_NSGI AIM_SYMBOL_Y + 35
|
||||
|
||||
#define AIM_POLICY_TITLE_STATEMENT_WIDTH 300
|
||||
#define AIM_POLICY_TITLE_STATEMENT_X IMAGE_OFFSET_X + (500 - AIM_POLICY_TITLE_STATEMENT_WIDTH) / 2 +5//80
|
||||
#define AIM_POLICY_TITLE_STATEMENT_Y AIM_SYMBOL_Y + AIM_SYMBOL_SIZE_Y + 75
|
||||
@@ -456,21 +462,20 @@ BOOLEAN ExitAimPolicyMenuBar(void)
|
||||
|
||||
BOOLEAN DrawAimPolicyMenu()
|
||||
{
|
||||
UINT16 i, usPosY;
|
||||
UINT16 usHeight;
|
||||
UINT32 uiStartLoc=0;
|
||||
CHAR16 sText[400];
|
||||
HVOBJECT hContentButtonHandle;
|
||||
UINT8 ubLocInFile[]=
|
||||
{ DEFINITIONS,
|
||||
LENGTH_OF_ENGAGEMENT,
|
||||
LOCATION_0F_ENGAGEMENT,
|
||||
CONTRACT_EXTENSIONS,
|
||||
TERMS_OF_PAYMENT,
|
||||
TERMS_OF_ENGAGEMENT,
|
||||
ENGAGEMENT_TERMINATION,
|
||||
EQUIPMENT_AND_INVENTORY,
|
||||
POLICY_MEDICAL};
|
||||
UINT16 i, usPosY;
|
||||
UINT16 usHeight;
|
||||
CHAR16 sText[400];
|
||||
HVOBJECT hContentButtonHandle;
|
||||
UINT8 ubLocInFile[]= {
|
||||
DEFINITIONS,
|
||||
LENGTH_OF_ENGAGEMENT,
|
||||
LOCATION_0F_ENGAGEMENT,
|
||||
CONTRACT_EXTENSIONS,
|
||||
TERMS_OF_PAYMENT,
|
||||
TERMS_OF_ENGAGEMENT,
|
||||
ENGAGEMENT_TERMINATION,
|
||||
EQUIPMENT_AND_INVENTORY,
|
||||
POLICY_MEDICAL};
|
||||
|
||||
GetVideoObject(&hContentButtonHandle, guiContentButton);
|
||||
|
||||
@@ -478,10 +483,16 @@ BOOLEAN DrawAimPolicyMenu()
|
||||
usPosY = AIM_POLICY_TOC_Y;
|
||||
for(i=0; i<NUM_AIM_POLICY_TOC_BUTTONS; i++)
|
||||
{
|
||||
BltVideoObject(FRAME_BUFFER, hContentButtonHandle, 0,AIM_POLICY_TOC_X, usPosY, VO_BLT_SRCTRANSPARENCY,NULL);
|
||||
|
||||
uiStartLoc = AIM_POLICY_LINE_SIZE * ubLocInFile[i];
|
||||
LoadEncryptedDataFromFile(AIMPOLICYFILE, sText, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
BltVideoObject(FRAME_BUFFER, hContentButtonHandle, 0,AIM_POLICY_TOC_X, usPosY, VO_BLT_SRCTRANSPARENCY,NULL);
|
||||
if(!g_bUseXML_Strings)
|
||||
{
|
||||
UINT32 uiStartLoc = AIM_POLICY_LINE_SIZE * ubLocInFile[i];
|
||||
LoadEncryptedDataFromFile(AIMPOLICYFILE, sText, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
}
|
||||
else
|
||||
{
|
||||
Loc::GetString(Loc::AIM_POLICY, L"Line", ubLocInFile[i], sText, 400);
|
||||
}
|
||||
DrawTextToScreen(sText, AIM_POLICY_TOC_X + AIM_POLICY_TOC_TEXT_OFFSET_X, (UINT16)(usPosY + AIM_POLICY_TOC_TEXT_OFFSET_Y), AIM_CONTENTBUTTON_WIDTH, AIM_POLICY_TOC_FONT, AIM_POLICY_TOC_COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED);
|
||||
|
||||
usPosY += AIM_POLICY_TOC_GAP_Y;
|
||||
@@ -557,17 +568,23 @@ void SelectPolicyTocMenuRegionCallBack(MOUSE_REGION * pRegion, INT32 iReason )
|
||||
BOOLEAN DisplayAimPolicyTitleText(void)
|
||||
{
|
||||
CHAR16 sText[400];
|
||||
UINT32 uiStartLoc = 0;
|
||||
|
||||
//Load anfd display title
|
||||
uiStartLoc = AIM_POLICY_LINE_SIZE * AIM_STATEMENT_OF_POLICY;
|
||||
LoadEncryptedDataFromFile(AIMPOLICYFILE, sText, uiStartLoc, AIM_POLICY_LINE_SIZE);
|
||||
|
||||
if(!g_bUseXML_Strings)
|
||||
{
|
||||
UINT32 uiStartLoc = AIM_POLICY_LINE_SIZE * AIM_STATEMENT_OF_POLICY;
|
||||
LoadEncryptedDataFromFile(AIMPOLICYFILE, sText, uiStartLoc, AIM_POLICY_LINE_SIZE);
|
||||
}
|
||||
else
|
||||
{
|
||||
Loc::GetString(Loc::AIM_POLICY, L"Line", AIM_STATEMENT_OF_POLICY);
|
||||
}
|
||||
if(gubCurPageNum == 0)
|
||||
DrawTextToScreen(sText, AIM_POLICY_TITLE_X, AIM_POLICY_TITLE_STATEMENT_Y-25, AIM_POLICY_TITLE_WIDTH, AIM_POLICY_TITLE_FONT, AIM_POLICY_TITLE_COLOR, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED);
|
||||
else
|
||||
DrawTextToScreen(sText, AIM_POLICY_TITLE_X, AIM_POLICY_TITLE_Y, AIM_POLICY_TITLE_WIDTH, AIM_POLICY_TITLE_FONT, AIM_POLICY_TITLE_COLOR, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED);
|
||||
|
||||
if(gGameExternalOptions.gfUseNewStartingGearInterface) DrawTextToScreen(sText, AIM_POLICY_TITLE_X, AIM_POLICY_TITLE_Y_NSGI, AIM_POLICY_TITLE_WIDTH, AIM_POLICY_TITLE_FONT, AIM_POLICY_TITLE_COLOR, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED);
|
||||
else DrawTextToScreen(sText, AIM_POLICY_TITLE_X, AIM_POLICY_TITLE_Y, AIM_POLICY_TITLE_WIDTH, AIM_POLICY_TITLE_FONT, AIM_POLICY_TITLE_COLOR, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED);
|
||||
|
||||
return(TRUE);
|
||||
}
|
||||
|
||||
@@ -575,17 +592,30 @@ BOOLEAN DisplayAimPolicyTitleText(void)
|
||||
BOOLEAN DisplayAimPolicyStatement(void)
|
||||
{
|
||||
CHAR16 sText[400];
|
||||
UINT32 uiStartLoc = 0;
|
||||
UINT16 usNumPixels;
|
||||
|
||||
//load and display the statment of policies
|
||||
uiStartLoc = AIM_POLICY_LINE_SIZE * AIM_STATEMENT_OF_POLICY_1;
|
||||
LoadEncryptedDataFromFile(AIMPOLICYFILE, sText, uiStartLoc, AIM_POLICY_LINE_SIZE);
|
||||
if(!g_bUseXML_Strings)
|
||||
{
|
||||
UINT32 uiStartLoc = AIM_POLICY_LINE_SIZE * AIM_STATEMENT_OF_POLICY_1;
|
||||
LoadEncryptedDataFromFile(AIMPOLICYFILE, sText, uiStartLoc, AIM_POLICY_LINE_SIZE);
|
||||
}
|
||||
else
|
||||
{
|
||||
Loc::GetString(Loc::AIM_POLICY, L"Line", AIM_STATEMENT_OF_POLICY_1, sText, 400);
|
||||
}
|
||||
usNumPixels = DisplayWrappedString(AIM_POLICY_TITLE_STATEMENT_X, AIM_POLICY_TITLE_STATEMENT_Y, AIM_POLICY_TITLE_STATEMENT_WIDTH, 2, AIM_POLICY_TEXT_FONT, AIM_POLICY_TEXT_COLOR, sText, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED);
|
||||
|
||||
//load and display the statment of policies
|
||||
uiStartLoc = AIM_POLICY_LINE_SIZE * AIM_STATEMENT_OF_POLICY_2;
|
||||
LoadEncryptedDataFromFile(AIMPOLICYFILE, sText, uiStartLoc, AIM_POLICY_LINE_SIZE);
|
||||
if(!g_bUseXML_Strings)
|
||||
{
|
||||
UINT32 uiStartLoc = AIM_POLICY_LINE_SIZE * AIM_STATEMENT_OF_POLICY_2;
|
||||
LoadEncryptedDataFromFile(AIMPOLICYFILE, sText, uiStartLoc, AIM_POLICY_LINE_SIZE);
|
||||
}
|
||||
else
|
||||
{
|
||||
Loc::GetString(Loc::AIM_POLICY, L"Line", AIM_STATEMENT_OF_POLICY_2, sText, 400);
|
||||
}
|
||||
DisplayWrappedString(AIM_POLICY_TITLE_STATEMENT_X, (UINT16)(AIM_POLICY_TITLE_STATEMENT_Y + usNumPixels+15), AIM_POLICY_TITLE_STATEMENT_WIDTH, 2, AIM_POLICY_TEXT_FONT, AIM_POLICY_TEXT_COLOR, sText, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED);
|
||||
|
||||
return(TRUE);
|
||||
@@ -650,11 +680,17 @@ BOOLEAN ExitAgreementButton(void)
|
||||
BOOLEAN DisplayAimPolicyTitle(UINT16 usPosY, UINT8 ubPageNum, FLOAT fNumber)
|
||||
{
|
||||
CHAR16 sText[400];
|
||||
UINT32 uiStartLoc = 0;
|
||||
|
||||
//Load and display title
|
||||
uiStartLoc = AIM_POLICY_LINE_SIZE * ubPageNum;
|
||||
LoadEncryptedDataFromFile(AIMPOLICYFILE, sText, uiStartLoc, AIM_POLICY_LINE_SIZE);
|
||||
if(!g_bUseXML_Strings)
|
||||
{
|
||||
UINT32 uiStartLoc = AIM_POLICY_LINE_SIZE * ubPageNum;
|
||||
LoadEncryptedDataFromFile(AIMPOLICYFILE, sText, uiStartLoc, AIM_POLICY_LINE_SIZE);
|
||||
}
|
||||
else
|
||||
{
|
||||
Loc::GetString(Loc::AIM_POLICY,L"Line", ubPageNum, sText, 400);
|
||||
}
|
||||
DrawTextToScreen(sText, AIM_POLICY_SUBTITLE_NUMBER, usPosY, 0, AIM_POLICY_SUBTITLE_FONT, AIM_POLICY_SUBTITLE_COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED);
|
||||
|
||||
return(TRUE);
|
||||
@@ -665,12 +701,16 @@ UINT16 DisplayAimPolicyParagraph(UINT16 usPosY, UINT8 ubPageNum, FLOAT fNumber)
|
||||
{
|
||||
CHAR16 sText[400];
|
||||
CHAR16 sTemp[20];
|
||||
UINT32 uiStartLoc=0;
|
||||
UINT16 usNumPixels;
|
||||
|
||||
uiStartLoc = AIM_POLICY_LINE_SIZE * ubPageNum;
|
||||
LoadEncryptedDataFromFile(AIMPOLICYFILE, sText, uiStartLoc, AIM_POLICY_LINE_SIZE);
|
||||
|
||||
if(!g_bUseXML_Strings)
|
||||
{
|
||||
UINT32 uiStartLoc = AIM_POLICY_LINE_SIZE * ubPageNum;
|
||||
LoadEncryptedDataFromFile(AIMPOLICYFILE, sText, uiStartLoc, AIM_POLICY_LINE_SIZE);
|
||||
}
|
||||
else
|
||||
{
|
||||
Loc::GetString(Loc::AIM_POLICY, L"Line", ubPageNum, sText, 400);
|
||||
}
|
||||
if(fNumber != 0.0)
|
||||
{
|
||||
//Display the section number
|
||||
@@ -688,12 +728,16 @@ UINT16 DisplayAimPolicySubParagraph(UINT16 usPosY, UINT8 ubPageNum, FLOAT fNumbe
|
||||
{
|
||||
CHAR16 sText[400];
|
||||
CHAR16 sTemp[20];
|
||||
UINT32 uiStartLoc=0;
|
||||
UINT16 usNumPixels;
|
||||
|
||||
uiStartLoc = AIM_POLICY_LINE_SIZE * ubPageNum;
|
||||
LoadEncryptedDataFromFile(AIMPOLICYFILE, sText, uiStartLoc, AIM_POLICY_LINE_SIZE);
|
||||
|
||||
if(!g_bUseXML_Strings)
|
||||
{
|
||||
UINT32 uiStartLoc = AIM_POLICY_LINE_SIZE * ubPageNum;
|
||||
LoadEncryptedDataFromFile(AIMPOLICYFILE, sText, uiStartLoc, AIM_POLICY_LINE_SIZE);
|
||||
}
|
||||
else
|
||||
{
|
||||
Loc::GetString(Loc::AIM_POLICY, L"Line", ubPageNum, sText, 400);
|
||||
}
|
||||
//Display the section number
|
||||
swprintf(sTemp, L"%2.2f", fNumber);
|
||||
DrawTextToScreen(sTemp, AIM_POLICY_SUBPARAGRAPH_NUMBER, usPosY, 0, AIM_POLICY_TEXT_FONT, AIM_POLICY_TEXT_COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED);
|
||||
|
||||
@@ -174,7 +174,6 @@ BOOLEAN EnterAimSort()
|
||||
VOBJECT_DESC VObjectDesc;
|
||||
UINT8 ubCurNumber=0;
|
||||
UINT16 ubWidth;
|
||||
UINT8 i;
|
||||
|
||||
AimSortCheckBoxLoc[0] = AIM_SORT_SORT_BY_X + 9;
|
||||
AimSortCheckBoxLoc[1] = AIM_SORT_SORT_BY_Y + 34;
|
||||
@@ -193,11 +192,6 @@ BOOLEAN EnterAimSort()
|
||||
AimSortCheckBoxLoc[14] = AIM_SORT_SORT_BY_X + 172;
|
||||
AimSortCheckBoxLoc[15] = AIM_SORT_SORT_BY_Y + 17;
|
||||
|
||||
//Everytime into Aim Sort, reset array.
|
||||
for(i=0; i<MAX_NUMBER_MERCS; i++)
|
||||
{
|
||||
AimMercArray[i] = i;
|
||||
}
|
||||
|
||||
InitAimDefaults();
|
||||
|
||||
|
||||
+136
-32
@@ -21,6 +21,8 @@
|
||||
#include "GameSettings.h"
|
||||
#include "Points.h"
|
||||
#include "Multi Language Graphic Utils.h"
|
||||
// HEADROCK HAM 4
|
||||
#include "input.h"
|
||||
#endif
|
||||
|
||||
|
||||
@@ -308,10 +310,12 @@ UINT16 DisplayLBEInfo(UINT16 usPosY, UINT16 usIndex, UINT16 usFontHeight);
|
||||
UINT16 DisplayWeight(UINT16 usPosY, UINT16 usIndex, UINT16 usFontHeight);
|
||||
UINT16 DisplayCaliber(UINT16 usPosY, UINT16 usIndex, UINT16 usFontHeight);
|
||||
void CreateMouseRegionForBigImage(UINT16 usPosY, UINT8 ubCount, INT16 *pItemNumbers );
|
||||
void PurchaseBobbyRayItem(UINT16 usItemNumber);
|
||||
// HEADROCK HAM 4: Now can purchase ALL items available.
|
||||
void PurchaseBobbyRayItem(UINT16 usItemNumber, BOOLEAN fAllItems );
|
||||
UINT8 CheckIfItemIsPurchased(UINT16 usItemNumber);
|
||||
UINT8 GetNextPurchaseNumber();
|
||||
void UnPurchaseBobbyRayItem(UINT16 usItemNumber);
|
||||
// HEADROCK HAM 4: Now can purchase ALL items available.
|
||||
void UnPurchaseBobbyRayItem(UINT16 usItemNumber, BOOLEAN fAllItems );
|
||||
UINT32 CalculateTotalPurchasePrice();
|
||||
void DisableBobbyRButtons();
|
||||
void CalcFirstIndexForPage( STORE_INVENTORY *pInv, UINT32 uiItemClass );
|
||||
@@ -1285,17 +1289,40 @@ void BtnBobbyRNextPreviousPageCallback(GUI_BUTTON *btn,INT32 reason)
|
||||
InvalidateRegion(btn->Area.RegionTopLeftX, btn->Area.RegionTopLeftY, btn->Area.RegionBottomRightX, btn->Area.RegionBottomRightY);
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
// HEADROCK HAM 4: Added ability to scroll forward 5 pages instead of one.
|
||||
// This is done by holding down SHIFT while clicking.
|
||||
//
|
||||
|
||||
//if previous screen
|
||||
if( bNewValue == BOBBYR_PREVIOUS_PAGE)
|
||||
{
|
||||
if( gubCurPage > 0 )
|
||||
gubCurPage--;
|
||||
{
|
||||
if (_KeyDown( 16 ) ) // SHIFT
|
||||
{
|
||||
gubCurPage = __max(gubCurPage - 5, 0);
|
||||
}
|
||||
else
|
||||
{
|
||||
gubCurPage--;
|
||||
}
|
||||
}
|
||||
}
|
||||
//else next screen
|
||||
else
|
||||
{
|
||||
if( gubCurPage < gubNumPages-1 )
|
||||
gubCurPage++;
|
||||
{
|
||||
if (_KeyDown( 16 ) ) // SHIFT
|
||||
{
|
||||
gubCurPage = __min(gubNumPages, gubCurPage+5);
|
||||
}
|
||||
else
|
||||
{
|
||||
gubCurPage++;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1736,10 +1763,11 @@ BOOLEAN DisplayAmmoInfo(UINT16 usIndex, UINT16 usTextPosY, BOOLEAN fUsed, UINT16
|
||||
|
||||
BOOLEAN DisplayBigItemImage(UINT16 usIndex, UINT16 PosY)
|
||||
{
|
||||
INT16 PosX, sCenX, sCenY;
|
||||
UINT32 usHeight, usWidth;
|
||||
INT16 PosX, sCenX, sCenY;
|
||||
UINT32 usHeight, usWidth;
|
||||
INT32 sOffsetX, sOffsetY;
|
||||
ETRLEObject *pTrav;
|
||||
INVTYPE *pItem;
|
||||
INVTYPE *pItem;
|
||||
UINT32 uiImage;
|
||||
HVOBJECT hPixHandle;
|
||||
|
||||
@@ -1749,20 +1777,43 @@ BOOLEAN DisplayBigItemImage(UINT16 usIndex, UINT16 PosY)
|
||||
LoadTileGraphicForItem(pItem, &uiImage);
|
||||
|
||||
GetVideoObject(&hPixHandle, uiImage);
|
||||
pTrav = &(hPixHandle->pETRLEObject[0]);
|
||||
|
||||
//center picture in frame
|
||||
usHeight = (UINT32)pTrav->usHeight;
|
||||
usWidth = (UINT32)pTrav->usWidth;
|
||||
if(hPixHandle->ubBitDepth == 8)
|
||||
{
|
||||
pTrav = &(hPixHandle->pETRLEObject[ 0 ] );
|
||||
|
||||
//center picture in frame
|
||||
usHeight = (UINT32)pTrav->usHeight;
|
||||
usWidth = (UINT32)pTrav->usWidth;
|
||||
sOffsetX = (INT32)pTrav->sOffsetX;
|
||||
sOffsetY = (INT32)pTrav->sOffsetY;
|
||||
}
|
||||
else if(hPixHandle->ubBitDepth == 16 && hPixHandle->p16BPPObject)
|
||||
{
|
||||
usHeight = hPixHandle->p16BPPObject->usHeight;
|
||||
usWidth = hPixHandle->p16BPPObject->usWidth;
|
||||
sOffsetX = hPixHandle->p16BPPObject->sOffsetX;
|
||||
sOffsetY = hPixHandle->p16BPPObject->sOffsetY;
|
||||
}
|
||||
else if(hPixHandle->ubBitDepth == 32)
|
||||
{
|
||||
usHeight = hPixHandle->p16BPPObject->usHeight;
|
||||
usWidth = hPixHandle->p16BPPObject->usWidth;
|
||||
sOffsetX = hPixHandle->p16BPPObject->sOffsetX;
|
||||
sOffsetY = hPixHandle->p16BPPObject->sOffsetY;
|
||||
}
|
||||
|
||||
// sCenX = PosX + ( abs( BOBBYR_GRID_PIC_WIDTH - usWidth ) / 2 );
|
||||
// sCenY = PosY + 8;
|
||||
sCenX = PosX + ( abs( BOBBYR_GRID_PIC_WIDTH - usWidth ) / 2 ) - pTrav->sOffsetX;
|
||||
sCenX = PosX + ( abs( BOBBYR_GRID_PIC_WIDTH - (int)usWidth ) / 2 ) - sOffsetX;
|
||||
sCenY = PosY + 8;
|
||||
|
||||
|
||||
//blt the shadow of the item
|
||||
if(gGameSettings.fOptions[ TOPTION_SHOW_ITEM_SHADOW ]) BltVideoObjectOutlineShadowFromIndex( FRAME_BUFFER, uiImage, 0, sCenX-2, sCenY+2);//pItem->ubGraphicNum
|
||||
|
||||
if(gGameSettings.fOptions[ TOPTION_SHOW_ITEM_SHADOW ])
|
||||
{
|
||||
BltVideoObjectOutlineShadowFromIndex( FRAME_BUFFER, uiImage, 0, sCenX-2, sCenY+2);//pItem->ubGraphicNum
|
||||
}
|
||||
BltVideoObject(FRAME_BUFFER, hPixHandle, 0, sCenX, sCenY, VO_BLT_SRCTRANSPARENCY,NULL);
|
||||
DeleteVideoObjectFromIndex(uiImage);
|
||||
|
||||
@@ -1923,9 +1974,13 @@ UINT16 DisplayDamage(UINT16 usPosY, UINT16 usIndex, UINT16 usFontHeight)
|
||||
UINT16 DisplayRange(UINT16 usPosY, UINT16 usIndex, UINT16 usFontHeight)
|
||||
{
|
||||
CHAR16 sTemp[20];
|
||||
UINT16 gunRange = 0;
|
||||
|
||||
DrawTextToScreen(BobbyRText[BOBBYR_GUNS_RANGE], BOBBYR_ITEM_WEIGHT_TEXT_X, (UINT16)usPosY, 0, BOBBYR_ITEM_DESC_TEXT_FONT, BOBBYR_STATIC_TEXT_COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED);
|
||||
swprintf(sTemp, L"%3d %s", Weapon[ usIndex ].usRange, pMessageStrings[ MSG_METER_ABBREVIATION ] );
|
||||
|
||||
gunRange = (UINT16)GetModifiedGunRange( usIndex);
|
||||
|
||||
swprintf(sTemp, L"%3d %s", gunRange, pMessageStrings[ MSG_METER_ABBREVIATION ] );
|
||||
DrawTextToScreen(sTemp, BOBBYR_ITEM_WEIGHT_NUM_X, (UINT16)usPosY, BOBBYR_ITEM_WEIGHT_NUM_WIDTH, BOBBYR_ITEM_DESC_TEXT_FONT, BOBBYR_ITEM_DESC_TEXT_COLOR, FONT_MCOLOR_BLACK, FALSE, RIGHT_JUSTIFIED);
|
||||
usPosY += usFontHeight + 2;
|
||||
return(usPosY);
|
||||
@@ -2417,6 +2472,7 @@ void CreateMouseRegionForBigImage( UINT16 usPosY, UINT8 ubCount, INT16 *pItemNum
|
||||
//UINT16 gunDamage = (UINT16)( Weapon[ pItemNumbers[ i ] ].ubImpact + ( (double) Weapon[ pItemNumbers[ i ] ].ubImpact / 100) * gGameExternalOptions.ubGunDamageMultiplier );
|
||||
UINT16 gunDamage = (UINT16)GetModifiedGunDamage( Weapon[ pItemNumbers[ i ] ].ubImpact );
|
||||
UINT16 readyAPs = (UINT16)(( Weapon[ pItemNumbers[ i ] ].ubReadyTime * (100 - Item[ pItemNumbers[ i ] ].percentreadytimeapreduction)) / 100);
|
||||
UINT16 gunRange = (UINT16)GetModifiedGunRange(pItemNumbers[ i ]);
|
||||
|
||||
//Calculate AP's
|
||||
CHAR16 apStr[20];
|
||||
@@ -2504,18 +2560,48 @@ void CreateMouseRegionForBigImage( UINT16 usPosY, UINT8 ubCount, INT16 *pItemNum
|
||||
wcscat( attachStr, attachStr3 );
|
||||
}
|
||||
}
|
||||
|
||||
//Sum up default attachments.
|
||||
BOOLEAN fFoundDefault = FALSE;
|
||||
swprintf( attachStr2, L"" );
|
||||
swprintf( attachStr3, L"" );
|
||||
for(UINT8 cnt = 0; cnt < MAX_DEFAULT_ATTACHMENTS; cnt++){
|
||||
if(Item[pItemNumbers[ i ]].defaultattachments[cnt] != 0){
|
||||
if (wcslen( attachStr ) + wcslen(attachStr3) + wcslen(Item[ Item[pItemNumbers[ i ]].defaultattachments[cnt] ].szItemName) > 3800)
|
||||
{
|
||||
// End list early to avoid stack overflow
|
||||
wcscat( attachStr3, L"\n..." );
|
||||
break;
|
||||
}
|
||||
fFoundDefault = TRUE;
|
||||
swprintf( attachStr2, L"\n%s", Item[ Item[pItemNumbers[ i ]].defaultattachments[cnt] ].szItemName );
|
||||
wcscat( attachStr3, attachStr2 );
|
||||
} else {
|
||||
//If we found an empty entry, we can assume the rest will be empty too.
|
||||
break;
|
||||
}
|
||||
}
|
||||
if(fFoundDefault){
|
||||
//Found at least one default attachment, write it to the attachment string.
|
||||
CHAR16 defaultStr[50];
|
||||
swprintf( defaultStr, L"\n \n%s", gWeaponStatsDesc[ 17 ] );
|
||||
wcscat( attachStr, defaultStr );
|
||||
wcscat( attachStr, attachStr3 );
|
||||
}
|
||||
|
||||
// HEADROCK HAM 3: Added last string (attachStr), for display of the possible attachment list.
|
||||
// If the feature is deactivated, the attachStr will simply be empty at this point
|
||||
// (remember? we emptied it earlier!).
|
||||
INT8 accuracy = (UsingNewCTHSystem()==true?Weapon[ pItemNumbers[ i ] ].nAccuracy:Weapon[ pItemNumbers[ i ] ].bAccuracy);
|
||||
swprintf( pStr, L"%s (%s)\n%s %d\n%s %d\n%s %d\n%s (%d) %s\n%s %1.1f %s%s",
|
||||
ItemNames[ pItemNumbers[ i ] ],
|
||||
AmmoCaliber[ Weapon[ pItemNumbers[ i ] ].ubCalibre ],
|
||||
gWeaponStatsDesc[ 9 ], //Accuracy String
|
||||
Weapon[ pItemNumbers[ i ] ].bAccuracy, //Accuracy
|
||||
accuracy, //Accuracy
|
||||
gWeaponStatsDesc[ 11 ], //Damage String
|
||||
gunDamage, //Gun damage
|
||||
gWeaponStatsDesc[ 10 ], //Range String
|
||||
gGameSettings.fOptions[ TOPTION_SHOW_WEAPON_RANGE_IN_TILES ] ? Weapon[ pItemNumbers[ i ] ].usRange/10 : Weapon[ pItemNumbers[ i ] ].usRange, //Gun Range
|
||||
gGameSettings.fOptions[ TOPTION_SHOW_WEAPON_RANGE_IN_TILES ] ? gunRange/10 : gunRange, //Gun Range
|
||||
gWeaponStatsDesc[ 6 ], //AP String
|
||||
readyAPs,
|
||||
apStr, //AP's
|
||||
@@ -2571,16 +2657,18 @@ void CreateMouseRegionForBigImage( UINT16 usPosY, UINT8 ubCount, INT16 *pItemNum
|
||||
{
|
||||
// HEADROCK HAM 3.6: Can now take a negative modifier.
|
||||
UINT16 gunDamage = (UINT16)GetModifiedGunDamage( Weapon[ pItemNumbers[ i ] ].ubImpact );
|
||||
UINT16 usRange = (UINT16)GetModifiedGunRange(pItemNumbers[ i ]);
|
||||
INT8 accuracy = (UsingNewCTHSystem()==true?Weapon[ pItemNumbers[ i ] ].nAccuracy:Weapon[ pItemNumbers[ i ] ].bAccuracy);
|
||||
//UINT16 gunDamage = (UINT16)( Weapon[ pItemNumbers[ i ] ].ubImpact + ( (double) Weapon[ pItemNumbers[ i ] ].ubImpact / 100) * gGameExternalOptions.ubGunDamageMultiplier );
|
||||
|
||||
swprintf( pStr, L"%s\n%s %d\n%s %d\n%s %d\n%s %s\n%s %1.1f %s",
|
||||
ItemNames[ pItemNumbers[ i ] ],
|
||||
gWeaponStatsDesc[ 9 ], //Accuracy String
|
||||
Weapon[ pItemNumbers[ i ] ].bAccuracy, //Accuracy
|
||||
accuracy, //Accuracy
|
||||
gWeaponStatsDesc[ 11 ], //Damage String
|
||||
gunDamage, //Gun damage
|
||||
gWeaponStatsDesc[ 10 ], //Range String
|
||||
gGameSettings.fOptions[ TOPTION_SHOW_WEAPON_RANGE_IN_TILES ] ? Weapon[ pItemNumbers[ i ] ].usRange/10 : Weapon[ pItemNumbers[ i ] ].usRange, //Gun Range
|
||||
gGameSettings.fOptions[ TOPTION_SHOW_WEAPON_RANGE_IN_TILES ] ? usRange/10 : usRange, //Gun Range
|
||||
gWeaponStatsDesc[ 6 ], //AP String
|
||||
//apStr, //AP's
|
||||
L"- / - / -",
|
||||
@@ -2764,7 +2852,11 @@ void SelectBigImageRegionCallBack(MOUSE_REGION * pRegion, INT32 iReason )
|
||||
{
|
||||
UINT16 usItemNum = (UINT16)MSYS_GetRegionUserData( pRegion, 0 );
|
||||
|
||||
PurchaseBobbyRayItem( gusItemNumberForItemsOnScreen[ usItemNum] );
|
||||
// HEADROCK HAM 4: Purchase all at once.
|
||||
if (_KeyDown( 16 ) ) // SHIFT
|
||||
PurchaseBobbyRayItem( gusItemNumberForItemsOnScreen[ usItemNum], TRUE );
|
||||
else
|
||||
PurchaseBobbyRayItem( gusItemNumberForItemsOnScreen[ usItemNum], FALSE );
|
||||
|
||||
fReDrawScreenFlag = TRUE;
|
||||
fPausedReDrawScreenFlag = TRUE;
|
||||
@@ -2773,7 +2865,11 @@ void SelectBigImageRegionCallBack(MOUSE_REGION * pRegion, INT32 iReason )
|
||||
{
|
||||
UINT16 usItemNum = (UINT16)MSYS_GetRegionUserData( pRegion, 0 );
|
||||
|
||||
UnPurchaseBobbyRayItem( gusItemNumberForItemsOnScreen[ usItemNum] );
|
||||
// HEADROCK HAM 4: Unpurchase all at once.
|
||||
if (_KeyDown( 16 ) ) // SHIFT
|
||||
UnPurchaseBobbyRayItem( gusItemNumberForItemsOnScreen[ usItemNum], TRUE );
|
||||
else
|
||||
UnPurchaseBobbyRayItem( gusItemNumberForItemsOnScreen[ usItemNum], FALSE );
|
||||
fReDrawScreenFlag = TRUE;
|
||||
fPausedReDrawScreenFlag = TRUE;
|
||||
}
|
||||
@@ -2781,7 +2877,7 @@ void SelectBigImageRegionCallBack(MOUSE_REGION * pRegion, INT32 iReason )
|
||||
{
|
||||
UINT16 usItemNum = (UINT16)MSYS_GetRegionUserData( pRegion, 0 );
|
||||
|
||||
PurchaseBobbyRayItem( gusItemNumberForItemsOnScreen[ usItemNum] );
|
||||
PurchaseBobbyRayItem( gusItemNumberForItemsOnScreen[ usItemNum], FALSE );
|
||||
fReDrawScreenFlag = TRUE;
|
||||
fPausedReDrawScreenFlag = TRUE;
|
||||
}
|
||||
@@ -2789,7 +2885,7 @@ void SelectBigImageRegionCallBack(MOUSE_REGION * pRegion, INT32 iReason )
|
||||
{
|
||||
UINT16 usItemNum = (UINT16)MSYS_GetRegionUserData( pRegion, 0 );
|
||||
|
||||
UnPurchaseBobbyRayItem( gusItemNumberForItemsOnScreen[ usItemNum] );
|
||||
UnPurchaseBobbyRayItem( gusItemNumberForItemsOnScreen[ usItemNum], FALSE );
|
||||
fReDrawScreenFlag = TRUE;
|
||||
fPausedReDrawScreenFlag = TRUE;
|
||||
}
|
||||
@@ -2797,7 +2893,7 @@ void SelectBigImageRegionCallBack(MOUSE_REGION * pRegion, INT32 iReason )
|
||||
|
||||
|
||||
|
||||
void PurchaseBobbyRayItem(UINT16 usItemNumber)
|
||||
void PurchaseBobbyRayItem(UINT16 usItemNumber, BOOLEAN fAllItems )
|
||||
{
|
||||
UINT8 ubPurchaseNumber;
|
||||
|
||||
@@ -2816,8 +2912,10 @@ void PurchaseBobbyRayItem(UINT16 usItemNumber)
|
||||
|
||||
if( ubPurchaseNumber != BOBBY_RAY_NOT_PURCHASED )
|
||||
{
|
||||
UINT8 ubNumItems = fAllItems ? LaptopSaveInfo.BobbyRayUsedInventory[ usItemNumber ].ubQtyOnHand : 1;
|
||||
|
||||
BobbyRayPurchases[ ubPurchaseNumber ].usItemIndex = LaptopSaveInfo.BobbyRayUsedInventory[ usItemNumber ].usItemIndex;
|
||||
BobbyRayPurchases[ ubPurchaseNumber ].ubNumberPurchased = 1;
|
||||
BobbyRayPurchases[ ubPurchaseNumber ].ubNumberPurchased = ubNumItems;
|
||||
BobbyRayPurchases[ ubPurchaseNumber ].bItemQuality = LaptopSaveInfo.BobbyRayUsedInventory[ usItemNumber ].ubItemQuality;
|
||||
BobbyRayPurchases[ ubPurchaseNumber ].usBobbyItemIndex = usItemNumber;
|
||||
BobbyRayPurchases[ ubPurchaseNumber ].fUsed = TRUE;
|
||||
@@ -2832,8 +2930,10 @@ void PurchaseBobbyRayItem(UINT16 usItemNumber)
|
||||
// Else If the item is already purchased increment purchase amount. Only if ordering less then the max amount!
|
||||
else
|
||||
{
|
||||
if( BobbyRayPurchases[ ubPurchaseNumber ].ubNumberPurchased <= BOBBY_RAY_MAX_AMOUNT_OF_ITEMS_TO_PURCHASE)
|
||||
BobbyRayPurchases[ ubPurchaseNumber ].ubNumberPurchased++;
|
||||
UINT8 ubNumItems = fAllItems ? LaptopSaveInfo.BobbyRayUsedInventory[ usItemNumber ].ubQtyOnHand - BobbyRayPurchases[ ubPurchaseNumber ].ubNumberPurchased : 1;
|
||||
|
||||
if( BobbyRayPurchases[ ubPurchaseNumber ].ubNumberPurchased <= BOBBY_RAY_MAX_AMOUNT_OF_ITEMS_TO_PURCHASE - (ubNumItems-1))
|
||||
BobbyRayPurchases[ ubPurchaseNumber ].ubNumberPurchased += ubNumItems;
|
||||
}
|
||||
}
|
||||
else
|
||||
@@ -2858,8 +2958,10 @@ void PurchaseBobbyRayItem(UINT16 usItemNumber)
|
||||
|
||||
if( ubPurchaseNumber != BOBBY_RAY_NOT_PURCHASED )
|
||||
{
|
||||
UINT8 ubNumItems = fAllItems ? LaptopSaveInfo.BobbyRayInventory[ usItemNumber ].ubQtyOnHand : 1;
|
||||
|
||||
BobbyRayPurchases[ ubPurchaseNumber ].usItemIndex = LaptopSaveInfo.BobbyRayInventory[ usItemNumber ].usItemIndex;
|
||||
BobbyRayPurchases[ ubPurchaseNumber ].ubNumberPurchased = 1;
|
||||
BobbyRayPurchases[ ubPurchaseNumber ].ubNumberPurchased = ubNumItems;
|
||||
BobbyRayPurchases[ ubPurchaseNumber ].bItemQuality = 100;
|
||||
BobbyRayPurchases[ ubPurchaseNumber ].usBobbyItemIndex = usItemNumber;
|
||||
BobbyRayPurchases[ ubPurchaseNumber ].fUsed = FALSE;
|
||||
@@ -2873,8 +2975,10 @@ void PurchaseBobbyRayItem(UINT16 usItemNumber)
|
||||
// Else If the item is already purchased increment purchase amount. Only if ordering less then the max amount!
|
||||
else
|
||||
{
|
||||
if( BobbyRayPurchases[ ubPurchaseNumber ].ubNumberPurchased <= BOBBY_RAY_MAX_AMOUNT_OF_ITEMS_TO_PURCHASE)
|
||||
BobbyRayPurchases[ ubPurchaseNumber ].ubNumberPurchased++;
|
||||
UINT8 ubNumItems = fAllItems ? LaptopSaveInfo.BobbyRayInventory[ usItemNumber ].ubQtyOnHand - BobbyRayPurchases[ ubPurchaseNumber ].ubNumberPurchased : 1;
|
||||
|
||||
if( BobbyRayPurchases[ ubPurchaseNumber ].ubNumberPurchased <= BOBBY_RAY_MAX_AMOUNT_OF_ITEMS_TO_PURCHASE - (ubNumItems-1))
|
||||
BobbyRayPurchases[ ubPurchaseNumber ].ubNumberPurchased += ubNumItems;
|
||||
}
|
||||
}
|
||||
else
|
||||
@@ -2916,7 +3020,7 @@ UINT8 GetNextPurchaseNumber()
|
||||
|
||||
|
||||
|
||||
void UnPurchaseBobbyRayItem(UINT16 usItemNumber)
|
||||
void UnPurchaseBobbyRayItem(UINT16 usItemNumber, BOOLEAN fAllItems )
|
||||
{
|
||||
UINT8 ubPurchaseNumber;
|
||||
|
||||
@@ -2924,7 +3028,7 @@ void UnPurchaseBobbyRayItem(UINT16 usItemNumber)
|
||||
|
||||
if( ubPurchaseNumber != BOBBY_RAY_NOT_PURCHASED )
|
||||
{
|
||||
if( BobbyRayPurchases[ ubPurchaseNumber ].ubNumberPurchased > 1)
|
||||
if( BobbyRayPurchases[ ubPurchaseNumber ].ubNumberPurchased > 1 && !fAllItems)
|
||||
BobbyRayPurchases[ ubPurchaseNumber ].ubNumberPurchased--;
|
||||
else
|
||||
{
|
||||
|
||||
@@ -31,6 +31,7 @@
|
||||
#include "Strategic Event Handler.h"
|
||||
#include "connect.h"
|
||||
|
||||
/*
|
||||
typedef struct
|
||||
{
|
||||
STR16 *psCityLoc;
|
||||
@@ -38,8 +39,9 @@ typedef struct
|
||||
UINT16 us2DaysService;
|
||||
UINT16 usStandardService;
|
||||
} BobbyROrderLocationStruct;
|
||||
*/
|
||||
|
||||
|
||||
/*
|
||||
BobbyROrderLocationStruct BobbyROrderLocations[]=
|
||||
{
|
||||
{ &pDeliveryLocationStrings[0], 20, 15, 10 },
|
||||
@@ -60,6 +62,7 @@ BobbyROrderLocationStruct BobbyROrderLocations[]=
|
||||
{ &pDeliveryLocationStrings[15], 100, 55, 30 },
|
||||
{ &pDeliveryLocationStrings[16], 45, 30, 20 },
|
||||
};
|
||||
*/
|
||||
|
||||
//drop down menu
|
||||
enum
|
||||
@@ -829,7 +832,10 @@ void BtnBobbyRAcceptOrderCallback(GUI_BUTTON *btn,INT32 reason)
|
||||
else
|
||||
{
|
||||
//else pop up a confirmation box
|
||||
swprintf( zTemp, BobbyROrderFormText[BOBBYR_CONFIRM_DEST], *BobbyROrderLocations[gbSelectedCity].psCityLoc );
|
||||
//swprintf( zTemp, BobbyROrderFormText[BOBBYR_CONFIRM_DEST], *BobbyROrderLocations[gbSelectedCity].psCityLoc );
|
||||
|
||||
// WANNE: Replaced hard coded town names with the externalized ones (from ShippingDestination.xml).
|
||||
swprintf( zTemp, BobbyROrderFormText[BOBBYR_CONFIRM_DEST], gDestinationTable[gbSelectedCity]->wstrName.c_str() );
|
||||
DoLapTopMessageBox( MSG_BOX_LAPTOP_DEFAULT, zTemp, LAPTOP_SCREEN, MSG_BOX_FLAG_YESNO, ConfirmBobbyRPurchaseMessageBoxCallBack );
|
||||
}
|
||||
|
||||
@@ -1433,10 +1439,12 @@ BOOLEAN CreateDestroyBobbyRDropDown( UINT8 ubDropDownAction )
|
||||
//display the name on the title bar
|
||||
ColorFillVideoSurfaceArea( FRAME_BUFFER, BOBBYR_SHIPPING_LOC_AREA_L_X, BOBBYR_SHIPPING_LOC_AREA_T_Y, BOBBYR_SHIPPING_LOC_AREA_L_X+175, BOBBYR_SHIPPING_LOC_AREA_T_Y+BOBBYR_DROP_DOWN_HEIGHT, Get16BPPColor( FROMRGB( 0, 0, 0 ) ) );
|
||||
|
||||
/*
|
||||
if( gbSelectedCity == -1 )
|
||||
DrawTextToScreen( BobbyROrderFormText[BOBBYR_SELECT_DEST], BOBBYR_CITY_START_LOCATION_X+BOBBYR_CITY_NAME_OFFSET, BOBBYR_SHIPPING_LOC_AREA_T_Y+3, 0, BOBBYR_DROPDOWN_FONT, BOBBYR_ORDER_DROP_DOWN_SELEC_COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED );
|
||||
else
|
||||
else
|
||||
DrawTextToScreen( *(BobbyROrderLocations[gbSelectedCity].psCityLoc), BOBBYR_CITY_START_LOCATION_X+BOBBYR_CITY_NAME_OFFSET, BOBBYR_SHIPPING_LOC_AREA_T_Y+3, 0, BOBBYR_DROPDOWN_FONT, BOBBYR_ORDER_DROP_DOWN_SELEC_COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED );
|
||||
*/
|
||||
|
||||
//disable the r\close regiuon
|
||||
MSYS_DisableRegion(&gSelectedCloseDropDownRegion);
|
||||
|
||||
+29
-10
@@ -25,11 +25,12 @@
|
||||
#include "IMP Confirm.h"
|
||||
#include "messageboxscreen.h"
|
||||
#include "LaptopSave.h"
|
||||
// These 4 added - SANDRO
|
||||
// These 5 added - SANDRO
|
||||
#include "IMP Character and Disability Entrance.h"
|
||||
#include "IMP Character Trait.h"
|
||||
#include "IMP Disability Trait.h"
|
||||
#include "IMP Color Choosing.h"
|
||||
#include "IMP Minor Trait.h"
|
||||
#endif
|
||||
|
||||
|
||||
@@ -67,6 +68,7 @@ CHAR16 pNickName[ 32 ];
|
||||
// skills
|
||||
INT32 iSkillA = 0;
|
||||
INT32 iSkillB = 0;
|
||||
INT32 iSkillC = 0; // added third skill - SANDRO
|
||||
|
||||
// personality
|
||||
INT32 iPersonality = 0;
|
||||
@@ -255,7 +257,7 @@ void HandleCharProfile()
|
||||
case( IMP_CONFIRM ):
|
||||
HandleIMPConfirm( );
|
||||
break;
|
||||
// These 4 added - SANDRO
|
||||
// These 5 added - SANDRO
|
||||
case( IMP_CHARACTER_AND_DISABILITY_ENTRANCE ):
|
||||
HandleIMPCharacterAndDisabilityEntrance( );
|
||||
break;
|
||||
@@ -268,6 +270,9 @@ void HandleCharProfile()
|
||||
case( IMP_COLOR_CHOICE_PAGE ):
|
||||
HandleIMPColorChoice( );
|
||||
break;
|
||||
case( IMP_MINOR_TRAITS_PAGE ):
|
||||
HandleIMPMinorTrait( );
|
||||
break;
|
||||
}
|
||||
|
||||
return;
|
||||
@@ -328,7 +333,7 @@ void RenderCharProfile()
|
||||
case( IMP_CONFIRM ):
|
||||
RenderIMPConfirm( );
|
||||
break;
|
||||
// These 4 added - SANDRO
|
||||
// These 5 added - SANDRO
|
||||
case( IMP_CHARACTER_AND_DISABILITY_ENTRANCE ):
|
||||
RenderIMPCharacterAndDisabilityEntrance( );
|
||||
break;
|
||||
@@ -341,6 +346,9 @@ void RenderCharProfile()
|
||||
case( IMP_COLOR_CHOICE_PAGE ):
|
||||
RenderIMPColorChoice( );
|
||||
break;
|
||||
case( IMP_MINOR_TRAITS_PAGE ):
|
||||
RenderIMPMinorTrait( );
|
||||
break;
|
||||
}
|
||||
|
||||
// render title bar
|
||||
@@ -425,7 +433,7 @@ void ExitOldIMPMode( void )
|
||||
case( IMP_CONFIRM ):
|
||||
ExitIMPConfirm( );
|
||||
break;
|
||||
// These 4 added - SANDRO
|
||||
// These 5 added - SANDRO
|
||||
case( IMP_CHARACTER_AND_DISABILITY_ENTRANCE ):
|
||||
DestroyIMPButtons( );
|
||||
ExitIMPCharacterAndDisabilityEntrance( );
|
||||
@@ -442,6 +450,10 @@ void ExitOldIMPMode( void )
|
||||
DestroyIMPButtons( );
|
||||
ExitIMPColorChoice( );
|
||||
break;
|
||||
case( IMP_MINOR_TRAITS_PAGE ):
|
||||
DestroyIMPButtons( );
|
||||
ExitIMPMinorTrait( );
|
||||
break;
|
||||
}
|
||||
|
||||
return;
|
||||
@@ -508,7 +520,7 @@ void EnterNewIMPMode( void )
|
||||
case( IMP_CONFIRM ):
|
||||
EnterIMPConfirm( );
|
||||
break;
|
||||
// These 4 added - SANDRO
|
||||
// These 5 added - SANDRO
|
||||
case( IMP_CHARACTER_AND_DISABILITY_ENTRANCE ):
|
||||
CreateIMPButtons( );
|
||||
EnterIMPCharacterAndDisabilityEntrance( );
|
||||
@@ -525,6 +537,10 @@ void EnterNewIMPMode( void )
|
||||
CreateIMPButtons( );
|
||||
EnterIMPColorChoice( );
|
||||
break;
|
||||
case( IMP_MINOR_TRAITS_PAGE ):
|
||||
CreateIMPButtons( );
|
||||
EnterIMPMinorTrait( );
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
@@ -552,6 +568,7 @@ void ResetCharacterStats( void )
|
||||
// skills
|
||||
iSkillA = 0;
|
||||
iSkillB = 0;
|
||||
iSkillC = 0; // SANDRO - added third skill
|
||||
|
||||
// personality
|
||||
iPersonality = 0;
|
||||
@@ -614,8 +631,9 @@ void LoadImpGraphics( void )
|
||||
LoadAvgMercIndentFrame( );
|
||||
LoadAboutUsIndentFrame( );
|
||||
|
||||
LoadAttribStartingLevelFrame( ); // Added by SANDRO
|
||||
LoadColorChoiceFrame( ); // Added by SANDRO
|
||||
// Added by SANDRO
|
||||
LoadAttribStartingLevelFrame( );
|
||||
LoadColorChoiceFrame( );
|
||||
|
||||
return;
|
||||
|
||||
@@ -666,9 +684,10 @@ void RemoveImpGraphics( void )
|
||||
DeleteAttrib2IndentFrame( );
|
||||
DeleteAvgMercIndentFrame( );
|
||||
DeleteAboutUsIndentFrame( );
|
||||
|
||||
DeleteAttribStartingLevelFrame( ); // Added by SANDRO
|
||||
DeleteColorChoiceFrame( ); // Added by SANDRO
|
||||
|
||||
// Added by SANDRO
|
||||
DeleteAttribStartingLevelFrame( );
|
||||
DeleteColorChoiceFrame( );
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -38,6 +38,7 @@ extern CHAR16 pNickName[];
|
||||
// skills
|
||||
extern INT32 iSkillA;
|
||||
extern INT32 iSkillB;
|
||||
extern INT32 iSkillC; // Added by SANDRO
|
||||
|
||||
// persoanlity
|
||||
extern INT32 iPersonality;
|
||||
@@ -78,11 +79,12 @@ enum{
|
||||
IMP_VOICE,
|
||||
IMP_ABOUT_US,
|
||||
IMP_CONFIRM,
|
||||
// These 4 added - SANDRO
|
||||
// These 5 added - SANDRO
|
||||
IMP_CHARACTER_AND_DISABILITY_ENTRANCE,
|
||||
IMP_CHARACTER_PAGE,
|
||||
IMP_DISABILITY_PAGE,
|
||||
IMP_COLOR_CHOICE_PAGE,
|
||||
IMP_MINOR_TRAITS_PAGE,
|
||||
|
||||
IMP_NUM_PAGES,
|
||||
};
|
||||
|
||||
+275
-111
@@ -23,7 +23,10 @@
|
||||
#include "IMP Compile Character.h"
|
||||
#include "text.h"
|
||||
#include "GameSettings.h"
|
||||
#include "IMP Disability Trait.h" // Added this one - SANDRO
|
||||
// Added these 3 - SANDRO
|
||||
#include "IMP Disability Trait.h"
|
||||
#include "IMP Color Choosing.h"
|
||||
#include "IMP Minor Trait.h"
|
||||
|
||||
#endif
|
||||
|
||||
@@ -84,6 +87,19 @@ INT32 iCurrentMechanical = 0;
|
||||
INT32 iCurrentMedical = 0;
|
||||
INT32 iCurrentExplosives = 0;
|
||||
|
||||
INT32 iStrengthMinimum = gGameExternalOptions.iMinAttribute;
|
||||
INT32 iAgilityMinimum = gGameExternalOptions.iMinAttribute;
|
||||
INT32 iDexterityMinimum = gGameExternalOptions.iMinAttribute;
|
||||
INT32 iHealthMinimum = gGameExternalOptions.iMinAttribute;
|
||||
INT32 iLeaderShipMinimum = gGameExternalOptions.iMinAttribute;
|
||||
INT32 iWisdomMinimum = gGameExternalOptions.iMinAttribute;
|
||||
INT32 iMarkmanshipMinimum = gGameExternalOptions.iMinAttribute;
|
||||
INT32 iMechanicalMinimum = gGameExternalOptions.iMinAttribute;
|
||||
INT32 iMedicalMinimum = gGameExternalOptions.iMinAttribute;
|
||||
INT32 iExplosivesMinimum = gGameExternalOptions.iMinAttribute;
|
||||
|
||||
|
||||
|
||||
// which stat is message about stat at zero about
|
||||
INT32 iCurrentStatAtZero = 0;
|
||||
|
||||
@@ -460,36 +476,36 @@ void ProcessAttributes( void )
|
||||
INT32 iMaxAttribute = gGameExternalOptions.iMaxAttribute;
|
||||
|
||||
// strength
|
||||
if( iCurrentStrength <= iMinAttribute )
|
||||
if( iCurrentStrength <= iStrengthMinimum )
|
||||
{
|
||||
iCurrentStrength = iMinAttribute;
|
||||
iCurrentStrength = iStrengthMinimum;
|
||||
// disable button too
|
||||
|
||||
|
||||
}
|
||||
|
||||
// dex
|
||||
if( iCurrentDexterity <= iMinAttribute )
|
||||
if( iCurrentDexterity <= iDexterityMinimum )
|
||||
{
|
||||
iCurrentDexterity = iMinAttribute;
|
||||
iCurrentDexterity = iDexterityMinimum;
|
||||
// disable button too
|
||||
|
||||
|
||||
}
|
||||
|
||||
// agility
|
||||
if( iCurrentAgility <= iMinAttribute )
|
||||
if( iCurrentAgility <= iAgilityMinimum )
|
||||
{
|
||||
iCurrentAgility = iMinAttribute;
|
||||
iCurrentAgility = iAgilityMinimum;
|
||||
// disable button too
|
||||
|
||||
|
||||
}
|
||||
|
||||
// wisdom
|
||||
if( iCurrentWisdom <= iMinAttribute )
|
||||
if( iCurrentWisdom <= iWisdomMinimum )
|
||||
{
|
||||
iCurrentWisdom = iMinAttribute;
|
||||
iCurrentWisdom = iWisdomMinimum;
|
||||
// disable button too
|
||||
|
||||
|
||||
@@ -504,9 +520,9 @@ void ProcessAttributes( void )
|
||||
//}
|
||||
|
||||
// health
|
||||
if( iCurrentHealth <= iMinAttribute )
|
||||
if( iCurrentHealth <= iHealthMinimum )
|
||||
{
|
||||
iCurrentHealth = iMinAttribute;
|
||||
iCurrentHealth = iHealthMinimum;
|
||||
// disable button too
|
||||
|
||||
}
|
||||
@@ -668,7 +684,7 @@ UINT8 IncrementStat( INT32 iStatToIncrement )
|
||||
{
|
||||
if( DoWeHaveThisManyBonusPoints( iMaxZeroBonus ) == TRUE )
|
||||
{
|
||||
iCurrentLeaderShip+=iMinAttribute;
|
||||
iCurrentLeaderShip+=iLeaderShipMinimum;
|
||||
iCurrentBonusPoints-=iMaxZeroBonus;
|
||||
fSkillAtZeroWarning = FALSE;
|
||||
}
|
||||
@@ -696,7 +712,7 @@ UINT8 IncrementStat( INT32 iStatToIncrement )
|
||||
{
|
||||
if( DoWeHaveThisManyBonusPoints( iMaxZeroBonus ) == TRUE )
|
||||
{
|
||||
iCurrentMarkmanship+=iMinAttribute;
|
||||
iCurrentMarkmanship+=iMarkmanshipMinimum;
|
||||
iCurrentBonusPoints-=iMaxZeroBonus;
|
||||
fSkillAtZeroWarning = FALSE;
|
||||
}
|
||||
@@ -724,7 +740,7 @@ UINT8 IncrementStat( INT32 iStatToIncrement )
|
||||
{
|
||||
if( DoWeHaveThisManyBonusPoints( iMaxZeroBonus ) == TRUE )
|
||||
{
|
||||
iCurrentMechanical+=iMinAttribute;
|
||||
iCurrentMechanical+=iMechanicalMinimum;
|
||||
iCurrentBonusPoints-=iMaxZeroBonus;
|
||||
fSkillAtZeroWarning = FALSE;
|
||||
}
|
||||
@@ -752,7 +768,7 @@ UINT8 IncrementStat( INT32 iStatToIncrement )
|
||||
{
|
||||
if( DoWeHaveThisManyBonusPoints( iMaxZeroBonus ) == TRUE )
|
||||
{
|
||||
iCurrentMedical+=iMinAttribute;
|
||||
iCurrentMedical+=iMedicalMinimum;
|
||||
iCurrentBonusPoints-=iMaxZeroBonus;
|
||||
fSkillAtZeroWarning = FALSE;
|
||||
}
|
||||
@@ -780,7 +796,7 @@ UINT8 IncrementStat( INT32 iStatToIncrement )
|
||||
{
|
||||
if( DoWeHaveThisManyBonusPoints( iMaxZeroBonus ) == TRUE )
|
||||
{
|
||||
iCurrentExplosives+=iMinAttribute;
|
||||
iCurrentExplosives+=iExplosivesMinimum;
|
||||
iCurrentBonusPoints-=iMaxZeroBonus;
|
||||
fSkillAtZeroWarning = FALSE;
|
||||
}
|
||||
@@ -821,23 +837,23 @@ UINT8 DecrementStat( INT32 iStatToDecrement )
|
||||
switch( iStatToDecrement )
|
||||
{
|
||||
case( STRENGTH_ATTRIBUTE ):
|
||||
if( iCurrentStrength > iMinAttribute )
|
||||
if( iCurrentStrength > iStrengthMinimum )
|
||||
{
|
||||
// ok to decrement
|
||||
iCurrentStrength--;
|
||||
iCurrentBonusPoints++;
|
||||
iCurrentBonusPoints++;
|
||||
}
|
||||
else
|
||||
{
|
||||
return( SLIDER_OUT_OF_RANGE );
|
||||
}
|
||||
break;
|
||||
case( DEXTERITY_ATTRIBUTE ):
|
||||
if( iCurrentDexterity > iMinAttribute )
|
||||
case( DEXTERITY_ATTRIBUTE ):
|
||||
if( iCurrentDexterity > iDexterityMinimum )
|
||||
{
|
||||
// ok to decrement
|
||||
iCurrentDexterity--;
|
||||
iCurrentBonusPoints++;
|
||||
iCurrentBonusPoints++;
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -845,23 +861,23 @@ UINT8 DecrementStat( INT32 iStatToDecrement )
|
||||
}
|
||||
break;
|
||||
case( AGILITY_ATTRIBUTE ):
|
||||
if( iCurrentAgility > iMinAttribute )
|
||||
if( iCurrentAgility > iAgilityMinimum )
|
||||
{
|
||||
// ok to decrement
|
||||
iCurrentAgility--;
|
||||
iCurrentBonusPoints++;
|
||||
iCurrentBonusPoints++;
|
||||
}
|
||||
else
|
||||
{
|
||||
return( SLIDER_OUT_OF_RANGE );
|
||||
}
|
||||
break;
|
||||
case( WISDOM_ATTRIBUTE ):
|
||||
if( iCurrentWisdom > iMinAttribute )
|
||||
case( WISDOM_ATTRIBUTE ):
|
||||
if( iCurrentWisdom > iWisdomMinimum )
|
||||
{
|
||||
// ok to decrement
|
||||
iCurrentWisdom--;
|
||||
iCurrentBonusPoints++;
|
||||
iCurrentBonusPoints++;
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -869,91 +885,106 @@ UINT8 DecrementStat( INT32 iStatToDecrement )
|
||||
}
|
||||
break;
|
||||
case( LEADERSHIP_ATTRIBUTE ):
|
||||
if( iCurrentLeaderShip > iMinAttribute )
|
||||
if( iCurrentLeaderShip > iLeaderShipMinimum )
|
||||
{
|
||||
// ok to decrement
|
||||
iCurrentLeaderShip--;
|
||||
iCurrentBonusPoints++;
|
||||
iCurrentBonusPoints++;
|
||||
}
|
||||
//Kaiden: Leadership couldn't be set to zero fixed below:
|
||||
else if( iCurrentLeaderShip == iMinAttribute)
|
||||
else if( iCurrentLeaderShip == iLeaderShipMinimum)
|
||||
{
|
||||
// ok to decrement
|
||||
iCurrentLeaderShip-=iMinAttribute;
|
||||
iCurrentBonusPoints+=iMaxZeroBonus;
|
||||
fSkillAtZeroWarning = TRUE;
|
||||
if (LeadershipRequiredDueToMajorSkills() == 0 && LeaderShipRequiredAdjustmentForMinorTraits( 0 ) == 0 )
|
||||
{
|
||||
// ok to decrement
|
||||
iCurrentLeaderShip-=iLeaderShipMinimum;
|
||||
iCurrentBonusPoints+=iMaxZeroBonus;
|
||||
fSkillAtZeroWarning = TRUE;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case( HEALTH_ATTRIBUTE ):
|
||||
if( iCurrentHealth > iMinAttribute )
|
||||
if( iCurrentHealth > iHealthMinimum )
|
||||
{
|
||||
// ok to decrement
|
||||
iCurrentHealth--;
|
||||
iCurrentBonusPoints++;
|
||||
iCurrentBonusPoints++;
|
||||
}
|
||||
else
|
||||
{
|
||||
return( SLIDER_OUT_OF_RANGE );
|
||||
}
|
||||
break;
|
||||
case( MARKSMANSHIP_SKILL ):
|
||||
if( iCurrentMarkmanship > iMinAttribute )
|
||||
case( MARKSMANSHIP_SKILL ):
|
||||
if( iCurrentMarkmanship > iMarkmanshipMinimum )
|
||||
{
|
||||
// ok to decrement
|
||||
iCurrentMarkmanship--;
|
||||
iCurrentBonusPoints++;
|
||||
iCurrentBonusPoints++;
|
||||
}
|
||||
else if( iCurrentMarkmanship == iMinAttribute)
|
||||
else if( iCurrentMarkmanship == iMarkmanshipMinimum)
|
||||
{
|
||||
// ok to decrement
|
||||
iCurrentMarkmanship-=iMinAttribute;
|
||||
iCurrentBonusPoints+=iMaxZeroBonus;
|
||||
fSkillAtZeroWarning = TRUE;
|
||||
if (MarksmanshipRequiredDueToMajorSkills() == 0 && MarksmanshipRequiredAdjustmentForMinorTraits( 0 ) == 0 )
|
||||
{
|
||||
// ok to decrement
|
||||
iCurrentMarkmanship-=iMarkmanshipMinimum;
|
||||
iCurrentBonusPoints+=iMaxZeroBonus;
|
||||
fSkillAtZeroWarning = TRUE;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case( MEDICAL_SKILL ):
|
||||
if( iCurrentMedical > iMinAttribute )
|
||||
if( iCurrentMedical > iMedicalMinimum )
|
||||
{
|
||||
// ok to decrement
|
||||
iCurrentMedical--;
|
||||
iCurrentBonusPoints++;
|
||||
iCurrentBonusPoints++;
|
||||
}
|
||||
else if( iCurrentMedical == iMinAttribute)
|
||||
else if( iCurrentMedical == iMedicalMinimum)
|
||||
{
|
||||
// ok to decrement
|
||||
iCurrentMedical-=iMinAttribute;
|
||||
iCurrentBonusPoints+=iMaxZeroBonus;
|
||||
fSkillAtZeroWarning = TRUE;
|
||||
if (MedicalRequiredDueToMajorSkills() == 0 && MedicalRequiredAdjustmentForMinorTraits( 0 ) == 0 )
|
||||
{
|
||||
// ok to decrement
|
||||
iCurrentMedical-=iMedicalMinimum;
|
||||
iCurrentBonusPoints+=iMaxZeroBonus;
|
||||
fSkillAtZeroWarning = TRUE;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case( MECHANICAL_SKILL ):
|
||||
if( iCurrentMechanical > iMinAttribute )
|
||||
if( iCurrentMechanical > iMechanicalMinimum )
|
||||
{
|
||||
// ok to decrement
|
||||
iCurrentMechanical--;
|
||||
iCurrentBonusPoints++;
|
||||
iCurrentBonusPoints++;
|
||||
}
|
||||
else if( iCurrentMechanical == iMinAttribute)
|
||||
else if( iCurrentMechanical == iMechanicalMinimum)
|
||||
{
|
||||
// ok to decrement
|
||||
iCurrentMechanical-=iMinAttribute;
|
||||
iCurrentBonusPoints+=iMaxZeroBonus;
|
||||
fSkillAtZeroWarning = TRUE;
|
||||
if (MechanicalRequiredDueToMajorSkills() == 0 && MechanicalRequiredAdjustmentForMinorTraits( 0 ) == 0 )
|
||||
{
|
||||
// ok to decrement
|
||||
iCurrentMechanical-=iMechanicalMinimum;
|
||||
iCurrentBonusPoints+=iMaxZeroBonus;
|
||||
fSkillAtZeroWarning = TRUE;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case( EXPLOSIVE_SKILL ):
|
||||
if( iCurrentExplosives > iMinAttribute )
|
||||
if( iCurrentExplosives > iExplosivesMinimum )
|
||||
{
|
||||
// ok to decrement
|
||||
iCurrentExplosives--;
|
||||
iCurrentBonusPoints++;
|
||||
iCurrentBonusPoints++;
|
||||
}
|
||||
else if( iCurrentExplosives == iMinAttribute)
|
||||
else if( iCurrentExplosives == iExplosivesMinimum)
|
||||
{
|
||||
// ok to decrement
|
||||
iCurrentExplosives-=iMinAttribute;
|
||||
iCurrentBonusPoints+=iMaxZeroBonus;
|
||||
fSkillAtZeroWarning = TRUE;
|
||||
if (ExplosivesRequiredDueToMajorSkills() == 0 && ExplosivesRequiredAdjustmentForMinorTraits( 0 ) == 0 )
|
||||
{
|
||||
// ok to decrement
|
||||
iCurrentExplosives-=iExplosivesMinimum;
|
||||
iCurrentBonusPoints+=iMaxZeroBonus;
|
||||
fSkillAtZeroWarning = TRUE;
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -1563,7 +1594,9 @@ void CreateSliderBarMouseRegions( void )
|
||||
INT16 sX = 0;
|
||||
|
||||
// set the starting X
|
||||
sX = DetermineNewPosition( gGameExternalOptions.iStartAttribute - iMinAttribute );
|
||||
// SANDRO - some changes in attribute points distribution method
|
||||
//sX = DetermineNewPosition( gGameExternalOptions.iStartAttribute - iMinAttribute );
|
||||
sX = DetermineNewPosition( 0 );
|
||||
|
||||
for( iCounter = 0; iCounter < 10; iCounter++ )
|
||||
{
|
||||
@@ -1882,59 +1915,190 @@ INT32 GetCurrentAttributeValue( INT32 iAttribute )
|
||||
|
||||
void SetAttributes( void )
|
||||
{
|
||||
INT8 bExtraPoints = 0;
|
||||
/*
|
||||
// set attributes and skills based on what is in charprofile.c
|
||||
|
||||
// attributes
|
||||
iCurrentStrength = iStrength + iAddStrength;
|
||||
iCurrentDexterity = iDexterity + iAddDexterity;
|
||||
iCurrentHealth = iHealth + iAddHealth;
|
||||
iCurrentLeaderShip = iLeadership + iAddLeadership;
|
||||
iCurrentWisdom = iWisdom + iAddWisdom;
|
||||
iCurrentAgility = iAgility + iAddAgility;
|
||||
|
||||
// skills
|
||||
iCurrentMarkmanship = iMarksmanship + iAddMarksmanship;
|
||||
iCurrentMechanical = iMechanical + iAddMechanical;
|
||||
iCurrentMedical = iMedical + iAddMedical;
|
||||
iCurrentExplosives = iExplosives + iAddExplosives;
|
||||
|
||||
// reset bonus pts
|
||||
iCurrentBonusPoints = 40;
|
||||
*/
|
||||
INT32 iExtraPoints = 0;
|
||||
|
||||
// added externilized multiplier for starting level - SADNRO
|
||||
iLevelCostMultiplier = gGameExternalOptions.iIMPStartingLevelCostMultiplier;
|
||||
|
||||
iCurrentStrength = gGameExternalOptions.iStartAttribute;
|
||||
iCurrentDexterity = gGameExternalOptions.iStartAttribute;
|
||||
iCurrentHealth = gGameExternalOptions.iStartAttribute;
|
||||
iCurrentLeaderShip = gGameExternalOptions.iStartAttribute;
|
||||
iCurrentWisdom = gGameExternalOptions.iStartAttribute;
|
||||
iCurrentAgility = gGameExternalOptions.iStartAttribute;
|
||||
/////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// SANDRO - determine minimum attribute values due to chosen traits
|
||||
|
||||
// skills
|
||||
iCurrentMarkmanship = gGameExternalOptions.iStartAttribute;
|
||||
iCurrentMechanical = gGameExternalOptions.iStartAttribute;
|
||||
iCurrentMedical = gGameExternalOptions.iStartAttribute;
|
||||
iCurrentExplosives = gGameExternalOptions.iStartAttribute;
|
||||
|
||||
|
||||
// reset bonus pts
|
||||
//iCurrentBonusPoints = 40;
|
||||
iCurrentBonusPoints = gGameExternalOptions.iImpAttributePoints;
|
||||
|
||||
|
||||
//Determine if the player has any extra points
|
||||
bExtraPoints += iPlayersAttributePointsBonusForDisabilitySelected(); // Added attribute bonus for chosen disability - SANDRO
|
||||
bExtraPoints += DoesPlayerHaveExtraAttibutePointsToDistributeBasedOnSkillSelection();
|
||||
|
||||
if( bExtraPoints > 0 )
|
||||
// For new trait system only though
|
||||
if ( gGameOptions.fNewTraitSystem )
|
||||
{
|
||||
iCurrentBonusPoints += bExtraPoints;
|
||||
}
|
||||
// reset bonus pts
|
||||
iCurrentBonusPoints = gGameExternalOptions.iImpAttributePoints;
|
||||
//Determine if the player has any extra points
|
||||
iExtraPoints += iPlayersAttributePointsBonusForDisabilitySelected();
|
||||
iExtraPoints += DoesPlayerHaveExtraAttibutePointsToDistributeBasedOnSkillSelection();
|
||||
|
||||
if( iExtraPoints > 0 )
|
||||
iCurrentBonusPoints += iExtraPoints;
|
||||
|
||||
// Get Strength minimum
|
||||
iStrengthMinimum = StrengthRequiredDueToMajorSkills();
|
||||
if ( iStrengthMinimum < gGameExternalOptions.iMinAttribute )
|
||||
iStrengthMinimum = gGameExternalOptions.iMinAttribute;
|
||||
|
||||
iStrengthMinimum += StrengthRequiredAdjustmentForMinorTraits( iStrengthMinimum );
|
||||
|
||||
// hehehe, make the alternative weapon holding anim requiring a big strength
|
||||
if ( bBadAssSelected() && iStrengthMinimum < 80 )
|
||||
iStrengthMinimum = 80;
|
||||
|
||||
if ( iStrengthMinimum > gGameExternalOptions.iMaxAttribute )
|
||||
iStrengthMinimum = gGameExternalOptions.iMaxAttribute;
|
||||
|
||||
iCurrentStrength = iStrengthMinimum;
|
||||
iCurrentBonusPoints -= iStrengthMinimum;
|
||||
|
||||
// Get Agility minimum
|
||||
iAgilityMinimum = AgilityRequiredDueToMajorSkills();
|
||||
if ( iAgilityMinimum < gGameExternalOptions.iMinAttribute )
|
||||
iAgilityMinimum = gGameExternalOptions.iMinAttribute;
|
||||
|
||||
iAgilityMinimum += AgilityRequiredAdjustmentForMinorTraits( iAgilityMinimum );
|
||||
|
||||
if ( iAgilityMinimum > gGameExternalOptions.iMaxAttribute )
|
||||
iAgilityMinimum = gGameExternalOptions.iMaxAttribute;
|
||||
|
||||
iCurrentAgility = iAgilityMinimum;
|
||||
iCurrentBonusPoints -= iAgilityMinimum;
|
||||
|
||||
// Get Dexterity minimum
|
||||
iDexterityMinimum = DexterityRequiredDueToMajorSkills();
|
||||
if ( iDexterityMinimum < gGameExternalOptions.iMinAttribute )
|
||||
iDexterityMinimum = gGameExternalOptions.iMinAttribute;
|
||||
|
||||
iDexterityMinimum += DexterityRequiredAdjustmentForMinorTraits( iDexterityMinimum );
|
||||
|
||||
if ( iDexterityMinimum > gGameExternalOptions.iMaxAttribute )
|
||||
iDexterityMinimum = gGameExternalOptions.iMaxAttribute;
|
||||
|
||||
iCurrentDexterity = iDexterityMinimum;
|
||||
iCurrentBonusPoints -= iDexterityMinimum;
|
||||
|
||||
// Get Health minimum
|
||||
iHealthMinimum = HealthRequiredDueToMajorSkills();
|
||||
if ( iHealthMinimum <= 0 )
|
||||
iHealthMinimum = gGameExternalOptions.iMinAttribute;
|
||||
|
||||
iHealthMinimum += HealthRequiredAdjustmentForMinorTraits( iHealthMinimum );
|
||||
|
||||
if ( iHealthMinimum > gGameExternalOptions.iMaxAttribute )
|
||||
iHealthMinimum = gGameExternalOptions.iMaxAttribute;
|
||||
|
||||
iCurrentHealth = iHealthMinimum;
|
||||
iCurrentBonusPoints -= iHealthMinimum;
|
||||
|
||||
// Get Leadership minimum
|
||||
iLeaderShipMinimum = LeadershipRequiredDueToMajorSkills();
|
||||
if ( iLeaderShipMinimum < gGameExternalOptions.iMinAttribute )
|
||||
iLeaderShipMinimum = gGameExternalOptions.iMinAttribute;
|
||||
|
||||
iLeaderShipMinimum += LeaderShipRequiredAdjustmentForMinorTraits( iLeaderShipMinimum );
|
||||
|
||||
if ( iLeaderShipMinimum > gGameExternalOptions.iMaxAttribute )
|
||||
iLeaderShipMinimum = gGameExternalOptions.iMaxAttribute;
|
||||
|
||||
iCurrentLeaderShip = iLeaderShipMinimum;
|
||||
iCurrentBonusPoints -= (iLeaderShipMinimum - gGameExternalOptions.iMinAttribute + gGameExternalOptions.iMaxZeroBonus);
|
||||
|
||||
// Get Wisdom minimum
|
||||
iWisdomMinimum = WisdomRequiredDueToMajorSkills();
|
||||
if ( iWisdomMinimum < gGameExternalOptions.iMinAttribute )
|
||||
iWisdomMinimum = gGameExternalOptions.iMinAttribute;
|
||||
|
||||
iWisdomMinimum += WisdomRequiredAdjustmentForMinorTraits( iWisdomMinimum );
|
||||
|
||||
if ( iWisdomMinimum > gGameExternalOptions.iMaxAttribute )
|
||||
iWisdomMinimum = gGameExternalOptions.iMaxAttribute;
|
||||
|
||||
iCurrentWisdom = iWisdomMinimum;
|
||||
iCurrentBonusPoints -= iWisdomMinimum;
|
||||
|
||||
// Get Marksmanship minimum
|
||||
iMarkmanshipMinimum = MarksmanshipRequiredDueToMajorSkills();
|
||||
if ( iMarkmanshipMinimum < gGameExternalOptions.iMinAttribute )
|
||||
iMarkmanshipMinimum = gGameExternalOptions.iMinAttribute;
|
||||
|
||||
iMarkmanshipMinimum += MarksmanshipRequiredAdjustmentForMinorTraits( iMarkmanshipMinimum );
|
||||
|
||||
if ( iMarkmanshipMinimum > gGameExternalOptions.iMaxAttribute )
|
||||
iMarkmanshipMinimum = gGameExternalOptions.iMaxAttribute;
|
||||
|
||||
iCurrentMarkmanship = iMarkmanshipMinimum;
|
||||
iCurrentBonusPoints -= (iMarkmanshipMinimum - gGameExternalOptions.iMinAttribute + gGameExternalOptions.iMaxZeroBonus);
|
||||
|
||||
// Get Mechanical minimum
|
||||
iMechanicalMinimum = MechanicalRequiredDueToMajorSkills();
|
||||
if ( iMechanicalMinimum < gGameExternalOptions.iMinAttribute )
|
||||
iMechanicalMinimum = gGameExternalOptions.iMinAttribute;
|
||||
|
||||
iMechanicalMinimum += MechanicalRequiredAdjustmentForMinorTraits( iMechanicalMinimum );
|
||||
|
||||
if ( iMechanicalMinimum > gGameExternalOptions.iMaxAttribute )
|
||||
iMechanicalMinimum = gGameExternalOptions.iMaxAttribute;
|
||||
|
||||
iCurrentMechanical = iMechanicalMinimum;
|
||||
iCurrentBonusPoints -= (iMechanicalMinimum - gGameExternalOptions.iMinAttribute + gGameExternalOptions.iMaxZeroBonus);
|
||||
|
||||
// Get Medical minimum
|
||||
iMedicalMinimum = MedicalRequiredDueToMajorSkills();
|
||||
if ( iMedicalMinimum < gGameExternalOptions.iMinAttribute )
|
||||
iMedicalMinimum = gGameExternalOptions.iMinAttribute;
|
||||
|
||||
iMedicalMinimum += MedicalRequiredAdjustmentForMinorTraits( iMedicalMinimum );
|
||||
|
||||
if ( iMedicalMinimum > gGameExternalOptions.iMaxAttribute )
|
||||
iMedicalMinimum = gGameExternalOptions.iMaxAttribute;
|
||||
|
||||
iCurrentMedical = iMedicalMinimum;
|
||||
iCurrentBonusPoints -= (iMedicalMinimum - gGameExternalOptions.iMinAttribute + gGameExternalOptions.iMaxZeroBonus);
|
||||
|
||||
// Get Explosives minimum
|
||||
iExplosivesMinimum = ExplosivesRequiredDueToMajorSkills();
|
||||
if ( iExplosivesMinimum < gGameExternalOptions.iMinAttribute )
|
||||
iExplosivesMinimum = gGameExternalOptions.iMinAttribute;
|
||||
|
||||
iExplosivesMinimum += ExplosivesRequiredAdjustmentForMinorTraits( iExplosivesMinimum );
|
||||
|
||||
if ( iExplosivesMinimum > gGameExternalOptions.iMaxAttribute )
|
||||
iExplosivesMinimum = gGameExternalOptions.iMaxAttribute;
|
||||
|
||||
iCurrentExplosives = iExplosivesMinimum;
|
||||
iCurrentBonusPoints -= (iExplosivesMinimum - gGameExternalOptions.iMinAttribute + gGameExternalOptions.iMaxZeroBonus);
|
||||
|
||||
|
||||
// if we exceeded points available, just give us zero points, but keep the attribute minimums untouched
|
||||
if ( iCurrentBonusPoints < 0 )
|
||||
iCurrentBonusPoints = 0;
|
||||
}
|
||||
/////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
else // ORIGINAL
|
||||
{
|
||||
iCurrentBonusPoints = gGameExternalOptions.iImpAttributePoints;
|
||||
|
||||
//Determine if the player has any extra points
|
||||
iExtraPoints += iPlayersAttributePointsBonusForDisabilitySelected();
|
||||
iExtraPoints += DoesPlayerHaveExtraAttibutePointsToDistributeBasedOnSkillSelection();
|
||||
if( iExtraPoints > 0 )
|
||||
iCurrentBonusPoints += iExtraPoints;
|
||||
|
||||
iCurrentStrength = gGameExternalOptions.iMinAttribute;
|
||||
iCurrentDexterity = gGameExternalOptions.iMinAttribute;
|
||||
iCurrentHealth = gGameExternalOptions.iMinAttribute;
|
||||
iCurrentLeaderShip = gGameExternalOptions.iMinAttribute;
|
||||
iCurrentWisdom = gGameExternalOptions.iMinAttribute;
|
||||
iCurrentAgility = gGameExternalOptions.iMinAttribute;
|
||||
iCurrentMarkmanship = gGameExternalOptions.iMinAttribute;
|
||||
iCurrentMechanical = gGameExternalOptions.iMinAttribute;
|
||||
iCurrentMedical = gGameExternalOptions.iMinAttribute;
|
||||
iCurrentExplosives = gGameExternalOptions.iMinAttribute;
|
||||
|
||||
iCurrentBonusPoints -= ((5 * gGameExternalOptions.iMinAttribute) + (5 * gGameExternalOptions.iMaxZeroBonus));
|
||||
}
|
||||
////////////////////////////////////////////////////
|
||||
|
||||
ResetIncrementCharacterAttributes( );
|
||||
|
||||
|
||||
+28
-28
@@ -32,7 +32,7 @@
|
||||
#include "LaptopSave.h"
|
||||
#endif
|
||||
|
||||
#include "VFS/Tools/ParserTools.h"
|
||||
#include <vfs/Tools/vfs_parser_tools.h>
|
||||
|
||||
#define FULL_NAME_CURSOR_Y LAPTOP_SCREEN_WEB_UL_Y + 138
|
||||
#define NICK_NAME_CURSOR_Y LAPTOP_SCREEN_WEB_UL_Y + 195
|
||||
@@ -1299,9 +1299,9 @@ BOOLEAN CheckCharacterInputForEgg( void )
|
||||
iMechanical = 0;
|
||||
iExplosives = 99;
|
||||
iMedical = 0;
|
||||
iSkillA = AMBIDEXT;
|
||||
iSkillB = AUTO_WEAPS;
|
||||
iPersonality = NO_PERSONALITYTRAIT;
|
||||
iSkillA = AMBIDEXT_OT;
|
||||
iSkillB = AUTO_WEAPS_OT;
|
||||
iPersonality = NO_DISABILITY;
|
||||
iAttitude = ATT_ASSHOLE;
|
||||
iCurrentImpPage = IMP_FINISH;
|
||||
// LaptopSaveInfo.iCurrentVoice = 1;
|
||||
@@ -1324,9 +1324,9 @@ BOOLEAN CheckCharacterInputForEgg( void )
|
||||
iMechanical = 40;
|
||||
iExplosives = 25;
|
||||
iMedical = 60;
|
||||
iSkillA = MARTIALARTS;
|
||||
iSkillB = AUTO_WEAPS;
|
||||
iPersonality = NO_PERSONALITYTRAIT;
|
||||
iSkillA = MARTIALARTS_OT;
|
||||
iSkillB = AUTO_WEAPS_OT;
|
||||
iPersonality = NO_DISABILITY;
|
||||
iAttitude = ATT_FRIENDLY;
|
||||
iCurrentImpPage = IMP_FINISH;
|
||||
// LaptopSaveInfo.iCurrentVoice = 1;
|
||||
@@ -1349,9 +1349,9 @@ BOOLEAN CheckCharacterInputForEgg( void )
|
||||
iMechanical = 100;
|
||||
iExplosives = 100;
|
||||
iMedical = 100;
|
||||
iSkillA = MARTIALARTS;
|
||||
iSkillB = AUTO_WEAPS;
|
||||
iPersonality = NO_PERSONALITYTRAIT;
|
||||
iSkillA = MARTIALARTS_OT;
|
||||
iSkillB = AUTO_WEAPS_OT;
|
||||
iPersonality = NO_DISABILITY;
|
||||
iAttitude = ATT_FRIENDLY;
|
||||
iCurrentImpPage = IMP_FINISH;
|
||||
// LaptopSaveInfo.iCurrentVoice = 2;
|
||||
@@ -1376,10 +1376,10 @@ BOOLEAN CheckCharacterInputForEgg( void )
|
||||
iExplosives = 99;
|
||||
iMedical = 75;
|
||||
|
||||
iSkillA = STEALTHY;
|
||||
iSkillB = MARTIALARTS;
|
||||
iSkillA = STEALTHY_OT;
|
||||
iSkillB = MARTIALARTS_OT;
|
||||
|
||||
iPersonality = NO_PERSONALITYTRAIT;
|
||||
iPersonality = NO_DISABILITY;
|
||||
iAttitude = ATT_AGGRESSIVE;
|
||||
iCurrentImpPage = IMP_FINISH;
|
||||
// LaptopSaveInfo.iCurrentVoice = 1;
|
||||
@@ -1404,10 +1404,10 @@ BOOLEAN CheckCharacterInputForEgg( void )
|
||||
iExplosives = 0;
|
||||
iMedical = 99;
|
||||
|
||||
iSkillA = AUTO_WEAPS;
|
||||
iSkillB = AMBIDEXT;
|
||||
iSkillA = AUTO_WEAPS_OT;
|
||||
iSkillB = AMBIDEXT_OT;
|
||||
|
||||
iPersonality = NO_PERSONALITYTRAIT;
|
||||
iPersonality = NO_DISABILITY;
|
||||
iAttitude = ATT_ARROGANT;
|
||||
iCurrentImpPage = IMP_FINISH;
|
||||
// LaptopSaveInfo.iCurrentVoice = 1;
|
||||
@@ -1432,10 +1432,10 @@ BOOLEAN CheckCharacterInputForEgg( void )
|
||||
iExplosives = 99;
|
||||
iMedical = 35;
|
||||
|
||||
iSkillA = AUTO_WEAPS;
|
||||
iSkillB = MARTIALARTS;
|
||||
iSkillA = AUTO_WEAPS_OT;
|
||||
iSkillB = MARTIALARTS_OT;
|
||||
|
||||
iPersonality = NO_PERSONALITYTRAIT;
|
||||
iPersonality = NO_DISABILITY;
|
||||
iAttitude = ATT_AGGRESSIVE;
|
||||
iCurrentImpPage = IMP_FINISH;
|
||||
// LaptopSaveInfo.iCurrentVoice = 1;
|
||||
@@ -1460,10 +1460,10 @@ BOOLEAN CheckCharacterInputForEgg( void )
|
||||
iExplosives = 99;
|
||||
iMedical = 0;
|
||||
|
||||
iSkillA = AUTO_WEAPS;
|
||||
iSkillB = MARTIALARTS;
|
||||
iSkillA = AUTO_WEAPS_OT;
|
||||
iSkillB = MARTIALARTS_OT;
|
||||
|
||||
iPersonality = NO_PERSONALITYTRAIT;
|
||||
iPersonality = NO_DISABILITY;
|
||||
iAttitude = ATT_LONER;
|
||||
iCurrentImpPage = IMP_FINISH;
|
||||
// LaptopSaveInfo.iCurrentVoice = 1;
|
||||
@@ -1486,8 +1486,8 @@ BOOLEAN CheckCharacterInputForEgg( void )
|
||||
iMechanical = 0;
|
||||
iExplosives = 99;
|
||||
iMedical = 0;
|
||||
iSkillA = AMBIDEXT;
|
||||
iSkillB = AUTO_WEAPS;
|
||||
iSkillA = AMBIDEXT_OT;
|
||||
iSkillB = AUTO_WEAPS_OT;
|
||||
iPersonality = PSYCHO;
|
||||
iAttitude = ATT_ASSHOLE;
|
||||
iCurrentImpPage = IMP_FINISH;
|
||||
@@ -1542,10 +1542,10 @@ BOOLEAN CheckCharacterInputForEgg( void )
|
||||
iExplosives = 99;
|
||||
iMedical = 60;
|
||||
|
||||
iSkillA = ELECTRONICS;
|
||||
iSkillB = LOCKPICKING;
|
||||
iSkillA = ELECTRONICS_OT;
|
||||
iSkillB = LOCKPICKING_OT;
|
||||
|
||||
iPersonality = NO_PERSONALITYTRAIT;
|
||||
iPersonality = NO_DISABILITY;
|
||||
iAttitude = ATT_LONER;
|
||||
iCurrentImpPage = IMP_FINISH;
|
||||
// LaptopSaveInfo.iCurrentVoice = 1;
|
||||
@@ -1575,7 +1575,7 @@ BOOLEAN CheckCharacterInputForEgg( void )
|
||||
iSkillA = 0;
|
||||
iSkillB = 0;
|
||||
|
||||
iPersonality = NO_PERSONALITYTRAIT;
|
||||
iPersonality = NO_DISABILITY;
|
||||
iAttitude = ATT_LONER;
|
||||
iCurrentImpPage = IMP_FINISH;
|
||||
LaptopSaveInfo.iIMPIndex = 54;
|
||||
|
||||
@@ -19,6 +19,7 @@
|
||||
#include "CharProfile.h"
|
||||
#include "soldier profile type.h"
|
||||
#include "IMP Compile Character.h"
|
||||
#include "GameSettings.h"
|
||||
#endif
|
||||
|
||||
|
||||
@@ -33,13 +34,6 @@
|
||||
#define IMP_CHARACTER_TRAIT__FONT FONT12ARIAL
|
||||
#define IMP_CHARACTER_TRAIT__COLOR FONT_MCOLOR_WHITE
|
||||
|
||||
enum
|
||||
{
|
||||
IMP_CHARACTER_TRAIT__TITLE_TEXT=IMP_CHARACTER_TRAITS_NUMBER,
|
||||
};
|
||||
|
||||
|
||||
|
||||
#define IMP_CHARACTER_1ST_COLUMN_START_X ( LAPTOP_SCREEN_UL_X + 15 )
|
||||
#define IMP_CHARACTER_1ST_COLUMN_START_Y ( LAPTOP_SCREEN_WEB_UL_Y + 40 )
|
||||
|
||||
@@ -48,7 +42,7 @@ enum
|
||||
|
||||
#define IMP_CHARACTER_TRAIT__SPACE_BTN_BUTTONS 38
|
||||
|
||||
#define IMP_CHARACTER_TRAIT_NUMBER_TO_START_2ND_COLUMN 5
|
||||
//#define IMP_CHARACTER_TRAIT_NUMBER_TO_START_2ND_COLUMN 5
|
||||
|
||||
#define IMP_CHARACTER_TRAIT__TEXT_OFFSET_X 65
|
||||
#define IMP_CHARACTER_TRAIT__TEXT_OFFSET_Y 12
|
||||
@@ -69,11 +63,11 @@ enum
|
||||
|
||||
BOOLEAN gfIST_Redraw2=FALSE;
|
||||
|
||||
BOOLEAN gfCharacterTraitQuestions[ IMP_CHARACTER_TRAITS_NUMBER ];
|
||||
BOOLEAN gfCharacterTraitQuestions[ 15 ];
|
||||
|
||||
// these are the buttons for the questions
|
||||
INT32 giIMPCharacterTraitAnswerButton[ IMP_CHARACTER_TRAITS_NUMBER ];
|
||||
INT32 giIMPCharacterTraitAnswerButtonImage[ IMP_CHARACTER_TRAITS_NUMBER ];
|
||||
INT32 giIMPCharacterTraitAnswerButton[ 15 ];
|
||||
INT32 giIMPCharacterTraitAnswerButtonImage[ 15 ];
|
||||
|
||||
// this is the Done buttons
|
||||
INT32 giIMPCharacterTraitFinsihButton;
|
||||
@@ -82,6 +76,8 @@ INT32 giIMPCharacterTraitFinsihButtonImage;
|
||||
//image handle
|
||||
UINT32 guiIST_GreyGoldBox2;
|
||||
|
||||
MOUSE_REGION gMR_CharacterTraitHelpTextRegions[IMP_NUMBER_CHARACTER_TRAITS];
|
||||
|
||||
//*******************************************************************
|
||||
//
|
||||
// Function Prototypes
|
||||
@@ -100,6 +96,7 @@ void IMPCharacterTraitDisplayCharacterTraits();
|
||||
//void HandleLastSelectedCharacterTraits( INT8 bNewTrait );
|
||||
BOOLEAN CameBackToCharacterTraitPageButNotFinished();
|
||||
//ppp
|
||||
void AssignCharacterTraitHelpText( UINT8 ubNumber );
|
||||
|
||||
//*******************************************************************
|
||||
//
|
||||
@@ -111,7 +108,7 @@ BOOLEAN CameBackToCharacterTraitPageButNotFinished();
|
||||
|
||||
void EnterIMPCharacterTrait( void )
|
||||
{
|
||||
// UINT32 uiCnt;
|
||||
// UINT32 ubCnt;
|
||||
VOBJECT_DESC VObjectDesc;
|
||||
|
||||
//add the skill trait buttons
|
||||
@@ -144,11 +141,36 @@ void EnterIMPCharacterTrait( void )
|
||||
if( iCurrentProfileMode != IMP__FINISH )
|
||||
{
|
||||
//Have the NONE trait initially selected
|
||||
gfCharacterTraitQuestions[ IMP_CHARACTER_TRAIT_NORMAL ] = TRUE;
|
||||
gfCharacterTraitQuestions[ 0 ] = TRUE;
|
||||
}
|
||||
|
||||
HandleCharacterTraitButtonStates( );
|
||||
|
||||
if ( gGameOptions.fNewTraitSystem )
|
||||
{
|
||||
// add regions for help texts
|
||||
UINT16 usPosX = IMP_CHARACTER_1ST_COLUMN_START_X + 62;
|
||||
UINT16 usPosY = IMP_CHARACTER_1ST_COLUMN_START_Y + 8;
|
||||
for( UINT8 ubCnt=0; ubCnt<(gGameOptions.fNewTraitSystem ? IMP_NUMBER_CHARACTER_TRAITS : IMP_NUMBER_ATTITUDES); ubCnt++ )
|
||||
{
|
||||
MSYS_DefineRegion( &gMR_CharacterTraitHelpTextRegions[ubCnt], ( usPosX ), ( usPosY ),
|
||||
(usPosX + 156), ( usPosY + 17), MSYS_PRIORITY_HIGH,
|
||||
MSYS_NO_CURSOR, MSYS_NO_CALLBACK, NULL );
|
||||
MSYS_AddRegion( &gMR_CharacterTraitHelpTextRegions[ubCnt] );
|
||||
|
||||
//Determine the next x location
|
||||
if( ubCnt < (gGameOptions.fNewTraitSystem ? 6 : 5) )
|
||||
usPosX = IMP_CHARACTER_1ST_COLUMN_START_X + 62;
|
||||
else
|
||||
usPosX = IMP_CHARACTER_2ND_COLUMN_START_X + 62;
|
||||
|
||||
//Determine the next Y location
|
||||
if( ubCnt == (gGameOptions.fNewTraitSystem ? 6 : 5) )
|
||||
usPosY = IMP_CHARACTER_2ND_COLUMN_START_Y + 8;
|
||||
else
|
||||
usPosY += IMP_CHARACTER_TRAIT__SPACE_BTN_BUTTONS;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -158,7 +180,10 @@ void RenderIMPCharacterTrait( void )
|
||||
RenderProfileBackGround();
|
||||
|
||||
//Display the title
|
||||
DrawTextToScreen( gzIMPCharacterTraitText[IMP_CHARACTER_TRAITS_NUMBER], LAPTOP_SCREEN_UL_X - 111, iScreenHeightOffset + 53, ( LAPTOP_SCREEN_LR_X - LAPTOP_SCREEN_UL_X ), FONT14ARIAL, FONT_MCOLOR_WHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
if ( gGameOptions.fNewTraitSystem )
|
||||
DrawTextToScreen( gzIMPCharacterTraitText[IMP_NUMBER_CHARACTER_TRAITS], LAPTOP_SCREEN_UL_X - 111, iScreenHeightOffset + 53, ( LAPTOP_SCREEN_LR_X - LAPTOP_SCREEN_UL_X ), FONT14ARIAL, FONT_MCOLOR_WHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
else
|
||||
DrawTextToScreen( gzIMPAttitudesText[IMP_NUMBER_ATTITUDES], LAPTOP_SCREEN_UL_X - 111, iScreenHeightOffset + 53, ( LAPTOP_SCREEN_LR_X - LAPTOP_SCREEN_UL_X ), FONT14ARIAL, FONT_MCOLOR_WHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
|
||||
IMPCharacterTraitDisplayCharacterTraits();
|
||||
}
|
||||
@@ -171,7 +196,7 @@ void ExitIMPCharacterTrait( void )
|
||||
DeleteVideoObjectFromIndex( guiIST_GreyGoldBox2 );
|
||||
|
||||
//remove the skill buttons
|
||||
for(iCnt = 0; iCnt < IMP_CHARACTER_TRAITS_NUMBER; iCnt++)
|
||||
for(iCnt = 0; iCnt < (gGameOptions.fNewTraitSystem ? IMP_NUMBER_CHARACTER_TRAITS : IMP_NUMBER_ATTITUDES); iCnt++)
|
||||
{
|
||||
//if there is a button allocated
|
||||
if( giIMPCharacterTraitAnswerButton[iCnt] != -1 )
|
||||
@@ -179,6 +204,9 @@ void ExitIMPCharacterTrait( void )
|
||||
RemoveButton(giIMPCharacterTraitAnswerButton[ iCnt ] );
|
||||
UnloadButtonImage(giIMPCharacterTraitAnswerButtonImage[ iCnt ] );
|
||||
}
|
||||
|
||||
if ( gGameOptions.fNewTraitSystem )
|
||||
MSYS_RemoveRegion( &gMR_CharacterTraitHelpTextRegions[iCnt] );
|
||||
}
|
||||
|
||||
RemoveButton( giIMPCharacterTraitFinsihButton );
|
||||
@@ -205,7 +233,7 @@ void AddImpCharacterTraitButtons()
|
||||
usPosX = IMP_CHARACTER_1ST_COLUMN_START_X;
|
||||
usPosY = IMP_CHARACTER_1ST_COLUMN_START_Y;
|
||||
|
||||
for(iCnt = 0; iCnt < IMP_CHARACTER_TRAITS_NUMBER; iCnt++)
|
||||
for(iCnt = 0; iCnt < (gGameOptions.fNewTraitSystem ? IMP_NUMBER_CHARACTER_TRAITS : IMP_NUMBER_ATTITUDES) ; iCnt++)
|
||||
{
|
||||
//reset
|
||||
giIMPCharacterTraitAnswerButton[iCnt] = -1;
|
||||
@@ -233,13 +261,13 @@ void AddImpCharacterTraitButtons()
|
||||
//ButtonList[ giIMPCharacterTraitAnswerButton[ iCnt ] ]->ubSoundSchemeID = 0;
|
||||
|
||||
//Determine the next x location
|
||||
if( iCnt < IMP_CHARACTER_TRAIT_NUMBER_TO_START_2ND_COLUMN )
|
||||
if( iCnt < (gGameOptions.fNewTraitSystem ? 6 : 5) )
|
||||
usPosX = IMP_CHARACTER_1ST_COLUMN_START_X;
|
||||
else
|
||||
usPosX = IMP_CHARACTER_2ND_COLUMN_START_X;
|
||||
|
||||
//Determine the next Y location
|
||||
if( iCnt == IMP_CHARACTER_TRAIT_NUMBER_TO_START_2ND_COLUMN )
|
||||
if( iCnt == (gGameOptions.fNewTraitSystem ? 6 : 5) )
|
||||
usPosY = IMP_CHARACTER_2ND_COLUMN_START_Y;
|
||||
else
|
||||
usPosY += IMP_CHARACTER_TRAIT__SPACE_BTN_BUTTONS;
|
||||
@@ -265,7 +293,7 @@ void BtnIMPCharacterTraitAnswerCallback(GUI_BUTTON *btn,INT32 reason)
|
||||
|
||||
void HandleIMPCharacterTraitAnswers( UINT32 uiSkillPressed )
|
||||
{
|
||||
UINT32 uiCnt;
|
||||
INT8 bCnt;
|
||||
|
||||
//if we are DONE and are just reviewing
|
||||
if( iCurrentProfileMode == IMP__FINISH )
|
||||
@@ -274,13 +302,13 @@ void HandleIMPCharacterTraitAnswers( UINT32 uiSkillPressed )
|
||||
}
|
||||
|
||||
//reset all other buttons
|
||||
for( uiCnt=0; uiCnt<IMP_CHARACTER_TRAITS_NUMBER; uiCnt++ )
|
||||
for( bCnt=0; bCnt < (gGameOptions.fNewTraitSystem ? IMP_NUMBER_CHARACTER_TRAITS : IMP_NUMBER_ATTITUDES); bCnt++ )
|
||||
{
|
||||
gfCharacterTraitQuestions[ uiCnt ] = FALSE;
|
||||
gfCharacterTraitQuestions[ bCnt ] = FALSE;
|
||||
}
|
||||
|
||||
//make sure its a valid character trait
|
||||
if( uiSkillPressed > IMP_CHARACTER_TRAITS_NUMBER )
|
||||
if( uiSkillPressed > (UINT32)(gGameOptions.fNewTraitSystem ? IMP_NUMBER_CHARACTER_TRAITS : IMP_NUMBER_ATTITUDES) )
|
||||
{
|
||||
Assert( 0 );
|
||||
return;
|
||||
@@ -315,26 +343,26 @@ void HandleIMPCharacterTraitAnswers( UINT32 uiSkillPressed )
|
||||
|
||||
void HandleCharacterTraitButtonStates( )
|
||||
{
|
||||
UINT32 uiCnt;
|
||||
INT8 bCnt;
|
||||
|
||||
for( uiCnt=0; uiCnt<IMP_CHARACTER_TRAITS_NUMBER; uiCnt++ )
|
||||
for( bCnt=0; bCnt < (gGameOptions.fNewTraitSystem ? IMP_NUMBER_CHARACTER_TRAITS : IMP_NUMBER_ATTITUDES); bCnt++ )
|
||||
{
|
||||
|
||||
//if the skill is selected ( ie depressed )
|
||||
if( gfCharacterTraitQuestions[ uiCnt ] )
|
||||
if( gfCharacterTraitQuestions[ bCnt ] )
|
||||
{
|
||||
ButtonList[ giIMPCharacterTraitAnswerButton[ uiCnt ] ]->uiFlags |= BUTTON_CLICKED_ON;
|
||||
ButtonList[ giIMPCharacterTraitAnswerButton[ bCnt ] ]->uiFlags |= BUTTON_CLICKED_ON;
|
||||
}
|
||||
else
|
||||
{
|
||||
ButtonList[ giIMPCharacterTraitAnswerButton[ uiCnt ] ]->uiFlags &= ~BUTTON_CLICKED_ON;
|
||||
ButtonList[ giIMPCharacterTraitAnswerButton[ bCnt ] ]->uiFlags &= ~BUTTON_CLICKED_ON;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void IMPCharacterTraitDisplayCharacterTraits()
|
||||
{
|
||||
UINT32 uiCnt;
|
||||
INT8 bCnt;
|
||||
UINT16 usPosX, usPosY;
|
||||
UINT16 usBoxPosX, usBoxPosY;
|
||||
HVOBJECT hImageHandle;
|
||||
@@ -345,13 +373,13 @@ void IMPCharacterTraitDisplayCharacterTraits()
|
||||
usPosX = IMP_CHARACTER_1ST_COLUMN_START_X + IMP_CHARACTER_TRAIT__TEXT_OFFSET_X;
|
||||
usPosY = IMP_CHARACTER_1ST_COLUMN_START_Y + IMP_CHARACTER_TRAIT__TEXT_OFFSET_Y;
|
||||
|
||||
for( uiCnt=0; uiCnt<IMP_CHARACTER_TRAITS_NUMBER; uiCnt++ )
|
||||
for( bCnt=0; bCnt<(gGameOptions.fNewTraitSystem ? IMP_NUMBER_CHARACTER_TRAITS : IMP_NUMBER_ATTITUDES); bCnt++ )
|
||||
{
|
||||
usBoxPosX = usPosX - IMP_CHARACTER_TRAIT__GREY_BOX_OFFSET_X;
|
||||
usBoxPosY = usPosY - IMP_CHARACTER_TRAIT__GREY_BOX_OFFSET_Y;
|
||||
|
||||
//if the trait is selected
|
||||
if( gfCharacterTraitQuestions[ uiCnt ] )
|
||||
if( gfCharacterTraitQuestions[ bCnt ] )
|
||||
{
|
||||
//Display the gold background box
|
||||
BltVideoObject(FRAME_BUFFER, hImageHandle, 1, usBoxPosX, usBoxPosY, VO_BLT_SRCTRANSPARENCY,NULL);
|
||||
@@ -363,16 +391,24 @@ void IMPCharacterTraitDisplayCharacterTraits()
|
||||
}
|
||||
|
||||
//draw the text to the screenx
|
||||
DrawTextToScreen( gzIMPCharacterTraitText[ uiCnt ], usPosX, usPosY, 0, IMP_CHARACTER_TRAIT__FONT, IMP_CHARACTER_TRAIT__COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED );
|
||||
if ( gGameOptions.fNewTraitSystem )
|
||||
DrawTextToScreen( gzIMPCharacterTraitText[ bCnt ], usPosX, usPosY, 0, IMP_CHARACTER_TRAIT__FONT, IMP_CHARACTER_TRAIT__COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED );
|
||||
else
|
||||
DrawTextToScreen( gzIMPAttitudesText[ bCnt ], usPosX, usPosY, 0, IMP_CHARACTER_TRAIT__FONT, IMP_CHARACTER_TRAIT__COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED );
|
||||
|
||||
if ( gGameOptions.fNewTraitSystem )
|
||||
{
|
||||
AssignCharacterTraitHelpText( bCnt );
|
||||
}
|
||||
|
||||
//Determine the next x location
|
||||
if( uiCnt < IMP_CHARACTER_TRAIT_NUMBER_TO_START_2ND_COLUMN )
|
||||
if( bCnt < (gGameOptions.fNewTraitSystem ? 6 : 5) )
|
||||
usPosX = IMP_CHARACTER_1ST_COLUMN_START_X + IMP_CHARACTER_TRAIT__TEXT_OFFSET_X;
|
||||
else
|
||||
usPosX = IMP_CHARACTER_2ND_COLUMN_START_X + IMP_CHARACTER_TRAIT__TEXT_OFFSET_X;
|
||||
|
||||
//Determine the next Y location
|
||||
if( uiCnt == IMP_CHARACTER_TRAIT_NUMBER_TO_START_2ND_COLUMN )
|
||||
if( bCnt == (gGameOptions.fNewTraitSystem ? 6 : 5) )
|
||||
usPosY = IMP_CHARACTER_2ND_COLUMN_START_Y + IMP_CHARACTER_TRAIT__TEXT_OFFSET_Y;
|
||||
else
|
||||
usPosY += IMP_CHARACTER_TRAIT__SPACE_BTN_BUTTONS;
|
||||
@@ -429,18 +465,32 @@ BOOLEAN CameBackToCharacterTraitPageButNotFinished()
|
||||
|
||||
INT8 iChosenCharacterTrait()
|
||||
{
|
||||
UINT32 uiCnt;
|
||||
INT8 bCnt;
|
||||
INT8 iCharacterTraitNumber = 0;
|
||||
|
||||
//loop through all the buttons and reset them
|
||||
for( uiCnt=0; uiCnt<IMP_CHARACTER_TRAITS_NUMBER; uiCnt++ )
|
||||
for( bCnt=0; bCnt<(gGameOptions.fNewTraitSystem ? IMP_NUMBER_CHARACTER_TRAITS : IMP_NUMBER_ATTITUDES); bCnt++ )
|
||||
{
|
||||
//if the trait is selected
|
||||
if( gfCharacterTraitQuestions[ uiCnt ] )
|
||||
if( gfCharacterTraitQuestions[ bCnt ] )
|
||||
{
|
||||
iCharacterTraitNumber = uiCnt;
|
||||
iCharacterTraitNumber = bCnt;
|
||||
}
|
||||
}
|
||||
return( iCharacterTraitNumber );
|
||||
}
|
||||
|
||||
|
||||
void AssignCharacterTraitHelpText( UINT8 ubNumber )
|
||||
{
|
||||
CHAR16 apStr[ 2000 ];
|
||||
|
||||
swprintf( apStr, L"" );
|
||||
swprintf( apStr, gzIMPNewCharacterTraitsHelpTexts[ubNumber] );
|
||||
|
||||
// Set region help text
|
||||
SetRegionFastHelpText( &(gMR_CharacterTraitHelpTextRegions[ubNumber]), apStr );
|
||||
SetRegionHelpEndCallback( &gMR_CharacterTraitHelpTextRegions[ubNumber], MSYS_NO_CALLBACK );
|
||||
|
||||
return;
|
||||
}
|
||||
@@ -10,23 +10,42 @@ void HandleIMPCharacterTrait( void );
|
||||
|
||||
//enum
|
||||
//{
|
||||
typedef enum
|
||||
{
|
||||
IMP_ATTITUDE_NORMAL = 0,
|
||||
IMP_ATTITUDE_FRIENDLY,
|
||||
IMP_ATTITUDE_LONER,
|
||||
IMP_ATTITUDE_OPTIMIST,
|
||||
IMP_ATTITUDE_PESSIMIST,
|
||||
IMP_ATTITUDE_AGGRESSIVE,
|
||||
IMP_ATTITUDE_ARROGANT,
|
||||
IMP_ATTITUDE_BIGSHOT,
|
||||
IMP_ATTITUDE_ASSHOLE,
|
||||
IMP_ATTITUDE_COWARD,
|
||||
IMP_NUMBER_ATTITUDES,
|
||||
};
|
||||
|
||||
typedef enum
|
||||
{
|
||||
IMP_CHARACTER_TRAIT_NORMAL = 0,
|
||||
IMP_CHARACTER_TRAIT_FRIENDLY,
|
||||
IMP_CHARACTER_TRAIT_SOCIABLE,
|
||||
IMP_CHARACTER_TRAIT_LONER,
|
||||
IMP_CHARACTER_TRAIT_OPTIMIST,
|
||||
IMP_CHARACTER_TRAIT_PESSIMIST,
|
||||
IMP_CHARACTER_TRAIT_ASSERTIVE,
|
||||
IMP_CHARACTER_TRAIT_INTELLECTUAL,
|
||||
IMP_CHARACTER_TRAIT_PRIMITIVE,
|
||||
IMP_CHARACTER_TRAIT_AGGRESSIVE,
|
||||
IMP_CHARACTER_TRAIT_ARROGANT,
|
||||
IMP_CHARACTER_TRAIT_BIGSHOT,
|
||||
IMP_CHARACTER_TRAIT_ASSHOLE,
|
||||
IMP_CHARACTER_TRAIT_COWARD,
|
||||
IMP_CHARACTER_TRAITS_NUMBER,
|
||||
} ;
|
||||
IMP_CHARACTER_TRAIT_PHLEGMATIC,
|
||||
IMP_CHARACTER_TRAIT_DAUNTLESS,
|
||||
IMP_CHARACTER_TRAIT_PACIFIST,
|
||||
IMP_CHARACTER_TRAIT_MALICIOUS,
|
||||
IMP_CHARACTER_TRAIT_SHOWOFF,
|
||||
IMP_NUMBER_CHARACTER_TRAITS,
|
||||
};
|
||||
|
||||
INT8 iChosenCharacterTrait();
|
||||
|
||||
STR16 gzIMPCharacterTraitText[];
|
||||
STR16 gzIMPAttitudesText[];
|
||||
|
||||
#endif
|
||||
|
||||
@@ -102,7 +102,7 @@ void WriteIMPCharacterAndDisabilityEntranceText( void )
|
||||
DisplayWrappedString( LAPTOP_SCREEN_UL_X + 106, LAPTOP_SCREEN_WEB_UL_Y + 63, ( 400 - 100 ), 2, FONT12ARIAL, FONT_WHITE, pCharacterTraitBeginIMPStrings[ 1 ],FONT_BLACK,FALSE,CENTER_JUSTIFIED);
|
||||
|
||||
// The disability part
|
||||
DisplayWrappedString( LAPTOP_SCREEN_UL_X + 106, LAPTOP_SCREEN_WEB_UL_Y + 145, ( 400 - 100 ), 2, FONT12ARIAL, FONT_WHITE, pCharacterTraitBeginIMPStrings[ 2 ],FONT_BLACK,FALSE,CENTER_JUSTIFIED);
|
||||
DisplayWrappedString( LAPTOP_SCREEN_UL_X + 106, LAPTOP_SCREEN_WEB_UL_Y + 148, ( 400 - 100 ), 2, FONT12ARIAL, FONT_WHITE, pCharacterTraitBeginIMPStrings[ 2 ],FONT_BLACK,FALSE,CENTER_JUSTIFIED);
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -23,8 +23,11 @@
|
||||
#include "IMP Begin Screen.h"
|
||||
#include "WCheck.h"
|
||||
#include "Animation Data.h"
|
||||
#include "GameSettings.h"
|
||||
#endif
|
||||
|
||||
#include "IMP Confirm.h"
|
||||
|
||||
enum
|
||||
{
|
||||
PINKSKIN,
|
||||
@@ -170,7 +173,7 @@ BOOLEAN gfIST_Redraw4=FALSE;
|
||||
BOOLEAN fReDrawColorScreenFlag;
|
||||
|
||||
BOOLEAN bBigBody;
|
||||
BOOLEAN bBadAss;
|
||||
BOOLEAN bBadAss = FALSE;
|
||||
|
||||
// these are the buttons for the arrows
|
||||
INT32 giIMPColorChoiceButton[ 11 ];
|
||||
@@ -224,8 +227,33 @@ void EnterIMPColorChoice( void )
|
||||
bBigBody = FALSE;
|
||||
bBadAss = FALSE;
|
||||
|
||||
if( fCharacterIsMale )
|
||||
{
|
||||
if ( gIMPMaleValues[ iPortraitNumber ].uiIndex == iPortraitNumber && gIMPMaleValues[ iPortraitNumber ].bSex == 0 )
|
||||
{
|
||||
iCurrentSkin = gIMPMaleValues[ iPortraitNumber ].iCurrentSkin;
|
||||
iCurrentHair = gIMPMaleValues[ iPortraitNumber ].iCurrentHair;
|
||||
iCurrentShirt = gIMPMaleValues[ iPortraitNumber ].iCurrentShirt;
|
||||
iCurrentPants = gIMPMaleValues[ iPortraitNumber ].iCurrentPants;
|
||||
bBigBody = gIMPMaleValues[ iPortraitNumber ].bBigBody;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
if ( gIMPFemaleValues[ iPortraitNumber ].uiIndex == iPortraitNumber && gIMPFemaleValues[ iPortraitNumber ].bSex == 1 )
|
||||
{
|
||||
iCurrentSkin = gIMPFemaleValues[ iPortraitNumber ].iCurrentSkin;
|
||||
iCurrentHair = gIMPFemaleValues[ iPortraitNumber ].iCurrentHair;
|
||||
iCurrentShirt = gIMPFemaleValues[ iPortraitNumber ].iCurrentShirt;
|
||||
iCurrentPants = gIMPFemaleValues[ iPortraitNumber ].iCurrentPants;
|
||||
bBigBody = gIMPFemaleValues[ iPortraitNumber ].bBigBody;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Based on the portrait chosen, set the default colors, when colors
|
||||
switch( iPortraitNumber )
|
||||
/* switch( iPortraitNumber )
|
||||
{
|
||||
case( 0 ):
|
||||
iCurrentSkin = 3;
|
||||
@@ -327,7 +355,7 @@ void EnterIMPColorChoice( void )
|
||||
iCurrentPants = 5;
|
||||
break;
|
||||
}
|
||||
|
||||
*/
|
||||
//add the buttons
|
||||
AddIMPColorChoiceButtons();
|
||||
|
||||
@@ -451,8 +479,8 @@ void ExitIMPColorChoice( void )
|
||||
|
||||
DeleteVideoObjectFromIndex( guiIST_GreyGoldBox4 );
|
||||
|
||||
//remove the skin buttons
|
||||
for(iCnt = 0; iCnt < ( fCharacterIsMale ? 11 : 8); iCnt++) // fix of bug, removing unasigned buttons when female
|
||||
//remove the buttons
|
||||
for(iCnt = 0; iCnt < ( fCharacterIsMale ? 11 : 8); iCnt++)
|
||||
{
|
||||
//if there is a button allocated
|
||||
if( giIMPColorChoiceButton[iCnt] != -1 )
|
||||
@@ -643,7 +671,16 @@ void AddIMPColorChoiceButtons()
|
||||
|
||||
MSYS_SetBtnUserData( giIMPColorChoiceButton[10], 0, 10 );
|
||||
SetButtonCursor( giIMPColorChoiceButton[10], CURSOR_WWW);
|
||||
SetButtonFastHelpText( giIMPColorChoiceButton[ 10 ], gzIMPColorChoosingText[4]);
|
||||
CHAR16 sBadAssHelpText[200];
|
||||
if( gGameOptions.fNewTraitSystem )
|
||||
{
|
||||
swprintf( sBadAssHelpText, L"%s%s", gzIMPColorChoosingText[4], gzIMPColorChoosingText[5]);
|
||||
}
|
||||
else
|
||||
{
|
||||
swprintf( sBadAssHelpText, L"%s", gzIMPColorChoosingText[4]);
|
||||
}
|
||||
SetButtonFastHelpText( giIMPColorChoiceButton[ 10 ], sBadAssHelpText );
|
||||
|
||||
|
||||
// Make respective button initialy pressed
|
||||
@@ -1150,4 +1187,12 @@ BOOLEAN bBadAssSelected()
|
||||
return( bBadAss );
|
||||
else
|
||||
return( FALSE );
|
||||
}
|
||||
|
||||
void SetBadAss( BOOLEAN fSetTrue )
|
||||
{
|
||||
if ( fSetTrue )
|
||||
bBadAss = TRUE;
|
||||
else
|
||||
bBadAss = FALSE;
|
||||
}
|
||||
@@ -17,4 +17,6 @@ INT8 iChosenPants();
|
||||
BOOLEAN bBigBodySelected();
|
||||
BOOLEAN bBadAssSelected();
|
||||
|
||||
void SetBadAss( BOOLEAN fSetTrue );
|
||||
|
||||
#endif
|
||||
|
||||
+179
-440
@@ -34,12 +34,15 @@
|
||||
#include "Animation Data.h"
|
||||
#include "random.h"
|
||||
#include "LaptopSave.h"
|
||||
// These 3 added - SANDRO
|
||||
// These 4 added - SANDRO
|
||||
#include "IMP Character Trait.h"
|
||||
#include "IMP Disability Trait.h"
|
||||
#include "IMP Color Choosing.h"
|
||||
#include "IMP Minor Trait.h"
|
||||
#endif
|
||||
|
||||
#include "IMP Confirm.h"
|
||||
|
||||
// how many times should a 'die' be rolled for skills of the same type?
|
||||
|
||||
#define HOW_MANY_ROLLS_FOR_SAME_SKILL_CHECK 20
|
||||
@@ -57,8 +60,9 @@ INT32 iLastElementInPersonalityList = 0;
|
||||
extern BOOLEAN fLoadingCharacterForPreviousImpProfile;
|
||||
|
||||
// positions of the face x and y for eyes and mouth for the 10 portraits
|
||||
INT16 sFacePositions[ NUMBER_OF_PLAYER_PORTRAITS ][ 4 ]=
|
||||
{
|
||||
|
||||
INT16 sFacePositions[ NUMBER_OF_PLAYER_PORTRAITS ][ 4 ];
|
||||
/*{
|
||||
{0,0,0,0},
|
||||
{0,0,0,0},
|
||||
{0,0,0,0},
|
||||
@@ -116,7 +120,7 @@ STR8 pPlayerSelectedBigFaceFileNames[ NUMBER_OF_PLAYER_PORTRAITS ]=
|
||||
"Faces\\BigFaces\\214.sti",
|
||||
"Faces\\BigFaces\\215.sti",
|
||||
};
|
||||
|
||||
*/
|
||||
|
||||
// function declarations
|
||||
void SelectMercFace( void );
|
||||
@@ -135,8 +139,6 @@ void CreateACharacterFromPlayerEnteredStats( void )
|
||||
// of changes and revisions that have been made to personalities and attitudes.
|
||||
CreatePlayersPersonalitySkillsAndAttitude();
|
||||
|
||||
|
||||
|
||||
// copy over full name
|
||||
wcscpy( gMercProfiles[ LaptopSaveInfo.iIMPIndex ].zName, pFullName );
|
||||
|
||||
@@ -174,10 +176,14 @@ void CreateACharacterFromPlayerEnteredStats( void )
|
||||
|
||||
|
||||
// personality
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].bPersonalityTrait = ( INT8 )iPersonality;
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].bDisability = ( INT8 )iPersonality;
|
||||
|
||||
// attitude
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].bAttitude = ( INT8 )iAttitude;
|
||||
// SANDRO - decide here, if we use the default attitude or the new so called Character Trait for new traits
|
||||
if ( gGameOptions.fNewTraitSystem)
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].bCharacterTrait = ( INT8 )iAttitude;
|
||||
else
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].bAttitude = ( INT8 )iAttitude;
|
||||
|
||||
// WDS: Advanced start
|
||||
//gMercProfiles[ LaptopSaveInfo.iIMPIndex ].bExpLevel = gGameExternalOptions.ubIMPStartingLevel;
|
||||
@@ -222,7 +228,7 @@ BOOLEAN DoesCharacterHaveAPersoanlity( void )
|
||||
{
|
||||
|
||||
|
||||
if( iPersonality != NO_PERSONALITYTRAIT )
|
||||
if( iPersonality != NO_DISABILITY )
|
||||
{
|
||||
// yep
|
||||
return ( TRUE );
|
||||
@@ -242,7 +248,7 @@ BOOLEAN DoesCharacterHaveAPersoanlity( void )
|
||||
return( FALSE );
|
||||
|
||||
// simply checks if caracter has a personality other than normal
|
||||
if( iPersonality != NO_PERSONALITYTRAIT )
|
||||
if( iPersonality != NO_DISABILITY )
|
||||
{
|
||||
// yep
|
||||
return ( TRUE );
|
||||
@@ -259,86 +265,8 @@ BOOLEAN DoesCharacterHaveAPersoanlity( void )
|
||||
|
||||
void CreatePlayerAttitude( void )
|
||||
{
|
||||
// We no longer need this - SANDRO
|
||||
/*if(gGameSettings.fOptions[TOPTION_USE_RANDOM_PERSONALITY] == TRUE)
|
||||
{
|
||||
AddAnAttitudeToAttitudeList( ATT_OPTIMIST );
|
||||
AddAnAttitudeToAttitudeList( ATT_LONER );
|
||||
AddAnAttitudeToAttitudeList( ATT_FRIENDLY );
|
||||
AddAnAttitudeToAttitudeList( ATT_ARROGANT );
|
||||
AddAnAttitudeToAttitudeList( ATT_NORMAL );
|
||||
AddAnAttitudeToAttitudeList( ATT_ASSHOLE );
|
||||
AddAnAttitudeToAttitudeList( ATT_COWARD );
|
||||
AddAnAttitudeToAttitudeList( ATT_AGGRESSIVE );
|
||||
AddAnAttitudeToAttitudeList( ATT_PESSIMIST );
|
||||
AddAnAttitudeToAttitudeList( ATT_BIG_SHOT );
|
||||
// DLETED UNUSED PART OF THE CODE - SANDRO
|
||||
|
||||
// this function will 'roll a die' and decide if any attitude does exists
|
||||
INT32 iDiceValue = 0;
|
||||
INT32 iCounter = 0, iCounter2 = 0;
|
||||
|
||||
INT32 iAttitudeHits[NUM_ATTITUDES] = { 0 };
|
||||
INT32 iHighestHits = 0;
|
||||
INT32 iNumAttitudesWithHighestHits = 0;
|
||||
|
||||
iAttitude = ATT_NORMAL;
|
||||
|
||||
if ( iLastElementInAttitudeList == 0 )
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
// count # of hits for each attitude
|
||||
for ( iCounter = 0; iCounter < iLastElementInAttitudeList; iCounter++ )
|
||||
{
|
||||
iAttitudeHits[ AttitudeList[ iCounter ] ]++;
|
||||
}
|
||||
|
||||
// find highest # of hits for any attitude
|
||||
for ( iCounter = 0; iCounter < NUM_ATTITUDES; iCounter++ )
|
||||
{
|
||||
if ( iAttitudeHits[ iCounter ] )
|
||||
{
|
||||
if ( iAttitudeHits[ iCounter ] > iHighestHits )
|
||||
{
|
||||
iHighestHits = __max( iHighestHits, iAttitudeHits[ iCounter ] );
|
||||
iNumAttitudesWithHighestHits = 1;
|
||||
}
|
||||
else if ( iAttitudeHits[ iCounter ] == iHighestHits )
|
||||
{
|
||||
iNumAttitudesWithHighestHits++;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// roll dice
|
||||
iDiceValue = Random( iNumAttitudesWithHighestHits + 1 );
|
||||
|
||||
// find attitude
|
||||
for ( iCounter = 0; iCounter < NUM_ATTITUDES; iCounter++ )
|
||||
{
|
||||
if ( iAttitudeHits[ iCounter ] == iHighestHits )
|
||||
{
|
||||
if ( iCounter2 == iDiceValue )
|
||||
{
|
||||
// this is it!
|
||||
iAttitude = iCounter2;
|
||||
break;
|
||||
}
|
||||
else
|
||||
{
|
||||
// one of the next attitudes...
|
||||
iCounter2++;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
iAttitude = gGameExternalOptions.iCustomAttitude;
|
||||
}*/
|
||||
|
||||
// Chosen by ourselves - SANDRO
|
||||
iAttitude = iChosenCharacterTrait();
|
||||
}
|
||||
|
||||
@@ -382,7 +310,7 @@ void ClearAllSkillsList( void )
|
||||
{
|
||||
INT32 iLoop;
|
||||
|
||||
for ( iLoop = 0; iLoop < iLastElementInSkillsList; iLoop++ )
|
||||
for ( iLoop = 0; iLoop < ATTITUDE_LIST_SIZE; iLoop++ ) // SANDRO - better clear everything to be sure
|
||||
{
|
||||
SkillsList[ iLoop ] = 0;
|
||||
}
|
||||
@@ -445,132 +373,113 @@ void ValidateSkillsList( void )
|
||||
if ( pProfile->bMechanical == 0 )
|
||||
{
|
||||
// without mechanical, electronics is useless
|
||||
iIndex = FindSkillInSkillsList( ELECTRONICS );
|
||||
if ( iIndex != -1 )
|
||||
// Electronics/Technician check - SANDRO
|
||||
if ( gGameOptions.fNewTraitSystem )
|
||||
{
|
||||
pProfile->bMechanical = 1;
|
||||
iIndex = FindSkillInSkillsList( TECHNICIAN_NT );
|
||||
if ( iIndex != -1 )
|
||||
pProfile->bMechanical = 1;
|
||||
}
|
||||
else
|
||||
{
|
||||
iIndex = FindSkillInSkillsList( ELECTRONICS_OT );
|
||||
if ( iIndex != -1 )
|
||||
pProfile->bMechanical = 1;
|
||||
|
||||
iIndex = FindSkillInSkillsList( LOCKPICKING_OT );
|
||||
if ( iIndex != -1 )
|
||||
pProfile->bMechanical = 1;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Kaiden using UB's code, lockpicking can't be removed from the list "yet".
|
||||
// special check for lockpicking
|
||||
//iValue = pProfile->bMechanical;
|
||||
//iValue = ( iValue * pProfile->bWisdom ) / 100;
|
||||
//iValue = ( iValue * pProfile->bDexterity ) / 100;
|
||||
//if ( iValue + gbSkillTraitBonus[ LOCKPICKING ] < 50 )
|
||||
//{
|
||||
// // not good enough for lockpicking!
|
||||
//
|
||||
// // so is lockpicking
|
||||
// iIndex = FindSkillInSkillsList( LOCKPICKING );
|
||||
// while ( iIndex != -1 )
|
||||
// {
|
||||
// RemoveSkillFromSkillsList( iIndex );
|
||||
// iIndex = FindSkillInSkillsList( LOCKPICKING );
|
||||
// }
|
||||
//}
|
||||
// SANDRO - added to give 1 medical skill to doctors
|
||||
if ( pProfile->bMedical == 0 && gGameOptions.fNewTraitSystem )
|
||||
{
|
||||
// without medical, Doctor trait is useless
|
||||
iIndex = FindSkillInSkillsList( DOCTOR_NT );
|
||||
if ( iIndex != -1 )
|
||||
pProfile->bMedical = 1;
|
||||
}
|
||||
|
||||
// SANDRO - added to give 1 explosive skill to dmolitions
|
||||
if ( pProfile->bExplosive == 0 && gGameOptions.fNewTraitSystem )
|
||||
{
|
||||
iIndex = FindSkillInSkillsList( DEMOLITIONS_NT );
|
||||
if ( iIndex != -1 )
|
||||
pProfile->bExplosive = 1;
|
||||
}
|
||||
|
||||
// SANDRO - added to give 1 Leadership skill to Squadleaders
|
||||
if ( pProfile->bLeadership == 0 && gGameOptions.fNewTraitSystem )
|
||||
{
|
||||
// without medical, Doctor trait is useless
|
||||
iIndex = FindSkillInSkillsList( SQUADLEADER_NT );
|
||||
if ( iIndex != -1 )
|
||||
pProfile->bLeadership = 1;
|
||||
}
|
||||
|
||||
if ( pProfile->bMarksmanship == 0 )
|
||||
{
|
||||
// without marksmanship, the following traits are useless:
|
||||
// auto weapons, heavy weapons
|
||||
iIndex = FindSkillInSkillsList( AUTO_WEAPS );
|
||||
if( iIndex != -1 )
|
||||
// auto weapons, heavy weapons, sniper, ranger, gunslinger
|
||||
|
||||
if ( gGameOptions.fNewTraitSystem ) // old/new traits - SANDRO
|
||||
{
|
||||
//RemoveSkillFromSkillsList( iIndex );
|
||||
//iIndex = FindSkillInSkillsList( AUTO_WEAPS );
|
||||
pProfile->bMarksmanship = 1;
|
||||
iIndex = FindSkillInSkillsList( AUTO_WEAPONS_NT );
|
||||
if( iIndex != -1 )
|
||||
pProfile->bMarksmanship = 1;
|
||||
|
||||
iIndex = FindSkillInSkillsList( HEAVY_WEAPONS_NT );
|
||||
if( iIndex != -1 )
|
||||
pProfile->bMarksmanship = 1;
|
||||
|
||||
iIndex = FindSkillInSkillsList( SNIPER_NT );
|
||||
if( iIndex != -1 )
|
||||
pProfile->bMarksmanship = 1;
|
||||
|
||||
iIndex = FindSkillInSkillsList( RANGER_NT );
|
||||
if( iIndex != -1 )
|
||||
pProfile->bMarksmanship = 1;
|
||||
|
||||
iIndex = FindSkillInSkillsList( GUNSLINGER_NT );
|
||||
if( iIndex != -1 )
|
||||
pProfile->bMarksmanship = 1;
|
||||
}
|
||||
// so is lockpicking
|
||||
iIndex = FindSkillInSkillsList( HEAVY_WEAPS );
|
||||
if( iIndex != -1 )
|
||||
else
|
||||
{
|
||||
//RemoveSkillFromSkillsList( iIndex );
|
||||
//iIndex = FindSkillInSkillsList( HEAVY_WEAPS );
|
||||
pProfile->bMarksmanship = 1;
|
||||
iIndex = FindSkillInSkillsList( AUTO_WEAPS_OT );
|
||||
if( iIndex != -1 )
|
||||
{
|
||||
//RemoveSkillFromSkillsList( iIndex );
|
||||
//iIndex = FindSkillInSkillsList( AUTO_WEAPS_OT );
|
||||
pProfile->bMarksmanship = 1;
|
||||
}
|
||||
iIndex = FindSkillInSkillsList( HEAVY_WEAPS_OT );
|
||||
if( iIndex != -1 )
|
||||
{
|
||||
//RemoveSkillFromSkillsList( iIndex );
|
||||
//iIndex = FindSkillInSkillsList( HEAVY_WEAPONS_NT );
|
||||
pProfile->bMarksmanship = 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void CreatePlayerSkills( void )
|
||||
{
|
||||
|
||||
// this function will 'roll a die' and decide if any attitude does exists
|
||||
INT32 iDiceValue = 0;
|
||||
|
||||
ValidateSkillsList();
|
||||
/* Kaiden - Commented out in UB to skip the whole random skill thing
|
||||
// roll dice
|
||||
iDiceValue = Random( iLastElementInSkillsList );
|
||||
|
||||
// set attitude
|
||||
iSkillA = SkillsList[ iDiceValue ];
|
||||
|
||||
// second dice value
|
||||
iDiceValue = Random( iLastElementInSkillsList );
|
||||
|
||||
iSkillB = SkillsList[ iDiceValue ];
|
||||
*/
|
||||
|
||||
// Kaiden: This section was added in it's place:
|
||||
// Kaiden: This section was added in it's place:
|
||||
// SANDRO - Note: this is actually used only for old trait system
|
||||
if( iLastElementInSkillsList > 0 )
|
||||
{
|
||||
// set attitude
|
||||
iSkillA = SkillsList[ 0 ];
|
||||
}
|
||||
|
||||
if( iLastElementInSkillsList > 1 )
|
||||
{
|
||||
iSkillB = SkillsList[ 1 ];
|
||||
}
|
||||
else
|
||||
{
|
||||
iSkillB = SkillsList[ 0 ];
|
||||
}
|
||||
|
||||
// allow expert level for generated merc so you CAN have two of the same
|
||||
// but there is no such thing as expert level for electronics
|
||||
|
||||
|
||||
while ( iSkillA == iSkillB && ( iSkillB == ELECTRONICS || iSkillB == AMBIDEXT ) )
|
||||
{
|
||||
// remove electronics as an option and roll again
|
||||
RemoveSkillFromSkillsList( iDiceValue );
|
||||
if ( iLastElementInSkillsList == 0 )
|
||||
{
|
||||
// ok, only one trait!
|
||||
iSkillB = NO_SKILLTRAIT;
|
||||
break;
|
||||
}
|
||||
else
|
||||
{
|
||||
iDiceValue = Random( iLastElementInSkillsList );
|
||||
iSkillB = SkillsList[ iDiceValue ];
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
// are the same,
|
||||
// reroll until different, or until ATTITUDE_LIST_SIZE times
|
||||
iSkillB = Random( iLastElementInSkillsList + 1 );
|
||||
|
||||
while( (iSkillA == iSkillB ) && ( iCounter < HOW_MANY_ROLLS_FOR_SAME_SKILL_CHECK ) )
|
||||
{
|
||||
// increment counter
|
||||
iCounter++;
|
||||
|
||||
// next random
|
||||
iSkillB = Random( iLastElementInSkillsList + 1 );
|
||||
|
||||
}
|
||||
if( iCounter == ATTITUDE_LIST_SIZE )
|
||||
{
|
||||
iSkillB = NO_SKILLTRAIT;
|
||||
}
|
||||
return;
|
||||
|
||||
|
||||
*/
|
||||
}
|
||||
|
||||
|
||||
@@ -604,82 +513,15 @@ void AddAPersonalityToPersonalityList( INT8 bPersonlity )
|
||||
|
||||
void CreatePlayerPersonality( void )
|
||||
{
|
||||
// DELETED UNUSED PART OF THE CODE - SANDRO
|
||||
|
||||
// Kaiden: Added for optional Mercenary personalities and attitudes
|
||||
// We don't need this - SANDRO
|
||||
/*if(gGameSettings.fOptions[TOPTION_USE_RANDOM_PERSONALITY] == TRUE)
|
||||
{
|
||||
// Kaiden: More chances for Psycho and Normal.
|
||||
AddAPersonalityToPersonalityList( NO_PERSONALITYTRAIT );
|
||||
AddAPersonalityToPersonalityList( PSYCHO );
|
||||
AddAPersonalityToPersonalityList( FORGETFUL );
|
||||
AddAPersonalityToPersonalityList( NERVOUS );
|
||||
AddAPersonalityToPersonalityList( HEAT_INTOLERANT );
|
||||
AddAPersonalityToPersonalityList( NO_PERSONALITYTRAIT );
|
||||
AddAPersonalityToPersonalityList( PSYCHO );
|
||||
AddAPersonalityToPersonalityList( CLAUSTROPHOBIC );
|
||||
AddAPersonalityToPersonalityList( NONSWIMMER );
|
||||
AddAPersonalityToPersonalityList( FEAR_OF_INSECTS );
|
||||
AddAPersonalityToPersonalityList( NO_PERSONALITYTRAIT );
|
||||
AddAPersonalityToPersonalityList( PSYCHO );
|
||||
AddAPersonalityToPersonalityList( FORGETFUL );
|
||||
AddAPersonalityToPersonalityList( NERVOUS );
|
||||
AddAPersonalityToPersonalityList( HEAT_INTOLERANT );
|
||||
AddAPersonalityToPersonalityList( NO_PERSONALITYTRAIT );
|
||||
AddAPersonalityToPersonalityList( PSYCHO );
|
||||
AddAPersonalityToPersonalityList( CLAUSTROPHOBIC );
|
||||
AddAPersonalityToPersonalityList( NONSWIMMER );
|
||||
AddAPersonalityToPersonalityList( FEAR_OF_INSECTS );
|
||||
|
||||
|
||||
INT32 iDiceValue = 0;
|
||||
INT32 iCounter = 0;
|
||||
INT32 iCounter2 = 0;
|
||||
|
||||
// Kaiden: Roll dice 20 times just to be on the safe side
|
||||
// was getting too many repeats. Will end up scrapping
|
||||
// rand() later anyway so will worry about fixing it then.
|
||||
for (iCounter2 = 0; iCounter2 < 20; iCounter2++)
|
||||
{
|
||||
iDiceValue = Random( iLastElementInPersonalityList + 1 );
|
||||
}
|
||||
|
||||
// Kaiden two chances to avoid a normal personality. As IMP
|
||||
// says, They check it twice just to make sure :p
|
||||
for( iCounter = 0; iCounter < iLastElementInPersonalityList; iCounter++ )
|
||||
{
|
||||
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("iDiceValue = %d",iDiceValue));
|
||||
|
||||
if( PersonalityList[ iDiceValue ] == NO_PERSONALITYTRAIT )
|
||||
{
|
||||
//Kaiden: Roll one more time for good measure:
|
||||
iDiceValue = Random( iLastElementInPersonalityList + 1 );
|
||||
}
|
||||
}
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("And our Personality is... = %d",PersonalityList[ iDiceValue ]));
|
||||
iPersonality = PersonalityList[ iDiceValue ];
|
||||
}
|
||||
else
|
||||
{
|
||||
iPersonality = gGameExternalOptions.iCustomPersonality;
|
||||
}*/
|
||||
|
||||
// Chosen by ourselves - SANDRO
|
||||
iPersonality = iChosenDisabilityTrait();
|
||||
|
||||
|
||||
return;
|
||||
|
||||
}
|
||||
|
||||
|
||||
void CreatePlayersPersonalitySkillsAndAttitude( void )
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
// creates personality, skills and attitudes from curretly built list
|
||||
|
||||
// personality
|
||||
@@ -731,12 +573,52 @@ void ResetIncrementCharacterAttributes( void )
|
||||
|
||||
void SelectMercFace( void )
|
||||
{
|
||||
/*
|
||||
UINT32 cnt;
|
||||
|
||||
for ( cnt = 0; cnt < MAX_NEW_IMP_PORTRAITS; cnt++ )
|
||||
{
|
||||
sFacePositions[ cnt ][ 0 ] = 0;
|
||||
sFacePositions[ cnt ][ 1 ] = 0;
|
||||
sFacePositions[ cnt ][ 2 ] = 0;
|
||||
sFacePositions[ cnt ][ 3 ] = 0;
|
||||
}
|
||||
*/
|
||||
// this procedure will select the approriate face for the merc and save offsets
|
||||
|
||||
// grab face filename
|
||||
// strcpy( gMercProfiles[ LaptopSaveInfo.iIMPIndex ].ubUnusedFaceFileName , pPlayerSelectedFaceFileNames[ iPortraitNumber ]);
|
||||
|
||||
|
||||
if( fCharacterIsMale )
|
||||
{
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].ubFaceIndex = 200 + ( UINT8 )iPortraitNumber;
|
||||
|
||||
// eyes
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].usEyesX = sFacePositions[ gIMPMaleValues[iPortraitNumber].uiEyeXPositions ][ 0 ];
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].usEyesY = sFacePositions[ gIMPMaleValues[iPortraitNumber].uiEyeYPositions ][ 1 ];
|
||||
|
||||
// mouth
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].usMouthX = sFacePositions[ gIMPMaleValues[iPortraitNumber].uiMouthXPositions ][ 2 ];
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].usMouthY = sFacePositions[ gIMPMaleValues[iPortraitNumber].uiMouthYPositions ][ 3 ];
|
||||
}
|
||||
else
|
||||
{
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].ubFaceIndex = 200 + ( UINT8 )iPortraitNumber;
|
||||
|
||||
// eyes
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].usEyesX = sFacePositions[ gIMPFemaleValues[iPortraitNumber].uiEyeXPositions ][ 0 ];
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].usEyesY = sFacePositions[ gIMPFemaleValues[iPortraitNumber].uiEyeYPositions ][ 1 ];
|
||||
|
||||
// mouth
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].usMouthX = sFacePositions[ gIMPFemaleValues[iPortraitNumber].uiMouthXPositions ][ 2 ];
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].usMouthY = sFacePositions[ gIMPFemaleValues[iPortraitNumber].uiMouthYPositions ][ 3 ];
|
||||
|
||||
|
||||
}
|
||||
|
||||
// now the offsets
|
||||
/*
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].ubFaceIndex = 200 + ( UINT8 )iPortraitNumber;
|
||||
|
||||
// eyes
|
||||
@@ -746,7 +628,7 @@ void SelectMercFace( void )
|
||||
// mouth
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].usMouthX = sFacePositions[ iPortraitNumber ][ 2 ];
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].usMouthY = sFacePositions[ iPortraitNumber ][ 3 ];
|
||||
|
||||
*/
|
||||
// set merc skins and hair color
|
||||
SetMercSkinAndHairColors( );
|
||||
return;
|
||||
@@ -754,40 +636,7 @@ void SelectMercFace( void )
|
||||
|
||||
void SetMercSkinAndHairColors( void )
|
||||
{
|
||||
// We don't need this - SANDRO
|
||||
/*enum{ PINKSKIN, TANSKIN, DARKSKIN, BLACKSKIN, NUMSKINS };
|
||||
enum{ BROWNHEAD, BLACKHEAD, //black skin (only this line )
|
||||
WHITEHEAD, //dark skin (this line plus all above)
|
||||
BLONDHEAD, REDHEAD, //pink/tan skin (this line plus all above )
|
||||
NUMHEADS
|
||||
};
|
||||
|
||||
enum
|
||||
{
|
||||
WHITEVEST,
|
||||
GYELLOWSHIRT,
|
||||
YELLOWVEST,
|
||||
GREYVEST,
|
||||
BROWNVEST,
|
||||
PURPLESHIRT,
|
||||
BLUEVEST,
|
||||
JEANVEST,
|
||||
GREENVEST,
|
||||
REDVEST,
|
||||
BLACKSHIRT,
|
||||
NUMSHIRTS
|
||||
};//shirts
|
||||
|
||||
enum
|
||||
{
|
||||
BLUEPANTS,
|
||||
BLACKPANTS,
|
||||
JEANPANTS,
|
||||
TANPANTS,
|
||||
BEIGEPANTS,
|
||||
GREENPANTS,
|
||||
NUMPANTS
|
||||
};//pants*/
|
||||
// DELETED UNUSED PART OF THE CODE - SANDRO
|
||||
|
||||
// skin strings
|
||||
STR sSkinStrings[]={
|
||||
@@ -832,117 +681,8 @@ void SetMercSkinAndHairColors( void )
|
||||
"GREENPANTS",
|
||||
};//pants
|
||||
|
||||
// We don't need this - SANDRO
|
||||
// given the portrait number, set the merc's skin and hair color
|
||||
/*INT16 sSkinColor = 0, sHairColor = 0, sShirtColor, sPantColor;
|
||||
// DELETED UNUSED PART OF THE CODE - SANDRO
|
||||
|
||||
switch( iPortraitNumber )
|
||||
{
|
||||
case( 0 ):
|
||||
sSkinColor = BLACKSKIN;
|
||||
sHairColor = BROWNHEAD;
|
||||
sShirtColor = JEANVEST;
|
||||
sPantColor = JEANPANTS;
|
||||
break;
|
||||
case( 1 ):
|
||||
sSkinColor = TANSKIN;
|
||||
sHairColor = BROWNHEAD;
|
||||
sShirtColor = BROWNVEST;
|
||||
sPantColor = TANPANTS;
|
||||
break;
|
||||
case( 2 ):
|
||||
sSkinColor = TANSKIN;
|
||||
sHairColor = BROWNHEAD;
|
||||
sShirtColor = WHITEVEST;
|
||||
sPantColor = BLUEPANTS;
|
||||
break;
|
||||
case( 3 ):
|
||||
sSkinColor = DARKSKIN;
|
||||
sHairColor = BROWNHEAD;
|
||||
sShirtColor = WHITEVEST;
|
||||
sPantColor = BLACKPANTS;
|
||||
break;
|
||||
case( 4 ):
|
||||
sSkinColor = TANSKIN;
|
||||
sHairColor = BROWNHEAD;
|
||||
sShirtColor = GREYVEST;
|
||||
sPantColor = GREENPANTS;
|
||||
break;
|
||||
case( 5 ):
|
||||
sSkinColor = DARKSKIN;
|
||||
sHairColor = BLACKHEAD;
|
||||
sShirtColor = GREYVEST;
|
||||
sPantColor = BLACKPANTS;
|
||||
break;
|
||||
case( 6 ):
|
||||
sSkinColor = TANSKIN;
|
||||
sHairColor = BROWNHEAD;
|
||||
sShirtColor = BROWNVEST;
|
||||
sPantColor = BLUEPANTS;
|
||||
break;
|
||||
case( 7 ):
|
||||
sSkinColor = TANSKIN;
|
||||
sHairColor = BROWNHEAD;
|
||||
sShirtColor = BLACKSHIRT;
|
||||
sPantColor = BLACKPANTS;
|
||||
break;
|
||||
case( 8 ):
|
||||
sSkinColor = TANSKIN;
|
||||
sHairColor = BROWNHEAD;
|
||||
sShirtColor = BROWNVEST;
|
||||
sPantColor = TANPANTS;
|
||||
break;
|
||||
case( 9 ):
|
||||
sSkinColor = PINKSKIN;
|
||||
sHairColor = BROWNHEAD;
|
||||
sShirtColor = BROWNVEST;
|
||||
sPantColor = BEIGEPANTS;
|
||||
break;
|
||||
case( 10 ):
|
||||
sSkinColor = TANSKIN;
|
||||
sHairColor = BLACKHEAD;
|
||||
sShirtColor = BROWNVEST;
|
||||
sPantColor = BLACKPANTS;
|
||||
break;
|
||||
case( 11 ):
|
||||
sSkinColor = TANSKIN;
|
||||
sHairColor = BLACKHEAD;
|
||||
sShirtColor = BLACKSHIRT;
|
||||
sPantColor = BLACKPANTS;
|
||||
break;
|
||||
case( 12 ):
|
||||
sSkinColor = PINKSKIN;
|
||||
sHairColor = BROWNHEAD;
|
||||
sShirtColor = WHITEVEST;
|
||||
sPantColor = GREENPANTS;
|
||||
break;
|
||||
case( 13 ):
|
||||
sSkinColor = BLACKSKIN;
|
||||
sHairColor = BROWNHEAD;
|
||||
sShirtColor = GREYVEST;
|
||||
sPantColor = BLACKPANTS;
|
||||
break;
|
||||
case( 14 ):
|
||||
sSkinColor = TANSKIN;
|
||||
sHairColor = REDHEAD;
|
||||
sShirtColor = WHITEVEST;
|
||||
sPantColor = JEANPANTS;
|
||||
break;
|
||||
case( 15 ):
|
||||
sSkinColor = TANSKIN;
|
||||
sHairColor = BLONDHEAD;
|
||||
sShirtColor = BROWNVEST;
|
||||
sPantColor = GREENPANTS;
|
||||
break;
|
||||
}
|
||||
|
||||
// now set them
|
||||
strcpy( gMercProfiles[ LaptopSaveInfo.iIMPIndex ].HAIR, sHairStrings[ sHairColor ] );
|
||||
strcpy( gMercProfiles[ LaptopSaveInfo.iIMPIndex ].SKIN, sSkinStrings[ sSkinColor ] );
|
||||
strcpy( gMercProfiles[ LaptopSaveInfo.iIMPIndex ].PANTS, sPantStrings[ sPantColor ] );
|
||||
strcpy( gMercProfiles[ LaptopSaveInfo.iIMPIndex ].VEST, sShirtStrings[ sShirtColor ] );*/
|
||||
|
||||
// Cosen colors by ourselves - SANDRO
|
||||
strcpy( gMercProfiles[ LaptopSaveInfo.iIMPIndex ].HAIR, sHairStrings[ iChosenHair() ] );
|
||||
strcpy( gMercProfiles[ LaptopSaveInfo.iIMPIndex ].SKIN, sSkinStrings[ iChosenSkin() ] );
|
||||
strcpy( gMercProfiles[ LaptopSaveInfo.iIMPIndex ].PANTS, sPantStrings[ iChosenPants() ] );
|
||||
@@ -957,9 +697,12 @@ void HandleMercStatsForChangesInFace( )
|
||||
return;
|
||||
}
|
||||
|
||||
//add the skills to the skills list
|
||||
//add the skills (major) to the skills list
|
||||
AddSelectedSkillsToSkillsList();
|
||||
|
||||
if ( gGameOptions.fNewTraitSystem ) // SANDRO - add also minor traits
|
||||
AddSelectedMinorTraitsToSkillsList();
|
||||
|
||||
// now figure out skills
|
||||
CreatePlayerSkills();
|
||||
|
||||
@@ -969,60 +712,56 @@ void HandleMercStatsForChangesInFace( )
|
||||
// male
|
||||
// big or regular
|
||||
// Madd - don't override the skills - override the body type instead
|
||||
if( ShouldThisMercHaveABigBody() && iSkillA != MARTIALARTS && iSkillB != MARTIALARTS )
|
||||
// this should not happen any more, we don't even offer the martial arts to big mercs - SANDRO
|
||||
//if( ShouldThisMercHaveABigBody() && iSkillA != MARTIALARTS_OT && iSkillB != MARTIALARTS_OT )
|
||||
if( ShouldThisMercHaveABigBody() ) // still added a safety check - SANDRO
|
||||
{
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].ubBodyType = BIGMALE;
|
||||
if (!gGameOptions.fNewTraitSystem) // SANDRO - traits
|
||||
{
|
||||
if (iSkillA == MARTIALARTS_OT )
|
||||
iSkillA = HANDTOHAND_OT;
|
||||
if (iSkillB == MARTIALARTS_OT )
|
||||
iSkillB = HANDTOHAND_OT;
|
||||
}
|
||||
|
||||
//if( iSkillA == MARTIALARTS )
|
||||
//{
|
||||
// iSkillA = HANDTOHAND;
|
||||
//}
|
||||
//if( iSkillB == MARTIALARTS )
|
||||
//{
|
||||
// iSkillB = HANDTOHAND;
|
||||
//}
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].ubBodyType = BIGMALE;
|
||||
}
|
||||
else
|
||||
{
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].ubBodyType = REGMALE;
|
||||
}
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].ubBodyType = REGMALE;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// female
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].ubBodyType = REGFEMALE;
|
||||
// female
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].ubBodyType = REGFEMALE;
|
||||
|
||||
if( iSkillA == MARTIALARTS )
|
||||
if (!gGameOptions.fNewTraitSystem) // SANDRO - traits
|
||||
{
|
||||
iSkillA = HANDTOHAND;
|
||||
}
|
||||
if( iSkillB == MARTIALARTS )
|
||||
{
|
||||
iSkillB = HANDTOHAND;
|
||||
if( iSkillA == MARTIALARTS_OT )
|
||||
iSkillA = HANDTOHAND_OT;
|
||||
if( iSkillB == MARTIALARTS_OT )
|
||||
iSkillB = HANDTOHAND_OT;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// skill trait
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].bSkillTrait = ( INT8 )iSkillA;
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].bSkillTrait2 = ( INT8 )iSkillB;
|
||||
|
||||
if (gGameOptions.fNewTraitSystem)
|
||||
{
|
||||
for ( UINT8 ubCnt = 0; ubCnt < gSkillTraitValues.ubMaxNumberOfTraits; ubCnt++ )
|
||||
{
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].bSkillTraits[ ubCnt ] = ( INT8 )SkillsList[ ubCnt ];
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// skill trait
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].bSkillTraits[0] = ( INT8 )iSkillA;
|
||||
gMercProfiles[ LaptopSaveInfo.iIMPIndex ].bSkillTraits[1] = ( INT8 )iSkillB;
|
||||
}
|
||||
}
|
||||
|
||||
BOOLEAN ShouldThisMercHaveABigBody( void )
|
||||
{
|
||||
// should this merc be a big body type
|
||||
// Madd - don't limit it by portrait
|
||||
//if ( ( iPortraitNumber == 0 ) || ( iPortraitNumber == 6 ) || ( iPortraitNumber == 7 ) )
|
||||
//{
|
||||
// if ( gMercProfiles[ LaptopSaveInfo.iIMPIndex ].bStrength >= 75 )
|
||||
// {
|
||||
// return( TRUE );
|
||||
// }
|
||||
//}
|
||||
|
||||
//return( FALSE );
|
||||
|
||||
// We can now choose this ourselves - SANDRO
|
||||
return( bBigBodySelected() );
|
||||
}
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
#define __IMP_COMPILE_H
|
||||
|
||||
#define PLAYER_GENERATED_CHARACTER_ID 51
|
||||
#define ATTITUDE_LIST_SIZE 20
|
||||
#define NUMBER_OF_PLAYER_PORTRAITS 16
|
||||
#define ATTITUDE_LIST_SIZE 30
|
||||
#define NUMBER_OF_PLAYER_PORTRAITS 50 //16
|
||||
|
||||
void AddAnAttitudeToAttitudeList( INT8 bAttitude );
|
||||
void CreatePlayerAttitude( void );
|
||||
|
||||
+434
-179
@@ -34,9 +34,13 @@
|
||||
#include "weapons.h"
|
||||
#include "Random.h"
|
||||
#include "GameVersion.h"
|
||||
#include "faces.h"
|
||||
#include "GameSettings.h"
|
||||
#endif
|
||||
|
||||
#include <vfs/Core/vfs.h>
|
||||
#include <vfs/Aspects/vfs_settings.h>
|
||||
|
||||
// Changed by ADB (rev 1513) to resolve IMPs created prior to structural changes
|
||||
//#define IMP_FILENAME_SUFFIX ".dat"
|
||||
#define OLD_IMP_FILENAME_SUFFIX ".dat"
|
||||
@@ -60,6 +64,13 @@ void GiveIMPItems( MERCPROFILESTRUCT *pProfile, INT8 abilityValue, UINT8 typeInd
|
||||
UINT32 giIMPConfirmButton[ 2 ];
|
||||
UINT32 giIMPConfirmButtonImage[ 2 ];
|
||||
BOOLEAN fNoAlreadySelected = FALSE;
|
||||
|
||||
IMP_FACE_VALUES gIMPFaceValues[200];
|
||||
|
||||
IMP_FEMALE_VALUES gIMPFemaleValues[200];
|
||||
IMP_MALE_VALUES gIMPMaleValues[200];
|
||||
|
||||
/*
|
||||
UINT16 uiEyeXPositions[ ]={
|
||||
8,
|
||||
9,
|
||||
@@ -137,7 +148,7 @@ UINT16 uiMouthYPositions[]={
|
||||
24, //214
|
||||
26,
|
||||
};
|
||||
|
||||
*/
|
||||
BOOLEAN fLoadingCharacterForPreviousImpProfile = FALSE;
|
||||
|
||||
void CreateConfirmButtons( void );
|
||||
@@ -271,8 +282,23 @@ BOOLEAN AddCharacterToPlayersTeam( void )
|
||||
HireMercStruct.ubInsertionCode = INSERTION_CODE_ARRIVING_GAME;
|
||||
HireMercStruct.uiTimeTillMercArrives = GetMercArrivalTimeOfDay( );
|
||||
|
||||
SetProfileFaceData( HireMercStruct.ubProfileID , ( UINT8 ) ( 200 + iPortraitNumber ), uiEyeXPositions[ iPortraitNumber ], uiEyeYPositions[ iPortraitNumber ], uiMouthXPositions[ iPortraitNumber ], uiMouthYPositions[ iPortraitNumber ] );
|
||||
|
||||
|
||||
if( fCharacterIsMale )
|
||||
{
|
||||
if ( gIMPMaleValues[ iPortraitNumber ].PortraitId !=0 )
|
||||
{
|
||||
SetProfileFaceData( HireMercStruct.ubProfileID , (UINT8)(gIMPMaleValues[ iPortraitNumber ].PortraitId), gIMPMaleValues[ iPortraitNumber ].uiEyeXPositions, gIMPMaleValues[ iPortraitNumber ].uiEyeYPositions, gIMPMaleValues[ iPortraitNumber ].uiMouthXPositions, gIMPMaleValues[ iPortraitNumber ].uiMouthYPositions );
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if ( gIMPFemaleValues[ iPortraitNumber ].PortraitId !=0 )
|
||||
{
|
||||
SetProfileFaceData( HireMercStruct.ubProfileID , (UINT8)(gIMPFemaleValues[ iPortraitNumber ].PortraitId), gIMPFemaleValues[ iPortraitNumber ].uiEyeXPositions, gIMPFemaleValues[ iPortraitNumber ].uiEyeYPositions, gIMPFemaleValues[ iPortraitNumber ].uiMouthXPositions, gIMPFemaleValues[ iPortraitNumber ].uiMouthYPositions );
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//if we succesfully hired the merc
|
||||
if( !HireMerc( &HireMercStruct ) )
|
||||
{
|
||||
@@ -310,18 +336,23 @@ void BtnIMPConfirmYes(GUI_BUTTON *btn,INT32 reason)
|
||||
return;
|
||||
}
|
||||
*/
|
||||
if( LaptopSaveInfo.iCurrentBalance < COST_OF_PROFILE )
|
||||
// SANDRO - changed to find the actual profile cost
|
||||
//if( LaptopSaveInfo.iCurrentBalance < COST_OF_PROFILE )
|
||||
if( LaptopSaveInfo.iCurrentBalance < iGetProfileCost() )
|
||||
{
|
||||
// not enough
|
||||
return;
|
||||
return;
|
||||
}
|
||||
|
||||
// line moved by CJC Nov 28 2002 to AFTER the check for money
|
||||
LaptopSaveInfo.fIMPCompletedFlag = TRUE;
|
||||
|
||||
// charge the player
|
||||
AddTransactionToPlayersBook(IMP_PROFILE, (UINT8)(LaptopSaveInfo.iIMPIndex), GetWorldTotalMin( ), - ( COST_OF_PROFILE ) );
|
||||
AddHistoryToPlayersLog( HISTORY_CHARACTER_GENERATED, 0,GetWorldTotalMin( ), -1, -1 );
|
||||
// SANDRO - changed to find the actual profile cost
|
||||
//AddTransactionToPlayersBook(IMP_PROFILE, (UINT8)(LaptopSaveInfo.iIMPIndex), GetWorldTotalMin( ), - ( COST_OF_PROFILE ) );
|
||||
AddTransactionToPlayersBook(IMP_PROFILE, (UINT8)(LaptopSaveInfo.iIMPIndex), GetWorldTotalMin( ), - ( iGetProfileCost() ) );
|
||||
|
||||
AddHistoryToPlayersLog( HISTORY_CHARACTER_GENERATED, 0,GetWorldTotalMin( ), -1, -1 );
|
||||
AddCharacterToPlayersTeam( );
|
||||
|
||||
// write the created imp merc
|
||||
@@ -426,9 +457,11 @@ void BtnIMPConfirmNo( GUI_BUTTON *btn,INT32 reason )
|
||||
}
|
||||
*/
|
||||
|
||||
|
||||
#define PROFILE_HAS_SKILL_TRAIT( p, t ) ((p->bSkillTrait == t) || (p->bSkillTrait2 == t))
|
||||
|
||||
// SANDRO - improved this function
|
||||
//#define PROFILE_HAS_SKILL_TRAIT( p, t ) ( gGameOptions.fNewTraitSystem ? ((p->bSkillTrait == t) || (p->bSkillTrait2 == t) || (p->bSkillTrait3 == t)) : ((p->bSkillTrait == t) || (p->bSkillTrait2 == t)))
|
||||
#define PROFILE_HAS_SKILL_TRAIT( p, t ) ( ProfileHasSkillTrait( p, t ) > 0 )
|
||||
// DBrot: need a check for experts
|
||||
#define PROFILE_HAS_EXPERT_TRAIT( p, t ) ( ProfileHasSkillTrait( p, t ) > 1 )
|
||||
//CHRISL: New function to handle proper distribution of starting gear
|
||||
void DistributeInitialGear(MERCPROFILESTRUCT *pProfile)
|
||||
{
|
||||
@@ -560,101 +593,26 @@ void DistributeInitialGear(MERCPROFILESTRUCT *pProfile)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void GiveItemsToPC( UINT8 ubProfileId )
|
||||
{
|
||||
MERCPROFILESTRUCT *pProfile;
|
||||
|
||||
|
||||
// gives starting items to merc
|
||||
// NOTE: Any guns should probably be from those available in regular gun set
|
||||
|
||||
pProfile = &(gMercProfiles[ubProfileId]);
|
||||
|
||||
|
||||
// STANDARD EQUIPMENT
|
||||
// SANDRO - obsolete code deleted
|
||||
|
||||
GiveIMPItems(pProfile, 100, IMP_DEFAULT);
|
||||
GiveIMPRandomItems(pProfile, IMP_RANDOMDEFAULT);
|
||||
|
||||
|
||||
// kevlar vest, leggings, & helmet
|
||||
// MakeProfileInvItemThisSlot(pProfile, VESTPOS, FLAK_JACKET, 100, 1);
|
||||
|
||||
GiveIMPItems (pProfile,pProfile->bWisdom,IMP_WISDOM);
|
||||
|
||||
|
||||
//if ( PreRandom( 100 ) < (UINT32) pProfile->bWisdom )
|
||||
//{
|
||||
// MakeProfileInvItemThisSlot(pProfile, HELMETPOS, STEEL_HELMET, 100, 1);
|
||||
//}
|
||||
|
||||
// canteen
|
||||
// MakeProfileInvItemThisSlot(pProfile, SMALLPOCK4POS, CANTEEN, 100, 1);
|
||||
|
||||
GiveIMPItems (pProfile,pProfile->bMarksmanship,IMP_MARKSMANSHIP);
|
||||
|
||||
|
||||
//Give ANY imp the calico
|
||||
// MakeProfileInvItemThisSlot( pProfile, HANDPOS, M950, 100, 1);
|
||||
|
||||
|
||||
|
||||
//No ammo clip MakeProfileInvItemThisSlot( pProfile, SMALLPOCK1POS, CLIP9_30, 100, 2);
|
||||
|
||||
/*
|
||||
Ja25 IMP only gets 1 gun now
|
||||
|
||||
|
||||
|
||||
|
||||
if (pProfile->bMarksmanship >= 80)
|
||||
{
|
||||
// good shooters get a better & matching ammo
|
||||
MakeProfileInvItemThisSlot( pProfile, HANDPOS, MP5K, 100, 1);
|
||||
MakeProfileInvItemThisSlot( pProfile, SMALLPOCK1POS, CLIP9_30, 100, 2);
|
||||
}
|
||||
else
|
||||
{
|
||||
// Automatic pistol, with matching ammo
|
||||
MakeProfileInvItemThisSlot( pProfile, HANDPOS, BERETTA_93R, 100, 1 );
|
||||
MakeProfileInvItemThisSlot( pProfile, SMALLPOCK1POS, CLIP9_15, 100, 3 );
|
||||
}
|
||||
*/
|
||||
|
||||
// OPTIONAL EQUIPMENT: depends on skills & special skills
|
||||
|
||||
GiveIMPItems (pProfile,pProfile->bMedical,IMP_MEDICAL);
|
||||
|
||||
//if (pProfile->bMedical >= 60)
|
||||
//{
|
||||
// // strong medics get full medic kit
|
||||
// MakeProfileInvItemAnySlot(pProfile, MEDICKIT, 100, 1);
|
||||
//}
|
||||
//else
|
||||
//if (pProfile->bMedical >= 30)
|
||||
//{
|
||||
// // passable medics get first aid kit
|
||||
// MakeProfileInvItemAnySlot(pProfile, FIRSTAIDKIT, 100, 1);
|
||||
//}
|
||||
|
||||
GiveIMPItems (pProfile,pProfile->bMechanical,IMP_MECHANICAL);
|
||||
|
||||
//if (pProfile->bMechanical >= 50)
|
||||
//{
|
||||
// // mechanics get toolkit
|
||||
// MakeProfileInvItemAnySlot(pProfile, TOOLKIT, 100, 1);
|
||||
//}
|
||||
|
||||
GiveIMPItems (pProfile,pProfile->bExplosive,IMP_EXPLOSIVE);
|
||||
|
||||
//if (pProfile->bExplosive >= 50)
|
||||
//{
|
||||
// // loonies get TNT & Detonator
|
||||
//MakeProfileInvItemAnySlot(pProfile, TNT, 100, 1);
|
||||
//MakeProfileInvItemAnySlot(pProfile, DETONATOR, 100, 1);
|
||||
//}
|
||||
|
||||
GiveIMPItems (pProfile,pProfile->bAgility,IMP_AGILITY);
|
||||
GiveIMPItems (pProfile,pProfile->bDexterity,IMP_DEXTERITY);
|
||||
GiveIMPItems (pProfile,pProfile->bStrength,IMP_STRENGTH);
|
||||
@@ -662,89 +620,309 @@ void GiveItemsToPC( UINT8 ubProfileId )
|
||||
GiveIMPItems (pProfile,pProfile->bLeadership,IMP_LEADERSHIP);
|
||||
|
||||
// check for special skills
|
||||
if (PROFILE_HAS_SKILL_TRAIT(pProfile, LOCKPICKING) && ( iMechanical ) )
|
||||
/////////////////////////////////////////////////////////////////////
|
||||
// Check for new traits - SANDRO
|
||||
// DBrot: experts get other stuff
|
||||
if ( gGameOptions.fNewTraitSystem )
|
||||
{
|
||||
//MakeProfileInvItemAnySlot(pProfile, LOCKSMITHKIT, 100, 1);
|
||||
GiveIMPRandomItems(pProfile,IMP_LOCKPICKING);
|
||||
// MAJOR TRAITS
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, AUTO_WEAPONS_NT))
|
||||
{
|
||||
if( gGameExternalOptions.fExpertsGetDifferentChoices && PROFILE_HAS_EXPERT_TRAIT(ubProfileId, AUTO_WEAPONS_NT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_AUTO_WEAPONS_EXP);
|
||||
}
|
||||
else
|
||||
{
|
||||
GiveIMPRandomItems(pProfile, IMP_AUTO_WEAPONS);
|
||||
}
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, HEAVY_WEAPONS_NT ))
|
||||
{
|
||||
if( gGameExternalOptions.fExpertsGetDifferentChoices && PROFILE_HAS_EXPERT_TRAIT(ubProfileId, HEAVY_WEAPONS_NT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_HEAVY_WEAPONS_EXP);
|
||||
}
|
||||
else
|
||||
{
|
||||
GiveIMPRandomItems(pProfile, IMP_HEAVY_WEAPONS);
|
||||
}
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, SNIPER_NT))
|
||||
{
|
||||
if( gGameExternalOptions.fExpertsGetDifferentChoices && PROFILE_HAS_EXPERT_TRAIT(ubProfileId, SNIPER_NT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_SNIPER_EXP);
|
||||
}
|
||||
else
|
||||
{
|
||||
GiveIMPRandomItems(pProfile, IMP_SNIPER);
|
||||
}
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, RANGER_NT))
|
||||
{
|
||||
if( gGameExternalOptions.fExpertsGetDifferentChoices && PROFILE_HAS_EXPERT_TRAIT(ubProfileId, RANGER_NT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_RANGER_EXP);
|
||||
}
|
||||
else
|
||||
{
|
||||
GiveIMPRandomItems(pProfile, IMP_RANGER);
|
||||
}
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, GUNSLINGER_NT))
|
||||
{
|
||||
if( gGameExternalOptions.fExpertsGetDifferentChoices && PROFILE_HAS_EXPERT_TRAIT(ubProfileId, GUNSLINGER_NT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_GUNSLINGER_EXP);
|
||||
}
|
||||
else
|
||||
{
|
||||
GiveIMPRandomItems(pProfile, IMP_GUNSLINGER);
|
||||
}
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, MARTIAL_ARTS_NT))
|
||||
{
|
||||
if( gGameExternalOptions.fExpertsGetDifferentChoices && PROFILE_HAS_EXPERT_TRAIT(ubProfileId, MARTIAL_ARTS_NT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_MARTIAL_ARTS_EXP);
|
||||
}
|
||||
else
|
||||
{
|
||||
GiveIMPRandomItems(pProfile, IMP_MARTIAL_ARTS);
|
||||
}
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, SQUADLEADER_NT))
|
||||
{
|
||||
if( gGameExternalOptions.fExpertsGetDifferentChoices && PROFILE_HAS_EXPERT_TRAIT(ubProfileId, SQUADLEADER_NT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_SQUADLEADER_EXP);
|
||||
}
|
||||
else
|
||||
{
|
||||
GiveIMPRandomItems(pProfile, IMP_SQUADLEADER);
|
||||
}
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, TECHNICIAN_NT) && ( iMechanical ) )
|
||||
{
|
||||
if( gGameExternalOptions.fExpertsGetDifferentChoices && PROFILE_HAS_EXPERT_TRAIT(ubProfileId, TECHNICIAN_NT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_TECHNICIAN_EXP);
|
||||
}
|
||||
else
|
||||
{
|
||||
GiveIMPRandomItems(pProfile, IMP_TECHNICIAN);
|
||||
}
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, DOCTOR_NT ))
|
||||
{
|
||||
if( gGameExternalOptions.fExpertsGetDifferentChoices && PROFILE_HAS_EXPERT_TRAIT(ubProfileId, DOCTOR_NT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_DOCTOR_EXP);
|
||||
}
|
||||
else
|
||||
{
|
||||
GiveIMPRandomItems(pProfile, IMP_DOCTOR);
|
||||
}
|
||||
}
|
||||
// MINOR TRAITS
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, AMBIDEXTROUS_NT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_AMBIDEXTROUS);
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, MELEE_NT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_MELEE);
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, THROWING_NT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_THROWING);
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, NIGHT_OPS_NT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_NIGHT_OPS);
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, STEALTHY_NT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_STEALTHY);
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, ATHLETICS_NT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_ATHLETICS);
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, BODYBUILDING_NT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_BODYBUILDING);
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, DEMOLITIONS_NT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_DEMOLITIONS);
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, TEACHING_NT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_TEACHING);
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, SCOUTING_NT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_SCOUTING);
|
||||
}
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, LOCKPICKING_OT) && ( iMechanical ) )
|
||||
{
|
||||
//MakeProfileInvItemAnySlot(pProfile, LOCKSMITHKIT, 100, 1);
|
||||
if( gGameExternalOptions.fExpertsGetDifferentChoices && PROFILE_HAS_EXPERT_TRAIT(ubProfileId, LOCKPICKING_OT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_LOCKPICKING_EXP);
|
||||
}
|
||||
else
|
||||
{
|
||||
GiveIMPRandomItems(pProfile, IMP_LOCKPICKING);
|
||||
}
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, ELECTRONICS_OT) && ( iMechanical ) )
|
||||
{
|
||||
//MakeProfileInvItemAnySlot(pProfile, METALDETECTOR, 100, 1);
|
||||
GiveIMPRandomItems(pProfile,IMP_ELECTRONICS);
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, CAMOUFLAGED_OT)) // TODO: Madd - other camouflage types, once we figure out a way to enable more traits
|
||||
{
|
||||
//MakeProfileInvItemAnySlot(pProfile, CAMOUFLAGEKIT, 100, 1);
|
||||
GiveIMPRandomItems(pProfile,IMP_CAMOUFLAGED);
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, AMBIDEXT_OT))
|
||||
{
|
||||
//MakeProfileInvItemAnySlot(pProfile, M950, 100, 1);
|
||||
GiveIMPRandomItems(pProfile,IMP_AMBIDEXTROUS);
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, NIGHTOPS_OT))
|
||||
{
|
||||
// MakeProfileInvItemAnySlot(pProfile, SILENCER, 100, 2);
|
||||
if( gGameExternalOptions.fExpertsGetDifferentChoices && PROFILE_HAS_EXPERT_TRAIT(ubProfileId, NIGHTOPS_OT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_NIGHT_OPS_EXP);
|
||||
}
|
||||
else
|
||||
{
|
||||
GiveIMPRandomItems(pProfile, IMP_NIGHT_OPS);
|
||||
}
|
||||
}
|
||||
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, HANDTOHAND_OT))
|
||||
{
|
||||
//MakeProfileInvItemAnySlot(pProfile, BRASS_KNUCKLES, 100, 1);
|
||||
if( gGameExternalOptions.fExpertsGetDifferentChoices && PROFILE_HAS_EXPERT_TRAIT(ubProfileId, HANDTOHAND_OT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_MARTIAL_ARTS_EXP);
|
||||
}
|
||||
else
|
||||
{
|
||||
GiveIMPRandomItems(pProfile, IMP_MARTIAL_ARTS);
|
||||
}
|
||||
}
|
||||
|
||||
if (PROFILE_HAS_SKILL_TRAIT(pProfile, HANDTOHAND))
|
||||
{
|
||||
//MakeProfileInvItemAnySlot(pProfile, BRASS_KNUCKLES, 100, 1);
|
||||
GiveIMPRandomItems(pProfile,IMP_HTH);
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, THROWING_OT))
|
||||
{
|
||||
// MakeProfileInvItemAnySlot(pProfile, THROWING_KNIFE, 100, 1);
|
||||
if( gGameExternalOptions.fExpertsGetDifferentChoices && PROFILE_HAS_EXPERT_TRAIT(ubProfileId, THROWING_OT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_THROWING_EXP);
|
||||
}
|
||||
else
|
||||
{
|
||||
GiveIMPRandomItems(pProfile, IMP_THROWING);
|
||||
}
|
||||
}
|
||||
|
||||
if (PROFILE_HAS_SKILL_TRAIT(pProfile, ELECTRONICS) && ( iMechanical ) )
|
||||
{
|
||||
//MakeProfileInvItemAnySlot(pProfile, METALDETECTOR, 100, 1);
|
||||
GiveIMPRandomItems(pProfile,IMP_ELECTRONICS);
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, STEALTHY_OT))
|
||||
{
|
||||
// MakeProfileInvItemAnySlot(pProfile, SILENCER, 100, 1);
|
||||
if( gGameExternalOptions.fExpertsGetDifferentChoices && PROFILE_HAS_EXPERT_TRAIT(ubProfileId, STEALTHY_OT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_STEALTHY_EXP);
|
||||
}
|
||||
else
|
||||
{
|
||||
GiveIMPRandomItems(pProfile, IMP_STEALTHY);
|
||||
}
|
||||
}
|
||||
|
||||
if (PROFILE_HAS_SKILL_TRAIT(pProfile, NIGHTOPS))
|
||||
{
|
||||
// MakeProfileInvItemAnySlot(pProfile, SILENCER, 100, 2);
|
||||
GiveIMPRandomItems(pProfile,IMP_NIGHTOPS);
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, KNIFING_OT))
|
||||
{
|
||||
// MakeProfileInvItemAnySlot(pProfile, COMBAT_KNIFE, 100, 1);
|
||||
if( gGameExternalOptions.fExpertsGetDifferentChoices && PROFILE_HAS_EXPERT_TRAIT(ubProfileId, KNIFING_OT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_MELEE_EXP);
|
||||
}
|
||||
else
|
||||
{
|
||||
GiveIMPRandomItems(pProfile, IMP_MELEE);
|
||||
}
|
||||
}
|
||||
|
||||
if (PROFILE_HAS_SKILL_TRAIT(pProfile, THROWING))
|
||||
{
|
||||
// MakeProfileInvItemAnySlot(pProfile, THROWING_KNIFE, 100, 1);
|
||||
GiveIMPRandomItems(pProfile,IMP_THROWING);
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, MARTIALARTS_OT))
|
||||
{
|
||||
if( gGameExternalOptions.fExpertsGetDifferentChoices && PROFILE_HAS_EXPERT_TRAIT(ubProfileId, MARTIALARTS_OT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_MARTIAL_ARTS_EXP);
|
||||
}
|
||||
else
|
||||
{
|
||||
GiveIMPRandomItems(pProfile, IMP_MARTIAL_ARTS);
|
||||
}
|
||||
}
|
||||
|
||||
if (PROFILE_HAS_SKILL_TRAIT(pProfile, STEALTHY))
|
||||
{
|
||||
// MakeProfileInvItemAnySlot(pProfile, SILENCER, 100, 1);
|
||||
GiveIMPRandomItems(pProfile,IMP_STEALTHY);
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, PROF_SNIPER_OT))
|
||||
{
|
||||
if( gGameExternalOptions.fExpertsGetDifferentChoices && PROFILE_HAS_EXPERT_TRAIT(ubProfileId, PROF_SNIPER_OT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_SNIPER_EXP);
|
||||
}
|
||||
else
|
||||
{
|
||||
GiveIMPRandomItems(pProfile, IMP_SNIPER);
|
||||
}
|
||||
}
|
||||
|
||||
if (PROFILE_HAS_SKILL_TRAIT(pProfile, KNIFING))
|
||||
{
|
||||
// MakeProfileInvItemAnySlot(pProfile, COMBAT_KNIFE, 100, 1);
|
||||
GiveIMPRandomItems(pProfile,IMP_KNIFING);
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, TEACHING_OT))
|
||||
{
|
||||
if( gGameExternalOptions.fExpertsGetDifferentChoices && PROFILE_HAS_EXPERT_TRAIT(ubProfileId, TEACHING_OT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_TEACHING_EXP);
|
||||
}
|
||||
else
|
||||
{
|
||||
GiveIMPRandomItems(pProfile, IMP_TEACHING);
|
||||
}
|
||||
}
|
||||
|
||||
if (PROFILE_HAS_SKILL_TRAIT(pProfile, CAMOUFLAGED)) // TODO: Madd - other camouflage types, once we figure out a way to enable more traits
|
||||
{
|
||||
// MakeProfileInvItemAnySlot(pProfile, CAMOUFLAGEKIT, 100, 1);
|
||||
GiveIMPRandomItems(pProfile,IMP_CAMOUFLAGED);
|
||||
}
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, AUTO_WEAPS_OT))
|
||||
{
|
||||
if( gGameExternalOptions.fExpertsGetDifferentChoices && PROFILE_HAS_EXPERT_TRAIT(ubProfileId, AUTO_WEAPS_OT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_AUTO_WEAPONS_EXP);
|
||||
}
|
||||
else
|
||||
{
|
||||
GiveIMPRandomItems(pProfile, IMP_AUTO_WEAPONS);
|
||||
}
|
||||
}
|
||||
|
||||
if (PROFILE_HAS_SKILL_TRAIT(pProfile, AMBIDEXT))
|
||||
{
|
||||
// MakeProfileInvItemAnySlot(pProfile, M950, 100, 1);
|
||||
GiveIMPRandomItems(pProfile,IMP_AMBIDEXTROUS);
|
||||
}
|
||||
|
||||
if (PROFILE_HAS_SKILL_TRAIT(pProfile, MARTIALARTS))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_MARTIALARTS);
|
||||
}
|
||||
|
||||
if (PROFILE_HAS_SKILL_TRAIT(pProfile, PROF_SNIPER))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_PROF_SNIPER);
|
||||
}
|
||||
|
||||
if (PROFILE_HAS_SKILL_TRAIT(pProfile, TEACHING))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_TEACHING);
|
||||
}
|
||||
|
||||
if (PROFILE_HAS_SKILL_TRAIT(pProfile, AUTO_WEAPS))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_AUTOWEAPONS);
|
||||
}
|
||||
|
||||
if (PROFILE_HAS_SKILL_TRAIT(pProfile, HEAVY_WEAPS ))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_HEAVYWEAPONS);
|
||||
}
|
||||
|
||||
if (PROFILE_HAS_SKILL_TRAIT(pProfile, THIEF ))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_THIEF);
|
||||
if (PROFILE_HAS_SKILL_TRAIT(ubProfileId, HEAVY_WEAPS_OT ))
|
||||
{
|
||||
if( gGameExternalOptions.fExpertsGetDifferentChoices && PROFILE_HAS_EXPERT_TRAIT(ubProfileId, HEAVY_WEAPS_OT))
|
||||
{
|
||||
GiveIMPRandomItems(pProfile,IMP_HEAVY_WEAPONS_EXP);
|
||||
}
|
||||
else
|
||||
{
|
||||
GiveIMPRandomItems(pProfile, IMP_HEAVY_WEAPONS);
|
||||
}
|
||||
}
|
||||
}
|
||||
/////////////////////////////////////////////////////////////////////
|
||||
|
||||
// CHRISL: Now that all items have been issued, distribute them into appropriate pockets, starting with the largest items
|
||||
DistributeInitialGear(pProfile);
|
||||
@@ -871,7 +1049,8 @@ INT32 SpecificFreePocket(MERCPROFILESTRUCT *pProfile, UINT16 usItem, UINT8 ubHow
|
||||
{
|
||||
if(LoadBearingEquipment[Item[usItem].ubClassIndex].lbeCombo!=0)
|
||||
{
|
||||
if((pProfile->inv[BPACKPOCKPOS]!=NONE && LoadBearingEquipment[Item[pProfile->inv[BPACKPOCKPOS]].ubClassIndex].lbeCombo==LoadBearingEquipment[Item[usItem].ubClassIndex].lbeCombo) || pProfile->inv[BPACKPOCKPOS]==NONE)
|
||||
//DBrot: changed to bitwise comparison
|
||||
if((pProfile->inv[BPACKPOCKPOS]!=NONE && (LoadBearingEquipment[Item[pProfile->inv[BPACKPOCKPOS]].ubClassIndex].lbeCombo & LoadBearingEquipment[Item[usItem].ubClassIndex].lbeCombo)) || pProfile->inv[BPACKPOCKPOS]==NONE)
|
||||
return CPACKPOCKPOS;
|
||||
}
|
||||
else if(pProfile->inv[BPACKPOCKPOS]==NONE)
|
||||
@@ -884,7 +1063,8 @@ INT32 SpecificFreePocket(MERCPROFILESTRUCT *pProfile, UINT16 usItem, UINT8 ubHow
|
||||
{
|
||||
if(LoadBearingEquipment[Item[usItem].ubClassIndex].lbeCombo!=0)
|
||||
{
|
||||
if((pProfile->inv[CPACKPOCKPOS]!=NONE && LoadBearingEquipment[Item[pProfile->inv[CPACKPOCKPOS]].ubClassIndex].lbeCombo==LoadBearingEquipment[Item[usItem].ubClassIndex].lbeCombo) || pProfile->inv[CPACKPOCKPOS]==NONE)
|
||||
//DBrot: changed to bitwise comparison
|
||||
if((pProfile->inv[CPACKPOCKPOS]!=NONE && (LoadBearingEquipment[Item[pProfile->inv[CPACKPOCKPOS]].ubClassIndex].lbeCombo & LoadBearingEquipment[Item[usItem].ubClassIndex].lbeCombo)) || pProfile->inv[CPACKPOCKPOS]==NONE)
|
||||
return BPACKPOCKPOS;
|
||||
}
|
||||
else if(pProfile->inv[CPACKPOCKPOS]==NONE)
|
||||
@@ -1117,8 +1297,6 @@ INT32 AnyFreeBigEnoughPocket(MERCPROFILESTRUCT *pProfile, INVNODE *tInv)
|
||||
return(-1);
|
||||
}
|
||||
|
||||
#include "VFS/vfs.h"
|
||||
#include "VFS/vfs_settings.h"
|
||||
void WriteOutCurrentImpCharacter( INT32 iProfileId )
|
||||
{
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("WriteOutCurrentImpCharacter: IMP.dat"));
|
||||
@@ -1145,11 +1323,11 @@ void WriteOutCurrentImpCharacter( INT32 iProfileId )
|
||||
char zFileName[32];
|
||||
if(vfs::Settings::getUseUnicode())
|
||||
{
|
||||
strncpy(zFileName, utf8string::as_utf8(gMercProfiles[iProfileId].zNickname,10).c_str(), 32);
|
||||
strncpy(zFileName, vfs::String::as_utf8(gMercProfiles[iProfileId].zNickname,10).c_str(), 32);
|
||||
}
|
||||
else
|
||||
{
|
||||
utf8string::narrow(gMercProfiles[iProfileId].zNickname, 10, zFileName, 32);
|
||||
vfs::String::narrow(gMercProfiles[iProfileId].zNickname, 10, zFileName, 32);
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -1339,20 +1517,31 @@ BOOLEAN LoadImpCharacter( STR nickName )
|
||||
//CHRISL: At this point, we need to resort profile inventory so that NewInv items don't accidentally appear in OldInv
|
||||
DistributeInitialGear(&gMercProfiles[iProfileId]);
|
||||
|
||||
if( LaptopSaveInfo.iCurrentBalance < COST_OF_PROFILE )
|
||||
// Changed to find actual IMP cost - SANDRO
|
||||
if( LaptopSaveInfo.iCurrentBalance < iGetProfileCost() )
|
||||
{
|
||||
DoLapTopMessageBox( MSG_BOX_IMP_STYLE, pImpPopUpStrings[ 3 ], LAPTOP_SCREEN, MSG_BOX_FLAG_OK, NULL);
|
||||
|
||||
// not enough
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
//new camo face
|
||||
if ( gGameExternalOptions.fShowCamouflageFaces == TRUE )
|
||||
{
|
||||
gCamoFace[iProfileId].gCamoface = TRUE;
|
||||
gCamoFace[iProfileId].gUrbanCamoface = FALSE;
|
||||
gCamoFace[iProfileId].gDesertCamoface = FALSE;
|
||||
gCamoFace[iProfileId].gSnowCamoface = FALSE;
|
||||
}
|
||||
|
||||
|
||||
// charge the player
|
||||
// is the character male?
|
||||
fCharacterIsMale = ( gMercProfiles[ iProfileId ].bSex == MALE );
|
||||
fLoadingCharacterForPreviousImpProfile = TRUE;
|
||||
AddTransactionToPlayersBook(IMP_PROFILE,0, GetWorldTotalMin( ), - ( COST_OF_PROFILE ) );
|
||||
// Changed to find actual IMP cost - SANDRO
|
||||
AddTransactionToPlayersBook(IMP_PROFILE,0, GetWorldTotalMin( ), - ( iGetProfileCost() ) );
|
||||
AddHistoryToPlayersLog( HISTORY_CHARACTER_GENERATED, 0,GetWorldTotalMin( ), -1, -1 );
|
||||
LaptopSaveInfo.iIMPIndex = iProfileId;
|
||||
AddCharacterToPlayersTeam( );
|
||||
@@ -1383,38 +1572,86 @@ BOOLEAN LoadImpCharacter( STR nickName )
|
||||
void ResetIMPCharactersEyesAndMouthOffsets( UINT8 ubMercProfileID )
|
||||
{
|
||||
// ATE: Check boundary conditions!
|
||||
if( ( ( gMercProfiles[ ubMercProfileID ].ubFaceIndex - 200 ) > 16 ) || ( ubMercProfileID >= PROF_HUMMER ) )
|
||||
if( ( ( gMercProfiles[ ubMercProfileID ].ubFaceIndex - 200 ) > MAX_NEW_IMP_PORTRAITS ) || ( ubMercProfileID >= PROF_HUMMER ) ) // 16
|
||||
{
|
||||
return;
|
||||
}
|
||||
/*
|
||||
gMercProfiles[ ubMercProfileID ].usEyesX = gIMPFaceValues[ gMercProfiles[ ubMercProfileID ].ubFaceIndex - 200 ].uiEyeXPositions;
|
||||
gMercProfiles[ ubMercProfileID ].usEyesY = gIMPFaceValues[ gMercProfiles[ ubMercProfileID ].ubFaceIndex - 200 ].uiEyeYPositions;
|
||||
|
||||
gMercProfiles[ ubMercProfileID ].usEyesX = uiEyeXPositions[ gMercProfiles[ ubMercProfileID ].ubFaceIndex - 200 ];
|
||||
gMercProfiles[ ubMercProfileID ].usEyesY = uiEyeYPositions[ gMercProfiles[ ubMercProfileID ].ubFaceIndex - 200 ];
|
||||
gMercProfiles[ ubMercProfileID ].usMouthX = gIMPFaceValues[ gMercProfiles[ ubMercProfileID ].ubFaceIndex - 200 ].uiMouthXPositions;
|
||||
gMercProfiles[ ubMercProfileID ].usMouthY = gIMPFaceValues[ gMercProfiles[ ubMercProfileID ].ubFaceIndex - 200 ].uiMouthYPositions;
|
||||
*/
|
||||
|
||||
|
||||
if( gMercProfiles[ ubMercProfileID ].bSex == 0 )
|
||||
{
|
||||
gMercProfiles[ ubMercProfileID ].usEyesX = gIMPMaleValues[ gMercProfiles[ ubMercProfileID ].ubFaceIndex - 200 ].uiEyeXPositions;
|
||||
gMercProfiles[ ubMercProfileID ].usEyesY = gIMPMaleValues[ gMercProfiles[ ubMercProfileID ].ubFaceIndex - 200 ].uiEyeYPositions;
|
||||
|
||||
gMercProfiles[ ubMercProfileID ].usMouthX = uiMouthXPositions[ gMercProfiles[ ubMercProfileID ].ubFaceIndex - 200 ];
|
||||
gMercProfiles[ ubMercProfileID ].usMouthY = uiMouthYPositions[ gMercProfiles[ ubMercProfileID ].ubFaceIndex - 200 ];
|
||||
gMercProfiles[ ubMercProfileID ].usMouthX = gIMPMaleValues[ gMercProfiles[ ubMercProfileID ].ubFaceIndex - 200 ].uiMouthXPositions;
|
||||
gMercProfiles[ ubMercProfileID ].usMouthY = gIMPMaleValues[ gMercProfiles[ ubMercProfileID ].ubFaceIndex - 200 ].uiMouthYPositions;
|
||||
}
|
||||
else
|
||||
{
|
||||
gMercProfiles[ ubMercProfileID ].usEyesX = gIMPFemaleValues[ gMercProfiles[ ubMercProfileID ].ubFaceIndex - 200 ].uiEyeXPositions;
|
||||
gMercProfiles[ ubMercProfileID ].usEyesY = gIMPFemaleValues[ gMercProfiles[ ubMercProfileID ].ubFaceIndex - 200 ].uiEyeYPositions;
|
||||
|
||||
gMercProfiles[ ubMercProfileID ].usMouthX = gIMPFemaleValues[ gMercProfiles[ ubMercProfileID ].ubFaceIndex - 200 ].uiMouthXPositions;
|
||||
gMercProfiles[ ubMercProfileID ].usMouthY = gIMPFemaleValues[ gMercProfiles[ ubMercProfileID ].ubFaceIndex - 200 ].uiMouthYPositions;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
void GiveIMPRandomItems( MERCPROFILESTRUCT *pProfile, UINT8 typeIndex )
|
||||
{
|
||||
/////////////////////////////////////////////////////////////////////
|
||||
// SANDRO - I've changed this formula a bit, <- me too - silversurfer
|
||||
// now it should not take the same choice twice
|
||||
/////////////////////////////////////////////////////////////////////
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("GiveIMPRandomItems: typeIndex = %d",typeIndex ));
|
||||
|
||||
UINT16 usItem = 0;
|
||||
INT32 iChoice;
|
||||
UINT8 ubValidChoices = 0;
|
||||
UINT8 ubNumChoices = gIMPItemChoices[ typeIndex ].ubChoices;
|
||||
UINT8 ubNumItemsToGive = 0;
|
||||
BOOLEAN ubItemsGiven[ 50 ]={FALSE};
|
||||
|
||||
if ( gIMPItemChoices[ typeIndex ].ubChoices <= 0 )
|
||||
return;
|
||||
|
||||
for ( int i=0; i < gIMPItemChoices[typeIndex].ubNumItems ;i++ )
|
||||
// check how many legal items are in the choices list, this is to prevent infinite loop
|
||||
for ( UINT8 cnt=0; cnt < ubNumChoices; cnt++ )
|
||||
{
|
||||
usItem = gIMPItemChoices[ typeIndex ].bItemNo[ cnt ];
|
||||
if ( ItemIsLegal(usItem) )
|
||||
ubValidChoices++;
|
||||
}
|
||||
|
||||
// if no valid items found, bail out
|
||||
if ( ubValidChoices <= 0 )
|
||||
return;
|
||||
|
||||
// define how many items we get
|
||||
if ( ubValidChoices < gIMPItemChoices[typeIndex].ubNumItems )
|
||||
// if there are less legal items than the number we should get, we only get the number of legal items
|
||||
ubNumItemsToGive = ubValidChoices;
|
||||
else
|
||||
// give us the maximum possible
|
||||
ubNumItemsToGive = gIMPItemChoices[typeIndex].ubNumItems;
|
||||
|
||||
for ( int i=0; i < ubNumItemsToGive ;i++ )
|
||||
{
|
||||
usItem = 0;
|
||||
while (usItem == 0 )
|
||||
{
|
||||
iChoice = Random(gIMPItemChoices[ typeIndex ].ubChoices);
|
||||
usItem = gIMPItemChoices[ typeIndex ].bItemNo[ iChoice ];
|
||||
if (!ItemIsLegal(usItem))
|
||||
usItem=0;
|
||||
iChoice = Random( ubNumChoices );
|
||||
usItem = gIMPItemChoices[ typeIndex ].bItemNo[ iChoice ];
|
||||
// is this legal and we don't have it already?
|
||||
if (ItemIsLegal(usItem) && !ubItemsGiven[iChoice] )
|
||||
ubItemsGiven[iChoice] = TRUE;
|
||||
else
|
||||
usItem=0;
|
||||
}
|
||||
DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("GiveIMPRandomItems: typeIndex = %d, usItem = %d ",typeIndex, usItem ));
|
||||
if ( usItem > 0 )
|
||||
@@ -1491,5 +1728,23 @@ void GiveIMPItems( MERCPROFILESTRUCT *pProfile, INT8 abilityValue, UINT8 typeInd
|
||||
|
||||
}
|
||||
|
||||
// SANDRO - Function to determine actual cost of profile
|
||||
INT32 iGetProfileCost()
|
||||
{
|
||||
if (gGameExternalOptions.fDynamicIMPProfileCost)
|
||||
{
|
||||
INT32 iIMPProfileCost;
|
||||
|
||||
iIMPProfileCost = gGameExternalOptions.iIMPProfileCost * CountFilledIMPSlots(-1);
|
||||
|
||||
if (iIMPProfileCost >= gGameExternalOptions.iIMPProfileCost)
|
||||
return(iIMPProfileCost);
|
||||
else
|
||||
return(gGameExternalOptions.iIMPProfileCost);
|
||||
}
|
||||
else
|
||||
return(gGameExternalOptions.iIMPProfileCost);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -6,6 +6,76 @@ void RenderIMPConfirm( void );
|
||||
void ExitIMPConfirm( void );
|
||||
void HandleIMPConfirm( void );
|
||||
|
||||
#define MAX_NEW_IMP_PORTRAITS 50
|
||||
|
||||
typedef struct
|
||||
{
|
||||
UINT16 uiEyeXPositions;
|
||||
UINT16 uiEyeYPositions;
|
||||
UINT16 uiMouthXPositions;
|
||||
UINT16 uiMouthYPositions;
|
||||
UINT16 uiIndex;
|
||||
UINT16 FaceIndex;
|
||||
UINT16 PortraitId;
|
||||
BOOLEAN bSex;
|
||||
INT32 iCurrentSkin;
|
||||
INT32 iCurrentHair;
|
||||
INT32 iCurrentShirt;
|
||||
INT32 iCurrentPants;
|
||||
BOOLEAN bBigBody;
|
||||
BOOLEAN bBadAss;
|
||||
|
||||
} IMP_FACE_VALUES;
|
||||
|
||||
extern IMP_FACE_VALUES gIMPFaceValues[200];
|
||||
|
||||
|
||||
typedef struct
|
||||
{
|
||||
UINT16 uiIndexIMP;
|
||||
BOOLEAN Enabled;
|
||||
|
||||
UINT16 uiEyeXPositions;
|
||||
UINT16 uiEyeYPositions;
|
||||
UINT16 uiMouthXPositions;
|
||||
UINT16 uiMouthYPositions;
|
||||
UINT16 uiIndex;
|
||||
UINT16 FaceIndex;
|
||||
UINT16 PortraitId;
|
||||
BOOLEAN bSex;
|
||||
INT32 iCurrentSkin;
|
||||
INT32 iCurrentHair;
|
||||
INT32 iCurrentShirt;
|
||||
INT32 iCurrentPants;
|
||||
BOOLEAN bBigBody;
|
||||
BOOLEAN bBadAss;
|
||||
|
||||
} IMP_MALE_VALUES;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
UINT16 uiIndexIMP;
|
||||
BOOLEAN Enabled;
|
||||
|
||||
UINT16 uiEyeXPositions;
|
||||
UINT16 uiEyeYPositions;
|
||||
UINT16 uiMouthXPositions;
|
||||
UINT16 uiMouthYPositions;
|
||||
UINT16 uiIndex;
|
||||
UINT16 FaceIndex;
|
||||
UINT16 PortraitId;
|
||||
BOOLEAN bSex;
|
||||
INT32 iCurrentSkin;
|
||||
INT32 iCurrentHair;
|
||||
INT32 iCurrentShirt;
|
||||
INT32 iCurrentPants;
|
||||
BOOLEAN bBigBody;
|
||||
BOOLEAN bBadAss;
|
||||
} IMP_FEMALE_VALUES;
|
||||
|
||||
extern IMP_FEMALE_VALUES gIMPFemaleValues[200];
|
||||
extern IMP_MALE_VALUES gIMPMaleValues[200];
|
||||
|
||||
BOOLEAN AddCharacterToPlayersTeam( void );
|
||||
BOOLEAN LoadImpCharacter( STR fileName );
|
||||
void WriteOutCurrentImpCharacter( INT32 iProfileId );
|
||||
@@ -15,5 +85,7 @@ void ResetIMPCharactersEyesAndMouthOffsets( UINT8 ubMercProfileID );
|
||||
|
||||
BOOLEAN ImpExists ( STR fileName );
|
||||
|
||||
INT32 iGetProfileCost( void ); // added by SANDRO
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
@@ -78,6 +78,8 @@ INT32 giIMPDisabilityTraitFinsihButtonImage;
|
||||
//image handle
|
||||
UINT32 guiIST_GreyGoldBox3;
|
||||
|
||||
MOUSE_REGION gMR_DisabilityHelpTextRegions[ IMP_DISABILITIES_NUMBER ];
|
||||
|
||||
//*******************************************************************
|
||||
//
|
||||
// Function Prototypes
|
||||
@@ -93,6 +95,7 @@ void IMPDisabilityTraitDisplayDisabilityTraits();
|
||||
|
||||
BOOLEAN CameBackToDisabilityTraitPageButNotFinished();
|
||||
|
||||
void AssignDisabilityHelpText( UINT8 ubNumber );
|
||||
|
||||
//*******************************************************************
|
||||
//
|
||||
@@ -141,7 +144,18 @@ void EnterIMPDisabilityTrait( void )
|
||||
}
|
||||
|
||||
HandleDisabilityTraitButtonStates( );
|
||||
|
||||
|
||||
// add regions for help texts
|
||||
UINT16 usPosY = IMP_DISABILITY_COLUMN_START_Y + 8;
|
||||
for( UINT8 ubCnt=0; ubCnt<IMP_DISABILITIES_NUMBER; ubCnt++ )
|
||||
{
|
||||
MSYS_DefineRegion( &gMR_DisabilityHelpTextRegions[ubCnt], ( IMP_DISABILITY_COLUMN_START_X + 62 ), ( usPosY ),
|
||||
(IMP_DISABILITY_COLUMN_START_X + 218), ( usPosY + 17), MSYS_PRIORITY_HIGH,
|
||||
MSYS_NO_CURSOR, MSYS_NO_CALLBACK, NULL );
|
||||
MSYS_AddRegion( &gMR_DisabilityHelpTextRegions[ubCnt] );
|
||||
|
||||
usPosY += IMP_DISABILITY_TRAIT__SPACE_BTN_BUTTONS;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -159,19 +173,21 @@ void RenderIMPDisabilityTrait( void )
|
||||
|
||||
void ExitIMPDisabilityTrait( void )
|
||||
{
|
||||
INT32 iCnt;
|
||||
INT32 ubCnt;
|
||||
|
||||
DeleteVideoObjectFromIndex( guiIST_GreyGoldBox3 );
|
||||
|
||||
//remove the skill buttons
|
||||
for(iCnt = 0; iCnt < IMP_DISABILITIES_NUMBER; iCnt++)
|
||||
for(ubCnt = 0; ubCnt < IMP_DISABILITIES_NUMBER; ubCnt++)
|
||||
{
|
||||
//if there is a button allocated
|
||||
if( giIMPDisabilityTraitAnswerButton[iCnt] != -1 )
|
||||
if( giIMPDisabilityTraitAnswerButton[ubCnt] != -1 )
|
||||
{
|
||||
RemoveButton(giIMPDisabilityTraitAnswerButton[ iCnt ] );
|
||||
UnloadButtonImage(giIMPDisabilityTraitAnswerButtonImage[ iCnt ] );
|
||||
RemoveButton(giIMPDisabilityTraitAnswerButton[ ubCnt ] );
|
||||
UnloadButtonImage(giIMPDisabilityTraitAnswerButtonImage[ ubCnt ] );
|
||||
}
|
||||
|
||||
MSYS_RemoveRegion( &gMR_DisabilityHelpTextRegions[ubCnt] );
|
||||
}
|
||||
|
||||
RemoveButton( giIMPDisabilityTraitFinsihButton );
|
||||
@@ -192,47 +208,47 @@ void HandleIMPDisabilityTrait( void )
|
||||
|
||||
void AddImpDisabilityTraitButtons()
|
||||
{
|
||||
INT32 iCnt = 0;
|
||||
INT8 ubCnt = 0;
|
||||
UINT16 usPosX, usPosY;
|
||||
|
||||
usPosX = IMP_DISABILITY_COLUMN_START_X;
|
||||
usPosY = IMP_DISABILITY_COLUMN_START_Y;
|
||||
|
||||
for(iCnt = 0; iCnt < IMP_DISABILITIES_NUMBER; iCnt++)
|
||||
for(ubCnt = 0; ubCnt < IMP_DISABILITIES_NUMBER; ubCnt++)
|
||||
{
|
||||
//reset
|
||||
giIMPDisabilityTraitAnswerButton[iCnt] = -1;
|
||||
giIMPDisabilityTraitAnswerButton[ubCnt] = -1;
|
||||
|
||||
//if we are not DONE and are just reviewing
|
||||
if( iCurrentProfileMode != IMP__FINISH )
|
||||
{
|
||||
gfDisabilityTraitQuestions[ iCnt ] = FALSE;
|
||||
gfDisabilityTraitQuestions[ ubCnt ] = FALSE;
|
||||
}
|
||||
|
||||
if( iCnt == 0 )
|
||||
giIMPDisabilityTraitAnswerButtonImage[ iCnt ] = LoadButtonImage( "LAPTOP\\button_6.sti", -1,0,-1,1,-1 );
|
||||
if( ubCnt == 0 )
|
||||
giIMPDisabilityTraitAnswerButtonImage[ ubCnt ] = LoadButtonImage( "LAPTOP\\button_6.sti", -1,0,-1,1,-1 );
|
||||
else
|
||||
giIMPDisabilityTraitAnswerButtonImage[ iCnt ] = UseLoadedButtonImage( giIMPDisabilityTraitAnswerButtonImage[ 0 ], -1,0,-1,1,-1 );
|
||||
giIMPDisabilityTraitAnswerButtonImage[ ubCnt ] = UseLoadedButtonImage( giIMPDisabilityTraitAnswerButtonImage[ 0 ], -1,0,-1,1,-1 );
|
||||
|
||||
giIMPDisabilityTraitAnswerButton[iCnt] = QuickCreateButton( giIMPDisabilityTraitAnswerButtonImage[ iCnt ], usPosX, usPosY,
|
||||
giIMPDisabilityTraitAnswerButton[ubCnt] = QuickCreateButton( giIMPDisabilityTraitAnswerButtonImage[ ubCnt ], usPosX, usPosY,
|
||||
BUTTON_TOGGLE, MSYS_PRIORITY_HIGHEST - 3,
|
||||
MSYS_NO_CALLBACK, (GUI_CALLBACK)BtnIMPDisabilityTraitAnswerCallback);
|
||||
|
||||
//Set the button data
|
||||
MSYS_SetBtnUserData( giIMPDisabilityTraitAnswerButton[iCnt], 0, iCnt );
|
||||
SetButtonCursor( giIMPDisabilityTraitAnswerButton[iCnt], CURSOR_WWW);
|
||||
MSYS_SetBtnUserData( giIMPDisabilityTraitAnswerButton[ubCnt], 0, ubCnt );
|
||||
SetButtonCursor( giIMPDisabilityTraitAnswerButton[ubCnt], CURSOR_WWW);
|
||||
|
||||
//Get rid of playing the button sound, it will be handled here
|
||||
//ButtonList[ giIMPDisabilityTraitAnswerButton[ iCnt ] ]->ubSoundSchemeID = 0;
|
||||
//ButtonList[ giIMPDisabilityTraitAnswerButton[ ubCnt ] ]->ubSoundSchemeID = 0;
|
||||
|
||||
//Determine the next x location
|
||||
//if( iCnt < IMP_DISABILITY_TRAIT_NUMBER_TO_START_2ND_COLUMN )
|
||||
//if( ubCnt < IMP_DISABILITY_TRAIT_NUMBER_TO_START_2ND_COLUMN )
|
||||
usPosX = IMP_DISABILITY_COLUMN_START_X;
|
||||
//else
|
||||
// usPosX = IMP_DISABILITY_2ND_COLUMN_START_X;
|
||||
|
||||
//Determine the next Y location
|
||||
//if( iCnt == IMP_DISABILITY_TRAIT_NUMBER_TO_START_2ND_COLUMN )
|
||||
//if( ubCnt == IMP_DISABILITY_TRAIT_NUMBER_TO_START_2ND_COLUMN )
|
||||
// usPosY = IMP_DISABILITY_2ND_COLUMN_START_Y;
|
||||
//else
|
||||
usPosY += IMP_DISABILITY_TRAIT__SPACE_BTN_BUTTONS;
|
||||
@@ -258,7 +274,7 @@ void BtnIMPDisabilityTraitAnswerCallback(GUI_BUTTON *btn,INT32 reason)
|
||||
|
||||
void HandleIMPDisabilityTraitAnswers( UINT32 uiSkillPressed )
|
||||
{
|
||||
UINT32 uiCnt;
|
||||
UINT8 ubCnt;
|
||||
|
||||
//if we are DONE and are just reviewing
|
||||
if( iCurrentProfileMode == IMP__FINISH )
|
||||
@@ -267,9 +283,9 @@ void HandleIMPDisabilityTraitAnswers( UINT32 uiSkillPressed )
|
||||
}
|
||||
|
||||
//reset all other buttons
|
||||
for( uiCnt=0; uiCnt<IMP_DISABILITIES_NUMBER; uiCnt++ )
|
||||
for( ubCnt=0; ubCnt<IMP_DISABILITIES_NUMBER; ubCnt++ )
|
||||
{
|
||||
gfDisabilityTraitQuestions[ uiCnt ] = FALSE;
|
||||
gfDisabilityTraitQuestions[ ubCnt ] = FALSE;
|
||||
}
|
||||
|
||||
//make sure its a valid disability trait
|
||||
@@ -308,26 +324,25 @@ void HandleIMPDisabilityTraitAnswers( UINT32 uiSkillPressed )
|
||||
|
||||
void HandleDisabilityTraitButtonStates( )
|
||||
{
|
||||
UINT32 uiCnt;
|
||||
UINT8 ubCnt;
|
||||
|
||||
for( uiCnt=0; uiCnt<IMP_DISABILITIES_NUMBER; uiCnt++ )
|
||||
for( ubCnt=0; ubCnt<IMP_DISABILITIES_NUMBER; ubCnt++ )
|
||||
{
|
||||
|
||||
//if the skill is selected ( ie depressed )
|
||||
if( gfDisabilityTraitQuestions[ uiCnt ] )
|
||||
if( gfDisabilityTraitQuestions[ ubCnt ] )
|
||||
{
|
||||
ButtonList[ giIMPDisabilityTraitAnswerButton[ uiCnt ] ]->uiFlags |= BUTTON_CLICKED_ON;
|
||||
ButtonList[ giIMPDisabilityTraitAnswerButton[ ubCnt ] ]->uiFlags |= BUTTON_CLICKED_ON;
|
||||
}
|
||||
else
|
||||
{
|
||||
ButtonList[ giIMPDisabilityTraitAnswerButton[ uiCnt ] ]->uiFlags &= ~BUTTON_CLICKED_ON;
|
||||
ButtonList[ giIMPDisabilityTraitAnswerButton[ ubCnt ] ]->uiFlags &= ~BUTTON_CLICKED_ON;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void IMPDisabilityTraitDisplayDisabilityTraits()
|
||||
{
|
||||
UINT32 uiCnt;
|
||||
UINT8 ubCnt;
|
||||
UINT16 usPosX, usPosY;
|
||||
UINT16 usBoxPosX, usBoxPosY;
|
||||
HVOBJECT hImageHandle;
|
||||
@@ -342,13 +357,13 @@ void IMPDisabilityTraitDisplayDisabilityTraits()
|
||||
usPosX = IMP_DISABILITY_COLUMN_START_X + IMP_DISABILITY_TRAIT__TEXT_OFFSET_X;
|
||||
usPosY = IMP_DISABILITY_COLUMN_START_Y + IMP_DISABILITY_TRAIT__TEXT_OFFSET_Y;
|
||||
|
||||
for( uiCnt=0; uiCnt<IMP_DISABILITIES_NUMBER; uiCnt++ )
|
||||
for( ubCnt=0; ubCnt<IMP_DISABILITIES_NUMBER; ubCnt++ )
|
||||
{
|
||||
usBoxPosX = usPosX - IMP_DISABILITY_TRAIT__GREY_BOX_OFFSET_X;
|
||||
usBoxPosY = usPosY - IMP_DISABILITY_TRAIT__GREY_BOX_OFFSET_Y;
|
||||
|
||||
//if the trait is selected
|
||||
if( gfDisabilityTraitQuestions[ uiCnt ] )
|
||||
if( gfDisabilityTraitQuestions[ ubCnt ] )
|
||||
{
|
||||
//Display the gold background box
|
||||
BltVideoObject(FRAME_BUFFER, hImageHandle, 1, usBoxPosX, usBoxPosY, VO_BLT_SRCTRANSPARENCY,NULL);
|
||||
@@ -360,16 +375,18 @@ void IMPDisabilityTraitDisplayDisabilityTraits()
|
||||
}
|
||||
|
||||
//draw the text to the screenx
|
||||
DrawTextToScreen( gzIMPDisabilityTraitText[ uiCnt ], usPosX, usPosY, 0, IMP_DISABILITY_TRAIT__FONT, IMP_DISABILITY_TRAIT__COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED );
|
||||
DrawTextToScreen( gzIMPDisabilityTraitText[ ubCnt ], usPosX, usPosY, 0, IMP_DISABILITY_TRAIT__FONT, IMP_DISABILITY_TRAIT__COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED );
|
||||
|
||||
AssignDisabilityHelpText( ubCnt );
|
||||
|
||||
//Determine the next x location
|
||||
// if( uiCnt < IMP_DISABILITY_TRAIT_NUMBER_TO_START_2ND_COLUMN )
|
||||
// if( ubCnt < IMP_DISABILITY_TRAIT_NUMBER_TO_START_2ND_COLUMN )
|
||||
usPosX = IMP_DISABILITY_COLUMN_START_X + IMP_DISABILITY_TRAIT__TEXT_OFFSET_X;
|
||||
//else
|
||||
// usPosX = IMP_DISABILITY_2ND_COLUMN_START_X + IMP_DISABILITY_TRAIT__TEXT_OFFSET_X;
|
||||
|
||||
//Determine the next Y location
|
||||
//if( uiCnt == IMP_DISABILITY_TRAIT_NUMBER_TO_START_2ND_COLUMN )
|
||||
//if( ubCnt == IMP_DISABILITY_TRAIT_NUMBER_TO_START_2ND_COLUMN )
|
||||
// usPosY = IMP_DISABILITY_2ND_COLUMN_START_Y + IMP_DISABILITY_TRAIT__TEXT_OFFSET_Y;
|
||||
//else
|
||||
usPosY += IMP_DISABILITY_TRAIT__SPACE_BTN_BUTTONS;
|
||||
@@ -427,16 +444,16 @@ BOOLEAN CameBackToDisabilityTraitPageButNotFinished()
|
||||
|
||||
INT8 iChosenDisabilityTrait()
|
||||
{
|
||||
UINT32 uiCnt;
|
||||
UINT8 ubCnt;
|
||||
INT8 iDisabilityTraitNumber = 0;
|
||||
|
||||
//loop through all the buttons and reset them
|
||||
for( uiCnt=0; uiCnt<IMP_DISABILITIES_NUMBER; uiCnt++ )
|
||||
for( ubCnt=0; ubCnt<IMP_DISABILITIES_NUMBER; ubCnt++ )
|
||||
{
|
||||
//if the trait is selected
|
||||
if( gfDisabilityTraitQuestions[ uiCnt ] )
|
||||
if( gfDisabilityTraitQuestions[ ubCnt ] )
|
||||
{
|
||||
iDisabilityTraitNumber = uiCnt;
|
||||
iDisabilityTraitNumber = ubCnt;
|
||||
}
|
||||
}
|
||||
return( iDisabilityTraitNumber );
|
||||
@@ -457,4 +474,18 @@ INT8 iPlayersAttributePointsBonusForDisabilitySelected()
|
||||
}
|
||||
|
||||
return( bExtraAttributePoints );
|
||||
}
|
||||
|
||||
void AssignDisabilityHelpText( UINT8 ubNumber )
|
||||
{
|
||||
CHAR16 apStr[ 2000 ];
|
||||
|
||||
swprintf( apStr, L"" );
|
||||
swprintf( apStr, gzIMPDisabilitiesHelpTexts[ubNumber] );
|
||||
|
||||
// Set region help text
|
||||
SetRegionFastHelpText( &(gMR_DisabilityHelpTextRegions[ubNumber]), apStr );
|
||||
SetRegionHelpEndCallback( &gMR_DisabilityHelpTextRegions[ubNumber], MSYS_NO_CALLBACK );
|
||||
|
||||
return;
|
||||
}
|
||||
+22
-1
@@ -24,6 +24,9 @@
|
||||
#include "text.h"
|
||||
#endif
|
||||
|
||||
|
||||
#include "IMP Confirm.h"
|
||||
|
||||
// min time btween frames of animation
|
||||
#define ANIMATE_MIN_TIME 200
|
||||
|
||||
@@ -659,7 +662,25 @@ BOOLEAN LoadCharacterPortrait( void )
|
||||
|
||||
// load it
|
||||
VObjectDesc.fCreateFlags=VOBJECT_CREATE_FROMFILE;
|
||||
FilenameForBPP( pPlayerSelectedFaceFileNames[ iPortraitNumber ] , VObjectDesc.ImageFile);
|
||||
|
||||
|
||||
if( fCharacterIsMale )
|
||||
{
|
||||
if ( gIMPMaleValues[ iPortraitNumber ].Enabled == 1 )
|
||||
{
|
||||
sprintf( VObjectDesc.ImageFile, "Faces\\%02d.sti", gIMPMaleValues[ iPortraitNumber ].PortraitId );
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if ( gIMPFemaleValues[ iPortraitNumber ].Enabled == 1 )
|
||||
{
|
||||
sprintf( VObjectDesc.ImageFile, "Faces\\%02d.sti", gIMPFemaleValues[ iPortraitNumber ].PortraitId );
|
||||
}
|
||||
}
|
||||
|
||||
//FilenameForBPP( pPlayerSelectedFaceFileNames[ iPortraitNumber ] , VObjectDesc.ImageFile);
|
||||
|
||||
CHECKF(AddVideoObject(&VObjectDesc, &guiCHARACTERPORTRAIT));
|
||||
|
||||
return( TRUE );
|
||||
|
||||
@@ -414,7 +414,7 @@ void ProcessPlayerInputActivationString( void )
|
||||
return;
|
||||
}
|
||||
|
||||
if (CountFilledIMPSlots(-1) < gGameExternalOptions.iMaxIMPCharacters)
|
||||
if (CountFilledIMPSlots(-1) < gGameOptions.ubMaxIMPCharacters)
|
||||
{
|
||||
// Kaiden: Need to reset skills, attributes and personalities with the new UB Method.
|
||||
ResetSkillsAttributesAndPersonality( );
|
||||
@@ -436,7 +436,7 @@ void ProcessPlayerInputActivationString( void )
|
||||
return;
|
||||
}
|
||||
|
||||
if (CountFilledIMPSlots(-1) < gGameExternalOptions.iMaxIMPCharacters)
|
||||
if (CountFilledIMPSlots(-1) < gGameOptions.ubMaxIMPCharacters)
|
||||
{
|
||||
if (LoadImpCharacter( IMP_MERC_FILENAME ) == TRUE)
|
||||
{
|
||||
@@ -462,7 +462,7 @@ void ProcessPlayerInputActivationString( void )
|
||||
return;
|
||||
}
|
||||
|
||||
if (CountFilledIMPSlots(-1) < gGameExternalOptions.iMaxIMPCharacters)
|
||||
if (CountFilledIMPSlots(-1) < gGameOptions.ubMaxIMPCharacters)
|
||||
{
|
||||
if (LoadImpCharacter( charPlayerActivationString ) == TRUE)
|
||||
{
|
||||
|
||||
+20
-2
@@ -27,6 +27,7 @@
|
||||
#include "Squads.h"
|
||||
#endif
|
||||
|
||||
#include "IMP Confirm.h"
|
||||
|
||||
#define MAIN_PAGE_BUTTON_TEXT_WIDTH 95
|
||||
|
||||
@@ -599,7 +600,8 @@ void BtnIMPMainPageBeginCallback(GUI_BUTTON *btn,INT32 reason)
|
||||
}
|
||||
else
|
||||
{
|
||||
if( LaptopSaveInfo.iCurrentBalance < COST_OF_PROFILE )
|
||||
//if( LaptopSaveInfo.iCurrentBalance < COST_OF_PROFILE )
|
||||
if( LaptopSaveInfo.iCurrentBalance < iGetProfileCost() ) // SANDRO - changed to find actual profile cost in IMPConfirm
|
||||
{
|
||||
DoLapTopMessageBox( MSG_BOX_IMP_STYLE, pImpPopUpStrings[ 3 ], LAPTOP_SCREEN, MSG_BOX_FLAG_OK, BeginMessageBoxCallBack);
|
||||
|
||||
@@ -1117,7 +1119,23 @@ BOOLEAN LoadCharacterPortraitForMainPage( void )
|
||||
{
|
||||
// load it
|
||||
VObjectDesc.fCreateFlags=VOBJECT_CREATE_FROMFILE;
|
||||
FilenameForBPP( pPlayerSelectedFaceFileNames[ iPortraitNumber ] , VObjectDesc.ImageFile);
|
||||
|
||||
if( fCharacterIsMale )
|
||||
{
|
||||
if ( gIMPMaleValues[ iPortraitNumber ].Enabled == 1 )
|
||||
{
|
||||
sprintf( VObjectDesc.ImageFile, "Faces\\%02d.sti", gIMPMaleValues[ iPortraitNumber ].PortraitId );
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if ( gIMPFemaleValues[ iPortraitNumber ].Enabled == 1 )
|
||||
{
|
||||
sprintf( VObjectDesc.ImageFile, "Faces\\%02d.sti", gIMPFemaleValues[ iPortraitNumber ].PortraitId );
|
||||
}
|
||||
}
|
||||
//FilenameForBPP( pPlayerSelectedFaceFileNames[ iPortraitNumber ] , VObjectDesc.ImageFile);
|
||||
|
||||
CHECKF(AddVideoObject(&VObjectDesc, &guiCHARACTERPORTRAITFORMAINPAGE));
|
||||
|
||||
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,44 @@
|
||||
#ifndef __IMP_MINOR_TRAIT__H_
|
||||
#define __IMP_MINOR_TRAIT__H_
|
||||
|
||||
#include "Types.h"
|
||||
|
||||
void EnterIMPMinorTrait( void );
|
||||
void RenderIMPMinorTrait( void );
|
||||
void ExitIMPMinorTrait( void );
|
||||
void HandleIMPMinorTrait( void );
|
||||
|
||||
enum
|
||||
{
|
||||
// minor traits
|
||||
IMP_SKILL_TRAITS_NEW_AMBIDEXTROUS,
|
||||
IMP_SKILL_TRAITS_NEW_MELEE,
|
||||
IMP_SKILL_TRAITS_NEW_THROWING,
|
||||
IMP_SKILL_TRAITS_NEW_NIGHT_OPS,
|
||||
IMP_SKILL_TRAITS_NEW_STEALTHY,
|
||||
IMP_SKILL_TRAITS_NEW_ATHLETICS,
|
||||
IMP_SKILL_TRAITS_NEW_BODYBUILDING,
|
||||
IMP_SKILL_TRAITS_NEW_DEMOLITIONS,
|
||||
IMP_SKILL_TRAITS_NEW_TEACHING,
|
||||
IMP_SKILL_TRAITS_NEW_SCOUTING,
|
||||
//////
|
||||
IMP_SKILL_TRAITS_NEW_MINOR_NONE,
|
||||
IMP_SKILL_TRAITS_NEW_NUMBER_MINOR_SKILLS,
|
||||
};
|
||||
|
||||
void AddSelectedMinorTraitsToSkillsList();
|
||||
|
||||
INT8 CountNumMinorTraitsSelected( BOOLEAN fIncludeNoneSkill );
|
||||
|
||||
UINT8 StrengthRequiredAdjustmentForMinorTraits( INT32 iInitialValue );
|
||||
UINT8 DexterityRequiredAdjustmentForMinorTraits( INT32 iInitialValue );
|
||||
UINT8 AgilityRequiredAdjustmentForMinorTraits( INT32 iInitialValue );
|
||||
UINT8 HealthRequiredAdjustmentForMinorTraits( INT32 iInitialValue );
|
||||
UINT8 WisdomRequiredAdjustmentForMinorTraits( INT32 iInitialValue );
|
||||
UINT8 LeaderShipRequiredAdjustmentForMinorTraits( INT32 iInitialValue );
|
||||
UINT8 MarksmanshipRequiredAdjustmentForMinorTraits( INT32 iInitialValue );
|
||||
UINT8 MechanicalRequiredAdjustmentForMinorTraits( INT32 iInitialValue );
|
||||
UINT8 MedicalRequiredAdjustmentForMinorTraits( INT32 iInitialValue );
|
||||
UINT8 ExplosivesRequiredAdjustmentForMinorTraits( INT32 iInitialValue );
|
||||
|
||||
#endif
|
||||
@@ -7,4 +7,6 @@ void RenderIMPPersonalityEntrance( void );
|
||||
void ExitIMPPersonalityEntrance( void );
|
||||
void HandleIMPPersonalityEntrance( void );
|
||||
|
||||
STR16 pSkillTraitBeginIMPStrings[];
|
||||
|
||||
#endif
|
||||
@@ -21,6 +21,7 @@
|
||||
#include "english.h"
|
||||
#endif
|
||||
|
||||
|
||||
// Kaiden this line was commented before I screwed with it
|
||||
//extern struct POINT;
|
||||
|
||||
@@ -207,10 +208,10 @@ void CreateIMPPersonalityQuizButtons( void )
|
||||
// ths Done button
|
||||
giIMPPersonalityQuizButtonImage[0]= LoadButtonImage( "LAPTOP\\button_7.sti" ,-1,0,-1,1,-1 );
|
||||
|
||||
/* giIMPPersonalityQuizButton[0] = QuickCreateButton( giIMPPersonalityQuizButtonImage[0], LAPTOP_SCREEN_UL_X + ( 197 ), LAPTOP_SCREEN_WEB_UL_Y + ( 310 ),
|
||||
BUTTON_TOGGLE, MSYS_PRIORITY_HIGHEST - 1,
|
||||
BtnGenericMouseMoveButtonCallback, (GUI_CALLBACK)BtnIMPPersonalityQuizAnswerConfirmCallback);
|
||||
*/
|
||||
// giIMPPersonalityQuizButton[0] = QuickCreateButton( giIMPPersonalityQuizButtonImage[0], LAPTOP_SCREEN_UL_X + ( 197 ), LAPTOP_SCREEN_WEB_UL_Y + ( 310 ),
|
||||
// BUTTON_TOGGLE, MSYS_PRIORITY_HIGHEST - 1,
|
||||
// BtnGenericMouseMoveButtonCallback, (GUI_CALLBACK)BtnIMPPersonalityQuizAnswerConfirmCallback);
|
||||
//
|
||||
giIMPPersonalityQuizButton[0] = CreateIconAndTextButton( giIMPPersonalityQuizButtonImage[0], pImpButtonText[ 8 ], FONT12ARIAL,
|
||||
FONT_WHITE, DEFAULT_SHADOW,
|
||||
FONT_WHITE, DEFAULT_SHADOW,
|
||||
@@ -221,10 +222,10 @@ void CreateIMPPersonalityQuizButtons( void )
|
||||
// start over
|
||||
giIMPPersonalityQuizButtonImage[ 1 ]= LoadButtonImage( "LAPTOP\\button_5.sti" ,-1,0,-1,1,-1 );
|
||||
|
||||
/* giIMPPersonalityQuizButton[ 1 ] = QuickCreateButton( giIMPPersonalityQuizButtonImage[1], LAPTOP_SCREEN_UL_X + ( BTN_FIRST_COLUMN_X ), LAPTOP_SCREEN_WEB_UL_Y + ( 310 ),
|
||||
BUTTON_TOGGLE, MSYS_PRIORITY_HIGHEST - 1,
|
||||
BtnGenericMouseMoveButtonCallback, (GUI_CALLBACK)BtnIMPPersonalityQuizStartOverCallback);
|
||||
*/
|
||||
// giIMPPersonalityQuizButton[ 1 ] = QuickCreateButton( giIMPPersonalityQuizButtonImage[1], LAPTOP_SCREEN_UL_X + ( BTN_FIRST_COLUMN_X ), LAPTOP_SCREEN_WEB_UL_Y + ( 310 ),
|
||||
// BUTTON_TOGGLE, MSYS_PRIORITY_HIGHEST - 1,
|
||||
// BtnGenericMouseMoveButtonCallback, (GUI_CALLBACK)BtnIMPPersonalityQuizStartOverCallback);
|
||||
//
|
||||
|
||||
giIMPPersonalityQuizButton[ 1 ] = CreateIconAndTextButton( giIMPPersonalityQuizButtonImage[ 1 ], pImpButtonText[ 7 ], FONT12ARIAL,
|
||||
FONT_WHITE, DEFAULT_SHADOW,
|
||||
@@ -1024,12 +1025,12 @@ void CompileQuestionsInStatsAndWhatNot( void )
|
||||
if( fCharacterIsMale )
|
||||
{
|
||||
// Martial arts
|
||||
AddSkillToSkillList( MARTIALARTS );
|
||||
AddSkillToSkillList( MARTIALARTS_OT );
|
||||
}
|
||||
else
|
||||
{
|
||||
// for women, ambidexterious
|
||||
AddSkillToSkillList( AMBIDEXT );
|
||||
AddSkillToSkillList( AMBIDEXT_OT );
|
||||
}
|
||||
break;
|
||||
case( 1 ):
|
||||
@@ -1037,15 +1038,15 @@ void CompileQuestionsInStatsAndWhatNot( void )
|
||||
break;
|
||||
case( 2 ):
|
||||
// hand to hand
|
||||
AddSkillToSkillList( HANDTOHAND );
|
||||
AddSkillToSkillList( HANDTOHAND_OT );
|
||||
break;
|
||||
case( 3 ):
|
||||
// lock picking
|
||||
AddSkillToSkillList( LOCKPICKING );
|
||||
AddSkillToSkillList( LOCKPICKING_OT );
|
||||
break;
|
||||
case( 4 ):
|
||||
// throwing
|
||||
AddSkillToSkillList( THROWING );
|
||||
AddSkillToSkillList( THROWING_OT );
|
||||
break;
|
||||
case( 5 ):
|
||||
// optimist
|
||||
@@ -1058,10 +1059,10 @@ void CompileQuestionsInStatsAndWhatNot( void )
|
||||
{
|
||||
case( 0 ):
|
||||
// teaching
|
||||
AddSkillToSkillList( TEACHING );
|
||||
AddSkillToSkillList( TEACHING_OT );
|
||||
break;
|
||||
case( 1 ):
|
||||
AddSkillToSkillList( STEALTHY );
|
||||
AddSkillToSkillList( STEALTHY_OT );
|
||||
break;
|
||||
case( 2 ):
|
||||
// psycho
|
||||
@@ -1077,14 +1078,14 @@ void CompileQuestionsInStatsAndWhatNot( void )
|
||||
{
|
||||
case( 0 ):
|
||||
// lock picking
|
||||
AddSkillToSkillList( LOCKPICKING );
|
||||
AddSkillToSkillList( LOCKPICKING_OT );
|
||||
break;
|
||||
case( 1 ):
|
||||
// arrogant
|
||||
AddAnAttitudeToAttitudeList( ATT_ARROGANT );
|
||||
break;
|
||||
case( 2 ):
|
||||
AddSkillToSkillList( STEALTHY );
|
||||
AddSkillToSkillList( STEALTHY_OT );
|
||||
break;
|
||||
case( 3 ):
|
||||
// normal
|
||||
@@ -1098,7 +1099,7 @@ void CompileQuestionsInStatsAndWhatNot( void )
|
||||
{
|
||||
case( 0 ):
|
||||
// automatic weapons
|
||||
AddSkillToSkillList( AUTO_WEAPS );
|
||||
AddSkillToSkillList( AUTO_WEAPS_OT );
|
||||
break;
|
||||
case( 1 ):
|
||||
// friendly
|
||||
@@ -1146,7 +1147,7 @@ void CompileQuestionsInStatsAndWhatNot( void )
|
||||
AddAnAttitudeToAttitudeList( ATT_COWARD );
|
||||
break;
|
||||
case( 1 ):
|
||||
AddSkillToSkillList( NIGHTOPS );
|
||||
AddSkillToSkillList( NIGHTOPS_OT );
|
||||
break;
|
||||
case( 2 ):
|
||||
// dont like boxes much
|
||||
@@ -1165,14 +1166,14 @@ void CompileQuestionsInStatsAndWhatNot( void )
|
||||
{
|
||||
case( 0 ):
|
||||
// electronics
|
||||
AddSkillToSkillList( ELECTRONICS );
|
||||
AddSkillToSkillList( ELECTRONICS_OT );
|
||||
break;
|
||||
case( 1 ):
|
||||
//knifing
|
||||
AddSkillToSkillList( KNIFING );
|
||||
AddSkillToSkillList( KNIFING_OT );
|
||||
break;
|
||||
case( 2 ):
|
||||
AddSkillToSkillList( NIGHTOPS );
|
||||
AddSkillToSkillList( NIGHTOPS_OT );
|
||||
break;
|
||||
case( 3 ):
|
||||
// none
|
||||
@@ -1184,7 +1185,7 @@ void CompileQuestionsInStatsAndWhatNot( void )
|
||||
{
|
||||
case( 0 ):
|
||||
// ambidexterous
|
||||
AddSkillToSkillList( AMBIDEXT );
|
||||
AddSkillToSkillList( AMBIDEXT_OT );
|
||||
break;
|
||||
case( 1 ):
|
||||
// none
|
||||
@@ -1247,7 +1248,7 @@ void CompileQuestionsInStatsAndWhatNot( void )
|
||||
break;
|
||||
case( 1 ):
|
||||
// teaching
|
||||
AddSkillToSkillList( TEACHING );
|
||||
AddSkillToSkillList( TEACHING_OT );
|
||||
break;
|
||||
case( 2 ):
|
||||
// aggressive
|
||||
@@ -1269,32 +1270,32 @@ void CompileQuestionsInStatsAndWhatNot( void )
|
||||
if( fCharacterIsMale )
|
||||
{
|
||||
// Martial arts
|
||||
AddSkillToSkillList( MARTIALARTS );
|
||||
AddSkillToSkillList( MARTIALARTS_OT );
|
||||
}
|
||||
else
|
||||
{
|
||||
// for women, ambidexterious
|
||||
AddSkillToSkillList( AMBIDEXT );
|
||||
AddSkillToSkillList( AMBIDEXT_OT );
|
||||
}
|
||||
break;
|
||||
case( 1 ):
|
||||
//knifing
|
||||
AddSkillToSkillList( KNIFING );
|
||||
AddSkillToSkillList( KNIFING_OT );
|
||||
break;
|
||||
case( 2 ):
|
||||
// none
|
||||
break;
|
||||
case( 3 ):
|
||||
// automatic weapons
|
||||
AddSkillToSkillList( AUTO_WEAPS );
|
||||
AddSkillToSkillList( AUTO_WEAPS_OT );
|
||||
break;
|
||||
case( 4 ):
|
||||
// hand to hand
|
||||
AddSkillToSkillList( HANDTOHAND );
|
||||
AddSkillToSkillList( HANDTOHAND_OT );
|
||||
break;
|
||||
case( 5 ):
|
||||
// electronics
|
||||
AddSkillToSkillList( ELECTRONICS );
|
||||
AddSkillToSkillList( ELECTRONICS_OT );
|
||||
break;
|
||||
case( 6 ):
|
||||
// ashole
|
||||
@@ -1350,11 +1351,11 @@ void CompileQuestionsInStatsAndWhatNot( void )
|
||||
{
|
||||
case( 0 ):
|
||||
// throwing
|
||||
AddSkillToSkillList( THROWING );
|
||||
AddSkillToSkillList( THROWING_OT );
|
||||
break;
|
||||
case( 1 ):
|
||||
// ambidexterous
|
||||
AddSkillToSkillList( AMBIDEXT );
|
||||
AddSkillToSkillList( AMBIDEXT_OT );
|
||||
break;
|
||||
case( 3 ):
|
||||
// none
|
||||
@@ -1622,71 +1623,71 @@ void HandleIMPQuizKeyBoard( void )
|
||||
// HOOK INTO MOUSE HOOKS
|
||||
|
||||
|
||||
/*
|
||||
if( (InputEvent.usEvent == KEY_DOWN ) && ( InputEvent.usParam >= '1' ) && ( InputEvent.usParam <= '9') )
|
||||
{
|
||||
if( ( UINT16 )( iNumberOfPersonaButtons ) >= InputEvent.usParam - '0' )
|
||||
{
|
||||
//
|
||||
//if( (InputEvent.usEvent == KEY_DOWN ) && ( InputEvent.usParam >= '1' ) && ( InputEvent.usParam <= '9') )
|
||||
//{
|
||||
// if( ( UINT16 )( iNumberOfPersonaButtons ) >= InputEvent.usParam - '0' )
|
||||
// {
|
||||
// reset buttons
|
||||
ResetQuizAnswerButtons( );
|
||||
// ResetQuizAnswerButtons( );
|
||||
|
||||
// ok, check to see if button was disabled, if so, re enable
|
||||
CheckStateOfTheConfirmButton( );
|
||||
// CheckStateOfTheConfirmButton( );
|
||||
|
||||
// toggle this button on
|
||||
ButtonList[ giIMPPersonalityQuizAnswerButton[ InputEvent.usParam - '1' ] ]->uiFlags |= (BUTTON_CLICKED_ON);
|
||||
// ButtonList[ giIMPPersonalityQuizAnswerButton[ InputEvent.usParam - '1' ] ]->uiFlags |= (BUTTON_CLICKED_ON);
|
||||
|
||||
iCurrentAnswer = InputEvent.usParam - '1';
|
||||
// iCurrentAnswer = InputEvent.usParam - '1';
|
||||
|
||||
PrintImpText( );
|
||||
// PrintImpText( );
|
||||
|
||||
// the current and last question numbers
|
||||
PrintQuizQuestionNumber( );
|
||||
// PrintQuizQuestionNumber( );
|
||||
|
||||
fReDrawCharProfile = TRUE;
|
||||
fSkipFrame = TRUE;
|
||||
}
|
||||
}
|
||||
else if( ( iCurrentAnswer != -1 ) && ( InputEvent.usEvent == KEY_DOWN ) && ( InputEvent.usParam == ENTER ) )
|
||||
{
|
||||
// fReDrawCharProfile = TRUE;
|
||||
// fSkipFrame = TRUE;
|
||||
// }
|
||||
// }
|
||||
// else if( ( iCurrentAnswer != -1 ) && ( InputEvent.usEvent == KEY_DOWN ) && ( InputEvent.usParam == ENTER ) )
|
||||
// {
|
||||
// reset all the buttons
|
||||
ResetQuizAnswerButtons( );
|
||||
// ResetQuizAnswerButtons( );
|
||||
|
||||
// copy the answer into the list
|
||||
iQuizAnswerList[ giCurrentPersonalityQuizQuestion ] = iCurrentAnswer;
|
||||
// iQuizAnswerList[ giCurrentPersonalityQuizQuestion ] = iCurrentAnswer;
|
||||
|
||||
// reset answer for next question
|
||||
iCurrentAnswer = -1;
|
||||
// iCurrentAnswer = -1;
|
||||
|
||||
// next question, JOHNNY!
|
||||
giCurrentPersonalityQuizQuestion++;
|
||||
giMaxPersonalityQuizQuestion++;
|
||||
// giCurrentPersonalityQuizQuestion++;
|
||||
// giMaxPersonalityQuizQuestion++;
|
||||
|
||||
|
||||
// OPPS!, done..time to finish up
|
||||
if( giCurrentPersonalityQuizQuestion > 15)
|
||||
{
|
||||
iCurrentImpPage = IMP_PERSONALITY_FINISH;
|
||||
// if( giCurrentPersonalityQuizQuestion > 15)
|
||||
// {
|
||||
// iCurrentImpPage = IMP_PERSONALITY_FINISH;
|
||||
// process
|
||||
CompileQuestionsInStatsAndWhatNot( );
|
||||
}
|
||||
// CompileQuestionsInStatsAndWhatNot( );
|
||||
// }
|
||||
|
||||
fSkipFrame = TRUE;
|
||||
}
|
||||
else if( ( InputEvent.usEvent == KEY_DOWN ) && ( InputEvent.usParam == '=' ) )
|
||||
{
|
||||
MoveAheadAQuestion( );
|
||||
fSkipFrame = TRUE;
|
||||
}
|
||||
else if( ( InputEvent.usEvent == KEY_DOWN ) && ( InputEvent.usParam == '-' ) )
|
||||
{
|
||||
MoveBackAQuestion( );
|
||||
fSkipFrame = TRUE;
|
||||
}
|
||||
else
|
||||
{
|
||||
// fSkipFrame = TRUE;
|
||||
// }
|
||||
// else if( ( InputEvent.usEvent == KEY_DOWN ) && ( InputEvent.usParam == '=' ) )
|
||||
// {
|
||||
// MoveAheadAQuestion( );
|
||||
// fSkipFrame = TRUE;
|
||||
// }
|
||||
// else if( ( InputEvent.usEvent == KEY_DOWN ) && ( InputEvent.usParam == '-' ) )
|
||||
// {
|
||||
// MoveBackAQuestion( );
|
||||
// fSkipFrame = TRUE;
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
|
||||
*/ switch(InputEvent.usEvent)
|
||||
switch(InputEvent.usEvent)
|
||||
{
|
||||
case LEFT_BUTTON_DOWN:
|
||||
MouseSystemHook(LEFT_BUTTON_DOWN, (INT16)MousePos.x, (INT16)MousePos.y,_LeftButtonDown, _RightButtonDown);
|
||||
@@ -1761,19 +1762,19 @@ void MoveAheadAQuestion( void )
|
||||
|
||||
CheckAndUpdateNextPreviousIMPQuestionButtonStates( );
|
||||
|
||||
/*
|
||||
EnableButton( giPreviousQuestionButton );
|
||||
|
||||
if( giCurrentPersonalityQuizQuestion >= giMaxPersonalityQuizQuestion )
|
||||
{
|
||||
DisableButton( giNextQuestionButton );
|
||||
iCurrentAnswer = -1;
|
||||
}
|
||||
else
|
||||
{
|
||||
EnableButton( giNextQuestionButton );
|
||||
}
|
||||
*/
|
||||
// EnableButton( giPreviousQuestionButton );
|
||||
|
||||
// if( giCurrentPersonalityQuizQuestion >= giMaxPersonalityQuizQuestion )
|
||||
// {
|
||||
// DisableButton( giNextQuestionButton );
|
||||
// iCurrentAnswer = -1;
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
// EnableButton( giNextQuestionButton );
|
||||
// }
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -1792,16 +1793,16 @@ void MoveBackAQuestion( void )
|
||||
EnableButton( giNextQuestionButton );
|
||||
|
||||
CheckAndUpdateNextPreviousIMPQuestionButtonStates( );
|
||||
/*
|
||||
if( giCurrentPersonalityQuizQuestion == 0 )
|
||||
{
|
||||
DisableButton( giPreviousQuestionButton );
|
||||
}
|
||||
else
|
||||
{
|
||||
EnableButton( giPreviousQuestionButton );
|
||||
}
|
||||
*/
|
||||
|
||||
// if( giCurrentPersonalityQuizQuestion == 0 )
|
||||
// {
|
||||
// DisableButton( giPreviousQuestionButton );
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
// EnableButton( giPreviousQuestionButton );
|
||||
// }
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
+105
-17
@@ -21,10 +21,15 @@
|
||||
#include "IMP Compile Character.h"
|
||||
#endif
|
||||
|
||||
#include "IMP Confirm.h"
|
||||
|
||||
//current and last pages
|
||||
INT32 iCurrentPortrait = 0;
|
||||
INT32 iLastPicture = 7;
|
||||
|
||||
INT32 iLastPictureF;
|
||||
INT32 iLastPictureM;
|
||||
|
||||
// buttons needed for the IMP portrait screen
|
||||
INT32 giIMPPortraitButton[ 3 ];
|
||||
INT32 giIMPPortraitButtonImage[ 3 ];
|
||||
@@ -52,6 +57,7 @@ void BtnIMPPortraitDoneCallback(GUI_BUTTON *btn,INT32 reason);
|
||||
void EnterIMPPortraits( void )
|
||||
{
|
||||
|
||||
iCurrentPortrait = 0;
|
||||
// create buttons
|
||||
CreateIMPPortraitButtons( );
|
||||
|
||||
@@ -121,7 +127,15 @@ BOOLEAN RenderPortrait( INT16 sX, INT16 sY )
|
||||
|
||||
// load it
|
||||
VObjectDesc.fCreateFlags=VOBJECT_CREATE_FROMFILE;
|
||||
FilenameForBPP( pPlayerSelectedBigFaceFileNames[ iCurrentPortrait ] , VObjectDesc.ImageFile);
|
||||
|
||||
|
||||
if ( gIMPMaleValues[ iCurrentPortrait ].Enabled == 1 )
|
||||
{
|
||||
sprintf( VObjectDesc.ImageFile, "Faces\\BigFaces\\%02d.sti", gIMPMaleValues[ iCurrentPortrait ].PortraitId );
|
||||
}
|
||||
|
||||
|
||||
//FilenameForBPP( pPlayerSelectedBigFaceFileNames[ iCurrentPortrait ] , VObjectDesc.ImageFile);
|
||||
CHECKF(AddVideoObject(&VObjectDesc, &uiGraphicHandle));
|
||||
|
||||
// show it
|
||||
@@ -138,7 +152,15 @@ BOOLEAN RenderPortrait( INT16 sX, INT16 sY )
|
||||
{
|
||||
// load it
|
||||
VObjectDesc.fCreateFlags=VOBJECT_CREATE_FROMFILE;
|
||||
FilenameForBPP( pPlayerSelectedBigFaceFileNames[ iCurrentPortrait + 8 ] , VObjectDesc.ImageFile);
|
||||
|
||||
//FilenameForBPP( pPlayerSelectedBigFaceFileNames[ iCurrentPortrait + 8 ] , VObjectDesc.ImageFile);
|
||||
|
||||
if ( gIMPFemaleValues[ iCurrentPortrait ].Enabled == 1 )
|
||||
{
|
||||
sprintf( VObjectDesc.ImageFile, "Faces\\BigFaces\\%02d.sti", gIMPFemaleValues[ iCurrentPortrait ].PortraitId );
|
||||
}
|
||||
|
||||
|
||||
CHECKF(AddVideoObject(&VObjectDesc, &uiGraphicHandle));
|
||||
|
||||
// show it
|
||||
@@ -154,12 +176,35 @@ BOOLEAN RenderPortrait( INT16 sX, INT16 sY )
|
||||
return ( TRUE );
|
||||
}
|
||||
|
||||
|
||||
|
||||
void IncrementPictureIndex( void )
|
||||
{
|
||||
// cycle to next picture
|
||||
|
||||
iCurrentPortrait++;
|
||||
if( fCharacterIsMale )
|
||||
{
|
||||
if( gIMPMaleValues[iCurrentPortrait].uiIndex == iCurrentPortrait && gIMPMaleValues[iCurrentPortrait].PortraitId !=0 )
|
||||
{
|
||||
iCurrentPortrait = gIMPMaleValues[iCurrentPortrait].uiIndex;
|
||||
}
|
||||
else
|
||||
{
|
||||
iCurrentPortrait = 0;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if( gIMPFemaleValues[iCurrentPortrait].uiIndex == iCurrentPortrait && gIMPFemaleValues[iCurrentPortrait].PortraitId !=0 )
|
||||
{
|
||||
iCurrentPortrait = gIMPFemaleValues[iCurrentPortrait].uiIndex;
|
||||
}
|
||||
else
|
||||
{
|
||||
iCurrentPortrait = 0;
|
||||
}
|
||||
|
||||
}
|
||||
// cycle to next picture
|
||||
/*
|
||||
iCurrentPortrait++;
|
||||
|
||||
// gone too far?
|
||||
@@ -168,23 +213,64 @@ void IncrementPictureIndex( void )
|
||||
iCurrentPortrait = 0;
|
||||
}
|
||||
|
||||
|
||||
*/
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
void DecrementPicture( void )
|
||||
{
|
||||
// cycle to previous picture
|
||||
UINT32 cnt;
|
||||
UINT32 idPort = 0;
|
||||
|
||||
iCurrentPortrait--;
|
||||
|
||||
if( fCharacterIsMale )
|
||||
{
|
||||
for ( cnt = 0; cnt < MAX_NEW_IMP_PORTRAITS; cnt++ )
|
||||
{
|
||||
if ( gIMPMaleValues[cnt].uiIndex == cnt && gIMPMaleValues[cnt].PortraitId !=0 )
|
||||
{
|
||||
iLastPictureM = gIMPMaleValues[cnt].uiIndex;
|
||||
}
|
||||
}
|
||||
|
||||
iLastPicture = iLastPictureM;
|
||||
}
|
||||
else
|
||||
{
|
||||
for ( cnt = 0; cnt < MAX_NEW_IMP_PORTRAITS; cnt++ )
|
||||
{
|
||||
if ( gIMPFemaleValues[cnt].uiIndex == cnt && gIMPFemaleValues[cnt].PortraitId !=0 )
|
||||
{
|
||||
iLastPictureF = gIMPFemaleValues[cnt].uiIndex;
|
||||
}
|
||||
}
|
||||
|
||||
iLastPicture = iLastPictureF;
|
||||
}
|
||||
|
||||
iCurrentPortrait--;
|
||||
if( fCharacterIsMale )
|
||||
{
|
||||
if( iCurrentPortrait < 0 )
|
||||
{
|
||||
iCurrentPortrait = iLastPicture;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if( iCurrentPortrait < 0 )
|
||||
{
|
||||
iCurrentPortrait = iLastPicture;
|
||||
}
|
||||
|
||||
}
|
||||
/*
|
||||
// gone too far?
|
||||
if( iCurrentPortrait < 0 )
|
||||
{
|
||||
iCurrentPortrait = iLastPicture;
|
||||
iCurrentPortrait = iLastPicture;
|
||||
}
|
||||
|
||||
*/
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -364,18 +450,20 @@ void BtnIMPPortraitDoneCallback(GUI_BUTTON *btn,INT32 reason)
|
||||
}*/
|
||||
|
||||
// grab picture number
|
||||
|
||||
|
||||
|
||||
if( fCharacterIsMale )
|
||||
{
|
||||
// male
|
||||
iPortraitNumber = iCurrentPortrait;
|
||||
// male
|
||||
iPortraitNumber = gIMPMaleValues[ iCurrentPortrait ].uiIndex; //iCurrentPortrait
|
||||
}
|
||||
else
|
||||
{
|
||||
// female
|
||||
iPortraitNumber = iCurrentPortrait + ( 8 );
|
||||
|
||||
// female
|
||||
iPortraitNumber = gIMPFemaleValues[ iCurrentPortrait ].uiIndex; //iCurrentPortrait ;//+ ( 8 );
|
||||
}
|
||||
|
||||
|
||||
fButtonPendingFlag = TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
+2040
-225
File diff suppressed because it is too large
Load Diff
@@ -28,10 +28,37 @@ enum
|
||||
IMP_SKILL_TRAITS__NUMBER_SKILLS,
|
||||
};
|
||||
|
||||
// STR16 gzIMPSkillTraitsText[];
|
||||
// other set for new traits - SANDRO
|
||||
enum
|
||||
{
|
||||
// major traits
|
||||
IMP_SKILL_TRAITS_NEW_AUTO_WEAPONS,
|
||||
IMP_SKILL_TRAITS_NEW_HEAVY_WEAPONS,
|
||||
IMP_SKILL_TRAITS_NEW_PROF_SNIPER,
|
||||
IMP_SKILL_TRAITS_NEW_RANGER,
|
||||
IMP_SKILL_TRAITS_NEW_GUNSLINGER,
|
||||
IMP_SKILL_TRAITS_NEW_MARTIAL_ARTS,
|
||||
IMP_SKILL_TRAITS_NEW_SQUADLEADER,
|
||||
IMP_SKILL_TRAITS_NEW_TECHNICIAN,
|
||||
IMP_SKILL_TRAITS_NEW_DOCTOR,
|
||||
IMP_SKILL_TRAITS_NEW_MAJOR_NONE,
|
||||
IMP_SKILL_TRAITS_NEW_NUMBER_MAJOR_SKILLS,
|
||||
};
|
||||
|
||||
INT8 DoesPlayerHaveExtraAttibutePointsToDistributeBasedOnSkillSelection();
|
||||
INT8 CountNumSkillTraitsSelected( BOOLEAN fIncludeNoneSkill );
|
||||
INT32 DoesPlayerHaveExtraAttibutePointsToDistributeBasedOnSkillSelection();
|
||||
|
||||
void AddSelectedSkillsToSkillsList();
|
||||
|
||||
INT32 StrengthRequiredDueToMajorSkills( void );
|
||||
INT32 AgilityRequiredDueToMajorSkills( void );
|
||||
INT32 DexterityRequiredDueToMajorSkills( void );
|
||||
INT32 HealthRequiredDueToMajorSkills( void );
|
||||
INT32 LeadershipRequiredDueToMajorSkills( void );
|
||||
INT32 WisdomRequiredDueToMajorSkills( void );
|
||||
INT32 MarksmanshipRequiredDueToMajorSkills( void );
|
||||
INT32 MechanicalRequiredDueToMajorSkills( void );
|
||||
INT32 MedicalRequiredDueToMajorSkills( void );
|
||||
INT32 ExplosivesRequiredDueToMajorSkills( void );
|
||||
|
||||
#endif
|
||||
|
||||
+38
-13
@@ -12,6 +12,11 @@
|
||||
#include "IMP Personality Finish.h"
|
||||
#include "IMP Attribute Selection.h"
|
||||
#include "IMP MainPage.h"
|
||||
// added by SANDRO
|
||||
#include "IMP Confirm.h"
|
||||
#include "GameSettings.h"
|
||||
#include "Text.h"
|
||||
#include "_Ja25Englishtext.h"
|
||||
#endif
|
||||
|
||||
#define IMP_SEEK_AMOUNT 5 * 80 * 2
|
||||
@@ -180,14 +185,20 @@ void PrintImpText( void )
|
||||
|
||||
break;
|
||||
case ( IMP_PERSONALITY ):
|
||||
// SANDRO - I HAVE CHANGED THESE TO BE ABLE TO EDIT THE TEXTS BEFORE SKILL TRAITS (THE TEXTS ARE ABOVE HERE)
|
||||
// EVEN IF IT IS A LITTLE STUPID WAY, I HAVEN'T FOUND A WAY HOW TO EDIT IMPtext.edt..
|
||||
// THE TEXTS OF "pSkillTraitBeginIMPStrings" ARE IN "_EnglishText.cpp" at the end
|
||||
// SANDRO - I HAVE CHANGED THESE TO BE ABLE TO EDIT THE TEXTS BEFORE SKILL TRAITS
|
||||
// EVEN IF IT IS A LITTLE STUPID WAY, I HAVEN'T FOUND A DIFFERENT WAY
|
||||
//LoadAndDisplayIMPText( LAPTOP_SCREEN_UL_X + 130, LAPTOP_SCREEN_WEB_UL_Y + 60, ( 456 - 200 ), IMP_PERS_1, FONT12ARIAL, FONT_WHITE, TRUE, CENTER_JUSTIFIED);
|
||||
//LoadAndDisplayIMPText( LAPTOP_SCREEN_UL_X + 130, LAPTOP_SCREEN_WEB_UL_Y + 130, ( 456 - 200 ), IMP_PERS_2, FONT12ARIAL, FONT_WHITE, TRUE, CENTER_JUSTIFIED);
|
||||
DisplayWrappedString( LAPTOP_SCREEN_UL_X + 130, LAPTOP_SCREEN_WEB_UL_Y + 57, ( 456 - 200 ), 2, FONT12ARIAL, FONT_WHITE, pSkillTraitBeginIMPStrings[ 0 ],FONT_BLACK,FALSE,CENTER_JUSTIFIED);
|
||||
DisplayWrappedString( LAPTOP_SCREEN_UL_X + 130, LAPTOP_SCREEN_WEB_UL_Y + 140, ( 456 - 200 ), 2, FONT12ARIAL, FONT_WHITE, pSkillTraitBeginIMPStrings[ 1 ],FONT_BLACK,FALSE,CENTER_JUSTIFIED);
|
||||
|
||||
if ( gGameOptions.fNewTraitSystem )
|
||||
{
|
||||
DisplayWrappedString( LAPTOP_SCREEN_UL_X + 130, LAPTOP_SCREEN_WEB_UL_Y + 57, ( 456 - 200 ), 2, FONT12ARIAL, FONT_WHITE, pSkillTraitBeginIMPStrings[ 2 ],FONT_BLACK,FALSE,CENTER_JUSTIFIED);
|
||||
DisplayWrappedString( LAPTOP_SCREEN_UL_X + 130, LAPTOP_SCREEN_WEB_UL_Y + 155, ( 456 - 200 ), 2, FONT12ARIAL, FONT_WHITE, pSkillTraitBeginIMPStrings[ 3 ],FONT_BLACK,FALSE,CENTER_JUSTIFIED);
|
||||
}
|
||||
else
|
||||
{
|
||||
DisplayWrappedString( LAPTOP_SCREEN_UL_X + 130, LAPTOP_SCREEN_WEB_UL_Y + 57, ( 456 - 200 ), 2, FONT12ARIAL, FONT_WHITE, pSkillTraitBeginIMPStrings[ 0 ],FONT_BLACK,FALSE,CENTER_JUSTIFIED);
|
||||
DisplayWrappedString( LAPTOP_SCREEN_UL_X + 130, LAPTOP_SCREEN_WEB_UL_Y + 140, ( 456 - 200 ), 2, FONT12ARIAL, FONT_WHITE, pSkillTraitBeginIMPStrings[ 1 ],FONT_BLACK,FALSE,CENTER_JUSTIFIED);
|
||||
}
|
||||
LoadAndDisplayIMPText( LAPTOP_SCREEN_UL_X - 111, LAPTOP_SCREEN_WEB_UL_Y + 7, sWidth, IMP_PERS_6, FONT14ARIAL, FONT_WHITE, TRUE, CENTER_JUSTIFIED );
|
||||
|
||||
|
||||
@@ -217,11 +228,21 @@ void PrintImpText( void )
|
||||
}
|
||||
break;
|
||||
case( IMP_ATTRIBUTE_ENTRANCE ):
|
||||
LoadAndDisplayIMPText( LAPTOP_SCREEN_UL_X - 111, LAPTOP_SCREEN_WEB_UL_Y + 7, sWidth, IMP_ATTRIB_1 - 1, FONT14ARIAL, FONT_WHITE, TRUE, CENTER_JUSTIFIED);
|
||||
LoadAndDisplayIMPText( LAPTOP_SCREEN_UL_X + 110, LAPTOP_SCREEN_WEB_UL_Y + 50, ( 300 ), IMP_ATTRIB_5, FONT12ARIAL, FONT_WHITE, TRUE, CENTER_JUSTIFIED);
|
||||
LoadAndDisplayIMPText( LAPTOP_SCREEN_UL_X + 110, LAPTOP_SCREEN_WEB_UL_Y + 130, ( 300 ), IMP_ATTRIB_6, FONT12ARIAL, FONT_WHITE, TRUE, CENTER_JUSTIFIED);
|
||||
LoadAndDisplayIMPText( LAPTOP_SCREEN_UL_X + 110, LAPTOP_SCREEN_WEB_UL_Y + 200, ( 300 ), IMP_ATTRIB_7, FONT12ARIAL, FONT_WHITE, TRUE, CENTER_JUSTIFIED);
|
||||
|
||||
if ( gGameOptions.fNewTraitSystem )
|
||||
{
|
||||
CHAR16 sMinAttr[400];
|
||||
swprintf( sMinAttr, sgAttributeSelectionText[ 4 ], gGameExternalOptions.iMinAttribute );
|
||||
DisplayWrappedString( LAPTOP_SCREEN_UL_X + 122, LAPTOP_SCREEN_WEB_UL_Y + 57, ( 466 - 190 ), 2, FONT12ARIAL, FONT_WHITE, sMinAttr,FONT_BLACK,FALSE,CENTER_JUSTIFIED);
|
||||
DisplayWrappedString( LAPTOP_SCREEN_UL_X + 122, LAPTOP_SCREEN_WEB_UL_Y + 116, ( 466 - 190 ), 2, FONT12ARIAL, FONT_WHITE, sgAttributeSelectionText[ 5 ],FONT_BLACK,FALSE,CENTER_JUSTIFIED);
|
||||
DisplayWrappedString( LAPTOP_SCREEN_UL_X + 122, LAPTOP_SCREEN_WEB_UL_Y + 163, ( 466 - 190 ), 2, FONT12ARIAL, FONT_WHITE, sgAttributeSelectionText[ 6 ],FONT_BLACK,FALSE,CENTER_JUSTIFIED);
|
||||
}
|
||||
else
|
||||
{
|
||||
LoadAndDisplayIMPText( LAPTOP_SCREEN_UL_X - 111, LAPTOP_SCREEN_WEB_UL_Y + 7, sWidth, IMP_ATTRIB_1 - 1, FONT14ARIAL, FONT_WHITE, TRUE, CENTER_JUSTIFIED);
|
||||
LoadAndDisplayIMPText( LAPTOP_SCREEN_UL_X + 110, LAPTOP_SCREEN_WEB_UL_Y + 50, ( 300 ), IMP_ATTRIB_5, FONT12ARIAL, FONT_WHITE, TRUE, CENTER_JUSTIFIED);
|
||||
LoadAndDisplayIMPText( LAPTOP_SCREEN_UL_X + 110, LAPTOP_SCREEN_WEB_UL_Y + 130, ( 300 ), IMP_ATTRIB_6, FONT12ARIAL, FONT_WHITE, TRUE, CENTER_JUSTIFIED);
|
||||
LoadAndDisplayIMPText( LAPTOP_SCREEN_UL_X + 110, LAPTOP_SCREEN_WEB_UL_Y + 200, ( 300 ), IMP_ATTRIB_7, FONT12ARIAL, FONT_WHITE, TRUE, CENTER_JUSTIFIED);
|
||||
}
|
||||
break;
|
||||
case( IMP_ATTRIBUTE_PAGE ):
|
||||
LoadAndDisplayIMPText( LAPTOP_SCREEN_UL_X - 111, LAPTOP_SCREEN_WEB_UL_Y + 7, sWidth, IMP_ATTRIB_1 - 1, FONT14ARIAL, FONT_WHITE, TRUE, CENTER_JUSTIFIED);
|
||||
@@ -284,9 +305,13 @@ void PrintImpText( void )
|
||||
LoadAndDisplayIMPText( LAPTOP_SCREEN_UL_X + 150, LAPTOP_SCREEN_WEB_UL_Y + 55, ( 200 ), IMP_FIN_2 - 1, FONT12ARIAL, FONT_WHITE, TRUE, 0);
|
||||
break;
|
||||
case( IMP_CONFIRM ):
|
||||
LoadAndDisplayIMPText( LAPTOP_SCREEN_UL_X - 111, LAPTOP_SCREEN_WEB_UL_Y + 7, sWidth, IMP_CON_1 , FONT14ARIAL, FONT_WHITE, TRUE, CENTER_JUSTIFIED);
|
||||
LoadAndDisplayIMPText( LAPTOP_SCREEN_UL_X - 111, LAPTOP_SCREEN_WEB_UL_Y + 7, sWidth, IMP_CON_1 , FONT14ARIAL, FONT_WHITE, TRUE, CENTER_JUSTIFIED);
|
||||
LoadAndDisplayIMPText( LAPTOP_SCREEN_UL_X + 160, LAPTOP_SCREEN_WEB_UL_Y + 60, ( 200 ), IMP_CON_2 , FONT12ARIAL, FONT_WHITE, TRUE, 0);
|
||||
LoadAndDisplayIMPText( LAPTOP_SCREEN_UL_X + 160, LAPTOP_SCREEN_WEB_UL_Y + 145, ( 200 ), IMP_CON_3 , FONT12ARIAL, FONT_WHITE, TRUE, 0);
|
||||
//LoadAndDisplayIMPText( LAPTOP_SCREEN_UL_X + 160, LAPTOP_SCREEN_WEB_UL_Y + 145, ( 200 ), IMP_CON_3 , FONT12ARIAL, FONT_WHITE, TRUE, 0);
|
||||
// SANDRO - changed to show exact cost of profile
|
||||
CHAR16 chPayCost[1000];
|
||||
swprintf( chPayCost, gzIMPProfileCostText[ 0 ], iGetProfileCost() );
|
||||
DisplayWrappedString( LAPTOP_SCREEN_UL_X + 160, LAPTOP_SCREEN_WEB_UL_Y + 145, ( 200 ), 2, FONT12ARIAL, FONT_WHITE, chPayCost,FONT_BLACK,FALSE,LEFT_JUSTIFIED);
|
||||
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -381,41 +381,7 @@ void BtnIMPVoicesDoneCallback(GUI_BUTTON *btn,INT32 reason)
|
||||
iCurrentImpPage = IMP_COLOR_CHOICE_PAGE;
|
||||
// Following part removed
|
||||
|
||||
// go to main page
|
||||
/*iCurrentImpPage = IMP_MAIN_PAGE;
|
||||
|
||||
// if we are already done, leave
|
||||
if( iCurrentProfileMode == IMP__FINISH )
|
||||
{
|
||||
iCurrentImpPage = IMP_FINISH;
|
||||
}
|
||||
else
|
||||
{
|
||||
if( CameBackToVoicePageButNotFinished() )
|
||||
{
|
||||
iCurrentImpPage = IMP_MAIN_PAGE;
|
||||
}
|
||||
else
|
||||
{
|
||||
iCurrentProfileMode = IMP__PERSONALITY;
|
||||
}
|
||||
}*/
|
||||
/*
|
||||
// current mode now is voice
|
||||
else if( iCurrentProfileMode < IMP__PORTRAIT )
|
||||
{
|
||||
iCurrentProfileMode = IMP__PORTRAIT;
|
||||
}
|
||||
|
||||
else if( iCurrentProfileMode == IMP__PORTRAIT )
|
||||
{
|
||||
// all done profiling
|
||||
iCurrentProfileMode = IMP__VOICE;
|
||||
iCurrentImpPage = IMP_FINISH;
|
||||
}
|
||||
*/
|
||||
// set voice id, to grab character slot
|
||||
|
||||
// WDS: Allow flexible numbers of IMPs of each sex
|
||||
LaptopSaveInfo.iIMPIndex = gGameExternalOptions.iaIMPSlots[iCurrentVoice];
|
||||
|
||||
|
||||
@@ -0,0 +1,895 @@
|
||||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="8,00"
|
||||
Name="Laptop"
|
||||
ProjectGUID="{5234CD2E-97F1-42FF-828D-CE0A1B46805E}"
|
||||
RootNamespace="Laptop"
|
||||
Keyword="Win32Proj"
|
||||
>
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Win32"
|
||||
/>
|
||||
</Platforms>
|
||||
<ToolFiles>
|
||||
</ToolFiles>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
OutputDirectory="..\lib\VS2005\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2005\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2.vsprops;..\ja2_Debug.vsprops"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions="/D "_CRT_SECURE_NO_DEPRECATE""
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
RuntimeTypeInfo="true"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
DebugInformationFormat="4"
|
||||
DisableSpecificWarnings="4100"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
OutputDirectory="..\lib\VS2005\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2005\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2.vsprops"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions="/D "_CRT_SECURE_NO_DEPRECATE""
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_LIB;"
|
||||
RuntimeLibrary="0"
|
||||
RuntimeTypeInfo="true"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
DebugInformationFormat="3"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="MapEditor|Win32"
|
||||
OutputDirectory="..\lib\VS2005\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2005\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2.vsprops;..\ja2_Editor.vsprops"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions="/D "_CRT_SECURE_NO_DEPRECATE""
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_LIB;"
|
||||
RuntimeLibrary="0"
|
||||
RuntimeTypeInfo="true"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
DebugInformationFormat="3"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="MapEditorD|Win32"
|
||||
OutputDirectory="..\lib\VS2005\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2005\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2.vsprops;..\ja2_Editor.vsprops"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions="/D "_CRT_SECURE_NO_DEPRECATE""
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
RuntimeTypeInfo="true"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
DebugInformationFormat="4"
|
||||
DisableSpecificWarnings="4100"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release_WithDebugInfo|Win32"
|
||||
OutputDirectory="..\lib\VS2005\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2005\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2.vsprops"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions="/D "_CRT_SECURE_NO_DEPRECATE""
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_LIB;"
|
||||
RuntimeLibrary="0"
|
||||
RuntimeTypeInfo="true"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
DebugInformationFormat="4"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<References>
|
||||
</References>
|
||||
<Files>
|
||||
<Filter
|
||||
Name="Header Files"
|
||||
Filter="h;hpp;hxx;hm;inl;inc;xsd"
|
||||
UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
|
||||
>
|
||||
<File
|
||||
RelativePath=".\aim.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\AimArchives.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\AimFacialIndex.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\AimHistory.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\AimLinks.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\AimMembers.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\AimPolicies.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\AimSort.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BobbyR.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BobbyRAmmo.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BobbyRArmour.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BobbyRGuns.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BobbyRMailOrder.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BobbyRMisc.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BobbyRShipments.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BobbyRUsed.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BrokenLink.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\CharProfile.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\email.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\files.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\finances.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\florist Cards.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\florist Gallery.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\florist Order Form.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\florist.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\funeral.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\GunEmporium.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\history.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP AboutUs.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Attribute Entrance.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Attribute Finish.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Attribute Selection.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Begin Screen.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Character and Disability Entrance.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Character Trait.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Color Choosing.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Compile Character.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Confirm.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Disability Trait.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Finish.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP HomePage.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP MainPage.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Minor Trait.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Personality Entrance.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Personality Finish.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Personality Quiz.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Portraits.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Skill Trait.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Text System.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Voices.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMPVideoObjects.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\insurance Comments.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\insurance Contract.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\insurance Info.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Insurance Text.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\insurance.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Laptop All.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\laptop.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\LaptopSave.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\mercs Account.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\mercs Files.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\mercs No Account.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\mercs.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\personnel.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\PostalService.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\sirtech.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Speck Quotes.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Store Inventory.h"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Source Files"
|
||||
Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
|
||||
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
|
||||
>
|
||||
<File
|
||||
RelativePath=".\aim.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\AimArchives.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\AimFacialIndex.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\AimHistory.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\AimLinks.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\AimMembers.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\AimPolicies.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\AimSort.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BobbyR.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BobbyRAmmo.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BobbyRArmour.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BobbyRGuns.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BobbyRMailOrder.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BobbyRMisc.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BobbyRShipments.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BobbyRUsed.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BrokenLink.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\CharProfile.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\email.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\files.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\finances.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\florist Cards.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\florist Gallery.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\florist Order Form.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\florist.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\funeral.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\history.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP AboutUs.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Attribute Entrance.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Attribute Finish.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Attribute Selection.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Begin Screen.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Character and Disability Entrance.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Character Trait.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Color Choosing.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Compile Character.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Confirm.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Disability Trait.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Finish.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP HomePage.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP MainPage.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Minor Trait.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Personality Entrance.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Personality Finish.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Personality Quiz.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Portraits.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Skill Trait.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Text System.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Voices.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMPVideoObjects.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\insurance Comments.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\insurance Contract.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\insurance Info.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\insurance.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\laptop.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\mercs Account.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\mercs Files.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\mercs No Account.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\mercs.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\personnel.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\PostalService.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\sirtech.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Store Inventory.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\XML_AIMAvailability.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\XML_ConditionsForMercAvailability.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\XML_DeliveryMethods.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\XML_IMPPortraits.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\XML_ShippingDestinations.cpp"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
</VisualStudioProject>
|
||||
@@ -21,7 +21,7 @@
|
||||
OutputDirectory="..\lib\VS2008\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2008\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2_VS2008.vsprops;..\ja2_VS2008Debug.vsprops"
|
||||
InheritedPropertySheets="..\ja2.vsprops;..\ja2_Debug.vsprops"
|
||||
CharacterSet="0"
|
||||
>
|
||||
<Tool
|
||||
@@ -83,7 +83,7 @@
|
||||
OutputDirectory="..\lib\VS2008\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2008\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2_VS2008.vsprops"
|
||||
InheritedPropertySheets="..\ja2.vsprops"
|
||||
CharacterSet="0"
|
||||
WholeProgramOptimization="0"
|
||||
>
|
||||
@@ -147,7 +147,7 @@
|
||||
OutputDirectory="..\lib\VS2008\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2008\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2_VS2008.vsprops;..\ja2_VS2008Editor.vsprops"
|
||||
InheritedPropertySheets="..\ja2.vsprops;..\ja2_Editor.vsprops"
|
||||
CharacterSet="0"
|
||||
WholeProgramOptimization="0"
|
||||
>
|
||||
@@ -211,7 +211,7 @@
|
||||
OutputDirectory="..\lib\VS2008\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2008\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2_VS2008.vsprops;..\ja2_VS2008Editor.vsprops"
|
||||
InheritedPropertySheets="..\ja2.vsprops;..\ja2_Editor.vsprops"
|
||||
CharacterSet="0"
|
||||
>
|
||||
<Tool
|
||||
@@ -273,7 +273,7 @@
|
||||
OutputDirectory="..\lib\VS2008\$(ConfigurationName)"
|
||||
IntermediateDirectory="..\build\VS2008\$(ProjectName)_$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="..\ja2_VS2008.vsprops"
|
||||
InheritedPropertySheets="..\ja2.vsprops"
|
||||
CharacterSet="0"
|
||||
WholeProgramOptimization="0"
|
||||
>
|
||||
@@ -507,6 +507,10 @@
|
||||
RelativePath="IMP MainPage.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Minor Trait.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="IMP Personality Entrance.h"
|
||||
>
|
||||
@@ -779,6 +783,10 @@
|
||||
RelativePath="IMP MainPage.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\IMP Minor Trait.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="IMP Personality Entrance.cpp"
|
||||
>
|
||||
@@ -863,10 +871,22 @@
|
||||
RelativePath="Store Inventory.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\XML_AIMAvailability.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\XML_ConditionsForMercAvailability.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\XML_DeliveryMethods.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\XML_IMPPortraits.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\XML_ShippingDestinations.cpp"
|
||||
>
|
||||
|
||||
@@ -0,0 +1,350 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="MapEditorD|Win32">
|
||||
<Configuration>MapEditorD</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="MapEditor|Win32">
|
||||
<Configuration>MapEditor</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Relese_WithDebugInfo|Win32">
|
||||
<Configuration>Relese_WithDebugInfo</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="aim.h" />
|
||||
<ClInclude Include="AimArchives.h" />
|
||||
<ClInclude Include="AimFacialIndex.h" />
|
||||
<ClInclude Include="AimHistory.h" />
|
||||
<ClInclude Include="AimLinks.h" />
|
||||
<ClInclude Include="AimMembers.h" />
|
||||
<ClInclude Include="AimPolicies.h" />
|
||||
<ClInclude Include="AimSort.h" />
|
||||
<ClInclude Include="BobbyR.h" />
|
||||
<ClInclude Include="BobbyRAmmo.h" />
|
||||
<ClInclude Include="BobbyRArmour.h" />
|
||||
<ClInclude Include="BobbyRGuns.h" />
|
||||
<ClInclude Include="BobbyRMailOrder.h" />
|
||||
<ClInclude Include="BobbyRMisc.h" />
|
||||
<ClInclude Include="BobbyRShipments.h" />
|
||||
<ClInclude Include="BobbyRUsed.h" />
|
||||
<ClInclude Include="BrokenLink.h" />
|
||||
<ClInclude Include="CharProfile.h" />
|
||||
<ClInclude Include="email.h" />
|
||||
<ClInclude Include="files.h" />
|
||||
<ClInclude Include="finances.h" />
|
||||
<ClInclude Include="florist Cards.h" />
|
||||
<ClInclude Include="florist Gallery.h" />
|
||||
<ClInclude Include="florist Order Form.h" />
|
||||
<ClInclude Include="florist.h" />
|
||||
<ClInclude Include="funeral.h" />
|
||||
<ClInclude Include="GunEmporium.h" />
|
||||
<ClInclude Include="history.h" />
|
||||
<ClInclude Include="IMP AboutUs.h" />
|
||||
<ClInclude Include="IMP Attribute Entrance.h" />
|
||||
<ClInclude Include="IMP Attribute Finish.h" />
|
||||
<ClInclude Include="IMP Attribute Selection.h" />
|
||||
<ClInclude Include="IMP Begin Screen.h" />
|
||||
<ClInclude Include="IMP Character and Disability Entrance.h" />
|
||||
<ClInclude Include="IMP Character Trait.h" />
|
||||
<ClInclude Include="IMP Color Choosing.h" />
|
||||
<ClInclude Include="IMP Compile Character.h" />
|
||||
<ClInclude Include="IMP Confirm.h" />
|
||||
<ClInclude Include="IMP Disability Trait.h" />
|
||||
<ClInclude Include="IMP Finish.h" />
|
||||
<ClInclude Include="IMP HomePage.h" />
|
||||
<ClInclude Include="IMP MainPage.h" />
|
||||
<ClInclude Include="IMP Minor Trait.h" />
|
||||
<ClInclude Include="IMP Personality Entrance.h" />
|
||||
<ClInclude Include="IMP Personality Finish.h" />
|
||||
<ClInclude Include="IMP Personality Quiz.h" />
|
||||
<ClInclude Include="IMP Portraits.h" />
|
||||
<ClInclude Include="IMP Skill Trait.h" />
|
||||
<ClInclude Include="IMP Text System.h" />
|
||||
<ClInclude Include="IMP Voices.h" />
|
||||
<ClInclude Include="IMPVideoObjects.h" />
|
||||
<ClInclude Include="insurance Comments.h" />
|
||||
<ClInclude Include="insurance Contract.h" />
|
||||
<ClInclude Include="insurance Info.h" />
|
||||
<ClInclude Include="Insurance Text.h" />
|
||||
<ClInclude Include="insurance.h" />
|
||||
<ClInclude Include="Laptop All.h" />
|
||||
<ClInclude Include="laptop.h" />
|
||||
<ClInclude Include="LaptopSave.h" />
|
||||
<ClInclude Include="mercs Account.h" />
|
||||
<ClInclude Include="mercs Files.h" />
|
||||
<ClInclude Include="mercs No Account.h" />
|
||||
<ClInclude Include="mercs.h" />
|
||||
<ClInclude Include="personnel.h" />
|
||||
<ClInclude Include="PostalService.h" />
|
||||
<ClInclude Include="sirtech.h" />
|
||||
<ClInclude Include="Speck Quotes.h" />
|
||||
<ClInclude Include="Store Inventory.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="aim.cpp" />
|
||||
<ClCompile Include="AimArchives.cpp" />
|
||||
<ClCompile Include="AimFacialIndex.cpp" />
|
||||
<ClCompile Include="AimHistory.cpp" />
|
||||
<ClCompile Include="AimLinks.cpp" />
|
||||
<ClCompile Include="AimMembers.cpp" />
|
||||
<ClCompile Include="AimPolicies.cpp" />
|
||||
<ClCompile Include="AimSort.cpp" />
|
||||
<ClCompile Include="BobbyR.cpp" />
|
||||
<ClCompile Include="BobbyRAmmo.cpp" />
|
||||
<ClCompile Include="BobbyRArmour.cpp" />
|
||||
<ClCompile Include="BobbyRGuns.cpp" />
|
||||
<ClCompile Include="BobbyRMailOrder.cpp" />
|
||||
<ClCompile Include="BobbyRMisc.cpp" />
|
||||
<ClCompile Include="BobbyRShipments.cpp" />
|
||||
<ClCompile Include="BobbyRUsed.cpp" />
|
||||
<ClCompile Include="BrokenLink.cpp" />
|
||||
<ClCompile Include="CharProfile.cpp" />
|
||||
<ClCompile Include="email.cpp" />
|
||||
<ClCompile Include="files.cpp" />
|
||||
<ClCompile Include="finances.cpp" />
|
||||
<ClCompile Include="florist Cards.cpp" />
|
||||
<ClCompile Include="florist Gallery.cpp" />
|
||||
<ClCompile Include="florist Order Form.cpp" />
|
||||
<ClCompile Include="florist.cpp" />
|
||||
<ClCompile Include="funeral.cpp" />
|
||||
<ClCompile Include="GunEmporium.cpp" />
|
||||
<ClCompile Include="history.cpp" />
|
||||
<ClCompile Include="IMP AboutUs.cpp" />
|
||||
<ClCompile Include="IMP Attribute Entrance.cpp" />
|
||||
<ClCompile Include="IMP Attribute Finish.cpp" />
|
||||
<ClCompile Include="IMP Attribute Selection.cpp" />
|
||||
<ClCompile Include="IMP Begin Screen.cpp" />
|
||||
<ClCompile Include="IMP Character and Disability Entrance.cpp" />
|
||||
<ClCompile Include="IMP Character Trait.cpp" />
|
||||
<ClCompile Include="IMP Color Choosing.cpp" />
|
||||
<ClCompile Include="IMP Compile Character.cpp" />
|
||||
<ClCompile Include="IMP Confirm.cpp" />
|
||||
<ClCompile Include="IMP Disability Trait.cpp" />
|
||||
<ClCompile Include="IMP Finish.cpp" />
|
||||
<ClCompile Include="IMP HomePage.cpp" />
|
||||
<ClCompile Include="IMP MainPage.cpp" />
|
||||
<ClCompile Include="IMP Minor Trait.cpp" />
|
||||
<ClCompile Include="IMP Personality Entrance.cpp" />
|
||||
<ClCompile Include="IMP Personality Finish.cpp" />
|
||||
<ClCompile Include="IMP Personality Quiz.cpp" />
|
||||
<ClCompile Include="IMP Portraits.cpp" />
|
||||
<ClCompile Include="IMP Skill Trait.cpp" />
|
||||
<ClCompile Include="IMP Text System.cpp" />
|
||||
<ClCompile Include="IMP Voices.cpp" />
|
||||
<ClCompile Include="IMPVideoObjects.cpp" />
|
||||
<ClCompile Include="insurance Comments.cpp" />
|
||||
<ClCompile Include="insurance Contract.cpp" />
|
||||
<ClCompile Include="insurance Info.cpp" />
|
||||
<ClCompile Include="insurance.cpp" />
|
||||
<ClCompile Include="laptop.cpp" />
|
||||
<ClCompile Include="mercs Account.cpp" />
|
||||
<ClCompile Include="mercs Files.cpp" />
|
||||
<ClCompile Include="mercs No Account.cpp" />
|
||||
<ClCompile Include="mercs.cpp" />
|
||||
<ClCompile Include="personnel.cpp" />
|
||||
<ClCompile Include="PostalService.cpp" />
|
||||
<ClCompile Include="sirtech.cpp" />
|
||||
<ClCompile Include="Store Inventory.cpp" />
|
||||
<ClCompile Include="XML_AIMAvailability.cpp" />
|
||||
<ClCompile Include="XML_ConditionsForMercAvailability.cpp" />
|
||||
<ClCompile Include="XML_DeliveryMethods.cpp" />
|
||||
<ClCompile Include="XML_IMPPortraits.cpp" />
|
||||
<ClCompile Include="XML_ShippingDestinations.cpp" />
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{6CFD0AF4-6BB4-4A19-B72E-71768A8D029D}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>Laptop</RootNamespace>
|
||||
<ProjectName>Laptop</ProjectName>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='MapEditorD|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>false</WholeProgramOptimization>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='MapEditor|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>false</WholeProgramOptimization>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Relese_WithDebugInfo|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>false</WholeProgramOptimization>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="..\ja2.props" />
|
||||
<Import Project="..\ja2_Debug.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='MapEditorD|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="..\ja2.props" />
|
||||
<Import Project="..\ja2_Debug.props" />
|
||||
<Import Project="..\ja2_Editor.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="..\ja2.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='MapEditor|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="..\ja2.props" />
|
||||
<Import Project="..\ja2_Editor.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Relese_WithDebugInfo|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="..\ja2.props" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<OutDir>..\lib\VS2010\$(Configuration)\</OutDir>
|
||||
<IntDir>..\build\VS2010\$(ProjectName)_$(Configuration)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='MapEditorD|Win32'">
|
||||
<OutDir>..\lib\VS2010\$(Configuration)\</OutDir>
|
||||
<IntDir>..\build\VS2010\$(ProjectName)_$(Configuration)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<IntDir>..\build\VS2010\$(ProjectName)_$(Configuration)\</IntDir>
|
||||
<OutDir>..\lib\VS2010\$(Configuration)\</OutDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='MapEditor|Win32'">
|
||||
<IntDir>..\build\VS2010\$(ProjectName)_$(Configuration)\</IntDir>
|
||||
<OutDir>..\lib\VS2010\$(Configuration)\</OutDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Relese_WithDebugInfo|Win32'">
|
||||
<IntDir>..\build\VS2010\$(ProjectName)_$(Configuration)\</IntDir>
|
||||
<OutDir>..\lib\VS2010\$(Configuration)\</OutDir>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
|
||||
<PrecompiledHeaderFile>
|
||||
</PrecompiledHeaderFile>
|
||||
<PrecompiledHeaderOutputFile>
|
||||
</PrecompiledHeaderOutputFile>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='MapEditorD|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
|
||||
<PrecompiledHeaderFile>
|
||||
</PrecompiledHeaderFile>
|
||||
<PrecompiledHeaderOutputFile>
|
||||
</PrecompiledHeaderOutputFile>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
<PrecompiledHeaderFile>
|
||||
</PrecompiledHeaderFile>
|
||||
<PrecompiledHeaderOutputFile>
|
||||
</PrecompiledHeaderOutputFile>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='MapEditor|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
<PrecompiledHeaderFile>
|
||||
</PrecompiledHeaderFile>
|
||||
<PrecompiledHeaderOutputFile>
|
||||
</PrecompiledHeaderOutputFile>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Relese_WithDebugInfo|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<PrecompiledHeader>NotUsing</PrecompiledHeader>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
<PrecompiledHeaderFile>
|
||||
</PrecompiledHeaderFile>
|
||||
<PrecompiledHeaderOutputFile>
|
||||
</PrecompiledHeaderOutputFile>
|
||||
<DebugInformationFormat>EditAndContinue</DebugInformationFormat>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
</Project>
|
||||
@@ -0,0 +1,426 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<Filter Include="Header Files">
|
||||
<UniqueIdentifier>{84a4f64f-bc1b-4e0c-848c-2b7c145ae615}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Source Files">
|
||||
<UniqueIdentifier>{b159d1de-d6d6-4531-b86a-b991f7210268}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="aim.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="AimArchives.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="AimFacialIndex.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="AimHistory.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="AimLinks.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="AimMembers.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="AimPolicies.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="AimSort.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="BobbyR.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="BobbyRAmmo.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="BobbyRArmour.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="BobbyRGuns.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="BobbyRMailOrder.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="BobbyRMisc.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="BobbyRShipments.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="BobbyRUsed.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="BrokenLink.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="CharProfile.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="email.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="files.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="finances.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="florist Cards.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="florist Gallery.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="florist Order Form.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="florist.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="funeral.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="GunEmporium.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="history.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP AboutUs.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP Attribute Entrance.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP Attribute Finish.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP Attribute Selection.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP Begin Screen.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP Character and Disability Entrance.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP Character Trait.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP Color Choosing.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP Compile Character.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP Confirm.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP Disability Trait.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP Finish.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP HomePage.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP MainPage.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP Minor Trait.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP Personality Entrance.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP Personality Finish.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP Personality Quiz.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP Portraits.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP Skill Trait.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP Text System.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMP Voices.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="IMPVideoObjects.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="insurance Comments.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="insurance Contract.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="insurance Info.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Insurance Text.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="insurance.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Laptop All.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="laptop.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="LaptopSave.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="mercs Account.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="mercs Files.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="mercs No Account.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="mercs.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="personnel.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="PostalService.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="sirtech.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Speck Quotes.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Store Inventory.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="aim.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="AimArchives.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="AimFacialIndex.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="AimHistory.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="AimLinks.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="AimMembers.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="AimPolicies.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="AimSort.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="BobbyR.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="BobbyRAmmo.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="BobbyRArmour.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="BobbyRGuns.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="BobbyRMailOrder.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="BobbyRMisc.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="BobbyRShipments.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="BobbyRUsed.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="BrokenLink.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="CharProfile.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="email.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="files.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="finances.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="florist Cards.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="florist Gallery.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="florist Order Form.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="florist.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="funeral.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="GunEmporium.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="history.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP AboutUs.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP Attribute Entrance.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP Attribute Finish.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP Attribute Selection.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP Begin Screen.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP Character and Disability Entrance.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP Character Trait.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP Color Choosing.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP Compile Character.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP Confirm.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP Disability Trait.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP Finish.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP HomePage.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP MainPage.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP Minor Trait.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP Personality Entrance.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP Personality Finish.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP Personality Quiz.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP Portraits.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP Skill Trait.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP Text System.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMP Voices.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="IMPVideoObjects.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="insurance Comments.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="insurance Contract.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="insurance Info.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="insurance.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="laptop.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="mercs Account.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="mercs Files.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="mercs No Account.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="mercs.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="personnel.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="PostalService.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="sirtech.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Store Inventory.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="XML_DeliveryMethods.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="XML_ShippingDestinations.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="XML_IMPPortraits.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="XML_AIMAvailability.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="XML_ConditionsForMercAvailability.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
@@ -313,8 +313,11 @@ BOOLEAN CPostalService::DeliverShipment(UINT16 usShipmentID)
|
||||
if( (shs.pDestination->ubMapX > 0) &&
|
||||
(shs.pDestination->ubMapX < MAP_WORLD_X - 1) &&
|
||||
(shs.pDestination->ubMapY > 0) &&
|
||||
(shs.pDestination->ubMapY < MAP_WORLD_Y - 1) &&
|
||||
GridNoOnVisibleWorldTile(shs.pDestination->sGridNo) )
|
||||
(shs.pDestination->ubMapY < MAP_WORLD_Y - 1) ) //&&
|
||||
//GridNoOnVisibleWorldTile(shs.pDestination->sGridNo) )
|
||||
// silversurfer: wtf? This test checked if the delivery tile was valid for the currently loaded sector
|
||||
// which is not necessarily the delivery sector
|
||||
// if we are currently below ground it will crash the game...
|
||||
{
|
||||
BOOLEAN fSectorLoaded = ( gWorldSectorX == shs.pDestination->ubMapX ) &&
|
||||
( gWorldSectorY == shs.pDestination->ubMapY ) &&
|
||||
@@ -417,8 +420,6 @@ BOOLEAN CPostalService::DeliverShipment(UINT16 usShipmentID)
|
||||
tempObject[0]->data.gun.ubGunShotsLeft = 0;
|
||||
}
|
||||
|
||||
// TODO.RW: Hier Pablo stealing code einfügen und ubItemsDelivered reduzieren!!!
|
||||
|
||||
UINT8 cnt = -1;
|
||||
// Loop through the items of a package
|
||||
while ( ubItemsDelivered )
|
||||
|
||||
@@ -0,0 +1,234 @@
|
||||
#ifdef PRECOMPILEDHEADERS
|
||||
#include "Tactical All.h"
|
||||
#else
|
||||
#include "sgp.h"
|
||||
#include "Debug Control.h"
|
||||
#include "expat.h"
|
||||
#include "XML.h"
|
||||
#include "Interface.h"
|
||||
#include "aim.h"
|
||||
#endif
|
||||
|
||||
struct
|
||||
{
|
||||
PARSE_STAGE curElement;
|
||||
|
||||
CHAR8 szCharData[MAX_CHAR_DATA_LENGTH+1];
|
||||
AIM_AVAILABLE curAimAvailability;
|
||||
AIM_AVAILABLE * curArray;
|
||||
|
||||
UINT32 maxArraySize;
|
||||
UINT32 curIndex;
|
||||
UINT32 currentDepth;
|
||||
UINT32 maxReadDepth;
|
||||
}
|
||||
typedef aimAvailabilityParseData;
|
||||
|
||||
BOOLEAN AimAvailability_TextOnly;
|
||||
|
||||
static void XMLCALL
|
||||
aimAvailabilityStartElementHandle(void *userData, const XML_Char *name, const XML_Char **atts)
|
||||
{
|
||||
aimAvailabilityParseData * pData = (aimAvailabilityParseData *)userData;
|
||||
|
||||
if(pData->currentDepth <= pData->maxReadDepth) //are we reading this element?
|
||||
{
|
||||
if(strcmp(name, "AIM_AVAILABLES") == 0 && pData->curElement == ELEMENT_NONE)
|
||||
{
|
||||
pData->curElement = ELEMENT_LIST;
|
||||
|
||||
pData->maxReadDepth++; //we are not skipping this element
|
||||
}
|
||||
else if(strcmp(name, "AIM") == 0 && pData->curElement == ELEMENT_LIST)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
|
||||
pData->maxReadDepth++; //we are not skipping this element
|
||||
}
|
||||
else if(pData->curElement == ELEMENT &&
|
||||
(strcmp(name, "uiIndex") == 0 ||
|
||||
strcmp(name, "ProfilId") == 0 ||
|
||||
strcmp(name, "AimBioID") == 0 ))
|
||||
{
|
||||
pData->curElement = ELEMENT_PROPERTY;
|
||||
|
||||
pData->maxReadDepth++; //we are not skipping this element
|
||||
}
|
||||
|
||||
pData->szCharData[0] = '\0';
|
||||
}
|
||||
|
||||
pData->currentDepth++;
|
||||
|
||||
}
|
||||
|
||||
static void XMLCALL
|
||||
aimCharacterDataHandle(void *userData, const XML_Char *str, int len)
|
||||
{
|
||||
aimAvailabilityParseData * pData = (aimAvailabilityParseData *)userData;
|
||||
|
||||
if( (pData->currentDepth <= pData->maxReadDepth) &&
|
||||
(strlen(pData->szCharData) < MAX_CHAR_DATA_LENGTH)
|
||||
){
|
||||
strncat(pData->szCharData,str,__min((unsigned int)len,MAX_CHAR_DATA_LENGTH-strlen(pData->szCharData)));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static void XMLCALL
|
||||
aimAvailabilityEndElementHandle(void *userData, const XML_Char *name)
|
||||
{
|
||||
aimAvailabilityParseData * pData = (aimAvailabilityParseData *)userData;
|
||||
|
||||
if(pData->currentDepth <= pData->maxReadDepth)
|
||||
{
|
||||
if(strcmp(name, "AIM_AVAILABLES") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT_NONE;
|
||||
}
|
||||
else if(strcmp(name, "AIM") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT_LIST;
|
||||
|
||||
if (!AimAvailability_TextOnly)
|
||||
{
|
||||
gAimAvailability[pData->curAimAvailability.uiIndex].uiIndex = pData->curAimAvailability.uiIndex;
|
||||
gAimAvailability[pData->curAimAvailability.uiIndex].ProfilId = pData->curAimAvailability.ProfilId;
|
||||
gAimAvailability[pData->curAimAvailability.uiIndex].ubAimArrayID = pData->curAimAvailability.uiIndex;
|
||||
gAimAvailability[pData->curAimAvailability.uiIndex].AimBio = pData->curAimAvailability.AimBio;
|
||||
|
||||
gAimAvailabilityTemp[pData->curAimAvailability.uiIndex].uiIndex = pData->curAimAvailability.uiIndex;
|
||||
gAimAvailabilityTemp[pData->curAimAvailability.uiIndex].ProfilId = pData->curAimAvailability.ProfilId;
|
||||
gAimAvailabilityTemp[pData->curAimAvailability.uiIndex].ubAimArrayID = pData->curAimAvailability.uiIndex;
|
||||
gAimAvailabilityTemp[pData->curAimAvailability.uiIndex].AimBio = pData->curAimAvailability.AimBio;
|
||||
}
|
||||
else
|
||||
{
|
||||
gAimAvailability[pData->curAimAvailability.uiIndex].uiIndex = pData->curAimAvailability.uiIndex;
|
||||
gAimAvailability[pData->curAimAvailability.uiIndex].ProfilId = pData->curAimAvailability.ProfilId;
|
||||
gAimAvailability[pData->curAimAvailability.uiIndex].ubAimArrayID = pData->curAimAvailability.uiIndex;
|
||||
gAimAvailability[pData->curAimAvailability.uiIndex].AimBio = pData->curAimAvailability.AimBio;
|
||||
|
||||
gAimAvailabilityTemp[pData->curAimAvailability.uiIndex].uiIndex = pData->curAimAvailability.uiIndex;
|
||||
gAimAvailabilityTemp[pData->curAimAvailability.uiIndex].ProfilId = pData->curAimAvailability.ProfilId;
|
||||
gAimAvailabilityTemp[pData->curAimAvailability.uiIndex].ubAimArrayID = pData->curAimAvailability.uiIndex;
|
||||
gAimAvailabilityTemp[pData->curAimAvailability.uiIndex].AimBio = pData->curAimAvailability.AimBio;
|
||||
}
|
||||
}
|
||||
else if(strcmp(name, "uiIndex") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curAimAvailability.uiIndex = (UINT8) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "ProfilId") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curAimAvailability.ProfilId = (UINT8) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "AimBioID") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curAimAvailability.AimBio = (UINT8) atol(pData->szCharData);
|
||||
}
|
||||
|
||||
pData->maxReadDepth--;
|
||||
}
|
||||
pData->currentDepth--;
|
||||
}
|
||||
|
||||
BOOLEAN ReadInAimAvailability(STR fileName, BOOLEAN localizedVersion)
|
||||
{
|
||||
HWFILE hFile;
|
||||
UINT32 uiBytesRead;
|
||||
UINT32 uiFSize;
|
||||
CHAR8 * lpcBuffer;
|
||||
XML_Parser parser = XML_ParserCreate(NULL);
|
||||
|
||||
aimAvailabilityParseData pData;
|
||||
|
||||
DebugMsg(TOPIC_JA2, DBG_LEVEL_3, "Loading AimAvailability.xml" );
|
||||
|
||||
AimAvailability_TextOnly = localizedVersion;
|
||||
|
||||
// Open file
|
||||
hFile = FileOpen( fileName, FILE_ACCESS_READ, FALSE );
|
||||
if ( !hFile )
|
||||
return( localizedVersion );
|
||||
|
||||
uiFSize = FileGetSize(hFile);
|
||||
lpcBuffer = (CHAR8 *) MemAlloc(uiFSize+1);
|
||||
|
||||
//Read in block
|
||||
if ( !FileRead( hFile, lpcBuffer, uiFSize, &uiBytesRead ) )
|
||||
{
|
||||
MemFree(lpcBuffer);
|
||||
return( FALSE );
|
||||
}
|
||||
|
||||
lpcBuffer[uiFSize] = 0; //add a null terminator
|
||||
|
||||
FileClose( hFile );
|
||||
|
||||
|
||||
XML_SetElementHandler(parser, aimAvailabilityStartElementHandle, aimAvailabilityEndElementHandle);
|
||||
XML_SetCharacterDataHandler(parser, aimCharacterDataHandle);
|
||||
|
||||
|
||||
memset(&pData,0,sizeof(pData));
|
||||
XML_SetUserData(parser, &pData);
|
||||
|
||||
|
||||
if(!XML_Parse(parser, lpcBuffer, uiFSize, TRUE))
|
||||
{
|
||||
CHAR8 errorBuf[511];
|
||||
|
||||
sprintf(errorBuf, "XML Parser Error in AimAvailability.xml: %s at line %d", XML_ErrorString(XML_GetErrorCode(parser)), XML_GetCurrentLineNumber(parser));
|
||||
LiveMessage(errorBuf);
|
||||
|
||||
MemFree(lpcBuffer);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
MemFree(lpcBuffer);
|
||||
|
||||
|
||||
XML_ParserFree(parser);
|
||||
|
||||
|
||||
return( TRUE );
|
||||
}
|
||||
|
||||
|
||||
BOOLEAN WriteAimAvailability(STR fileName)
|
||||
{
|
||||
HWFILE hFile;
|
||||
|
||||
//Debug code; make sure that what we got from the file is the same as what's there
|
||||
// Open a new file
|
||||
hFile = FileOpen( fileName, FILE_ACCESS_WRITE | FILE_CREATE_ALWAYS, FALSE );
|
||||
if ( !hFile )
|
||||
return( FALSE );
|
||||
|
||||
{
|
||||
UINT32 cnt;
|
||||
|
||||
FilePrintf(hFile,"<AIM_AVAILABLES>\r\n");
|
||||
for(cnt = 0;cnt < NUM_PROFILES;cnt++)
|
||||
{
|
||||
|
||||
FilePrintf(hFile,"\t<AIM>\r\n");
|
||||
|
||||
FilePrintf(hFile,"\t\t<uiIndex>%d</uiIndex>\r\n", cnt);
|
||||
// FilePrintf(hFile,"\t\t<ProfilId>-1</ProfilId>\r\n");
|
||||
// FilePrintf(hFile,"\t\t<AIMBioID>0</AIMBioID>\r\n");
|
||||
|
||||
FilePrintf(hFile,"\t\t<ProfilId>%d</ProfilId>\r\n", gAimAvailability[cnt].ProfilId);
|
||||
FilePrintf(hFile,"\t\t<AIMBioID>%d</AIMBioID>\r\n", gAimAvailability[cnt].AimBio);
|
||||
FilePrintf(hFile,"\t</AIM>\r\n");
|
||||
}
|
||||
FilePrintf(hFile,"</AIM_AVAILABLES>\r\n");
|
||||
}
|
||||
FileClose( hFile );
|
||||
|
||||
return( TRUE );
|
||||
}
|
||||
@@ -0,0 +1,294 @@
|
||||
#ifdef PRECOMPILEDHEADERS
|
||||
#include "Tactical All.h"
|
||||
#else
|
||||
#include "sgp.h"
|
||||
#include "Debug Control.h"
|
||||
#include "expat.h"
|
||||
#include "XML.h"
|
||||
#include "Interface.h"
|
||||
#include "mercs.h"
|
||||
#endif
|
||||
|
||||
struct
|
||||
{
|
||||
PARSE_STAGE curElement;
|
||||
|
||||
CHAR8 szCharData[MAX_CHAR_DATA_LENGTH+1];
|
||||
CONTITION_FOR_MERC_AVAILABLE curMercAvailability;
|
||||
CONTITION_FOR_MERC_AVAILABLE * curArray;
|
||||
|
||||
UINT32 maxArraySize;
|
||||
UINT32 curIndex;
|
||||
UINT32 currentDepth;
|
||||
UINT32 maxReadDepth;
|
||||
}
|
||||
typedef mercAvailabilityParseData;
|
||||
|
||||
BOOLEAN MercAvailability_TextOnly;
|
||||
|
||||
static void XMLCALL
|
||||
mercAvailabilityStartElementHandle(void *userData, const XML_Char *name, const XML_Char **atts)
|
||||
{
|
||||
mercAvailabilityParseData * pData = (mercAvailabilityParseData *)userData;
|
||||
|
||||
if(pData->currentDepth <= pData->maxReadDepth) //are we reading this element?
|
||||
{
|
||||
if(strcmp(name, "MERC_AVAILABLES") == 0 && pData->curElement == ELEMENT_NONE)
|
||||
{
|
||||
pData->curElement = ELEMENT_LIST;
|
||||
|
||||
pData->maxReadDepth++; //we are not skipping this element
|
||||
}
|
||||
else if(strcmp(name, "MERC") == 0 && pData->curElement == ELEMENT_LIST)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
|
||||
pData->maxReadDepth++; //we are not skipping this element
|
||||
}
|
||||
else if(pData->curElement == ELEMENT &&
|
||||
(strcmp(name, "uiIndex") == 0 ||
|
||||
strcmp(name, "ProfilId") == 0 ||
|
||||
strcmp(name, "usMoneyPaid") == 0 ||
|
||||
strcmp(name, "Available") == 0 ||
|
||||
strcmp(name, "NewMercsAvailable") == 0 ||
|
||||
strcmp(name, "StartMercsAvailable") == 0 ||
|
||||
strcmp(name, "MercBioID") == 0 ||
|
||||
strcmp(name, "Drunk") == 0 ||
|
||||
strcmp(name, "uiAlternateIndex") == 0 ||
|
||||
strcmp(name, "usDay") == 0 ))
|
||||
{
|
||||
pData->curElement = ELEMENT_PROPERTY;
|
||||
|
||||
pData->maxReadDepth++; //we are not skipping this element
|
||||
}
|
||||
|
||||
pData->szCharData[0] = '\0';
|
||||
}
|
||||
|
||||
pData->currentDepth++;
|
||||
|
||||
}
|
||||
|
||||
static void XMLCALL
|
||||
mercCharacterDataHandle(void *userData, const XML_Char *str, int len)
|
||||
{
|
||||
mercAvailabilityParseData * pData = (mercAvailabilityParseData *)userData;
|
||||
|
||||
if( (pData->currentDepth <= pData->maxReadDepth) &&
|
||||
(strlen(pData->szCharData) < MAX_CHAR_DATA_LENGTH)
|
||||
){
|
||||
strncat(pData->szCharData,str,__min((unsigned int)len,MAX_CHAR_DATA_LENGTH-strlen(pData->szCharData)));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static void XMLCALL
|
||||
mercAvailabilityEndElementHandle(void *userData, const XML_Char *name)
|
||||
{
|
||||
mercAvailabilityParseData * pData = (mercAvailabilityParseData *)userData;
|
||||
|
||||
if(pData->currentDepth <= pData->maxReadDepth)
|
||||
{
|
||||
if(strcmp(name, "MERC_AVAILABLES") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT_NONE;
|
||||
}
|
||||
else if(strcmp(name, "MERC") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT_LIST;
|
||||
|
||||
if (!MercAvailability_TextOnly)
|
||||
{
|
||||
gConditionsForMercAvailability[pData->curMercAvailability.uiIndex].uiIndex = pData->curMercAvailability.uiIndex;
|
||||
gConditionsForMercAvailability[pData->curMercAvailability.uiIndex].ProfilId = pData->curMercAvailability.ProfilId;
|
||||
gConditionsForMercAvailability[pData->curMercAvailability.uiIndex].usMoneyPaid = pData->curMercAvailability.usMoneyPaid;
|
||||
gConditionsForMercAvailability[pData->curMercAvailability.uiIndex].usDay = pData->curMercAvailability.usDay;
|
||||
gConditionsForMercAvailability[pData->curMercAvailability.uiIndex].ubMercArrayID = pData->curMercAvailability.uiIndex;
|
||||
gConditionsForMercAvailability[pData->curMercAvailability.uiIndex].NewMercsAvailable = pData->curMercAvailability.NewMercsAvailable;
|
||||
gConditionsForMercAvailability[pData->curMercAvailability.uiIndex].StartMercsAvailable = pData->curMercAvailability.StartMercsAvailable;
|
||||
gConditionsForMercAvailability[pData->curMercAvailability.uiIndex].MercBio = pData->curMercAvailability.MercBio;
|
||||
gConditionsForMercAvailability[pData->curMercAvailability.uiIndex].Drunk = pData->curMercAvailability.Drunk;
|
||||
gConditionsForMercAvailability[pData->curMercAvailability.uiIndex].uiAlternateIndex = pData->curMercAvailability.uiAlternateIndex;
|
||||
|
||||
gConditionsForMercAvailabilityTemp[pData->curMercAvailability.uiIndex].uiIndex = pData->curMercAvailability.uiIndex;
|
||||
gConditionsForMercAvailabilityTemp[pData->curMercAvailability.uiIndex].ProfilId = pData->curMercAvailability.ProfilId;
|
||||
gConditionsForMercAvailabilityTemp[pData->curMercAvailability.uiIndex].usMoneyPaid = pData->curMercAvailability.usMoneyPaid;
|
||||
gConditionsForMercAvailabilityTemp[pData->curMercAvailability.uiIndex].usDay = pData->curMercAvailability.usDay;
|
||||
gConditionsForMercAvailabilityTemp[pData->curMercAvailability.uiIndex].ubMercArrayID = pData->curMercAvailability.uiIndex;
|
||||
gConditionsForMercAvailabilityTemp[pData->curMercAvailability.uiIndex].NewMercsAvailable = pData->curMercAvailability.NewMercsAvailable;
|
||||
gConditionsForMercAvailabilityTemp[pData->curMercAvailability.uiIndex].StartMercsAvailable = pData->curMercAvailability.StartMercsAvailable;
|
||||
gConditionsForMercAvailabilityTemp[pData->curMercAvailability.uiIndex].MercBio = pData->curMercAvailability.MercBio;
|
||||
gConditionsForMercAvailabilityTemp[pData->curMercAvailability.uiIndex].Drunk = pData->curMercAvailability.Drunk;
|
||||
gConditionsForMercAvailabilityTemp[pData->curMercAvailability.uiIndex].uiAlternateIndex = pData->curMercAvailability.uiAlternateIndex;
|
||||
}
|
||||
else
|
||||
{
|
||||
gConditionsForMercAvailability[pData->curMercAvailability.uiIndex].uiIndex = pData->curMercAvailability.uiIndex;
|
||||
gConditionsForMercAvailability[pData->curMercAvailability.uiIndex].ProfilId = pData->curMercAvailability.ProfilId;
|
||||
gConditionsForMercAvailability[pData->curMercAvailability.uiIndex].usMoneyPaid = pData->curMercAvailability.usMoneyPaid;
|
||||
gConditionsForMercAvailability[pData->curMercAvailability.uiIndex].usDay = pData->curMercAvailability.usDay;
|
||||
gConditionsForMercAvailability[pData->curMercAvailability.uiIndex].ubMercArrayID = pData->curMercAvailability.uiIndex;
|
||||
gConditionsForMercAvailability[pData->curMercAvailability.uiIndex].NewMercsAvailable = pData->curMercAvailability.NewMercsAvailable;
|
||||
gConditionsForMercAvailability[pData->curMercAvailability.uiIndex].StartMercsAvailable = pData->curMercAvailability.StartMercsAvailable;
|
||||
gConditionsForMercAvailability[pData->curMercAvailability.uiIndex].MercBio = pData->curMercAvailability.MercBio;
|
||||
gConditionsForMercAvailability[pData->curMercAvailability.uiIndex].Drunk = pData->curMercAvailability.Drunk;
|
||||
gConditionsForMercAvailability[pData->curMercAvailability.uiIndex].uiAlternateIndex = pData->curMercAvailability.uiAlternateIndex;
|
||||
|
||||
gConditionsForMercAvailabilityTemp[pData->curMercAvailability.uiIndex].uiIndex = pData->curMercAvailability.uiIndex;
|
||||
gConditionsForMercAvailabilityTemp[pData->curMercAvailability.uiIndex].ProfilId = pData->curMercAvailability.ProfilId;
|
||||
gConditionsForMercAvailabilityTemp[pData->curMercAvailability.uiIndex].usMoneyPaid = pData->curMercAvailability.usMoneyPaid;
|
||||
gConditionsForMercAvailabilityTemp[pData->curMercAvailability.uiIndex].usDay = pData->curMercAvailability.usDay;
|
||||
gConditionsForMercAvailabilityTemp[pData->curMercAvailability.uiIndex].ubMercArrayID = pData->curMercAvailability.uiIndex;
|
||||
gConditionsForMercAvailabilityTemp[pData->curMercAvailability.uiIndex].NewMercsAvailable = pData->curMercAvailability.NewMercsAvailable;
|
||||
gConditionsForMercAvailabilityTemp[pData->curMercAvailability.uiIndex].StartMercsAvailable = pData->curMercAvailability.StartMercsAvailable;
|
||||
gConditionsForMercAvailabilityTemp[pData->curMercAvailability.uiIndex].MercBio = pData->curMercAvailability.MercBio;
|
||||
gConditionsForMercAvailabilityTemp[pData->curMercAvailability.uiIndex].Drunk = pData->curMercAvailability.Drunk;
|
||||
gConditionsForMercAvailabilityTemp[pData->curMercAvailability.uiIndex].uiAlternateIndex = pData->curMercAvailability.uiAlternateIndex;
|
||||
|
||||
}
|
||||
}
|
||||
else if(strcmp(name, "uiIndex") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curMercAvailability.uiIndex = (UINT8) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "usMoneyPaid") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curMercAvailability.usMoneyPaid = (UINT16) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "usDay") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curMercAvailability.usDay = (UINT16) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "ProfilId") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curMercAvailability.ProfilId = (UINT8) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "NewMercsAvailable") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curMercAvailability.NewMercsAvailable = (BOOLEAN) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "StartMercsAvailable") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curMercAvailability.StartMercsAvailable = (BOOLEAN) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "MercBioID") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curMercAvailability.MercBio = (UINT8) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "Drunk") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curMercAvailability.Drunk = (BOOLEAN) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "uiAlternateIndex") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curMercAvailability.uiAlternateIndex = (UINT8) atol(pData->szCharData);
|
||||
}
|
||||
|
||||
pData->maxReadDepth--;
|
||||
}
|
||||
pData->currentDepth--;
|
||||
}
|
||||
|
||||
BOOLEAN ReadInMercAvailability(STR fileName, BOOLEAN localizedVersion)
|
||||
{
|
||||
HWFILE hFile;
|
||||
UINT32 uiBytesRead;
|
||||
UINT32 uiFSize;
|
||||
CHAR8 * lpcBuffer;
|
||||
XML_Parser parser = XML_ParserCreate(NULL);
|
||||
|
||||
mercAvailabilityParseData pData;
|
||||
|
||||
DebugMsg(TOPIC_JA2, DBG_LEVEL_3, "Loading MercAvailability.xml" );
|
||||
|
||||
MercAvailability_TextOnly = localizedVersion;
|
||||
|
||||
// Open file
|
||||
hFile = FileOpen( fileName, FILE_ACCESS_READ, FALSE );
|
||||
if ( !hFile )
|
||||
return( localizedVersion );
|
||||
|
||||
uiFSize = FileGetSize(hFile);
|
||||
lpcBuffer = (CHAR8 *) MemAlloc(uiFSize+1);
|
||||
|
||||
//Read in block
|
||||
if ( !FileRead( hFile, lpcBuffer, uiFSize, &uiBytesRead ) )
|
||||
{
|
||||
MemFree(lpcBuffer);
|
||||
return( FALSE );
|
||||
}
|
||||
|
||||
lpcBuffer[uiFSize] = 0; //add a null terminator
|
||||
|
||||
FileClose( hFile );
|
||||
|
||||
|
||||
XML_SetElementHandler(parser, mercAvailabilityStartElementHandle, mercAvailabilityEndElementHandle);
|
||||
XML_SetCharacterDataHandler(parser, mercCharacterDataHandle);
|
||||
|
||||
|
||||
memset(&pData,0,sizeof(pData));
|
||||
XML_SetUserData(parser, &pData);
|
||||
|
||||
|
||||
if(!XML_Parse(parser, lpcBuffer, uiFSize, TRUE))
|
||||
{
|
||||
CHAR8 errorBuf[511];
|
||||
|
||||
sprintf(errorBuf, "XML Parser Error in MercAvailability.xml: %s at line %d", XML_ErrorString(XML_GetErrorCode(parser)), XML_GetCurrentLineNumber(parser));
|
||||
LiveMessage(errorBuf);
|
||||
|
||||
MemFree(lpcBuffer);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
MemFree(lpcBuffer);
|
||||
|
||||
|
||||
XML_ParserFree(parser);
|
||||
|
||||
|
||||
return( TRUE );
|
||||
}
|
||||
|
||||
|
||||
BOOLEAN WriteMercAvailability(STR fileName)
|
||||
{
|
||||
HWFILE hFile;
|
||||
|
||||
//Debug code; make sure that what we got from the file is the same as what's there
|
||||
// Open a new file
|
||||
hFile = FileOpen( fileName, FILE_ACCESS_WRITE | FILE_CREATE_ALWAYS, FALSE );
|
||||
if ( !hFile )
|
||||
return( FALSE );
|
||||
|
||||
{
|
||||
UINT32 cnt;
|
||||
|
||||
FilePrintf(hFile,"<MERC_AVAILABLES>\r\n");
|
||||
for(cnt = 0;cnt < NUM_PROFILES;cnt++)
|
||||
{
|
||||
|
||||
FilePrintf(hFile,"\t<MERC>\r\n");
|
||||
|
||||
FilePrintf(hFile,"\t\t<uiIndex>%d</uiIndex>\r\n", cnt);
|
||||
FilePrintf(hFile,"\t\t<usMoneyPaid>%d</usMoneyPaid>\r\n", gConditionsForMercAvailability[cnt].usMoneyPaid);
|
||||
FilePrintf(hFile,"\t\t<usDay>%d</usDay>\r\n", gConditionsForMercAvailability[cnt].usDay);
|
||||
FilePrintf(hFile,"\t\t<ProfilId>%d</ProfilId>\r\n", gConditionsForMercAvailability[cnt].ProfilId);
|
||||
FilePrintf(hFile,"\t</MERC>\r\n");
|
||||
}
|
||||
FilePrintf(hFile,"</MERC_AVAILABLES>\r\n");
|
||||
}
|
||||
FileClose( hFile );
|
||||
|
||||
return( TRUE );
|
||||
}
|
||||
@@ -0,0 +1,315 @@
|
||||
#ifdef PRECOMPILEDHEADERS
|
||||
#include "Tactical All.h"
|
||||
#else
|
||||
#include "sgp.h"
|
||||
#include "Debug Control.h"
|
||||
#include "expat.h"
|
||||
#include "XML.h"
|
||||
#include "Interface.h"
|
||||
#include "IMP Confirm.h"
|
||||
#include "IMP Portraits.h"
|
||||
#endif
|
||||
|
||||
struct
|
||||
{
|
||||
PARSE_STAGE curElement;
|
||||
|
||||
CHAR8 szCharData[MAX_CHAR_DATA_LENGTH+1];
|
||||
IMP_FACE_VALUES curIMPPortraits;
|
||||
IMP_FACE_VALUES * curArray;
|
||||
|
||||
UINT32 maxArraySize;
|
||||
UINT32 curIndex;
|
||||
UINT32 currentDepth;
|
||||
UINT32 maxReadDepth;
|
||||
//CHAR16 gzIMPPortraits[MAX_IMP_NAMES_CHARS];
|
||||
}
|
||||
typedef impPortraitsParseData;
|
||||
|
||||
BOOLEAN IMPPortraits_TextOnly;
|
||||
|
||||
static void XMLCALL
|
||||
impPortraitsStartElementHandle(void *userData, const XML_Char *name, const XML_Char **atts)
|
||||
{
|
||||
impPortraitsParseData * pData = (impPortraitsParseData *)userData;
|
||||
|
||||
if(pData->currentDepth <= pData->maxReadDepth) //are we reading this element?
|
||||
{
|
||||
if(strcmp(name, "IMPPORTRAITSLIST") == 0 && pData->curElement == ELEMENT_NONE)
|
||||
{
|
||||
pData->curElement = ELEMENT_LIST;
|
||||
|
||||
pData->maxReadDepth++; //we are not skipping this element
|
||||
}
|
||||
else if(strcmp(name, "IMP") == 0 && pData->curElement == ELEMENT_LIST)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
|
||||
pData->maxReadDepth++; //we are not skipping this element
|
||||
}
|
||||
else if(pData->curElement == ELEMENT &&
|
||||
(strcmp(name, "uiIndex") == 0 ||
|
||||
strcmp(name, "PortraitId") == 0 ||
|
||||
strcmp(name, "bSex") == 0 ||
|
||||
strcmp(name, "usEyesX") == 0 ||
|
||||
strcmp(name, "usEyesY") == 0 ||
|
||||
strcmp(name, "usMouthY") == 0 ||
|
||||
strcmp(name, "usMouthX") == 0 ||
|
||||
strcmp(name, "DefaultSkin") == 0 ||
|
||||
strcmp(name, "DefaultHair") == 0 ||
|
||||
strcmp(name, "DefaultShirt") == 0 ||
|
||||
strcmp(name, "DefaultPants") == 0 ||
|
||||
strcmp(name, "DefaultBigBody") == 0 ))
|
||||
{
|
||||
pData->curElement = ELEMENT_PROPERTY;
|
||||
|
||||
pData->maxReadDepth++; //we are not skipping this element
|
||||
}
|
||||
|
||||
pData->szCharData[0] = '\0';
|
||||
}
|
||||
|
||||
pData->currentDepth++;
|
||||
|
||||
}
|
||||
|
||||
static void XMLCALL
|
||||
impPortraitsCharacterDataHandle(void *userData, const XML_Char *str, int len)
|
||||
{
|
||||
impPortraitsParseData * pData = (impPortraitsParseData *)userData;
|
||||
|
||||
if( (pData->currentDepth <= pData->maxReadDepth) &&
|
||||
(strlen(pData->szCharData) < MAX_CHAR_DATA_LENGTH)
|
||||
){
|
||||
strncat(pData->szCharData,str,__min((unsigned int)len,MAX_CHAR_DATA_LENGTH-strlen(pData->szCharData)));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static void XMLCALL
|
||||
impPortraitsEndElementHandle(void *userData, const XML_Char *name)
|
||||
{
|
||||
impPortraitsParseData * pData = (impPortraitsParseData *)userData;
|
||||
|
||||
if(pData->currentDepth <= pData->maxReadDepth)
|
||||
{
|
||||
if(strcmp(name, "IMPPORTRAITSLIST") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT_NONE;
|
||||
}
|
||||
else if(strcmp(name, "IMP") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT_LIST;
|
||||
|
||||
if (!IMPPortraits_TextOnly)
|
||||
{
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].uiEyeXPositions = pData->curIMPPortraits.uiEyeXPositions;
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].uiEyeYPositions = pData->curIMPPortraits.uiEyeYPositions;
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].uiMouthXPositions = pData->curIMPPortraits.uiMouthXPositions;
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].uiMouthYPositions = pData->curIMPPortraits.uiMouthYPositions;
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].PortraitId = pData->curIMPPortraits.PortraitId;
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].bSex = pData->curIMPPortraits.bSex;
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].iCurrentSkin = pData->curIMPPortraits.iCurrentSkin;
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].iCurrentShirt = pData->curIMPPortraits.iCurrentShirt;
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].iCurrentHair = pData->curIMPPortraits.iCurrentHair;
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].iCurrentPants = pData->curIMPPortraits.iCurrentPants;
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].bBigBody = pData->curIMPPortraits.bBigBody;
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].uiEyeXPositions = pData->curIMPPortraits.uiEyeXPositions;
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].uiEyeYPositions = pData->curIMPPortraits.uiEyeYPositions;
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].uiMouthXPositions = pData->curIMPPortraits.uiMouthXPositions;
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].uiMouthYPositions = pData->curIMPPortraits.uiMouthYPositions;
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].PortraitId = pData->curIMPPortraits.PortraitId;
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].bSex = pData->curIMPPortraits.bSex;
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].iCurrentSkin = pData->curIMPPortraits.iCurrentSkin;
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].iCurrentShirt = pData->curIMPPortraits.iCurrentShirt;
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].iCurrentHair = pData->curIMPPortraits.iCurrentHair;
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].iCurrentPants = pData->curIMPPortraits.iCurrentPants;
|
||||
gIMPFaceValues[pData->curIMPPortraits.uiIndex].bBigBody = pData->curIMPPortraits.bBigBody;
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
else if(strcmp(name, "uiIndex") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curIMPPortraits.uiIndex = (UINT16) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "PortraitId") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curIMPPortraits.PortraitId = (INT32) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "bSex") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curIMPPortraits.bSex = (BOOLEAN) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "usEyesX") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curIMPPortraits.uiEyeXPositions = (INT8) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "usEyesY") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curIMPPortraits.uiEyeYPositions = (INT8) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "usMouthX") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curIMPPortraits.uiMouthXPositions = (INT8) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "usMouthY") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curIMPPortraits.uiMouthYPositions = (INT8) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "DefaultSkin") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curIMPPortraits.iCurrentSkin = (INT32) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "DefaultHair") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curIMPPortraits.iCurrentHair = (INT32) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "DefaultShirt") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curIMPPortraits.iCurrentShirt = (INT32) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "DefaultPants") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curIMPPortraits.iCurrentPants = (INT32) atol(pData->szCharData);
|
||||
}
|
||||
else if(strcmp(name, "DefaultBigBody") == 0)
|
||||
{
|
||||
pData->curElement = ELEMENT;
|
||||
pData->curIMPPortraits.bBigBody = (INT32) atol(pData->szCharData);
|
||||
}
|
||||
|
||||
pData->maxReadDepth--;
|
||||
}
|
||||
pData->currentDepth--;
|
||||
}
|
||||
|
||||
BOOLEAN ReadInIMPPortraits(STR fileName, BOOLEAN localizedVersion)
|
||||
{
|
||||
HWFILE hFile;
|
||||
UINT32 uiBytesRead;
|
||||
UINT32 uiFSize;
|
||||
CHAR8 * lpcBuffer;
|
||||
XML_Parser parser = XML_ParserCreate(NULL);
|
||||
|
||||
impPortraitsParseData pData;
|
||||
|
||||
DebugMsg(TOPIC_JA2, DBG_LEVEL_3, "Loading IMPPortraits.xml" );
|
||||
|
||||
IMPPortraits_TextOnly = localizedVersion;
|
||||
|
||||
// Open file
|
||||
hFile = FileOpen( fileName, FILE_ACCESS_READ, FALSE );
|
||||
if ( !hFile )
|
||||
return( localizedVersion );
|
||||
|
||||
uiFSize = FileGetSize(hFile);
|
||||
lpcBuffer = (CHAR8 *) MemAlloc(uiFSize+1);
|
||||
|
||||
//Read in block
|
||||
if ( !FileRead( hFile, lpcBuffer, uiFSize, &uiBytesRead ) )
|
||||
{
|
||||
MemFree(lpcBuffer);
|
||||
return( FALSE );
|
||||
}
|
||||
|
||||
lpcBuffer[uiFSize] = 0; //add a null terminator
|
||||
|
||||
FileClose( hFile );
|
||||
|
||||
|
||||
XML_SetElementHandler(parser, impPortraitsStartElementHandle, impPortraitsEndElementHandle);
|
||||
XML_SetCharacterDataHandler(parser, impPortraitsCharacterDataHandle);
|
||||
|
||||
|
||||
memset(&pData,0,sizeof(pData));
|
||||
XML_SetUserData(parser, &pData);
|
||||
|
||||
|
||||
if(!XML_Parse(parser, lpcBuffer, uiFSize, TRUE))
|
||||
{
|
||||
CHAR8 errorBuf[511];
|
||||
|
||||
sprintf(errorBuf, "XML Parser Error in IMPPortraits.xml: %s at line %d", XML_ErrorString(XML_GetErrorCode(parser)), XML_GetCurrentLineNumber(parser));
|
||||
LiveMessage(errorBuf);
|
||||
|
||||
MemFree(lpcBuffer);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
MemFree(lpcBuffer);
|
||||
|
||||
|
||||
XML_ParserFree(parser);
|
||||
|
||||
|
||||
return( TRUE );
|
||||
}
|
||||
|
||||
|
||||
void LoadIMPPortraitsTEMP()
|
||||
{
|
||||
UINT32 cnt;
|
||||
UINT32 cnt2 = 0;
|
||||
UINT32 cnt3 = 0;
|
||||
|
||||
for ( cnt = 0; cnt < 200; cnt++ )
|
||||
{
|
||||
if (gIMPFaceValues[cnt].bSex == 1 && gIMPFaceValues[cnt].PortraitId !=0)
|
||||
{
|
||||
gIMPFemaleValues[cnt2].uiIndex = cnt2;
|
||||
|
||||
gIMPFemaleValues[cnt2].Enabled = 1;
|
||||
|
||||
gIMPFemaleValues[cnt2].uiEyeXPositions = gIMPFaceValues[cnt].uiEyeXPositions;
|
||||
gIMPFemaleValues[cnt2].uiEyeYPositions = gIMPFaceValues[cnt].uiEyeYPositions;
|
||||
gIMPFemaleValues[cnt2].uiMouthXPositions = gIMPFaceValues[cnt].uiMouthXPositions;
|
||||
gIMPFemaleValues[cnt2].uiMouthYPositions = gIMPFaceValues[cnt].uiMouthYPositions;
|
||||
gIMPFemaleValues[cnt2].PortraitId = gIMPFaceValues[cnt].PortraitId;
|
||||
gIMPFemaleValues[cnt2].bSex = gIMPFaceValues[cnt].bSex;
|
||||
gIMPFemaleValues[cnt2].iCurrentSkin = gIMPFaceValues[cnt].iCurrentSkin;
|
||||
gIMPFemaleValues[cnt2].iCurrentShirt = gIMPFaceValues[cnt].iCurrentShirt;
|
||||
gIMPFemaleValues[cnt2].iCurrentHair = gIMPFaceValues[cnt].iCurrentHair;
|
||||
gIMPFemaleValues[cnt2].iCurrentPants = gIMPFaceValues[cnt].iCurrentPants;
|
||||
gIMPFemaleValues[cnt2].bBigBody = gIMPFaceValues[cnt].bBigBody;
|
||||
cnt2++;
|
||||
}
|
||||
}
|
||||
|
||||
for ( cnt = 0; cnt < 200; cnt++ )
|
||||
{
|
||||
if (gIMPFaceValues[cnt].bSex == 0 && gIMPFaceValues[cnt].PortraitId !=0)
|
||||
{
|
||||
gIMPMaleValues[cnt3].uiIndex = cnt3;
|
||||
gIMPMaleValues[cnt3].Enabled = 1;
|
||||
gIMPMaleValues[cnt3].uiEyeXPositions = gIMPFaceValues[cnt].uiEyeXPositions;
|
||||
gIMPMaleValues[cnt3].uiEyeYPositions = gIMPFaceValues[cnt].uiEyeYPositions;
|
||||
gIMPMaleValues[cnt3].uiMouthXPositions = gIMPFaceValues[cnt].uiMouthXPositions;
|
||||
gIMPMaleValues[cnt3].uiMouthYPositions = gIMPFaceValues[cnt].uiMouthYPositions;
|
||||
gIMPMaleValues[cnt3].PortraitId = gIMPFaceValues[cnt].PortraitId;
|
||||
gIMPMaleValues[cnt3].bSex = gIMPFaceValues[cnt].bSex;
|
||||
gIMPMaleValues[cnt3].iCurrentSkin = gIMPFaceValues[cnt].iCurrentSkin;
|
||||
gIMPMaleValues[cnt3].iCurrentShirt = gIMPFaceValues[cnt].iCurrentShirt;
|
||||
gIMPMaleValues[cnt3].iCurrentHair = gIMPFaceValues[cnt].iCurrentHair;
|
||||
gIMPMaleValues[cnt3].iCurrentPants = gIMPFaceValues[cnt].iCurrentPants;
|
||||
gIMPMaleValues[cnt3].bBigBody = gIMPFaceValues[cnt].bBigBody;
|
||||
cnt3++;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
+82
-33
@@ -14,11 +14,18 @@
|
||||
#include "Text.h"
|
||||
#include "LaptopSave.h"
|
||||
#include "Multi Language Graphic Utils.h"
|
||||
#include "GameSettings.h"
|
||||
#endif
|
||||
|
||||
#include "LocalizedStrings.h"
|
||||
#include "Soldier Profile.h"
|
||||
|
||||
UINT8 MAX_NUMBER_MERCS = 0;
|
||||
|
||||
UINT8 AimMercArray[ MAX_NUMBER_MERCS ];
|
||||
UINT8 AimMercArray[ NUM_PROFILES ]; //MAX_NUMBER_MERCS ];
|
||||
|
||||
AIM_AVAILABLE_TEMP gAimAvailabilityTemp[ NUM_PROFILES ];
|
||||
AIM_AVAILABLE gAimAvailability[ NUM_PROFILES ];
|
||||
|
||||
UINT8 gCurrentAimPage[ NUM_AIM_SCREENS ] =
|
||||
{
|
||||
@@ -470,14 +477,27 @@ BOOLEAN InitAimDefaults()
|
||||
CHECKF(AddVideoObject(&VObjectDesc, &guiRustBackGround));
|
||||
|
||||
// load the Aim Symbol graphic and add it
|
||||
VObjectDesc.fCreateFlags=VOBJECT_CREATE_FROMFILE;
|
||||
GetMLGFilename( VObjectDesc.ImageFile, MLG_AIMSYMBOL );
|
||||
CHECKF(AddVideoObject(&VObjectDesc, &guiAimSymbol));
|
||||
if(gGameExternalOptions.gfUseNewStartingGearInterface)
|
||||
{
|
||||
VObjectDesc.fCreateFlags=VOBJECT_CREATE_FROMFILE;
|
||||
GetMLGFilename( VObjectDesc.ImageFile, MLG_AIMSYMBOL_SMALL );
|
||||
CHECKF(AddVideoObject(&VObjectDesc, &guiAimSymbol));
|
||||
//Mouse region for the Links
|
||||
MSYS_DefineRegion( &gSelectedAimLogo, AIM_SYMBOL_SMALL_X, AIM_SYMBOL_SMALL_Y, AIM_SYMBOL_SMALL_X+AIM_SYMBOL_SMALL_WIDTH, AIM_SYMBOL_SMALL_Y+AIM_SYMBOL_SMALL_HEIGHT, MSYS_PRIORITY_HIGH,
|
||||
CURSOR_WWW, MSYS_NO_CALLBACK, SelectAimLogoRegionCallBack);
|
||||
MSYS_AddRegion(&gSelectedAimLogo);
|
||||
}
|
||||
else
|
||||
{
|
||||
VObjectDesc.fCreateFlags=VOBJECT_CREATE_FROMFILE;
|
||||
GetMLGFilename( VObjectDesc.ImageFile, MLG_AIMSYMBOL );
|
||||
CHECKF(AddVideoObject(&VObjectDesc, &guiAimSymbol));
|
||||
//Mouse region for the Links
|
||||
MSYS_DefineRegion( &gSelectedAimLogo, AIM_SYMBOL_X, AIM_SYMBOL_Y, AIM_SYMBOL_X+AIM_SYMBOL_WIDTH, AIM_SYMBOL_Y+AIM_SYMBOL_HEIGHT, MSYS_PRIORITY_HIGH,
|
||||
CURSOR_WWW, MSYS_NO_CALLBACK, SelectAimLogoRegionCallBack);
|
||||
MSYS_AddRegion(&gSelectedAimLogo);
|
||||
}
|
||||
|
||||
//Mouse region for the Links
|
||||
MSYS_DefineRegion( &gSelectedAimLogo, AIM_SYMBOL_X, AIM_SYMBOL_Y, AIM_SYMBOL_X+AIM_SYMBOL_WIDTH, AIM_SYMBOL_Y+AIM_SYMBOL_HEIGHT, MSYS_PRIORITY_HIGH,
|
||||
CURSOR_WWW, MSYS_NO_CALLBACK, SelectAimLogoRegionCallBack);
|
||||
MSYS_AddRegion(&gSelectedAimLogo);
|
||||
|
||||
|
||||
return(TRUE);
|
||||
@@ -514,8 +534,16 @@ BOOLEAN DrawAimDefaults()
|
||||
}
|
||||
|
||||
// Aim Symbol
|
||||
GetVideoObject(&hAimSymbolHandle, guiAimSymbol);
|
||||
BltVideoObject(FRAME_BUFFER, hAimSymbolHandle, 0,AIM_SYMBOL_X, AIM_SYMBOL_Y, VO_BLT_SRCTRANSPARENCY,NULL);
|
||||
if(gGameExternalOptions.gfUseNewStartingGearInterface)
|
||||
{
|
||||
GetVideoObject(&hAimSymbolHandle, guiAimSymbol);
|
||||
BltVideoObject(FRAME_BUFFER, hAimSymbolHandle, 0,AIM_SYMBOL_SMALL_X, AIM_SYMBOL_SMALL_Y, VO_BLT_SRCTRANSPARENCY,NULL);
|
||||
}
|
||||
else
|
||||
{
|
||||
GetVideoObject(&hAimSymbolHandle, guiAimSymbol);
|
||||
BltVideoObject(FRAME_BUFFER, hAimSymbolHandle, 0,AIM_SYMBOL_X, AIM_SYMBOL_Y, VO_BLT_SRCTRANSPARENCY,NULL);
|
||||
}
|
||||
|
||||
return(TRUE);
|
||||
}
|
||||
@@ -541,8 +569,14 @@ void SelectAimLogoRegionCallBack(MOUSE_REGION * pRegion, INT32 iReason )
|
||||
BOOLEAN DisplayAimSlogan()
|
||||
{
|
||||
CHAR16 sSlogan[400];
|
||||
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sSlogan, 0, AIM_HISTORY_LINE_SIZE);
|
||||
if(!g_bUseXML_Strings)
|
||||
{
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sSlogan, 0, AIM_HISTORY_LINE_SIZE);
|
||||
}
|
||||
else
|
||||
{
|
||||
Loc::GetString(Loc::AIM_HISTORY, L"Line", 0, sSlogan, 400);
|
||||
}
|
||||
//Display Aim Text under the logo
|
||||
DisplayWrappedString(AIM_LOGO_TEXT_X, AIM_LOGO_TEXT_Y, AIM_LOGO_TEXT_WIDTH, 2, AIM_LOGO_FONT, AIM_FONT_MCOLOR_WHITE, sSlogan, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED);
|
||||
|
||||
@@ -550,27 +584,37 @@ BOOLEAN DisplayAimSlogan()
|
||||
}
|
||||
|
||||
|
||||
|
||||
BOOLEAN DisplayAimCopyright()
|
||||
{
|
||||
CHAR16 sSlogan[400];
|
||||
UINT32 uiStartLoc=0;
|
||||
|
||||
//Load and Display the copyright notice
|
||||
if(!g_bUseXML_Strings)
|
||||
{
|
||||
UINT32 uiStartLoc=0;
|
||||
uiStartLoc = AIM_HISTORY_LINE_SIZE * AIM_COPYRIGHT_1;
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sSlogan, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
DrawTextToScreen(sSlogan, AIM_COPYRIGHT_X, AIM_COPYRIGHT_Y, AIM_COPYRIGHT_WIDTH, AIM_COPYRIGHT_FONT, FONT_MCOLOR_DKWHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED);
|
||||
|
||||
uiStartLoc = AIM_HISTORY_LINE_SIZE * AIM_COPYRIGHT_1;
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sSlogan, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
DrawTextToScreen(sSlogan, AIM_COPYRIGHT_X, AIM_COPYRIGHT_Y, AIM_COPYRIGHT_WIDTH, AIM_COPYRIGHT_FONT, FONT_MCOLOR_DKWHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED);
|
||||
uiStartLoc = AIM_HISTORY_LINE_SIZE * AIM_COPYRIGHT_2;
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sSlogan, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
DrawTextToScreen(sSlogan, AIM_COPYRIGHT_X, AIM_COPYRIGHT_Y + AIM_COPYRIGHT_GAP, AIM_COPYRIGHT_WIDTH, AIM_COPYRIGHT_FONT, FONT_MCOLOR_DKWHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED);
|
||||
|
||||
uiStartLoc = AIM_HISTORY_LINE_SIZE * AIM_COPYRIGHT_2;
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sSlogan, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
DrawTextToScreen(sSlogan, AIM_COPYRIGHT_X, AIM_COPYRIGHT_Y + AIM_COPYRIGHT_GAP, AIM_COPYRIGHT_WIDTH, AIM_COPYRIGHT_FONT, FONT_MCOLOR_DKWHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED);
|
||||
|
||||
uiStartLoc = AIM_HISTORY_LINE_SIZE * AIM_COPYRIGHT_3;
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sSlogan, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
DrawTextToScreen(sSlogan, AIM_COPYRIGHT_X, AIM_COPYRIGHT_Y + AIM_COPYRIGHT_GAP*2, AIM_COPYRIGHT_WIDTH, AIM_COPYRIGHT_FONT, FONT_MCOLOR_DKWHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED);
|
||||
uiStartLoc = AIM_HISTORY_LINE_SIZE * AIM_COPYRIGHT_3;
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sSlogan, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
DrawTextToScreen(sSlogan, AIM_COPYRIGHT_X, AIM_COPYRIGHT_Y + AIM_COPYRIGHT_GAP*2, AIM_COPYRIGHT_WIDTH, AIM_COPYRIGHT_FONT, FONT_MCOLOR_DKWHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED);
|
||||
}
|
||||
else
|
||||
{
|
||||
Loc::GetString(Loc::AIM_HISTORY, L"Line", AIM_COPYRIGHT_1, sSlogan, 400);
|
||||
DrawTextToScreen(sSlogan, AIM_COPYRIGHT_X, AIM_COPYRIGHT_Y, AIM_COPYRIGHT_WIDTH, AIM_COPYRIGHT_FONT, FONT_MCOLOR_DKWHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED);
|
||||
|
||||
Loc::GetString(Loc::AIM_HISTORY, L"Line", AIM_COPYRIGHT_2, sSlogan, 400);
|
||||
DrawTextToScreen(sSlogan, AIM_COPYRIGHT_X, AIM_COPYRIGHT_Y + AIM_COPYRIGHT_GAP, AIM_COPYRIGHT_WIDTH, AIM_COPYRIGHT_FONT, FONT_MCOLOR_DKWHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED);
|
||||
|
||||
Loc::GetString(Loc::AIM_HISTORY, L"Line", AIM_COPYRIGHT_3, sSlogan, 400);
|
||||
DrawTextToScreen(sSlogan, AIM_COPYRIGHT_X, AIM_COPYRIGHT_Y + AIM_COPYRIGHT_GAP*2, AIM_COPYRIGHT_WIDTH, AIM_COPYRIGHT_FONT, FONT_MCOLOR_DKWHITE, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED);
|
||||
}
|
||||
return(TRUE);
|
||||
}
|
||||
|
||||
@@ -847,25 +891,30 @@ BOOLEAN DisplayFlowerAd( BOOLEAN fInit, BOOLEAN fRedraw )
|
||||
|
||||
BOOLEAN DrawWarningBox( BOOLEAN fInit, BOOLEAN fRedraw )
|
||||
{
|
||||
static UINT32 uiLastTime;
|
||||
static UINT8 ubSubImage=0;
|
||||
UINT32 uiCurTime = GetJA2Clock();
|
||||
static UINT32 uiLastTime;
|
||||
static UINT8 ubSubImage = 0;
|
||||
UINT32 uiCurTime = GetJA2Clock();
|
||||
|
||||
|
||||
if( fInit || fRedraw)
|
||||
{
|
||||
CHAR16 sText[400];
|
||||
UINT32 uiStartLoc=0;
|
||||
CHAR16 sText[400];
|
||||
//UINT16 usLocY = AIM_WARNING_TEXT_Y + (GetFontHeight(AIM_WARNING_FONT) + 2) * 2;
|
||||
HVOBJECT hWarningHandle;
|
||||
HVOBJECT hWarningHandle;
|
||||
|
||||
//Warning
|
||||
GetVideoObject(&hWarningHandle, guiWarning);
|
||||
BltVideoObject(FRAME_BUFFER, hWarningHandle, 0,WARNING_X, WARNING_Y, VO_BLT_SRCTRANSPARENCY,NULL);
|
||||
|
||||
|
||||
uiStartLoc = AIM_HISTORY_LINE_SIZE * AIM_WARNING_1;
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sText, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
if(!g_bUseXML_Strings)
|
||||
{
|
||||
UINT32 uiStartLoc = AIM_HISTORY_LINE_SIZE * AIM_WARNING_1;
|
||||
LoadEncryptedDataFromFile(AIMHISTORYFILE, sText, uiStartLoc, AIM_HISTORY_LINE_SIZE);
|
||||
}
|
||||
else
|
||||
{
|
||||
Loc::GetString(Loc::AIM_HISTORY, L"Line", AIM_WARNING_1, sText, 400);
|
||||
}
|
||||
|
||||
//Display Aim Warning Text
|
||||
DisplayWrappedString(AIM_WARNING_TEXT_X, AIM_WARNING_TEXT_Y, AIM_WARNING_TEXT_WIDTH, 2, AIM_WARNING_FONT, FONT_RED, sText, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED);
|
||||
|
||||
+34
-3
@@ -2,7 +2,7 @@
|
||||
#define __AIM_H
|
||||
|
||||
#include "Cursors.h"
|
||||
|
||||
#include "Soldier Profile.h"
|
||||
|
||||
//
|
||||
// AIM defines
|
||||
@@ -12,8 +12,32 @@
|
||||
#define AIMHISTORYFILE "BINARYDATA\\AimHist.edt"
|
||||
#define AIM_HISTORY_LINE_SIZE 400 * 2
|
||||
|
||||
#define MAX_NUMBER_MERCS 40
|
||||
extern UINT8 AimMercArray[ MAX_NUMBER_MERCS ];
|
||||
//#define MAX_NUMBER_MERCS 40
|
||||
|
||||
extern UINT8 MAX_NUMBER_MERCS;
|
||||
|
||||
extern UINT8 AimMercArray[ NUM_PROFILES ];//MAX_NUMBER_MERCS ];
|
||||
|
||||
typedef struct
|
||||
{
|
||||
UINT8 ubAimArrayID;
|
||||
UINT8 uiIndex;
|
||||
UINT8 ProfilId;
|
||||
UINT8 AimBio;
|
||||
|
||||
} AIM_AVAILABLE;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
UINT8 ubAimArrayID;
|
||||
UINT8 uiIndex;
|
||||
UINT8 ProfilId;
|
||||
UINT8 AimBio;
|
||||
|
||||
} AIM_AVAILABLE_TEMP;
|
||||
|
||||
extern AIM_AVAILABLE_TEMP gAimAvailabilityTemp[ NUM_PROFILES ];
|
||||
extern AIM_AVAILABLE gAimAvailability[ NUM_PROFILES ];
|
||||
|
||||
#define NUM_AIM_SCREENS 6
|
||||
|
||||
@@ -34,6 +58,13 @@ extern UINT8 AimMercArray[ MAX_NUMBER_MERCS ];
|
||||
#define AIM_SYMBOL_WIDTH 203
|
||||
#define AIM_SYMBOL_HEIGHT 51
|
||||
|
||||
//tais: small logo for nsgi
|
||||
#define AIM_SYMBOL_SMALL_X IMAGE_OFFSET_X + 3
|
||||
#define AIM_SYMBOL_SMALL_Y IMAGE_OFFSET_Y + 3
|
||||
#define AIM_SYMBOL_SMALL_WIDTH 102
|
||||
#define AIM_SYMBOL_SMALL_HEIGHT 26
|
||||
|
||||
|
||||
// RustBackGround
|
||||
#define RUSTBACKGROUND_SIZE_X 125
|
||||
#define RUSTBACKGROUND_SIZE_Y 100
|
||||
|
||||
+342
-174
@@ -22,6 +22,8 @@
|
||||
#include "LaptopSave.h"
|
||||
#include "finances.h"
|
||||
#include "PostalService.h"
|
||||
#include "faces.h"
|
||||
#include "GameSettings.h"
|
||||
#include <string>
|
||||
#endif
|
||||
using namespace std;
|
||||
@@ -693,6 +695,26 @@ void AddEmailWithSpecialData(INT32 iMessageOffset, INT32 iMessageLength, UINT8 u
|
||||
return;
|
||||
}
|
||||
|
||||
void AddEmailWFMercLevelUp(INT32 iMessageOffset, INT32 iMessageLength, UINT8 ubSender, INT32 iDate, INT32 iCurrentIMPPosition)
|
||||
{
|
||||
CHAR16 pSubject[320];
|
||||
|
||||
UINT8 subjectLine = (170 - iMessageLength) * 2;
|
||||
wcscpy( pSubject, New113AIMMercMailTexts[subjectLine] );
|
||||
|
||||
AddEmailMessage(iMessageOffset,iMessageLength, pSubject, iDate, ubSender, FALSE, 0, 0, iCurrentIMPPosition );
|
||||
|
||||
// if we are in fact int he laptop, redraw icons, might be change in mail status
|
||||
|
||||
if( fCurrentlyInLaptop == TRUE )
|
||||
{
|
||||
// redraw icons, might be new mail
|
||||
DrawLapTopIcons();
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
void AddEmail(INT32 iMessageOffset, INT32 iMessageLength, UINT8 ubSender, INT32 iDate, INT32 iCurrentIMPPosition)
|
||||
{
|
||||
CHAR16 pSubject[320];
|
||||
@@ -700,7 +722,6 @@ void AddEmail(INT32 iMessageOffset, INT32 iMessageLength, UINT8 ubSender, INT32
|
||||
//MessagePtr pMessage;
|
||||
//CHAR16 pMessageString[320];
|
||||
|
||||
|
||||
// WANNE: Short work in both ways
|
||||
LoadEncryptedDataFromFile("BINARYDATA\\Email.edt", pSubject, 640*(iMessageOffset), 640);
|
||||
|
||||
@@ -711,8 +732,8 @@ void AddEmail(INT32 iMessageOffset, INT32 iMessageLength, UINT8 ubSender, INT32
|
||||
|
||||
if( fCurrentlyInLaptop == TRUE )
|
||||
{
|
||||
// redraw icons, might be new mail
|
||||
DrawLapTopIcons();
|
||||
// redraw icons, might be new mail
|
||||
DrawLapTopIcons();
|
||||
}
|
||||
|
||||
return;
|
||||
@@ -784,10 +805,23 @@ void AddEmailMessage(INT32 iMessageOffset, INT32 iMessageLength,STR16 pSubject,
|
||||
//}
|
||||
//pTempEmail->pText[iCounter]=NULL;
|
||||
|
||||
/*
|
||||
// WANNE: Not needed anymore, bug is fixed!!
|
||||
// WANNE: Fix the memory heap problem -> CTD (fix by BirdFlu)
|
||||
// The text for the wildfire merc is too long (> 128 characters)!!
|
||||
// copy subject
|
||||
int _len = wcslen(pSubject);
|
||||
pTempEmail->pSubject = (STR16) MemAlloc( (_len + 1) * sizeof(CHAR16) );
|
||||
memset( pTempEmail->pSubject, 0, sizeof( CHAR16 ) * (_len + 1) );
|
||||
wcsncpy(pTempEmail->pSubject,pSubject,_len);
|
||||
pTempEmail->pSubject[_len] = 0;
|
||||
*/
|
||||
|
||||
// copy subject
|
||||
pTempEmail->pSubject = (STR16) MemAlloc( 128 * sizeof(CHAR16) );
|
||||
memset( pTempEmail->pSubject, 0, sizeof( CHAR16 ) * 128 );
|
||||
wcscpy(pTempEmail->pSubject,pSubject);
|
||||
|
||||
|
||||
// copy offset and length of the actual message in email.edt
|
||||
pTempEmail->usOffset =(UINT16)iMessageOffset;
|
||||
@@ -3414,10 +3448,10 @@ void HandleIMPCharProfileResultsMessage( void)
|
||||
}
|
||||
|
||||
// personality itself
|
||||
switch( gMercProfiles[ iCurrentIMPSlot ].bPersonalityTrait)
|
||||
switch( gMercProfiles[ iCurrentIMPSlot ].bDisability)
|
||||
{
|
||||
// normal as can be
|
||||
case( NO_PERSONALITYTRAIT ):
|
||||
case( NO_DISABILITY ):
|
||||
iOffSet = IMP_PERSONALITY_NORMAL;
|
||||
break;
|
||||
case( HEAT_INTOLERANT ):
|
||||
@@ -3456,7 +3490,7 @@ void HandleIMPCharProfileResultsMessage( void)
|
||||
AddEmailRecordToList( pString );
|
||||
|
||||
// extra paragraph for bugs
|
||||
if( gMercProfiles[ iCurrentIMPSlot ].bPersonalityTrait == FEAR_OF_INSECTS )
|
||||
if( gMercProfiles[ iCurrentIMPSlot ].bDisability == FEAR_OF_INSECTS )
|
||||
{
|
||||
// persoanlity paragraph
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( iOffSet + IMP_PERSONALITY_LENGTH + 1 ), MAIL_STRING_SIZE );
|
||||
@@ -3830,163 +3864,235 @@ void HandleIMPCharProfileResultsMessage( void)
|
||||
iCounter++;
|
||||
}
|
||||
|
||||
if( ( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait == KNIFING )||( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait2 == KNIFING ) )
|
||||
{
|
||||
// read one record from email file
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_KNIFE ), MAIL_STRING_SIZE );
|
||||
|
||||
// add to list
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
|
||||
// lockpick
|
||||
if( ( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait == LOCKPICKING)||( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait2 == LOCKPICKING) )
|
||||
{
|
||||
// read one record from email file
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_LOCK ), MAIL_STRING_SIZE );
|
||||
|
||||
// add to list
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
|
||||
// hand to hand
|
||||
if( ( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait == HANDTOHAND )||( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait2 == HANDTOHAND ) )
|
||||
{
|
||||
// read one record from email file
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_HAND ), MAIL_STRING_SIZE );
|
||||
|
||||
// add to list
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
|
||||
// electronics
|
||||
if( ( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait == ELECTRONICS )||( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait2 == ELECTRONICS ) )
|
||||
{
|
||||
// read one record from email file
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_ELEC ), MAIL_STRING_SIZE );
|
||||
|
||||
// add to list
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
|
||||
if( ( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait == NIGHTOPS )||( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait2 == NIGHTOPS ) )
|
||||
{
|
||||
// read one record from email file
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_NIGHT ), MAIL_STRING_SIZE );
|
||||
|
||||
// add to list
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
|
||||
if( ( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait == THROWING)||( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait2 == THROWING) )
|
||||
{
|
||||
// read one record from email file
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_THROW ), MAIL_STRING_SIZE );
|
||||
|
||||
// add to list
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
|
||||
if( ( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait == TEACHING )||( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait2 == TEACHING ) )
|
||||
{
|
||||
// read one record from email file
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_TEACH ), MAIL_STRING_SIZE );
|
||||
|
||||
// add to list
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
|
||||
if( ( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait == HEAVY_WEAPS )||( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait2 == HEAVY_WEAPS ) )
|
||||
{
|
||||
// read one record from email file
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_HEAVY ), MAIL_STRING_SIZE );
|
||||
|
||||
// add to list
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
|
||||
if( ( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait == AUTO_WEAPS )||( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait2 == AUTO_WEAPS ) )
|
||||
{
|
||||
// read one record from email file
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_AUTO ), MAIL_STRING_SIZE );
|
||||
|
||||
// add to list
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
|
||||
if( ( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait == STEALTHY )||( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait2 == STEALTHY ) )
|
||||
{
|
||||
// read one record from email file
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_STEALTH ), MAIL_STRING_SIZE );
|
||||
|
||||
// add to list
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
|
||||
if( ( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait == AMBIDEXT)||( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait2 == AMBIDEXT) )
|
||||
{
|
||||
// read one record from email file
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_AMBI ), MAIL_STRING_SIZE );
|
||||
|
||||
// add to list
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
|
||||
if( ( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait == THIEF )||( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait2 == THIEF ) )
|
||||
{
|
||||
// read one record from email file
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_THIEF ), MAIL_STRING_SIZE );
|
||||
|
||||
// add to list
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
|
||||
if( ( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait == MARTIALARTS )||( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait2 == MARTIALARTS ) )
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
// SANDRO - switch for old/new traits
|
||||
if ( gGameOptions.fNewTraitSystem )
|
||||
{
|
||||
// read one record from email file
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_MARTIAL ), MAIL_STRING_SIZE );
|
||||
|
||||
// add to list
|
||||
AddEmailRecordToList( pString );
|
||||
// Auto Weapons
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, AUTO_WEAPONS_NT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_AUTO ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Heavy Weapons
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, HEAVY_WEAPONS_NT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_HEAVY ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Sniper
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, SNIPER_NT ) > 0 )
|
||||
{
|
||||
wcscpy(pString, MissingIMPSkillsDescriptions[0]);
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Ranger
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, RANGER_NT ) > 0 )
|
||||
{
|
||||
if ( gGameExternalOptions.fShowCamouflageFaces == TRUE )
|
||||
{
|
||||
gCamoFace[iCurrentIMPSlot].gCamoface = TRUE;
|
||||
gCamoFace[iCurrentIMPSlot].gUrbanCamoface = FALSE;
|
||||
gCamoFace[iCurrentIMPSlot].gDesertCamoface = FALSE;
|
||||
gCamoFace[iCurrentIMPSlot].gSnowCamoface = FALSE;
|
||||
}
|
||||
wcscpy(pString, MissingIMPSkillsDescriptions[2]);
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Gunslinger
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, GUNSLINGER_NT ) > 0 )
|
||||
{
|
||||
wcscpy(pString, MissingIMPSkillsDescriptions[3]);
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Martial Artist
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, MARTIAL_ARTS_NT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_MARTIAL ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Squadleader
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, SQUADLEADER_NT ) > 0 )
|
||||
{
|
||||
wcscpy(pString, MissingIMPSkillsDescriptions[4]);
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Technician
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, TECHNICIAN_NT ) > 0 )
|
||||
{
|
||||
wcscpy(pString, MissingIMPSkillsDescriptions[5]);
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Doctor
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, DOCTOR_NT ) > 0 )
|
||||
{
|
||||
wcscpy(pString, MissingIMPSkillsDescriptions[6]);
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Ambidextrous
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, AMBIDEXTROUS_NT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_AMBI ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Melee
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, MELEE_NT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_KNIFE ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Throwing
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, THROWING_NT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_THROW ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Night Ops
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, NIGHT_OPS_NT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_NIGHT ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Stealthy
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, STEALTHY_NT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_STEALTH ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Athletics
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, ATHLETICS_NT ) > 0 )
|
||||
{
|
||||
wcscpy(pString, MissingIMPSkillsDescriptions[7]);
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Bodybuilding
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, BODYBUILDING_NT ) > 0 )
|
||||
{
|
||||
wcscpy(pString, MissingIMPSkillsDescriptions[8]);
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Demolitions
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, DEMOLITIONS_NT ) > 0 )
|
||||
{
|
||||
wcscpy(pString, MissingIMPSkillsDescriptions[9]);
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Teaching
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, TEACHING_NT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_TEACH ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Scouting
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, SCOUTING_NT ) > 0 )
|
||||
{
|
||||
wcscpy(pString, MissingIMPSkillsDescriptions[10]);
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// Lockpick
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, LOCKPICKING_OT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_LOCK ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Hand to Hand
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, HANDTOHAND_OT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_HAND ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Electronics
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, ELECTRONICS_OT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_ELEC ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Night Ops
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, NIGHTOPS_OT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_NIGHT ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Throwing
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, THROWING_OT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_THROW ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Teaching
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, TEACHING_OT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_TEACH ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Heavy Weapons
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, HEAVY_WEAPS_OT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_HEAVY ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Auto Weapons
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, AUTO_WEAPS_OT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_AUTO ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Stealthy
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, STEALTHY_OT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_STEALTH ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Ambidextrous
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, AMBIDEXT_OT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_AMBI ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Thief
|
||||
/*if( ( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait == THIEF_OT )||( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait2 == THIEF_OT ) )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_THIEF ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}*/
|
||||
// Martial Arts
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, MARTIALARTS_OT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_MARTIAL ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Knifing
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, KNIFING_OT ) > 0 )
|
||||
{
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_KNIFE ), MAIL_STRING_SIZE );
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Sniper
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, PROF_SNIPER_OT ) > 0 )
|
||||
{
|
||||
wcscpy(pString, MissingIMPSkillsDescriptions[0]);
|
||||
// add to list
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
// Camouflage
|
||||
if ( ProfileHasSkillTrait( iCurrentIMPSlot, CAMOUFLAGED_OT ) > 0 )
|
||||
{
|
||||
if ( gGameExternalOptions.fShowCamouflageFaces == TRUE )
|
||||
{
|
||||
gCamoFace[iCurrentIMPSlot].gCamoface = TRUE;
|
||||
gCamoFace[iCurrentIMPSlot].gUrbanCamoface = FALSE;
|
||||
gCamoFace[iCurrentIMPSlot].gDesertCamoface = FALSE;
|
||||
gCamoFace[iCurrentIMPSlot].gSnowCamoface = FALSE;
|
||||
}
|
||||
wcscpy(pString, MissingIMPSkillsDescriptions[1]);
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
}
|
||||
|
||||
// rooftop
|
||||
if( ( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait == PROF_SNIPER )||( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait2 == PROF_SNIPER ) )
|
||||
{
|
||||
// WANNE: No entry in the Impass.edt for rooftop, so add any static text here
|
||||
// read one record from email file
|
||||
//LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_ONROOF ), MAIL_STRING_SIZE );
|
||||
|
||||
wcscpy(pString, MissingIMPSkillsDescriptions[0]);
|
||||
|
||||
//#ifdef GERMAN
|
||||
// wcscpy(pString, L"Dach-Treffer Bonus: <Noch keine Beschreibung vorhanden>");
|
||||
//#else
|
||||
//wcscpy(pString, L"Sniper: <No description yet>");
|
||||
//#endif
|
||||
|
||||
// add to list
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
|
||||
// camouflage
|
||||
if( ( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait == CAMOUFLAGED )||( gMercProfiles[ iCurrentIMPSlot ].bSkillTrait2 == CAMOUFLAGED ) )
|
||||
{
|
||||
// WANNE: No entry in the Impass.edt for camouflage, so add any static text here
|
||||
// read one record from email file
|
||||
//LoadEncryptedDataFromFile( "BINARYDATA\\Impass.edt", pString, MAIL_STRING_SIZE * ( IMP_SKILLS_SPECIAL_CAMOUFLAGED ), MAIL_STRING_SIZE );
|
||||
|
||||
wcscpy(pString, MissingIMPSkillsDescriptions[1]);
|
||||
|
||||
/*#ifdef GERMAN
|
||||
wcscpy(pString, L"Getarnt: <Noch keine Beschreibung vorhanden>");
|
||||
#else
|
||||
wcscpy(pString, L"Camouflage: <No description yet>");
|
||||
#endif*/
|
||||
|
||||
// add to list
|
||||
AddEmailRecordToList( pString );
|
||||
}
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
// now the physical
|
||||
// imperial physical
|
||||
@@ -4770,6 +4876,7 @@ void ShutDownEmailList()
|
||||
ClearPages();
|
||||
}
|
||||
|
||||
// Pre Process the mail, when clicking on a mail in the mail list
|
||||
void PreProcessEmail( EmailPtr pMail )
|
||||
{
|
||||
RecordPtr pTempRecord, pCurrentRecord, pLastRecord , pTempList;
|
||||
@@ -4791,21 +4898,31 @@ void PreProcessEmail( EmailPtr pMail )
|
||||
|
||||
// WANNE: Get the text and replace name!
|
||||
int iNew113MERCMerc = 0;
|
||||
int iNew113AIMMerc = 0;
|
||||
|
||||
if (pMail->usLength == MERC_UP_LEVEL_GASTON || pMail->usLength == MERC_UP_LEVEL_STOGIE ||
|
||||
pMail->usLength == MERC_UP_LEVEL_TEX || pMail->usLength == MERC_UP_LEVEL_BIGGENS)
|
||||
{
|
||||
iNew113MERCMerc = pMail->usLength;
|
||||
pMail->usLength = 2;
|
||||
}
|
||||
else if (pMail->usLength >= 170 && pMail->usLength <= 177)
|
||||
{
|
||||
iNew113AIMMerc = pMail->usLength;
|
||||
pMail->usLength = 2;
|
||||
}
|
||||
|
||||
// list doesn't exist, reload
|
||||
if( !pTempRecord )
|
||||
{
|
||||
while(pMail->usLength > iCounter)
|
||||
while(pMail->usLength > iCounter)
|
||||
{
|
||||
// read one record from email file
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Email.edt", pString, MAIL_STRING_SIZE * ( iOffSet + iCounter ), MAIL_STRING_SIZE );
|
||||
// read one record from email file
|
||||
LoadEncryptedDataFromFile( "BINARYDATA\\Email.edt", pString, MAIL_STRING_SIZE * ( iOffSet + iCounter ), MAIL_STRING_SIZE );
|
||||
|
||||
// ----------------
|
||||
// New MERC Merc
|
||||
// ----------------
|
||||
// WANNE: We have a new 1.13 MERC merc (Text, Gaston, Stogie or Biggens)
|
||||
if (iNew113MERCMerc != 0)
|
||||
{
|
||||
@@ -4815,8 +4932,7 @@ void PreProcessEmail( EmailPtr pMail )
|
||||
wcscpy(pString, L"\0");
|
||||
if (iNew113MERCMerc == MERC_UP_LEVEL_GASTON)
|
||||
{
|
||||
wcscpy( pString, New113MERCMercMailTexts[0] );
|
||||
|
||||
wcscpy( pString, New113MERCMercMailTexts[0] );
|
||||
}
|
||||
else if (iNew113MERCMerc == MERC_UP_LEVEL_STOGIE)
|
||||
{
|
||||
@@ -4832,21 +4948,73 @@ void PreProcessEmail( EmailPtr pMail )
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// ----------------
|
||||
// New AIM Merc
|
||||
// ----------------
|
||||
// WANNE: We have a new 1.13 MERC merc (Text, Gaston, Stogie or Biggens)
|
||||
if (iNew113AIMMerc != 0)
|
||||
{
|
||||
wcscpy(pString, L"\0");
|
||||
|
||||
// Only output the mail text, not the subject, cause we already have the subject as text
|
||||
if (iCounter == 1)
|
||||
{
|
||||
if (iNew113AIMMerc == 170)
|
||||
{
|
||||
wcscpy( pString, New113AIMMercMailTexts[1] );
|
||||
}
|
||||
else if (iNew113MERCMerc == 171)
|
||||
{
|
||||
wcscpy( pString, New113AIMMercMailTexts[3] );
|
||||
}
|
||||
else if (iNew113MERCMerc == 172)
|
||||
{
|
||||
wcscpy( pString, New113AIMMercMailTexts[5] );
|
||||
}
|
||||
else if (iNew113MERCMerc == 173)
|
||||
{
|
||||
wcscpy( pString, New113AIMMercMailTexts[7] );
|
||||
}
|
||||
else if (iNew113MERCMerc == 174)
|
||||
{
|
||||
wcscpy( pString, New113AIMMercMailTexts[9] );
|
||||
}
|
||||
else if (iNew113MERCMerc == 175)
|
||||
{
|
||||
wcscpy( pString, New113AIMMercMailTexts[11] );
|
||||
}
|
||||
else if (iNew113MERCMerc == 176)
|
||||
{
|
||||
wcscpy( pString, New113AIMMercMailTexts[13] );
|
||||
}
|
||||
else if (iNew113MERCMerc == 177)
|
||||
{
|
||||
wcscpy( pString, New113AIMMercMailTexts[15] );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// add to list
|
||||
AddEmailRecordToList( pString );
|
||||
|
||||
// increment email record counter
|
||||
iCounter++;
|
||||
}
|
||||
// increment email record counter
|
||||
iCounter++;
|
||||
}
|
||||
|
||||
// WANNE: Set the value back
|
||||
if (iNew113MERCMerc != 0)
|
||||
{
|
||||
pMail->usLength = iNew113MERCMerc;
|
||||
}
|
||||
// WANNE: Set the value back
|
||||
if (iNew113MERCMerc != 0)
|
||||
{
|
||||
pMail->usLength = iNew113MERCMerc;
|
||||
}
|
||||
|
||||
giPrevMessageId = giMessageId;
|
||||
// WANNE: Set the value back
|
||||
if (iNew113AIMMerc != 0)
|
||||
{
|
||||
pMail->usLength = iNew113AIMMerc;
|
||||
}
|
||||
|
||||
giPrevMessageId = giMessageId;
|
||||
|
||||
}
|
||||
|
||||
|
||||
+5
-1
@@ -144,12 +144,12 @@
|
||||
//#define MERC_UP_LEVEL_BIGGENS (MERC_UP_LEVEL_TEX + MERC_UP_LEVEL_TEX_LENGTH)
|
||||
//#define MERC_UP_LEVEL_BIGGENS_LENGTH 2
|
||||
|
||||
|
||||
#define MERC_UP_LEVEL_GASTON 165
|
||||
#define MERC_UP_LEVEL_STOGIE 166
|
||||
#define MERC_UP_LEVEL_TEX 167
|
||||
#define MERC_UP_LEVEL_BIGGENS 168
|
||||
|
||||
|
||||
struct message{
|
||||
STR16 pString;
|
||||
struct message *Next;
|
||||
@@ -299,6 +299,10 @@ void RemoveEmailMessage(INT32 iId);
|
||||
EmailPtr GetEmailMessage(INT32 iId);
|
||||
void LookForUnread();
|
||||
void AddEmail(INT32 iMessageOffset, INT32 iMessageLength, UINT8 ubSender, INT32 iDate, INT32 iCurrentIMPPosition);
|
||||
|
||||
// WANNE: For the new WF merc
|
||||
void AddEmailWFMercLevelUp(INT32 iMessageOffset, INT32 iMessageLength, UINT8 ubSender, INT32 iDate, INT32 iCurrentIMPPosition);
|
||||
|
||||
void AddPreReadEmail(INT32 iMessageOffset, INT32 iMessageLength, UINT8 ubSender, INT32 iDate);
|
||||
BOOLEAN DisplayNewMailBox();
|
||||
void CreateDestroyNewMailButton();
|
||||
|
||||
+57
-28
@@ -409,7 +409,7 @@ INT32 GetProjectedTotalDailyIncome( void )
|
||||
// HEADROCK HAM 3.6: Facilities can make you money, and this is figured into your daily income.
|
||||
|
||||
INT32 iRate = 0;
|
||||
iRate = PredictIncomeFromPlayerMines() + (15 * GetTotalFacilityHourlyCosts( TRUE )); // 15 hours is the average time a merc can work per day
|
||||
iRate = PredictIncomeFromPlayerMines(TRUE) + (15 * GetTotalFacilityHourlyCosts( TRUE )); // 15 hours is the average time a merc can work per day
|
||||
|
||||
return( iRate );
|
||||
}
|
||||
@@ -1167,21 +1167,23 @@ void OpenAndReadFinancesFile( void )
|
||||
// file exists, read in data, continue until file end
|
||||
while( FileGetSize( hFileHandle ) > uiByteCount)
|
||||
{
|
||||
|
||||
// read in other data
|
||||
FileRead( hFileHandle, &ubCode, sizeof(UINT8), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &ubCode, sizeof(UINT8), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &ubSecondCode, sizeof(UINT8), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &uiDate, sizeof(UINT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iAmount, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iBalanceToDate, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iAmount, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iBalanceToDate, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
|
||||
AssertMsg( iBytesRead, "Failed To Read Data Entry");
|
||||
|
||||
// WANNE: Fix uiDate (add 1 day!)!
|
||||
uiDate += 1500;
|
||||
|
||||
// add transaction
|
||||
ProcessAndEnterAFinacialRecord(ubCode, uiDate, iAmount, ubSecondCode, iBalanceToDate);
|
||||
ProcessAndEnterAFinacialRecord(ubCode, uiDate, iAmount, ubSecondCode, iBalanceToDate);
|
||||
|
||||
// increment byte counter
|
||||
uiByteCount += sizeof( INT32 ) + sizeof( UINT32 ) + sizeof( UINT8 )+ sizeof(UINT8) + sizeof( INT32 );
|
||||
uiByteCount += sizeof( INT32 ) + sizeof( UINT32 ) + sizeof( UINT8 )+ sizeof(UINT8) + sizeof( INT32 );
|
||||
}
|
||||
|
||||
// close file
|
||||
@@ -1906,19 +1908,23 @@ BOOLEAN LoadInRecords( UINT32 uiPage )
|
||||
{
|
||||
|
||||
// read in data
|
||||
FileRead( hFileHandle, &ubCode, sizeof(UINT8), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &ubCode, sizeof(UINT8), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &ubSecondCode, sizeof(UINT8), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &uiDate, sizeof(UINT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iAmount, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iBalanceToDate, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iAmount, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iBalanceToDate, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
|
||||
AssertMsg( iBytesRead, "Failed To Read Data Entry");
|
||||
|
||||
// WANNE: Do not add the fix + 1 day here, because otherwise we have a day + 1 offset
|
||||
// WANNE: Fix uiDate (add 1 day!)!
|
||||
//uiDate += 1500;
|
||||
|
||||
// add transaction
|
||||
ProcessAndEnterAFinacialRecord(ubCode, uiDate, iAmount, ubSecondCode, iBalanceToDate);
|
||||
ProcessAndEnterAFinacialRecord(ubCode, uiDate, iAmount, ubSecondCode, iBalanceToDate);
|
||||
|
||||
// increment byte counter
|
||||
uiByteCount += sizeof( INT32 ) + sizeof( UINT32 ) + sizeof( UINT8 )+ sizeof(UINT8) + sizeof( INT32 );
|
||||
uiByteCount += sizeof( INT32 ) + sizeof( UINT32 ) + sizeof( UINT8 )+ sizeof(UINT8) + sizeof( INT32 );
|
||||
|
||||
// we've overextended our welcome, and bypassed end of file, get out
|
||||
if( uiByteCount >= FileGetSize( hFileHandle ) )
|
||||
@@ -2127,8 +2133,11 @@ INT32 GetPreviousDaysBalance( void )
|
||||
FileRead( hFileHandle, &ubCode, sizeof(UINT8), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &ubSecondCode, sizeof(UINT8), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &uiDate, sizeof(UINT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iAmount, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iBalanceToDate, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iAmount, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iBalanceToDate, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
|
||||
// WANNE: Fix uiDate (add 1 day!)!
|
||||
uiDate += 1500;
|
||||
|
||||
// check to see if we are far enough
|
||||
if( ( uiDate / ( 24 * 60 ) ) == ( iDateInMinutes / ( 24 * 60 ) ) - 2 )
|
||||
@@ -2221,10 +2230,14 @@ INT32 GetTodaysBalance( void )
|
||||
FileRead( hFileHandle, &ubCode, sizeof(UINT8), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &ubSecondCode, sizeof(UINT8), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &uiDate, sizeof(UINT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iAmount, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iBalanceToDate, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iAmount, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iBalanceToDate, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
|
||||
AssertMsg( iBytesRead, "Failed To Read Data Entry");
|
||||
|
||||
// WANNE: Fix uiDate (add 1 day!)!
|
||||
uiDate += 1500;
|
||||
|
||||
// check to see if we are far enough
|
||||
if( ( uiDate / ( 24 * 60 ) ) == ( iDateInMinutes / ( 24 * 60 ) ) - 1 )
|
||||
{
|
||||
@@ -2301,15 +2314,19 @@ INT32 GetPreviousDaysIncome( void )
|
||||
// incrment byte count
|
||||
iByteCount += RECORD_SIZE;
|
||||
|
||||
FileGetPos( hFileHandle );
|
||||
FileGetPos( hFileHandle );
|
||||
|
||||
FileRead( hFileHandle, &ubCode, sizeof(UINT8), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &ubSecondCode, sizeof(UINT8), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &uiDate, sizeof(UINT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iAmount, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iBalanceToDate, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iAmount, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iBalanceToDate, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
|
||||
AssertMsg( iBytesRead, "Failed To Read Data Entry");
|
||||
|
||||
// WANNE: Fix uiDate (add 1 day!)!
|
||||
uiDate += 1500;
|
||||
|
||||
// check to see if we are far enough
|
||||
if( ( uiDate / ( 24 * 60 ) )== ( iDateInMinutes / ( 24 * 60 ) ) - 2 )
|
||||
{
|
||||
@@ -2318,7 +2335,7 @@ INT32 GetPreviousDaysIncome( void )
|
||||
|
||||
// there are no entries for the previous day
|
||||
if( ( uiDate / ( 24 * 60 ) ) < ( iDateInMinutes / ( 24 * 60 ) ) - 2 )
|
||||
{
|
||||
{
|
||||
fGoneTooFar = TRUE;
|
||||
|
||||
}
|
||||
@@ -2402,10 +2419,14 @@ INT32 GetTodaysDaysIncome( void )
|
||||
FileRead( hFileHandle, &ubCode, sizeof(UINT8), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &ubSecondCode, sizeof(UINT8), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &uiDate, sizeof(UINT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iAmount, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iBalanceToDate, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iAmount, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iBalanceToDate, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
|
||||
AssertMsg( iBytesRead, "Failed To Read Data Entry");
|
||||
|
||||
// WANNE: Fix uiDate (add 1 day!)!
|
||||
uiDate += 1500;
|
||||
|
||||
// check to see if we are far enough
|
||||
if( ( uiDate / ( 24 * 60 ) ) == ( iDateInMinutes / ( 24 * 60 ) ) - 1 )
|
||||
{
|
||||
@@ -2527,16 +2548,20 @@ INT32 GetTodaysOtherDeposits( void )
|
||||
{
|
||||
FileSeek( hFileHandle, RECORD_SIZE * iCounter , FILE_SEEK_FROM_END );
|
||||
|
||||
// incrment byte count
|
||||
iByteCount += RECORD_SIZE;
|
||||
// incrment byte count
|
||||
iByteCount += RECORD_SIZE;
|
||||
|
||||
FileRead( hFileHandle, &ubCode, sizeof(UINT8), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &ubSecondCode, sizeof(UINT8), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &uiDate, sizeof(UINT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iAmount, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iBalanceToDate, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iAmount, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iBalanceToDate, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
|
||||
AssertMsg( iBytesRead, "Failed To Read Data Entry");
|
||||
|
||||
// WANNE: Fix uiDate (add 1 day!)!
|
||||
uiDate += 1500;
|
||||
|
||||
// check to see if we are far enough
|
||||
if( ( uiDate / ( 24 * 60 ) ) == ( iDateInMinutes / ( 24 * 60 ) ) - 1 )
|
||||
{
|
||||
@@ -2629,10 +2654,14 @@ INT32 GetYesterdaysOtherDeposits( void )
|
||||
FileRead( hFileHandle, &ubCode, sizeof(UINT8), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &ubSecondCode, sizeof(UINT8), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &uiDate, sizeof(UINT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iAmount, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iBalanceToDate, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iAmount, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
FileRead( hFileHandle, &iBalanceToDate, sizeof(INT32), (UINT32 *)&iBytesRead );
|
||||
|
||||
AssertMsg( iBytesRead, "Failed To Read Data Entry");
|
||||
|
||||
// WANNE: Fix uiDate (add 1 day!)!
|
||||
uiDate += 1500;
|
||||
|
||||
// check to see if we are far enough
|
||||
if( ( uiDate / ( 24 * 60 ) )== ( iDateInMinutes / ( 24 * 60 ) ) - 2 )
|
||||
{
|
||||
|
||||
@@ -53,6 +53,7 @@ enum
|
||||
SOLD_ITEMS,
|
||||
FACILITY_OPERATIONS, // HEADROCK HAM 3.6: Facility costs (daily payment)
|
||||
MILITIA_UPKEEP, // HEADROCK HAM 3.6: Militia Upkeep Costs (daily payment)
|
||||
TEXT_NUM_FINCANCES
|
||||
};
|
||||
|
||||
|
||||
|
||||
@@ -103,6 +103,7 @@ enum{
|
||||
HISTORY_GAVE_CARMEN_HEAD,
|
||||
HISTORY_SLAY_MYSTERIOUSLY_LEFT,
|
||||
HISTORY_MERC_KILLED_CHARACTER,
|
||||
TEXT_NUM_HISTORY
|
||||
};
|
||||
|
||||
typedef struct history HistoryUnit;
|
||||
|
||||
@@ -194,6 +194,7 @@ enum{
|
||||
FLORIST_BOOKMARK,
|
||||
INSURANCE_BOOKMARK,
|
||||
CANCEL_STRING,
|
||||
TEXT_NUM_LAPTOP_BOOKMARKS
|
||||
};
|
||||
|
||||
|
||||
|
||||
@@ -189,9 +189,14 @@ INT32 GetNumberOfHiredMercs()
|
||||
|
||||
for (i = 0; i<=(NUMBER_OF_MERCS - 1); i++)
|
||||
{
|
||||
if( i == MERC_LARRY_ROACHBURN )
|
||||
// WANNE: If we have drunken merc, then skip otherwise is will exist 2 times!
|
||||
if (gConditionsForMercAvailability[ i ].Drunk)
|
||||
continue;
|
||||
|
||||
// WANNE.LARRY
|
||||
/*if( i == MERC_LARRY_ROACHBURN )
|
||||
continue;*/
|
||||
|
||||
usMercID = GetMercIDFromMERCArray( i );
|
||||
|
||||
// Is the merc hired?
|
||||
@@ -489,6 +494,7 @@ void DisplayHiredMercs()
|
||||
usMercIDEnd = usMercIDStart + MAX_NUMBER_MERCS_ON_PAGE;
|
||||
}
|
||||
|
||||
// WANNE.LARRY: I don't understand why this is needed??? I did not change anything on this yet.
|
||||
// At least second page
|
||||
// This approach is needed, because auf LARRY_ROACHBURN
|
||||
if (usMercIDStart > 0)
|
||||
@@ -503,10 +509,15 @@ void DisplayHiredMercs()
|
||||
if (usCurrentRow == usMercIDEnd - 1)
|
||||
break;
|
||||
|
||||
//if it larry Roach burn advance. ( cause larry is in twice, a sober larry and a stoned larry )
|
||||
if( i == MERC_LARRY_ROACHBURN )
|
||||
// WANNE: If we have drunken merc, then skip otherwise is will exist 2 times!
|
||||
if (gConditionsForMercAvailability[ i ].Drunk)
|
||||
continue;
|
||||
|
||||
// WANNE.LARRY
|
||||
//if it larry Roach burn advance. ( cause larry is in twice, a sober larry and a stoned larry )
|
||||
/*if( i == MERC_LARRY_ROACHBURN )
|
||||
continue;*/
|
||||
|
||||
usMercID = GetMercIDFromMERCArray( i );
|
||||
|
||||
//is the merc on the team, or is owed money
|
||||
@@ -741,9 +752,14 @@ UINT32 CalculateHowMuchPlayerOwesSpeck()
|
||||
|
||||
for(i=0; i<(NUMBER_OF_MERCS - 1); i++)
|
||||
{
|
||||
//if it larry Roach burn advance. ( cause larry is in twice, a sober larry and a stoned larry )
|
||||
if( i == MERC_LARRY_ROACHBURN )
|
||||
// WANNE: If we have drunken merc, then skip otherwise is will exist 2 times!
|
||||
if (gConditionsForMercAvailability[ i ].Drunk)
|
||||
continue;
|
||||
|
||||
// WANNE.LARRY
|
||||
//if it larry Roach burn advance. ( cause larry is in twice, a sober larry and a stoned larry )
|
||||
//if( i == MERC_LARRY_ROACHBURN )
|
||||
// continue;
|
||||
|
||||
usMercID = GetMercIDFromMERCArray( i );
|
||||
//if( IsMercOnTeam( (UINT8)usMercID ) )
|
||||
|
||||
Binary file not shown.
+156
-92
@@ -29,8 +29,9 @@
|
||||
|
||||
#include "connect.h"
|
||||
|
||||
UINT8 NUMBER_OF_MERCS;
|
||||
UINT8 LAST_MERC_ID;
|
||||
UINT8 NUMBER_OF_MERCS = 0;
|
||||
UINT8 LAST_MERC_ID = -1;
|
||||
UINT8 NUMBER_OF_BAD_MERCS = -1;
|
||||
|
||||
#define MERC_TEXT_FONT FONT12ARIAL
|
||||
#define MERC_TEXT_COLOR FONT_MCOLOR_WHITE
|
||||
@@ -117,30 +118,9 @@ UINT8 LAST_MERC_ID;
|
||||
#define MERC__AMOUNT_OF_MONEY_FOR_BUBBA 6000
|
||||
#define MERC__DAY_WHEN_BUBBA_CAN_BECOME_AVAILABLE 10
|
||||
|
||||
|
||||
enum
|
||||
{
|
||||
MERC_ARRIVES_BUBBA,
|
||||
MERC_ARRIVES_LARRY,
|
||||
MERC_ARRIVES_NUMB,
|
||||
MERC_ARRIVES_TEX,
|
||||
MERC_ARRIVES_BIGGENS,
|
||||
MERC_ARRIVES_COUGAR,
|
||||
MERC_ARRIVES_GASTON,
|
||||
MERC_ARRIVES_STOGIE,
|
||||
|
||||
NUM_MERC_ARRIVALS,
|
||||
};
|
||||
|
||||
typedef struct
|
||||
{
|
||||
UINT16 usMoneyPaid;
|
||||
UINT16 usDay;
|
||||
UINT8 ubMercArrayID;
|
||||
|
||||
} CONTITION_FOR_MERC_AVAILABLE;
|
||||
|
||||
CONTITION_FOR_MERC_AVAILABLE gConditionsForMercAvailability[ NUM_MERC_ARRIVALS ] =
|
||||
CONTITION_FOR_MERC_AVAILABLE_TEMP gConditionsForMercAvailabilityTemp[ NUM_PROFILES ];
|
||||
CONTITION_FOR_MERC_AVAILABLE gConditionsForMercAvailability[ NUM_PROFILES ]; //NUM_MERC_ARRIVALS ]; //=
|
||||
/*
|
||||
{
|
||||
5000, 8, 6, //BUBBA
|
||||
10000, 15, 7, //Larry
|
||||
@@ -152,7 +132,7 @@ CONTITION_FOR_MERC_AVAILABLE gConditionsForMercAvailability[ NUM_MERC_ARRIVALS ]
|
||||
26000, 31, 14, //Stogie
|
||||
|
||||
};
|
||||
|
||||
*/
|
||||
|
||||
enum
|
||||
{
|
||||
@@ -183,7 +163,7 @@ UINT32 guiMercBackGround;
|
||||
UINT32 guiMercVideoFaceBackground;
|
||||
UINT32 guiMercVideoPopupBackground;
|
||||
|
||||
UINT8 gubMercArray[ MAX_NUMBER_OF_MERCS ];
|
||||
UINT8 gubMercArray[ NUM_PROFILES ]; //MAX_NUMBER_OF_MERCS
|
||||
UINT8 gubCurMercIndex;
|
||||
|
||||
INT32 iMercPopUpBox = -1;
|
||||
@@ -281,6 +261,8 @@ MOUSE_REGION gMercSiteSubTitleMouseRegion;
|
||||
void MercSiteSubTitleRegionCallBack(MOUSE_REGION * pRegion, INT32 iReason );
|
||||
|
||||
|
||||
BOOLEAN LoadNewMercsFromLoadGameFile( HWFILE hFile );
|
||||
BOOLEAN SaveNewMercsToSaveGameFile( HWFILE hFile );
|
||||
|
||||
|
||||
//*******************************
|
||||
@@ -324,47 +306,57 @@ BOOLEAN CanMercBeAvailableYet( UINT8 ubMercToCheck );
|
||||
UINT32 CalcMercDaysServed();
|
||||
//ppp
|
||||
|
||||
BOOLEAN SaveNewMercsToSaveGameFile( HWFILE hFile )
|
||||
{
|
||||
UINT32 uiNumBytesWritten;
|
||||
|
||||
FileWrite( hFile, &gConditionsForMercAvailability, sizeof( gConditionsForMercAvailability), &uiNumBytesWritten );
|
||||
if( uiNumBytesWritten != sizeof( gConditionsForMercAvailability ) )
|
||||
{
|
||||
return( FALSE );
|
||||
}
|
||||
|
||||
return( TRUE );
|
||||
}
|
||||
|
||||
BOOLEAN LoadNewMercsFromLoadGameFile( HWFILE hFile )
|
||||
{
|
||||
UINT32 uiNumBytesRead;
|
||||
|
||||
FileRead( hFile, &gConditionsForMercAvailability, sizeof( gConditionsForMercAvailability ), &uiNumBytesRead );
|
||||
if( uiNumBytesRead != sizeof( gConditionsForMercAvailability ) )
|
||||
{
|
||||
return( FALSE );
|
||||
}
|
||||
|
||||
return( TRUE );
|
||||
}
|
||||
|
||||
|
||||
void GameInitMercs()
|
||||
{
|
||||
// for(i=0; i<NUMBER_OF_MERCS; i++)
|
||||
// gubMercArray[ i ] = i+BIFF;
|
||||
|
||||
// WANNE - MP: Initialize the the variables for single player
|
||||
NUMBER_OF_MERCS = 15;
|
||||
LAST_MERC_ID = 14;
|
||||
|
||||
//can now be out of order
|
||||
gubMercArray[ 0 ] = BIFF;
|
||||
gubMercArray[ 1 ] = HAYWIRE;
|
||||
gubMercArray[ 2 ] = GASKET;
|
||||
gubMercArray[ 3 ] = RAZOR;
|
||||
gubMercArray[ 4 ] = FLO;
|
||||
gubMercArray[ 5 ] = GUMPY;
|
||||
gubMercArray[ 6 ] = BUBBA;
|
||||
gubMercArray[ 7 ] = LARRY_NORMAL; //if changing this values, change in GetMercIDFromMERCArray()
|
||||
gubMercArray[ 8 ] = LARRY_DRUNK; //if changing this values, change in GetMercIDFromMERCArray()
|
||||
gubMercArray[ 9 ] = NUMB;
|
||||
gubMercArray[ 10 ] = TEX;
|
||||
gubMercArray[ 11 ] = BIGGENS;
|
||||
gubMercArray[ 12 ] = COUGAR;
|
||||
gubMercArray[ 13 ] = GASTON;
|
||||
gubMercArray[ 14 ] = STOGIE;
|
||||
gubMercArray[ 15 ] = 57;//hayden
|
||||
gubMercArray[ 16 ] = 58;
|
||||
gubMercArray[ 17 ] = 59;
|
||||
gubMercArray[ 18 ] = 60;
|
||||
gubMercArray[ 19 ] = 61;
|
||||
gubMercArray[ 20 ] = 63;
|
||||
gubMercArray[ 21 ] = 66;
|
||||
gubMercArray[ 22 ] = 67;
|
||||
gubMercArray[ 23 ] = 68;
|
||||
gubMercArray[ 24 ] = 69;
|
||||
gubMercArray[ 25 ] = 70;
|
||||
gubMercArray[ 26 ] = 72;
|
||||
gubMercArray[ 27 ] = 64;
|
||||
UINT8 i;
|
||||
|
||||
NUMBER_OF_MERCS = 0;
|
||||
LAST_MERC_ID = -1;
|
||||
NUMBER_OF_BAD_MERCS = -1;
|
||||
|
||||
for(i=0; i<NUM_PROFILES; i++)
|
||||
{
|
||||
if ( gConditionsForMercAvailability[i].ProfilId != 0 )
|
||||
{
|
||||
NUMBER_OF_MERCS = NUMBER_OF_MERCS + 1;
|
||||
LAST_MERC_ID = LAST_MERC_ID + 1;
|
||||
gubMercArray[ i ] = gConditionsForMercAvailability[i].ProfilId;
|
||||
}
|
||||
}
|
||||
|
||||
for(i=0; i<NUM_PROFILES; i++)
|
||||
{
|
||||
if ( gConditionsForMercAvailability[i].StartMercsAvailable == TRUE && gConditionsForMercAvailability[i].NewMercsAvailable == FALSE )
|
||||
NUMBER_OF_BAD_MERCS = NUMBER_OF_BAD_MERCS + 1;
|
||||
}
|
||||
|
||||
LaptopSaveInfo.gubPlayersMercAccountStatus = MERC_NO_ACCOUNT;
|
||||
gubCurMercIndex = 0;
|
||||
|
||||
@@ -782,10 +774,15 @@ void DailyUpdateOfMercSite( UINT16 usDate)
|
||||
ubMercID = GetMercIDFromMERCArray( (UINT8) i );
|
||||
if( IsMercOnTeam( ubMercID ) )
|
||||
{
|
||||
//if it larry Roach burn advance. ( cause larry is in twice, a sober larry and a stoned larry )
|
||||
if( i == MERC_LARRY_ROACHBURN )
|
||||
// WANNE: If we have drunken merc, then skip otherwise is will exist 2 times!
|
||||
if (gConditionsForMercAvailability[ i ].Drunk)
|
||||
continue;
|
||||
|
||||
//// WANNE.LARRY
|
||||
////if it larry Roach burn advance. ( cause larry is in twice, a sober larry and a stoned larry )
|
||||
//if( i == MERC_LARRY_ROACHBURN )
|
||||
// continue;
|
||||
|
||||
sSoldierID = GetSoldierIDFromMercID( ubMercID );
|
||||
pSoldier = MercPtrs[ sSoldierID ];
|
||||
|
||||
@@ -988,31 +985,33 @@ void DailyUpdateOfMercSite( UINT16 usDate)
|
||||
//Gets the actual merc id from the array
|
||||
UINT8 GetMercIDFromMERCArray(UINT8 ubMercID)
|
||||
{
|
||||
//if it is one of the regular MERCS
|
||||
if( ubMercID <= 6 )
|
||||
{
|
||||
return( gubMercArray[ ubMercID ] );
|
||||
}
|
||||
|
||||
//if it is Larry, determine if it Stoned larry or straight larry
|
||||
else if( ( ubMercID == 7 ) || ( ubMercID == 8 ) )
|
||||
// Is this a drunken merc (e.g Larry) and has an additional drunken profile
|
||||
if( gConditionsForMercAvailability[ ubMercID ].Drunk == TRUE && gConditionsForMercAvailability[ ubMercID ].uiAlternateIndex != 255)
|
||||
{
|
||||
if ( HasLarryRelapsed() )
|
||||
{
|
||||
return( gubMercArray[ 8 ] );
|
||||
// Drunken Larry
|
||||
if (gConditionsForMercAvailability[ ubMercID ].uiIndex <= NUM_PROFILES)
|
||||
{
|
||||
return( gubMercArray[ gConditionsForMercAvailability[ ubMercID ].uiIndex ] );
|
||||
}
|
||||
else
|
||||
{
|
||||
Assert(0);
|
||||
return( TRUE );
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
return( gubMercArray[ 7 ] );
|
||||
// Normal Larry (Normal Profile is one
|
||||
return( gubMercArray[ gConditionsForMercAvailability[ ubMercID ].uiAlternateIndex ] );
|
||||
}
|
||||
}
|
||||
|
||||
//if it is one of the newer mercs
|
||||
else if( ubMercID <= LAST_MERC_ID )
|
||||
// Merc is not drunken
|
||||
else if( ubMercID <= NUM_PROFILES )
|
||||
{
|
||||
return( gubMercArray[ ubMercID ] );
|
||||
}
|
||||
|
||||
//else its an error
|
||||
else
|
||||
{
|
||||
@@ -1071,7 +1070,9 @@ void InitMercVideoFace()
|
||||
BOOLEAN StartSpeckTalking(UINT16 usQuoteNum)
|
||||
{
|
||||
|
||||
if(is_networked)return( FALSE );
|
||||
if(is_networked)
|
||||
return( FALSE );
|
||||
|
||||
if( usQuoteNum == MERC_VIDEO_SPECK_SPEECH_NOT_TALKING || usQuoteNum == MERC_VIDEO_SPECK_HAS_TO_TALK_BUT_QUOTE_NOT_CHOSEN_YET )
|
||||
return( FALSE );
|
||||
|
||||
@@ -2122,7 +2123,7 @@ BOOLEAN IsMercMercAvailable( UINT8 ubMercID )
|
||||
UINT8 cnt;
|
||||
|
||||
//loop through the array of mercs
|
||||
for( cnt=0; cnt<LaptopSaveInfo.gubLastMercIndex; cnt++ )
|
||||
for( cnt=0; cnt<NUM_PROFILES; cnt++ ) //LaptopSaveInfo.gubLastMercIndex; cnt++ )
|
||||
{
|
||||
//if this is the merc
|
||||
if( GetMercIDFromMERCArray( cnt ) == ubMercID )
|
||||
@@ -2475,12 +2476,15 @@ BOOLEAN AreAnyOfTheNewMercsAvailable()
|
||||
if( LaptopSaveInfo.fNewMercsAvailableAtMercSite )
|
||||
return( FALSE );
|
||||
|
||||
for(i=(LARRY_NORMAL-BIFF); i<=LaptopSaveInfo.gubLastMercIndex; i++)
|
||||
//for(i=(LARRY_NORMAL-BIFF); i<=LaptopSaveInfo.gubLastMercIndex; i++)
|
||||
for(i=0; i<=NUM_PROFILES; i++)
|
||||
{
|
||||
ubMercID = GetMercIDFromMERCArray( i );
|
||||
|
||||
if( IsMercMercAvailable( ubMercID ) )
|
||||
return( TRUE );
|
||||
if ( gConditionsForMercAvailability[i].NewMercsAvailable == FALSE && gProfilesMERC[i].ProfilId != 0 )
|
||||
{
|
||||
ubMercID = GetMercIDFromMERCArray( i );
|
||||
if( IsMercMercAvailable( ubMercID ) )
|
||||
return( TRUE );
|
||||
}
|
||||
}
|
||||
|
||||
return( FALSE );
|
||||
@@ -2490,10 +2494,33 @@ void ShouldAnyNewMercMercBecomeAvailable()
|
||||
{
|
||||
BOOLEAN fNewMercAreAvailable = FALSE;
|
||||
|
||||
UINT8 i;
|
||||
BOOLEAN Stop = FALSE;
|
||||
|
||||
//Kaiden: Added this if test to make sure that the "New Mercs Available"
|
||||
// e-mail doesn't show up and no unneccessary checks are made when you
|
||||
// have the ALL_MERCS_AT_MERC set to TRUE in the INI file.
|
||||
if(!gGameExternalOptions.fAllMercsAvailable)
|
||||
{
|
||||
for(i=0; i<NUM_PROFILES; i++)
|
||||
{
|
||||
if ( Stop == FALSE )
|
||||
{
|
||||
if ( gConditionsForMercAvailability[i].ProfilId != 0 && gConditionsForMercAvailability[i].NewMercsAvailable == FALSE && gConditionsForMercAvailability[i].StartMercsAvailable == FALSE )
|
||||
{
|
||||
|
||||
if( CanMercBeAvailableYet( gConditionsForMercAvailability[i].uiIndex ) )
|
||||
{
|
||||
fNewMercAreAvailable = TRUE;
|
||||
Stop = TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* if(!gGameExternalOptions.fAllMercsAvailable)
|
||||
{
|
||||
//for bubba
|
||||
// if( GetMercIDFromMERCArray( LaptopSaveInfo.gubLastMercIndex ) == GUMPY )
|
||||
@@ -2551,20 +2578,20 @@ void ShouldAnyNewMercMercBecomeAvailable()
|
||||
{
|
||||
fNewMercAreAvailable = TRUE;
|
||||
}
|
||||
|
||||
*/
|
||||
//if there is a new merc available
|
||||
if( fNewMercAreAvailable )
|
||||
{
|
||||
//Set up an event to add the merc in x days
|
||||
AddStrategicEvent( EVENT_MERC_SITE_NEW_MERC_AVAILABLE, GetMidnightOfFutureDayInMinutes( 1 ) + 420 + Random( 3 * 60 ), 0 );
|
||||
}
|
||||
}
|
||||
// }
|
||||
}
|
||||
|
||||
BOOLEAN CanMercBeAvailableYet( UINT8 ubMercToCheck )
|
||||
{
|
||||
//if the merc is already available
|
||||
if( gConditionsForMercAvailability[ ubMercToCheck ].ubMercArrayID <= LaptopSaveInfo.gubLastMercIndex )
|
||||
if( gConditionsForMercAvailability[ ubMercToCheck ].ubMercArrayID ) //<= LaptopSaveInfo.gubLastMercIndex )
|
||||
return( FALSE );
|
||||
|
||||
//if the merc is already hired
|
||||
@@ -2584,8 +2611,45 @@ BOOLEAN CanMercBeAvailableYet( UINT8 ubMercToCheck )
|
||||
void NewMercsAvailableAtMercSiteCallBack( )
|
||||
{
|
||||
BOOLEAN fSendEmail=FALSE;
|
||||
|
||||
BOOLEAN Stop = FALSE;
|
||||
UINT8 i;
|
||||
|
||||
for(i=0; i<NUM_PROFILES; i++)
|
||||
{
|
||||
|
||||
if ( Stop == FALSE )
|
||||
{
|
||||
if ( gConditionsForMercAvailability[i].ProfilId != 0 && gConditionsForMercAvailability[i].NewMercsAvailable == FALSE && gConditionsForMercAvailability[i].StartMercsAvailable == FALSE )
|
||||
{
|
||||
gConditionsForMercAvailability[i].NewMercsAvailable = TRUE;
|
||||
|
||||
if( CanMercBeAvailableYet( gConditionsForMercAvailability[i].uiIndex ) )
|
||||
{
|
||||
|
||||
if ( gConditionsForMercAvailability[ gConditionsForMercAvailability[i].uiIndex ].Drunk == TRUE )
|
||||
{
|
||||
LaptopSaveInfo.gubLastMercIndex = gConditionsForMercAvailability[gConditionsForMercAvailability[i].uiAlternateIndex].uiIndex;
|
||||
}
|
||||
else
|
||||
{
|
||||
LaptopSaveInfo.gubLastMercIndex++;
|
||||
}
|
||||
|
||||
// LaptopSaveInfo.gubLastMercIndex++;
|
||||
gConditionsForMercAvailability[gConditionsForMercAvailability[i].uiIndex].NewMercsAvailable = TRUE;
|
||||
LaptopSaveInfo.ubLastMercAvailableId = gConditionsForMercAvailability[i].uiIndex;
|
||||
gConditionsForMercAvailability[i].StartMercsAvailable = TRUE;
|
||||
fSendEmail = TRUE;
|
||||
Stop = TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// if( GetMercIDFromMERCArray( LaptopSaveInfo.gubLastMercIndex ) == BUBBA )
|
||||
{
|
||||
|
||||
/* {
|
||||
if( CanMercBeAvailableYet( MERC_ARRIVES_BUBBA ) )
|
||||
{
|
||||
LaptopSaveInfo.gubLastMercIndex++;
|
||||
@@ -2655,7 +2719,7 @@ void NewMercsAvailableAtMercSiteCallBack( )
|
||||
LaptopSaveInfo.ubLastMercAvailableId = MERC_ARRIVES_STOGIE;
|
||||
fSendEmail = TRUE;
|
||||
}
|
||||
|
||||
*/
|
||||
if( fSendEmail )
|
||||
AddEmail( NEW_MERCS_AT_MERC, NEW_MERCS_AT_MERC_LENGTH, SPECK_FROM_MERC, GetWorldTotalMin(), -1);
|
||||
|
||||
|
||||
+59
-3
@@ -1,6 +1,7 @@
|
||||
#ifndef __MERCS_H
|
||||
#define __MERCS_H
|
||||
|
||||
#include "soldier profile type.h"
|
||||
|
||||
#define MERC_BUTTON_UP_COLOR FONT_MCOLOR_WHITE
|
||||
#define MERC_BUTTON_DOWN_COLOR FONT_MCOLOR_DKWHITE
|
||||
@@ -10,7 +11,10 @@ extern UINT8 LAST_MERC_ID;
|
||||
|
||||
#define MAX_NUMBER_OF_MERCS 28
|
||||
|
||||
#define NUMBER_OF_BAD_MERCS 5
|
||||
//#define NUMBER_OF_BAD_MERCS 5
|
||||
|
||||
extern UINT8 NUMBER_OF_BAD_MERCS;
|
||||
|
||||
#define NUMBER_MERCS_AFTER_FIRST_MERC_ARRIVES 6
|
||||
#define NUMBER_MERCS_AFTER_SECOND_MERC_ARRIVES 8
|
||||
#define NUMBER_MERCS_AFTER_THIRD_MERC_ARRIVES 9
|
||||
@@ -21,11 +25,63 @@ extern UINT8 LAST_MERC_ID;
|
||||
#define MERC_NUM_DAYS_TILL_ACCOUNT_INVALID 12
|
||||
|
||||
|
||||
#define MERC_LARRY_ROACHBURN 7
|
||||
// WANNE.LARRY
|
||||
//#define MERC_LARRY_ROACHBURN 7
|
||||
|
||||
|
||||
#define DAYS_TIL_M_E_R_C_AVAIL 3
|
||||
|
||||
enum
|
||||
{
|
||||
MERC_ARRIVES_BUBBA,
|
||||
MERC_ARRIVES_LARRY,
|
||||
MERC_ARRIVES_NUMB,
|
||||
MERC_ARRIVES_TEX,
|
||||
MERC_ARRIVES_BIGGENS,
|
||||
MERC_ARRIVES_COUGAR,
|
||||
MERC_ARRIVES_GASTON,
|
||||
MERC_ARRIVES_STOGIE,
|
||||
MERC_ARRIVES_NEW = MERC_ARRIVES_STOGIE + 240,
|
||||
|
||||
NUM_MERC_ARRIVALS,
|
||||
};
|
||||
|
||||
typedef struct
|
||||
{
|
||||
UINT16 usMoneyPaid;
|
||||
UINT16 usDay;
|
||||
UINT8 ubMercArrayID;
|
||||
UINT8 uiIndex;
|
||||
UINT8 ProfilId;
|
||||
BOOLEAN NewMercsAvailable;
|
||||
BOOLEAN StartMercsAvailable;
|
||||
UINT8 MercBio;
|
||||
BOOLEAN Drunk;
|
||||
UINT8 uiAlternateIndex;
|
||||
|
||||
} CONTITION_FOR_MERC_AVAILABLE;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
UINT16 usMoneyPaid;
|
||||
UINT16 usDay;
|
||||
UINT8 ubMercArrayID;
|
||||
UINT8 uiIndex;
|
||||
UINT8 ProfilId;
|
||||
BOOLEAN NewMercsAvailable;
|
||||
BOOLEAN StartMercsAvailable;
|
||||
UINT8 MercBio;
|
||||
BOOLEAN Drunk;
|
||||
UINT8 uiAlternateIndex;
|
||||
|
||||
} CONTITION_FOR_MERC_AVAILABLE_TEMP;
|
||||
|
||||
extern CONTITION_FOR_MERC_AVAILABLE gConditionsForMercAvailability[ NUM_PROFILES ]; //NUM_MERC_ARRIVALS ];
|
||||
extern CONTITION_FOR_MERC_AVAILABLE_TEMP gConditionsForMercAvailabilityTemp[ NUM_PROFILES ];
|
||||
|
||||
extern BOOLEAN LoadNewMercsFromLoadGameFile( HWFILE hFile );
|
||||
extern BOOLEAN SaveNewMercsToSaveGameFile( HWFILE hFile );
|
||||
|
||||
//The players account information for the MERC site
|
||||
enum
|
||||
{
|
||||
@@ -82,7 +138,7 @@ extern UINT16 gusMercVideoSpeckSpeech;
|
||||
|
||||
extern UINT8 gubArrivedFromMercSubSite;
|
||||
|
||||
extern UINT8 gubMercArray[ MAX_NUMBER_OF_MERCS ];
|
||||
extern UINT8 gubMercArray[ NUM_PROFILES ]; //MAX_NUMBER_OF_MERCS
|
||||
extern UINT8 gubCurMercIndex;
|
||||
//extern UINT8 gubLastMercIndex;
|
||||
|
||||
|
||||
+2359
-281
File diff suppressed because it is too large
Load Diff
@@ -9,6 +9,49 @@
|
||||
// delay for change in ATM mode
|
||||
#define DELAY_PER_MODE_CHANGE_IN_ATM 2000
|
||||
|
||||
//enums for the pPersonnelScreenStrings[]
|
||||
enum
|
||||
{
|
||||
PRSNL_TXT_HEALTH, // 0 HEALTH OF MERC
|
||||
PRSNL_TXT_AGILITY,
|
||||
PRSNL_TXT_DEXTERITY,
|
||||
PRSNL_TXT_STRENGTH,
|
||||
PRSNL_TXT_LEADERSHIP,
|
||||
PRSNL_TXT_WISDOM, // 5
|
||||
PRSNL_TXT_EXP_LVL, // EXPERIENCE LEVEL
|
||||
PRSNL_TXT_MARKSMANSHIP,
|
||||
PRSNL_TXT_MECHANICAL,
|
||||
PRSNL_TXT_EXPLOSIVES,
|
||||
PRSNL_TXT_MEDICAL, // 10
|
||||
PRSNL_TXT_MED_DEPOSIT, // AMOUNT OF MEDICAL DEPOSIT PUT DOWN ON THE MERC
|
||||
PRSNL_TXT_CURRENT_CONTRACT, // COST OF CURRENT CONTRACT
|
||||
PRSNL_TXT_KILLS, // NUMBER OF KILLS BY MERC
|
||||
PRSNL_TXT_ASSISTS, // NUMBER OF ASSISTS ON KILLS BY MERC
|
||||
PRSNL_TXT_DAILY_COST, // 15 DAILY COST OF MERC
|
||||
PRSNL_TXT_TOTAL_COST, // TOTAL COST OF MERC
|
||||
PRSNL_TXT_CONTRACT, // COST OF CURRENT CONTRACT
|
||||
PRSNL_TXT_TOTAL_SERVICE, // TOTAL SERVICE RENDERED BY MERC
|
||||
PRSNL_TXT_UNPAID_AMOUNT, // AMOUNT LEFT ON MERC MERC TO BE PAID
|
||||
PRSNL_TXT_HIT_PERCENTAGE, // 20 PERCENTAGE OF SHOTS THAT HIT TARGET
|
||||
PRSNL_TXT_BATTLES, // NUMBER OF BATTLES FOUGHT
|
||||
PRSNL_TXT_TIMES_WOUNDED, // NUMBER OF TIMES MERC HAS BEEN WOUNDED
|
||||
PRSNL_TXT_SKILLS,
|
||||
PRSNL_TXT_NOSKILLS,
|
||||
PRSNL_TXT_ACHIEVEMNTS,
|
||||
TEXT_NUM_PRSNL,
|
||||
};
|
||||
|
||||
// departed states
|
||||
enum
|
||||
{
|
||||
DEPARTED_DEAD = 0,
|
||||
DEPARTED_FIRED,
|
||||
DEPARTED_OTHER,
|
||||
DEPARTED_MARRIED,
|
||||
DEPARTED_CONTRACT_EXPIRED,
|
||||
DEPARTED_QUIT,
|
||||
TEXT_NUM_DEPARTED
|
||||
};
|
||||
|
||||
void GameInitPersonnel();
|
||||
void EnterPersonnel();
|
||||
|
||||
+254
-1276
File diff suppressed because it is too large
Load Diff
+2
-1
@@ -52,7 +52,8 @@ enum
|
||||
NIGHT,
|
||||
HELI,
|
||||
DAY_ALT,
|
||||
NIGHT_ALT
|
||||
NIGHT_ALT,
|
||||
UNDERGROUND,
|
||||
};
|
||||
|
||||
|
||||
|
||||
+2
-2
@@ -896,7 +896,7 @@ void BtnChatTogglesCallback( GUI_BUTTON *btn, INT32 reason )
|
||||
{
|
||||
UINT8 ubButton = (UINT8)MSYS_GetBtnUserData( btn, 0 );
|
||||
|
||||
if (ubButton == 1 && PLAYER_BSIDE != 1)
|
||||
if (ubButton == 1 && cGameType != MP_TYPE_TEAMDEATMATCH)
|
||||
return;
|
||||
|
||||
if( reason & MSYS_CALLBACK_REASON_LBUTTON_UP )
|
||||
@@ -1160,7 +1160,7 @@ void EnableDisableChatLogScrollButtonsAndRegions( void )
|
||||
MSYS_EnableRegion( &gChatLogScrollBarRegion );
|
||||
}
|
||||
|
||||
if (PLAYER_BSIDE==1)
|
||||
if (cGameType==MP_TYPE_TEAMDEATMATCH)
|
||||
{
|
||||
// Only enable Allies toggle for team deathmatch
|
||||
EnableButton( guiChatToggles[1] );
|
||||
|
||||
@@ -525,3 +525,39 @@ void CheckForContinue()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#include <vfs/Core/vfs_os_functions.h>
|
||||
#include <vfs/Core/vfs_profile.h>
|
||||
#include <vfs/Core/vfs.h>
|
||||
#include <vfs/Core/vfs_init.h>
|
||||
|
||||
void ja2::mp::InitializeMultiplayerProfile(vfs::Path const& profileRoot)
|
||||
{
|
||||
// does the profile root directory actually exist
|
||||
if(!vfs::OS::checkRealDirectory(profileRoot))
|
||||
{
|
||||
// OK, directory did not exist, probably a new profile
|
||||
SGP_THROW_IFFALSE( vfs::OS::createRealDirectory(profileRoot),
|
||||
_BS(L"Could not create directory : ") << profileRoot << _BS::wget );
|
||||
}
|
||||
|
||||
// create and initialize a new Multiplayer profile
|
||||
std::auto_ptr<vfs::CVirtualProfile> pProf( new vfs::CVirtualProfile("_MULTIPLAYER",profileRoot,true) );
|
||||
|
||||
if(!vfs_init::initWriteProfile(*pProf))
|
||||
{
|
||||
SGP_THROW(_BS(L"Could not initialize client profile") << profileRoot << _BS::wget);
|
||||
}
|
||||
|
||||
vfs::CProfileStack *PS = getVFS()->getProfileStack();
|
||||
|
||||
// remove old Multiplayer profile (if it exists)
|
||||
vfs::CVirtualProfile *pOldProf = PS->getProfile("_MULTIPLAYER");
|
||||
if( pOldProf && (pOldProf == PS->topProfile()) )
|
||||
{
|
||||
SGP_THROW_IFFALSE(PS->popProfile(), L"Could not remove old \"_MULTIPLAYER\" profile");
|
||||
}
|
||||
|
||||
// add new profile
|
||||
PS->pushProfile(pProf.release());
|
||||
}
|
||||
|
||||
+2315
-1247
File diff suppressed because it is too large
Load Diff
+98
-107
@@ -31,10 +31,10 @@
|
||||
#include "saveloadscreen.h"
|
||||
#include "game init.h"
|
||||
|
||||
#include "VFS/vfs.h"
|
||||
#include "VFS/vfs_init.h"
|
||||
#include "VFS/PropertyContainer.h"
|
||||
#include "VFS/os_functions.h"
|
||||
#include <vfs/Core/vfs.h>
|
||||
#include <vfs/Core/vfs_init.h>
|
||||
#include <vfs/Tools/vfs_property_container.h>
|
||||
#include <vfs/Core/vfs_os_functions.h>
|
||||
|
||||
#include "Random.h"
|
||||
|
||||
@@ -51,15 +51,17 @@
|
||||
#define MPJ_LABEL_TEXT_COLOR FONT_MCOLOR_WHITE
|
||||
|
||||
//buttons
|
||||
#define MPJ_BTN_JOIN_X iScreenWidthOffset + 320 + 143
|
||||
#define MPJ_BTN_JOIN_Y iScreenHeightOffset + 435
|
||||
#define MPJ_BTN_HOST_X MPJ_BTN_JOIN_X-180
|
||||
#define MPJ_BTN_HOST_Y iScreenHeightOffset + 435
|
||||
#define MPJ_CANCEL_X iScreenWidthOffset + ((320 - 115) / 2)
|
||||
|
||||
#define MPJ_BTN_HOST_X iScreenWidthOffset + 265
|
||||
#define MPJ_BTN_HOST_Y iScreenHeightOffset + 435
|
||||
|
||||
#define MPJ_BTN_JOIN_X iScreenWidthOffset + 425
|
||||
#define MPJ_BTN_JOIN_Y iScreenHeightOffset + 435
|
||||
|
||||
//textboxes
|
||||
#define MPJ_TXT_HANDLE_X iScreenWidthOffset + 100
|
||||
#define MPJ_TXT_HANDLE_Y iScreenHeightOffset + 60
|
||||
#define MPJ_TXT_HANDLE_Y iScreenHeightOffset + 100
|
||||
#define MPJ_TXT_HANDLE_WIDTH 120
|
||||
#define MPJ_TXT_HANDLE_HEIGHT 17
|
||||
#define MPJ_TXT_IP_X iScreenWidthOffset + 100
|
||||
@@ -73,7 +75,7 @@
|
||||
|
||||
|
||||
//main title
|
||||
#define MPJ_MAIN_TITLE_X 0
|
||||
#define MPJ_MAIN_TITLE_X 0
|
||||
#define MPJ_MAIN_TITLE_Y iScreenHeightOffset + 10
|
||||
#define MPJ_MAIN_TITLE_WIDTH SCREEN_WIDTH
|
||||
|
||||
@@ -91,7 +93,6 @@
|
||||
#define MPJ_LABEL_PORT_WIDTH 80
|
||||
#define MPJ_LABEL_PORT_HEIGHT 17
|
||||
|
||||
|
||||
////////////////////////////////////////////
|
||||
//
|
||||
// Global Variables
|
||||
@@ -127,9 +128,8 @@ CHAR16 gzServerPortField[ 5+1 ] = {0} ;
|
||||
// client sets this when joining
|
||||
extern CHAR16 gzFileTransferDirectory[100];
|
||||
|
||||
#ifdef USE_VFS
|
||||
|
||||
void CUniqueServerId::uniqueRandomString(utf8string& str)
|
||||
void CUniqueServerId::uniqueRandomString(vfs::String& str)
|
||||
{
|
||||
std::vector<wchar_t> _rand(30,0);
|
||||
int pos = 0;
|
||||
@@ -153,25 +153,24 @@ void CUniqueServerId::uniqueRandomString(utf8string& str)
|
||||
str.r_wcs().assign(&_rand[0],29);
|
||||
}
|
||||
|
||||
utf8string const& CUniqueServerId::getServerId(vfs::Path dir, CPropertyContainer* props)
|
||||
vfs::String const& CUniqueServerId::getServerId(vfs::Path dir, vfs::PropertyContainer* props)
|
||||
{
|
||||
if(!props)
|
||||
{
|
||||
return _id;
|
||||
}
|
||||
utf8string key = L"\"" + dir.c_wcs() + L"\"";
|
||||
utf8string id = props->getStringProperty(L"SERVER",key);
|
||||
vfs::String key = L"\"" + dir.c_wcs() + L"\"";
|
||||
vfs::String id = props->getStringProperty(JA2MP_INI_SERVER_SECTION,key);
|
||||
if(id.empty())
|
||||
{
|
||||
uniqueRandomString(id);
|
||||
}
|
||||
_id = id;
|
||||
props->setStringProperty(L"SERVER",key,_id);
|
||||
props->setStringProperty(JA2MP_INI_SERVER_SECTION,key,_id);
|
||||
return _id;
|
||||
}
|
||||
|
||||
CUniqueServerId s_ServerId;
|
||||
#endif
|
||||
|
||||
////////////////////////////////////////////
|
||||
//
|
||||
@@ -217,21 +216,30 @@ void DoneFadeOutForExitMPJScreen( void );
|
||||
void DoneFadeInForExitMPJScreen( void );
|
||||
|
||||
|
||||
void MpIniExists()
|
||||
{
|
||||
if(!getVFS()->fileExists(JA2MP_INI_FILENAME))
|
||||
{
|
||||
SGP_THROW_IFFALSE(getVFS()->createNewFile(JA2MP_INI_FILENAME),L"could not create file : Ja2_mp.ini");
|
||||
vfs::tWritableFile* file = getVFS()->getWriteFile(JA2MP_INI_FILENAME);
|
||||
if(file)
|
||||
{
|
||||
file->openWrite(true);
|
||||
file->close();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
UINT32 MPJoinScreenInit( void )
|
||||
{
|
||||
// WANNE - MP: Read the values from Profiles/UserProfile/ja2_mp.ini
|
||||
#ifndef USE_VFS
|
||||
// read settings from JA2 ini
|
||||
GetPrivateProfileStringW( L"Ja2_mp Settings",L"SERVER_IP", L"127.0.0.1", gzServerIPField, 16, L"..\\Ja2_mp.ini" );
|
||||
GetPrivateProfileStringW( L"Ja2_mp Settings",L"SERVER_PORT", L"60005", gzServerPortField, 6, L"..\\Ja2_mp.ini" );
|
||||
GetPrivateProfileStringW( L"Ja2_mp Settings",L"CLIENT_NAME", L"Player Name", gzPlayerHandleField, 12 , L"..\\Ja2_mp.ini" );
|
||||
#else
|
||||
CPropertyContainer props;
|
||||
props.initFromIniFile( L"Ja2_mp.ini");
|
||||
props.getStringProperty( L"Ja2_mp Settings", L"SERVER_IP", gzServerIPField, 16, "127.0.0.1");
|
||||
props.getStringProperty( L"Ja2_mp Settings", L"SERVER_PORT", gzServerPortField, 6, "60005");
|
||||
props.getStringProperty( L"Ja2_mp Settings", L"CLIENT_NAME", gzPlayerHandleField, 12, L"Player Name");
|
||||
#endif
|
||||
// WANNE - MP: Read the values from Profiles/UserProfile/ja2_mp.ini
|
||||
MpIniExists();
|
||||
vfs::PropertyContainer props;
|
||||
props.initFromIniFile( JA2MP_INI_FILENAME);
|
||||
props.getStringProperty( JA2MP_INI_INITIAL_SECTION, JA2MP_SERVER_IP, gzServerIPField, 16, "127.0.0.1");
|
||||
props.getStringProperty( JA2MP_INI_INITIAL_SECTION, JA2MP_SERVER_PORT, gzServerPortField, 6, "60005");
|
||||
props.getStringProperty( JA2MP_INI_INITIAL_SECTION, JA2MP_CLIENT_NAME, gzPlayerHandleField, 12, L"Player Name");
|
||||
return( 1 );
|
||||
}
|
||||
|
||||
@@ -244,23 +252,17 @@ void SaveJoinSettings(bool ReSaving)
|
||||
Get16BitStringFromField( 2, gzServerPortField, 6 );
|
||||
}
|
||||
|
||||
#ifndef USE_VFS
|
||||
// save settings to JA2_mp.ini
|
||||
WritePrivateProfileStringW( L"Ja2_mp Settings",L"SERVER_IP", gzServerIPField, L"..\\Ja2_mp.ini" );
|
||||
WritePrivateProfileStringW( L"Ja2_mp Settings",L"SERVER_PORT", gzServerPortField, L"..\\Ja2_mp.ini" );
|
||||
WritePrivateProfileStringW( L"Ja2_mp Settings",L"CLIENT_NAME", gzPlayerHandleField , L"..\\Ja2_mp.ini" );
|
||||
#else
|
||||
CPropertyContainer props;
|
||||
props.initFromIniFile("Ja2_mp.ini");
|
||||
MpIniExists();
|
||||
vfs::PropertyContainer props;
|
||||
props.initFromIniFile(JA2MP_INI_FILENAME);
|
||||
|
||||
props.setStringProperty(L"Ja2_mp Settings",L"SERVER_IP", gzServerIPField);
|
||||
props.setStringProperty(L"Ja2_mp Settings",L"SERVER_PORT", gzServerPortField);
|
||||
props.setStringProperty(L"Ja2_mp Settings",L"CLIENT_NAME", gzPlayerHandleField);
|
||||
props.setStringProperty(JA2MP_INI_INITIAL_SECTION,JA2MP_SERVER_IP, gzServerIPField);
|
||||
props.setStringProperty(JA2MP_INI_INITIAL_SECTION,JA2MP_SERVER_PORT, gzServerPortField);
|
||||
props.setStringProperty(JA2MP_INI_INITIAL_SECTION,JA2MP_CLIENT_NAME, gzPlayerHandleField);
|
||||
|
||||
s_ServerId.getServerId(vfs::Path(gzFileTransferDirectory), &props);
|
||||
|
||||
props.writeToIniFile(L"ja2_mp.ini",true);
|
||||
#endif
|
||||
props.writeToIniFile(JA2MP_INI_FILENAME,false);
|
||||
}
|
||||
|
||||
bool ValidateJoinSettings(bool bSkipServerAddress, bool bSkipSyncDir)
|
||||
@@ -326,30 +328,10 @@ bool ValidateJoinSettings(bool bSkipServerAddress, bool bSkipSyncDir)
|
||||
|
||||
if (!bSkipSyncDir)
|
||||
{
|
||||
#ifndef USE_VFS
|
||||
// Create MULTIPLAYER / SERVERS if it dosent exist
|
||||
STRING512 syncDir;
|
||||
STRING512 executableDir;
|
||||
|
||||
GetExecutableDirectory(executableDir);
|
||||
sprintf(syncDir, "%s\\multiplayer", executableDir);
|
||||
|
||||
if (!DirectoryExists(syncDir))
|
||||
if(vfs::OS::createRealDirectory(vfs::Path(L"Multiplayer")))
|
||||
{
|
||||
CreateDirectoryA(syncDir, NULL);
|
||||
vfs::OS::createRealDirectory(vfs::Path(L"Multiplayer/Servers"));
|
||||
}
|
||||
|
||||
sprintf(syncDir, "%s\\multiplayer\\servers", executableDir);
|
||||
if (!DirectoryExists(syncDir))
|
||||
{
|
||||
CreateDirectoryA(syncDir, NULL);
|
||||
}
|
||||
#else
|
||||
if(os::createRealDirectory(vfs::Path(L"Multiplayer")))
|
||||
{
|
||||
os::createRealDirectory(vfs::Path(L"Multiplayer/Servers"));
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
return true;
|
||||
@@ -361,8 +343,6 @@ UINT32 MPJoinScreenHandle( void )
|
||||
|
||||
if( gfMPJScreenEntry )
|
||||
{
|
||||
// PauseGame();
|
||||
|
||||
EnterMPJScreen();
|
||||
gfMPJScreenEntry = FALSE;
|
||||
gfMPJScreenExit = FALSE;
|
||||
@@ -371,7 +351,6 @@ UINT32 MPJoinScreenHandle( void )
|
||||
|
||||
GetMPJScreenUserInput();
|
||||
|
||||
|
||||
HandleMPJScreen();
|
||||
|
||||
// render buttons marked dirty
|
||||
@@ -380,12 +359,7 @@ UINT32 MPJoinScreenHandle( void )
|
||||
|
||||
// render text boxes
|
||||
RenderAllTextFields(); // textbox system call
|
||||
|
||||
// render help
|
||||
// RenderFastHelp( );
|
||||
// RenderButtonsFastHelp( );
|
||||
|
||||
|
||||
|
||||
ExecuteBaseDirtyRectQueue();
|
||||
EndFrameBufferRender();
|
||||
|
||||
@@ -409,17 +383,15 @@ UINT32 MPJoinScreenHandle( void )
|
||||
|
||||
if ( HandleBeginFadeIn( gubMPJExitScreen ) )
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
if( gfMPJScreenExit ) // we are exiting this screen
|
||||
if( gfMPJScreenExit )
|
||||
{
|
||||
ExitMPJScreen(); // perform destruction
|
||||
ExitMPJScreen();
|
||||
}
|
||||
|
||||
return( gubMPJExitScreen );
|
||||
} // end MPJoinScreenHandle()
|
||||
|
||||
}
|
||||
|
||||
UINT32 MPJoinScreenShutdown( void )
|
||||
{
|
||||
@@ -545,9 +517,7 @@ BOOLEAN EnterMPJScreen()
|
||||
gfMPJButtonsAllocated = TRUE;
|
||||
|
||||
return( TRUE );
|
||||
|
||||
} // End of EnterMPJScreen()
|
||||
|
||||
}
|
||||
|
||||
BOOLEAN ExitMPJScreen()
|
||||
{
|
||||
@@ -582,10 +552,9 @@ BOOLEAN ExitMPJScreen()
|
||||
|
||||
return( TRUE );
|
||||
|
||||
} // End of ExitMPJScreen()
|
||||
}
|
||||
|
||||
|
||||
void HandleMPJScreen()
|
||||
void HandleMPJScreen()
|
||||
{
|
||||
if( gubMPJScreenHandler != MPJ_NOTHING )
|
||||
{
|
||||
@@ -617,23 +586,54 @@ void HandleMPJScreen()
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
gubMPJScreenHandler = MPJ_NOTHING;
|
||||
}
|
||||
|
||||
|
||||
if( gfReRenderMPJScreen )
|
||||
{
|
||||
RenderMPJScreen();
|
||||
gfReRenderMPJScreen = FALSE;
|
||||
}
|
||||
}
|
||||
|
||||
// <TODO> add restore backgrounds in...
|
||||
//RestoreGIOButtonBackGrounds();
|
||||
} // end of HandleMPJScreen
|
||||
void DrawHelpText()
|
||||
{
|
||||
int x = MPJ_LABEL_HANDLE_X;
|
||||
int y = iScreenHeightOffset + 60;
|
||||
int width = 640 - (2 * 50);
|
||||
int lineSpacing = 12;
|
||||
|
||||
// Visit IRC
|
||||
DrawTextToScreen( gzMPJHelpText[ 0 ], x, y, width, FONT10ARIAL, MPJ_TITLE_COLOR, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
|
||||
// Host
|
||||
y += 150;
|
||||
|
||||
y+= lineSpacing;
|
||||
DrawTextToScreen( gzMPJHelpText[ 1 ], x, y, width, FONT12ARIAL, MPJ_TITLE_COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED );
|
||||
y+= lineSpacing + 5;
|
||||
DrawTextToScreen( gzMPJHelpText[ 2 ], x, y, width, FONT10ARIAL, MPJ_TITLE_COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED );
|
||||
y+= lineSpacing;
|
||||
DrawTextToScreen( gzMPJHelpText[ 3 ], x, y, width, FONT10ARIAL, MPJ_TITLE_COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED );
|
||||
y+= lineSpacing;
|
||||
DrawTextToScreen( gzMPJHelpText[ 4 ], x, y, width, FONT10ARIAL, MPJ_TITLE_COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED );
|
||||
y+= lineSpacing;
|
||||
DrawTextToScreen( gzMPJHelpText[ 5 ], x, y, width, FONT10ARIAL, MPJ_TITLE_COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED );
|
||||
|
||||
// Join
|
||||
y += 20;
|
||||
|
||||
y += lineSpacing;
|
||||
DrawTextToScreen( gzMPJHelpText[ 6 ], x, y, width, FONT12ARIAL, MPJ_TITLE_COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED );
|
||||
y += lineSpacing + 5;
|
||||
DrawTextToScreen( gzMPJHelpText[ 7 ], x, y, width, FONT10ARIAL, MPJ_TITLE_COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED );
|
||||
y += lineSpacing;
|
||||
DrawTextToScreen( gzMPJHelpText[ 8 ], x, y, width, FONT10ARIAL, MPJ_TITLE_COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED );
|
||||
y += lineSpacing;
|
||||
DrawTextToScreen( gzMPJHelpText[ 9 ], x, y, width, FONT10ARIAL, MPJ_TITLE_COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED );
|
||||
}
|
||||
|
||||
BOOLEAN RenderMPJScreen()
|
||||
{
|
||||
@@ -648,9 +648,11 @@ BOOLEAN RenderMPJScreen()
|
||||
|
||||
//Display the title
|
||||
DrawTextToScreen( gzMPJScreenText[ MPJ_TITLE_TEXT ], MPJ_MAIN_TITLE_X, MPJ_MAIN_TITLE_Y, MPJ_MAIN_TITLE_WIDTH, MPJ_TITLE_FONT, MPJ_TITLE_COLOR, FONT_MCOLOR_BLACK, FALSE, CENTER_JUSTIFIED );
|
||||
|
||||
DrawHelpText();
|
||||
|
||||
// Player name text label
|
||||
DisplayWrappedString( MPJ_LABEL_HANDLE_X, MPJ_LABEL_HANDLE_Y, MPJ_LABEL_HANDLE_WIDTH, 2, MPJ_LABEL_TEXT_FONT, MPJ_LABEL_TEXT_COLOR, gzMPJScreenText[ MPJ_HANDLE_TEXT ], FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED );
|
||||
DisplayWrappedString( MPJ_LABEL_HANDLE_X, MPJ_LABEL_HANDLE_Y, MPJ_LABEL_HANDLE_WIDTH, 2, MPJ_LABEL_TEXT_FONT, MPJ_LABEL_TEXT_COLOR, gzMPJScreenText[ MPJ_HANDLE_TEXT ], FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED );
|
||||
|
||||
// Server IP text label
|
||||
DisplayWrappedString( MPJ_LABEL_IP_X, MPJ_LABEL_IP_Y, MPJ_LABEL_IP_WIDTH, 2, MPJ_LABEL_TEXT_FONT, MPJ_LABEL_TEXT_COLOR, gzMPJScreenText[ MPJ_SERVERIP_TEXT ], FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED );
|
||||
@@ -659,16 +661,11 @@ BOOLEAN RenderMPJScreen()
|
||||
DisplayWrappedString( MPJ_LABEL_PORT_X, MPJ_LABEL_PORT_Y, MPJ_LABEL_PORT_WIDTH, 2, MPJ_LABEL_TEXT_FONT, MPJ_LABEL_TEXT_COLOR, gzMPJScreenText[ MPJ_SERVERPORT_TEXT ], FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED );
|
||||
|
||||
return( TRUE );
|
||||
} // end of RenderMPJScreen()
|
||||
}
|
||||
|
||||
|
||||
|
||||
void GetMPJScreenUserInput()
|
||||
void GetMPJScreenUserInput()
|
||||
{
|
||||
InputAtom Event;
|
||||
// POINT MousePos;
|
||||
|
||||
// GetCursorPos(&MousePos);
|
||||
|
||||
while( DequeueEvent( &Event ) )
|
||||
{
|
||||
@@ -697,11 +694,9 @@ void GetMPJScreenUserInput()
|
||||
}
|
||||
}
|
||||
}
|
||||
} // end of GetMPJScreenUserInput()
|
||||
|
||||
}
|
||||
|
||||
// CALLBACKS
|
||||
|
||||
void BtnMPJoinCallback(GUI_BUTTON *btn,INT32 reason)
|
||||
{
|
||||
if(reason & MSYS_CALLBACK_REASON_LBUTTON_DWN )
|
||||
@@ -768,9 +763,6 @@ BOOLEAN DoMPJMessageBox( UINT8 ubStyle, const STR16 zString, UINT32 uiExitScreen
|
||||
{
|
||||
SGPRect CenteringRect= {0, 0, SCREEN_WIDTH-1, SCREEN_HEIGHT-1 };
|
||||
|
||||
// reset exit mode
|
||||
// gfExitGioDueToMessageBox = TRUE;
|
||||
|
||||
// do message box and return
|
||||
giMPJMessageBox = DoMessageBox( ubStyle, zString, uiExitScreen, ( UINT16 ) ( usFlags| MSG_BOX_FLAG_USE_CENTERING_RECT ), ReturnCallback, &CenteringRect );
|
||||
|
||||
@@ -780,8 +772,7 @@ BOOLEAN DoMPJMessageBox( UINT8 ubStyle, const STR16 zString, UINT32 uiExitScreen
|
||||
|
||||
void DoneFadeOutForExitMPJScreen( void )
|
||||
{
|
||||
// As we bypassed the GIO screen, set up some game options for multiplayer here
|
||||
// <TODO> most things i have left as thier defaults here for testing.
|
||||
// As we bypassed the GIO screen, set up some game options for multiplayer here
|
||||
is_networked = true;
|
||||
is_host = false; // we want to be a client, not we ARE a client yet (is_client)
|
||||
auto_retry = true;
|
||||
|
||||
+10
-10
@@ -1,31 +1,31 @@
|
||||
#ifndef _MP_JOIN_SCREEN_H_
|
||||
#define _MP_JOIN_SCREEN_H_
|
||||
|
||||
#include "VFS/vfs.h"
|
||||
#include <vfs/Core/vfs.h>
|
||||
|
||||
#ifdef USE_VFS
|
||||
|
||||
class CPropertyContainer;
|
||||
namespace vfs{
|
||||
class PropertyContainer;
|
||||
}
|
||||
|
||||
class CUniqueServerId
|
||||
{
|
||||
public:
|
||||
utf8string const& getServerId(vfs::Path dir, CPropertyContainer* props = NULL);
|
||||
vfs::String const& getServerId(vfs::Path dir, vfs::PropertyContainer* props = NULL);
|
||||
|
||||
static void uniqueRandomString(utf8string& str);
|
||||
static void uniqueRandomString(vfs::String& str);
|
||||
private:
|
||||
utf8string _id;
|
||||
vfs::String _id;
|
||||
};
|
||||
|
||||
extern CUniqueServerId s_ServerId;
|
||||
|
||||
#endif
|
||||
|
||||
UINT32 MPJoinScreenInit( void );
|
||||
UINT32 MPJoinScreenHandle( void );
|
||||
UINT32 MPJoinScreenShutdown( void );
|
||||
|
||||
void SaveJoinSettings(bool ReSaving);
|
||||
void SaveJoinSettings(bool ReSaving);
|
||||
|
||||
void MpIniExists();
|
||||
|
||||
|
||||
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user