mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-01-22 23:26:34 +00:00
(svn r3269) -Fix: return CMD_ERROR instead of -1 if AI_DoCommandChecked fails
This commit is contained in:
parent
bfc8b30325
commit
54cb542e1d
2
ai/ai.c
2
ai/ai.c
@ -137,7 +137,7 @@ int32 AI_DoCommandChecked(uint tile, uint32 p1, uint32 p2, uint32 flags, uint pr
|
||||
|
||||
res = AI_DoCommand(tile, p1, p2, flags & ~DC_EXEC, procc);
|
||||
if (CmdFailed(res))
|
||||
return -1;
|
||||
return CMD_ERROR;
|
||||
|
||||
/* Save the command and his things, together with the unique_id */
|
||||
new = malloc(sizeof(AICommand));
|
||||
|
Loading…
Reference in New Issue
Block a user