diff options
author | truebrain <truebrain@openttd.org> | 2012-02-15 15:18:38 +0000 |
---|---|---|
committer | truebrain <truebrain@openttd.org> | 2012-02-15 15:18:38 +0000 |
commit | b601b057d40800a894508b8270280d9c790da418 (patch) | |
tree | 72a9f7bf09f3fa75f9b8cf89bb9d0b2b5dae881c | |
parent | 1274a77da0ebf42e54bea4814c7ac3e724b12c00 (diff) | |
download | openttd-b601b057d40800a894508b8270280d9c790da418.tar.xz |
(svn r23950) -Fix (r23731) [FS#5063]: never show GSGoal::Question() to spectators. Accidently INVALID_COMPANY == COMPANY_SPECTATOR
-rw-r--r-- | src/goal.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/goal.cpp b/src/goal.cpp index cc28bce73..59edec787 100644 --- a/src/goal.cpp +++ b/src/goal.cpp @@ -140,7 +140,7 @@ CommandCost CmdGoalQuestion(TileIndex tile, DoCommandFlag flags, uint32 p1, uint if (type >= GOAL_QUESTION_TYPE_COUNT) return CMD_ERROR; if (flags & DC_EXEC) { - if (company == _local_company || (company == INVALID_COMPANY && Company::IsValidID(_local_company))) ShowGoalQuestion(uniqueid, type, p2, text); + if ((company != INVALID_COMPANY && company == _local_company) || (company == INVALID_COMPANY && Company::IsValidID(_local_company))) ShowGoalQuestion(uniqueid, type, p2, text); } return CommandCost(); |