1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-01-02 00:10:22 +02:00

* patch update from Dikamilo

This commit is contained in:
Michał W. Urbańczyk 2009-02-08 16:36:53 +00:00
parent dd36cfce50
commit a113a8d289
7 changed files with 53 additions and 44 deletions

View File

@ -14,7 +14,7 @@ using namespace boost::lambda;
using namespace std; using namespace std;
using namespace GeniusAI; using namespace GeniusAI;
#if defined (_MSC_VER) && (_MSC_VER >= 1020) && (__MINGW32__) #if defined (_MSC_VER) && (_MSC_VER >= 1020) || (__MINGW32__)
#include <windows.h> #include <windows.h>
#endif #endif

View File

@ -81,16 +81,16 @@ private:
}; };
enum EActionType enum EActionType
{ {
action_cancel = 0, // Cancel BattleAction action_cancel = 0, // Cancel BattleAction
action_cast_spell = 1, // Hero cast a spell action_cast_spell = 1, // Hero cast a spell
action_walk = 2, // Walk action_walk = 2, // Walk
action_defend = 3, // Defend action_defend = 3, // Defend
action_retreat = 4, // Retreat from the battle action_retreat = 4, // Retreat from the battle
action_surrender = 5, // Surrender action_surrender = 5, // Surrender
action_walk_and_attack = 6, // Walk and Attack action_walk_and_attack = 6, // Walk and Attack
action_shoot = 7, // Shoot action_shoot = 7, // Shoot
action_wait = 8, // Wait action_wait = 8, // Wait
action_catapult = 9, // Catapult action_catapult = 9, // Catapult
action_monster_casts_spell = 10 // Monster casts a spell (i.e. Faerie Dragons) action_monster_casts_spell = 10 // Monster casts a spell (i.e. Faerie Dragons)
}; };
struct SCreatureCasualties struct SCreatureCasualties
@ -118,10 +118,10 @@ private:
bool m_bIsAttacker; bool m_bIsAttacker;
ICallback *m_cb; ICallback *m_cb;
CCreatureSet *m_army1; CCreatureSet *m_army1;
CCreatureSet *m_army2; CCreatureSet *m_army2;
int3 m_tile; int3 m_tile;
CGHeroInstance *m_hero1; CGHeroInstance *m_hero1;
CGHeroInstance *m_hero2; CGHeroInstance *m_hero2;
bool m_side; bool m_side;
// statistics // statistics
@ -174,7 +174,7 @@ private:
/** /**
* Only for debug purpose. * Only for debug purpose.
*/ */
void CBattleLogic::PrintBattleAction(const BattleAction &action); void PrintBattleAction(const BattleAction &action);
}; };
class CGeniusAI : public CGlobalAI class CGeniusAI : public CGlobalAI

View File

@ -9,9 +9,9 @@
<Build> <Build>
<Target title="Debug Win32"> <Target title="Debug Win32">
<Option platforms="Windows;" /> <Option platforms="Windows;" />
<Option output="..\..\..\..\..\Install\Heroes3\AI\GeniusAI" prefix_auto="1" extension_auto="1" /> <Option output="bin\Debug\GeniusAI" prefix_auto="1" extension_auto="1" />
<Option working_dir="..\..\..\..\..\Install\Heroes3\AI" /> <Option working_dir="bin\Debug\" />
<Option object_output="Debug Win32" /> <Option object_output="obj\Debug\" />
<Option type="3" /> <Option type="3" />
<Option compiler="gcc" /> <Option compiler="gcc" />
<Option createDefFile="1" /> <Option createDefFile="1" />
@ -25,12 +25,15 @@
<Add option="-D_USRDLL" /> <Add option="-D_USRDLL" />
<Add option="-DGENIUS_EXPORTS" /> <Add option="-DGENIUS_EXPORTS" />
</Compiler> </Compiler>
<Linker>
<Add library="..\..\lib\bin\Debug\libVCMI_lib.a" />
</Linker>
</Target> </Target>
<Target title="Release Win32"> <Target title="Release Win32">
<Option platforms="Windows;" /> <Option platforms="Windows;" />
<Option output="..\..\..\..\..\Install\Heroes3\AI\GeniusAI" prefix_auto="1" extension_auto="1" /> <Option output="bin\Release\GeniusAI" prefix_auto="1" extension_auto="1" />
<Option working_dir="..\..\..\..\..\Install\Heroes3\AI" /> <Option working_dir="bin\Release\" />
<Option object_output="Release Win32" /> <Option object_output="obj\Release\" />
<Option type="3" /> <Option type="3" />
<Option compiler="gcc" /> <Option compiler="gcc" />
<Option createDefFile="1" /> <Option createDefFile="1" />
@ -51,6 +54,7 @@
</Compiler> </Compiler>
<Linker> <Linker>
<Add option="-s" /> <Add option="-s" />
<Add library="..\..\lib\bin\Release\libVCMI_lib.a" />
</Linker> </Linker>
</Target> </Target>
</Build> </Build>
@ -59,7 +63,6 @@
<Add directory="$(#boost.include)" /> <Add directory="$(#boost.include)" />
</Compiler> </Compiler>
<Linker> <Linker>
<Add library="..\..\..\..\..\Install\Heroes3\libVCMI_lib.a" />
<Add directory="$(#boost.lib)" /> <Add directory="$(#boost.lib)" />
</Linker> </Linker>
<Unit filename="CGeniusAI.cpp" /> <Unit filename="CGeniusAI.cpp" />

