Freeciv21
Develop your civilization from humble roots to a global empire
explanation.h
Go to the documentation of this file.
1 /**************************************************************************
2  Copyright (c) 1996-2020 Freeciv21 and Freeciv contributors. This file is
3  __ __ part of Freeciv21. Freeciv21 is free software: you can
4 / \\..// \ redistribute it and/or modify it under the terms of the GNU
5  ( oo ) General Public License as published by the Free Software
6  \__/ Foundation, either version 3 of the License, or (at your
7  option) any later version. You should have received
8  a copy of the GNU General Public License along with Freeciv21. If not,
9  see https://www.gnu.org/licenses/.
10 **************************************************************************/
11 
12 #pragma once
13 
14 // A category of reasons why an action isn't enabled.
15 enum ane_kind {
16  // Explanation: wrong actor unit.
18  // Explanation: no action target.
20  // Explanation: the action is redundant vs this target.
22  // Explanation: bad actor terrain.
24  // Explanation: bad target terrain.
26  // Explanation: being transported.
28  // Explanation: not being transported.
30  // Explanation: transports a cargo unit.
32  // Explanation: doesn't transport a cargo unit.
34  // Explanation: actor unit has a home city.
36  // Explanation: actor unit has no a home city.
38  // Explanation: must declare war first.
40  // Explanation: must break peace first.
42  // Explanation: can't be done to domestic targets.
44  // Explanation: can't be done to foreign targets.
46  // Explanation: this nation can't act.
48  // Explanation: this nation can't be targeted.
50  // Explanation: not enough MP left.
52  // Explanation: can't be done to city centers.
54  // Explanation: can't be done to non city centers.
56  // Explanation: can't be done to claimed target tiles.
58  // Explanation: can't be done to unclaimed target tiles.
60  // Explanation: can't be done because target is too near.
62  // Explanation: can't be done because target is too far away.
64  // Explanation: can't be done to targets that far from the coast line.
66  /* Explanation: can't be done because the actor can't exit its
67  * transport. */
69  // Explanation: actor can't reach unit at target.
71  // Explanation: the action is disabled in this scenario.
73  // Explanation: too close to a city.
75  // Explanation: the target city is too big.
77  // Explanation: the target city's population limit banned the action.
79  // Explanation: the specified city don't have the needed capacity.
81  /* Explanation: the target unit can't switch sides because it is unique
82  * and the actor player already has one. */
84  // Explanation: the target tile is unknown.
86  // Explanation: the actor player can't afford performing this action.
88  // Explanation: the action is blocked by another action.
90  // Explanation not detected.
92 };
ane_kind
Definition: explanation.h:15
@ ANEK_IS_CITY_CENTER
Definition: explanation.h:53
@ ANEK_ACTION_BLOCKS
Definition: explanation.h:89
@ ANEK_DOMESTIC
Definition: explanation.h:43
@ ANEK_LOW_MP
Definition: explanation.h:51
@ ANEK_TGT_TILE_UNKNOWN
Definition: explanation.h:85
@ ANEK_BAD_TERRAIN_TGT
Definition: explanation.h:25
@ ANEK_TRIREME_MOVE
Definition: explanation.h:65
@ ANEK_CITY_TOO_CLOSE_TGT
Definition: explanation.h:74
@ ANEK_CITY_NO_CAPACITY
Definition: explanation.h:80
@ ANEK_NATION_TGT
Definition: explanation.h:49
@ ANEK_BAD_TARGET
Definition: explanation.h:21
@ ANEK_MISSING_TARGET
Definition: explanation.h:19
@ ANEK_TGT_IS_CLAIMED
Definition: explanation.h:57
@ ANEK_FOREIGN
Definition: explanation.h:45
@ ANEK_DISEMBARK_ACT
Definition: explanation.h:68
@ ANEK_IS_TRANSPORTED
Definition: explanation.h:27
@ ANEK_IS_NOT_CITY_CENTER
Definition: explanation.h:55
@ ANEK_TGT_IS_UNCLAIMED
Definition: explanation.h:59
@ ANEK_BAD_TERRAIN_ACT
Definition: explanation.h:23
@ ANEK_SCENARIO_DISABLED
Definition: explanation.h:72
@ ANEK_ACTOR_HAS_HOME_CITY
Definition: explanation.h:35
@ ANEK_PEACE
Definition: explanation.h:41
@ ANEK_DISTANCE_NEAR
Definition: explanation.h:61
@ ANEK_UNKNOWN
Definition: explanation.h:91
@ ANEK_ACT_NOT_ENOUGH_MONEY
Definition: explanation.h:87
@ ANEK_IS_NOT_TRANSPORTING
Definition: explanation.h:33
@ ANEK_TGT_UNREACHABLE
Definition: explanation.h:70
@ ANEK_ACTOR_HAS_NO_HOME_CITY
Definition: explanation.h:37
@ ANEK_CITY_TOO_BIG
Definition: explanation.h:76
@ ANEK_NO_WAR
Definition: explanation.h:39
@ ANEK_DISTANCE_FAR
Definition: explanation.h:63
@ ANEK_ACTOR_UNIT
Definition: explanation.h:17
@ ANEK_NATION_ACT
Definition: explanation.h:47
@ ANEK_IS_NOT_TRANSPORTED
Definition: explanation.h:29
@ ANEK_IS_TRANSPORTING
Definition: explanation.h:31
@ ANEK_CITY_POP_LIMIT
Definition: explanation.h:78
@ ANEK_TGT_IS_UNIQUE_ACT_HAS
Definition: explanation.h:83