From d58ae673f64f0c9176674c3af7a85c38c51a2ca4 Mon Sep 17 00:00:00 2001 From: Marko Lindqvist Date: Wed, 24 Mar 2021 06:24:51 +0200 Subject: [PATCH 33/33] Replace 1 with TRUE in ai_fuzzy() function header It refers to a boolean value. See osdn #41847 Signed-off-by: Marko Lindqvist --- ai/difficulty.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ai/difficulty.c b/ai/difficulty.c index 7a01475bd7..60515e4b0e 100644 --- a/ai/difficulty.c +++ b/ai/difficulty.c @@ -328,12 +328,12 @@ char *ai_level_help(const char *cmdname) if (ai_fuzzy(pplayer, condition)) { action } to sometimes flip a decision, to simulate an AI with some confusion, indecisiveness, forgetfulness etc. In practice its often safer to use - if (condition && ai_fuzzy(pplayer,1)) { action } + if (condition && ai_fuzzy(pplayer, TRUE)) { action } for an action which only makes sense if condition holds, but which a fuzzy AI can safely "forget". Note that for a non-fuzzy AI, or for a human player being helped by the AI (eg, autosettlers), you can ignore the "ai_fuzzy(pplayer," part, and read the previous example as: - if (condition && 1) { action } + if (condition && TRUE) { action } --dwp **************************************************************************/ bool ai_fuzzy(const struct player *pplayer, bool normal_decision) -- 2.30.2