View File

@ -9,9 +9,9 @@
<Build> <Build>
<Target title="Debug Win32"> <Target title="Debug Win32">
<Option platforms="Windows;" /> <Option platforms="Windows;" />
<Option output="..\..\..\..\Install\Heroes3\VCMI_client" prefix_auto="1" extension_auto="1" /> <Option output="bin\Debug\VCMI_client" prefix_auto="1" extension_auto="1" />
<Option working_dir="..\..\..\..\Install\Heroes3" /> <Option working_dir="bin\Debug\" />
<Option object_output="Debug Win32" /> <Option object_output="obj\Debug\" />
<Option type="1" /> <Option type="1" />
<Option compiler="gcc" /> <Option compiler="gcc" />
<Option use_console_runner="0" /> <Option use_console_runner="0" />
@ -19,12 +19,15 @@
<Add option="-g" /> <Add option="-g" />
<Add option="-D_DEBUG" /> <Add option="-D_DEBUG" />
</Compiler> </Compiler>
<Linker>
<Add library="..\..\lib\bin\Debug\libVCMI_lib.a" />
</Linker>
</Target> </Target>
<Target title="Release Win32"> <Target title="Release Win32">
<Option platforms="Windows;" /> <Option platforms="Windows;" />
<Option output="..\..\..\..\Install\Heroes3\VCMI_client" prefix_auto="1" extension_auto="1" /> <Option output="bin\Release\VCMI_client" prefix_auto="1" extension_auto="1" />
<Option working_dir="..\..\..\..\Install\Heroes3" /> <Option working_dir="bin\Release\" />
<Option object_output="Release Win32" /> <Option object_output="obj\Release\" />
<Option type="1" /> <Option type="1" />
<Option compiler="gcc" /> <Option compiler="gcc" />
<Option use_console_runner="0" /> <Option use_console_runner="0" />
@ -38,6 +41,7 @@
</Compiler> </Compiler>
<Linker> <Linker>
<Add option="-s" /> <Add option="-s" />
<Add library="..\..\lib\bin\Release\libVCMI_lib.a" />
</Linker> </Linker>
</Target> </Target>
</Build> </Build>
@ -57,7 +61,6 @@
<Add option="-llibboost_thread-mgw43-mt-1_37" /> <Add option="-llibboost_thread-mgw43-mt-1_37" />
<Add option="-llibboost_system-mgw43-mt-1_37" /> <Add option="-llibboost_system-mgw43-mt-1_37" />
<Add option="-llibboost_filesystem-mgw43-mt-1_37" /> <Add option="-llibboost_filesystem-mgw43-mt-1_37" />
<Add library="..\..\..\..\Install\Heroes3\libVCMI_lib.a" />
<Add directory="$(#sdl.lib)" /> <Add directory="$(#sdl.lib)" />
<Add directory="$(#boost.lib)" /> <Add directory="$(#boost.lib)" />
<Add directory="$(#zlib.lib)" /> <Add directory="$(#zlib.lib)" />

View File

