Add AI/game script DoCommand calls to command log

This commit is contained in:
Jonathan G Rennison
2019-04-04 18:44:04 +01:00
parent c3e90b61b7
commit 4bf4862674
3 changed files with 27 additions and 7 deletions

View File

@@ -310,7 +310,7 @@ ScriptObject::ActiveInstance::~ActiveInstance()
tile, TileX(tile), TileY(tile), p1, p2, scope_dumper().CompanyInfo(_current_company), cmd, GetCommandName(cmd), estimate_only);
/* Try to perform the command. */
CommandCost res = ::DoCommandPInternal(tile, p1, p2, cmd, (_networking && !_generating_world) ? ScriptObject::GetActiveInstance()->GetDoCommandCallback() : NULL, text, false, estimate_only, 0);
CommandCost res = ::DoCommandPScript(tile, p1, p2, cmd, (_networking && !_generating_world) ? ScriptObject::GetActiveInstance()->GetDoCommandCallback() : NULL, text, false, estimate_only, 0);
/* We failed; set the error and bail out */
if (res.Failed()) {