diff options
author | yexo <yexo@openttd.org> | 2009-09-11 17:18:06 +0000 |
---|---|---|
committer | yexo <yexo@openttd.org> | 2009-09-11 17:18:06 +0000 |
commit | 8ef7b80719a4c3837b24157a0c65222011f1898d (patch) | |
tree | e20ff2578364bb2c7b1e403cc74e7e548cbdf8e3 /src/ai/api/ai_controller.cpp | |
parent | c9a25c88fa522fa778c2de827d98cce46700d1f6 (diff) | |
download | openttd-8ef7b80719a4c3837b24157a0c65222011f1898d.tar.xz |
(svn r17500) -Fix (r16502): The wrong value was restored to SetAllowDoCommand possible resulting in an AI that wasn't allowed to do any actions
Diffstat (limited to 'src/ai/api/ai_controller.cpp')
-rw-r--r-- | src/ai/api/ai_controller.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ai/api/ai_controller.cpp b/src/ai/api/ai_controller.cpp index 88e666db4..6852e1142 100644 --- a/src/ai/api/ai_controller.cpp +++ b/src/ai/api/ai_controller.cpp @@ -30,7 +30,7 @@ /* static */ void AIController::Sleep(int ticks) { - if (!AIObject::GetAllowDoCommand()) { + if (!AIObject::CanSuspend()) { throw AI_FatalError("You are not allowed to call Sleep in your constructor, Save(), Load(), and any valuator."); } |