@ -9,9 +9,9 @@
<Build> <Build>
<Target title="Debug Win32"> <Target title="Debug Win32">
<Option platforms="Windows;" /> <Option platforms="Windows;" />
<Option output="..\..\..\..\Install\Heroes3\VCMI_lib" prefix_auto="1" extension_auto="1" /> <Option output="bin\Debug\VCMI_lib" prefix_auto="1" extension_auto="1" />
<Option working_dir="..\..\..\..\Install\Heroes3" /> <Option working_dir="bin\Debug\" />
<Option object_output="Debug Win32" /> <Option object_output="obj\Debug\" />
<Option type="3" /> <Option type="3" />
<Option compiler="gcc" /> <Option compiler="gcc" />
<Option createDefFile="1" /> <Option createDefFile="1" />
@ -23,9 +23,9 @@
</Target> </Target>
<Target title="Release Win32"> <Target title="Release Win32">
<Option platforms="Windows;" /> <Option platforms="Windows;" />
<Option output="..\..\..\..\Install\Heroes3\VCMI_lib" prefix_auto="1" extension_auto="1" /> <Option output="bin\Release\VCMI_lib" prefix_auto="1" extension_auto="1" />
<Option working_dir="..\..\..\..\Install\Heroes3" /> <Option working_dir="bin\Release\" />
<Option object_output="Release Win32" /> <Option object_output="obj\Release\" />
<Option type="3" /> <Option type="3" />
<Option compiler="gcc" /> <Option compiler="gcc" />
<Option createDefFile="1" /> <Option createDefFile="1" />

View File

@ -9,21 +9,24 @@
<Build> <Build>
<Target title="Debug Win32"> <Target title="Debug Win32">
<Option platforms="Windows;" /> <Option platforms="Windows;" />
<Option output="..\..\..\..\Install\Heroes3\VCMI_server" prefix_auto="1" extension_auto="1" /> <Option output="bin\Debug\VCMI_server" prefix_auto="1" extension_auto="1" />
<Option working_dir="..\..\..\..\Install\Heroes3" /> <Option working_dir="bin\Debug\" />
<Option object_output="Debug Win32" /> <Option object_output="obj\Debug\" />
<Option type="1" /> <Option type="1" />
<Option compiler="gcc" /> <Option compiler="gcc" />
<Option use_console_runner="0" /> <Option use_console_runner="0" />
<Compiler> <Compiler>
<Add option="-g" /> <Add option="-g" />
</Compiler> </Compiler>
<Linker>
<Add library="..\..\lib\bin\Debug\libVCMI_lib.a" />
</Linker>
</Target> </Target>
<Target title="Release Win32"> <Target title="Release Win32">
<Option platforms="Windows;" /> <Option platforms="Windows;" />
<Option output="..\..\..\..\Install\Heroes3\VCMI_server" prefix_auto="1" extension_auto="1" /> <Option output="bin\Release\VCMI_server" prefix_auto="1" extension_auto="1" />
<Option working_dir="..\..\..\..\Install\Heroes3" /> <Option working_dir="bin\Release\" />
<Option object_output="Release Win32" /> <Option object_output="obj\Release\" />
<Option type="1" /> <Option type="1" />
<Option compiler="gcc" /> <Option compiler="gcc" />
<Option use_console_runner="0" /> <Option use_console_runner="0" />
@ -37,6 +40,7 @@
</Compiler> </Compiler>
<Linker> <Linker>
<Add option="-s" /> <Add option="-s" />
<Add library="..\..\lib\bin\Release\libVCMI_lib.a" />
</Linker> </Linker>
</Target> </Target>
</Build> </Build>
@ -51,7 +55,6 @@
<Add option="-llibboost_filesystem-mgw43-mt-1_37" /> <Add option="-llibboost_filesystem-mgw43-mt-1_37" />
<Add option="-lwsock32" /> <Add option="-lwsock32" />
<Add option="-lws2_32" /> <Add option="-lws2_32" />
<Add library="..\..\..\..\Install\Heroes3\libVCMI_lib.a" />
<Add directory="$(#zlib.lib)" /> <Add directory="$(#zlib.lib)" />
<Add directory="$(#boost.lib)" /> <Add directory="$(#boost.lib)" />
</Linker> </Linker>

View File

@ -1,9 +1,9 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<CodeBlocks_workspace_file> <CodeBlocks_workspace_file>
<Workspace title="VCMI"> <Workspace title="VCMI">
<Project filename="client\VCMI_client.cbp" /> <Project filename="client\VCMI_client.cbp" active="1" />
<Project filename="server\VCMI_server.cbp" /> <Project filename="server\VCMI_server.cbp" />
<Project filename="lib\VCMI_lib.cbp" active="1" /> <Project filename="lib\VCMI_lib.cbp" />
<Project filename="AI\GeniusAI\genius.cbp" /> <Project filename="AI\GeniusAI\genius.cbp" />
</Workspace> </Workspace>
</CodeBlocks_workspace_file> </CodeBlocks_workspace_file>