mirror of
https://github.com/1dot13/source.git
synced 2026-08-05 14:00:23 +02:00
Added functions for utf8 <> wstring conversion.
Added message when AI breaks deadlock because cannot complete action. git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@9262 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -52,6 +52,7 @@
|
||||
#include "Queen Command.h"
|
||||
#include "points.h"
|
||||
#include "Soldier Functions.h" // added by SANDRO
|
||||
#include "Text.h" // sevenfm
|
||||
#endif
|
||||
|
||||
#include "connect.h"
|
||||
@@ -81,9 +82,6 @@ extern BOOLEAN gfWaitingForTriggerTimer;
|
||||
|
||||
UINT8 gubAICounter;
|
||||
|
||||
extern STR16 gStrAction[];
|
||||
extern STR szAction[];
|
||||
|
||||
//
|
||||
// Commented out/ to fix:
|
||||
// lots of other stuff, I think
|
||||
@@ -703,7 +701,7 @@ void HandleSoldierAI( SOLDIERTYPE *pSoldier ) // FIXME - this function is named
|
||||
// ATE: Display message that deadlock occured...
|
||||
LiveMessage( "Breaking Deadlock" );
|
||||
|
||||
//ScreenMsg(FONT_MCOLOR_LTRED, MSG_INTERFACE, L"Aborting AI deadlock for [%d] %s data %d", pSoldier->ubID, gStrAction[pSoldier->aiData.bAction], pSoldier->aiData.usActionData);
|
||||
ScreenMsg(FONT_MCOLOR_LTRED, MSG_INTERFACE, L"Aborting AI deadlock for [%d] %s %s data %d", pSoldier->ubID, pSoldier->GetName(), utf8_to_wstring(std::string(szAction[pSoldier->aiData.bAction])), pSoldier->aiData.usActionData);
|
||||
DebugAI(String("Aborting AI deadlock for [%d] %s data %d", pSoldier->ubID, szAction[pSoldier->aiData.bAction], pSoldier->aiData.usActionData));
|
||||
|
||||
#ifdef JA2TESTVERSION
|
||||
@@ -1906,7 +1904,7 @@ INT8 ExecuteAction(SOLDIERTYPE *pSoldier)
|
||||
{
|
||||
INT32 iRetCode;
|
||||
//NumMessage("ExecuteAction - Guy#",pSoldier->ubID);
|
||||
|
||||
//ScreenMsg(FONT_MCOLOR_LTRED, MSG_INTERFACE, L"Execute action: [%d] %s %s data %d", pSoldier->ubID, pSoldier->GetName(), utf8_to_wstring(std::string(szAction[pSoldier->aiData.bAction])), pSoldier->aiData.usActionData);
|
||||
|
||||
// in most cases, merc will change location, or may cause damage to opponents,
|
||||
// so a new cover check will be necessary. Exceptions handled individually.
|
||||
|
||||
Reference in New Issue
Block a user