summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authoryexo <yexo@openttd.org>2011-11-12 18:48:21 +0000
committeryexo <yexo@openttd.org>2011-11-12 18:48:21 +0000
commit924a5e06b354b573412201e58bc95b39aabf2183 (patch)
tree05754ac894120c2c19e8286adf10808506454501 /src
parente963ff9cf96dc7fdab38ff1868aba1ab79d4fdce (diff)
downloadopenttd-924a5e06b354b573412201e58bc95b39aabf2183.tar.xz
(svn r23201) -Doc: [NoAI] Hide all contents of AIObject from the API documentation as AIs were never able to use it anyway
Diffstat (limited to 'src')
-rw-r--r--src/ai/ai_gui.cpp2
-rw-r--r--src/ai/api/Doxyfile2
-rw-r--r--src/ai/api/ai_bridge.hpp2
-rw-r--r--src/ai/api/ai_event_types.hpp2
-rw-r--r--src/ai/api/ai_info_docs.hpp2
-rw-r--r--src/ai/api/ai_list.hpp4
-rw-r--r--src/ai/api/ai_object.hpp9
-rw-r--r--src/ai/api/ai_order.hpp4
-rw-r--r--src/ai/api/ai_tunnel.hpp4
9 files changed, 13 insertions, 18 deletions
diff --git a/src/ai/ai_gui.cpp b/src/ai/ai_gui.cpp
index 6e51eea1d..96c5bb0ed 100644
--- a/src/ai/ai_gui.cpp
+++ b/src/ai/ai_gui.cpp
@@ -294,7 +294,7 @@ struct AISettingsWindow : public Window {
this->SetWidgetDisabledState(AIS_WIDGET_RESET, _game_mode != GM_MENU && Company::IsValidID(this->slot));
- this->vscroll->SetCount(this->visible_settings.size());
+ this->vscroll->SetCount((int)this->visible_settings.size());
}
/**
diff --git a/src/ai/api/Doxyfile b/src/ai/api/Doxyfile
index ae031b6c8..f830dbd18 100644
--- a/src/ai/api/Doxyfile
+++ b/src/ai/api/Doxyfile
@@ -206,7 +206,7 @@ EXPAND_ONLY_PREDEF = YES
SEARCH_INCLUDES = YES
INCLUDE_PATH =
INCLUDE_FILE_PATTERNS =
-PREDEFINED = DOXYGEN_SKIP
+PREDEFINED = DOXYGEN_AI_DOCS
EXPAND_AS_DEFINED = DEF_COMMAND
SKIP_FUNCTION_MACROS = YES
#---------------------------------------------------------------------------
diff --git a/src/ai/api/ai_bridge.hpp b/src/ai/api/ai_bridge.hpp
index 78f62522e..92204d123 100644
--- a/src/ai/api/ai_bridge.hpp
+++ b/src/ai/api/ai_bridge.hpp
@@ -109,7 +109,7 @@ public:
*/
static int32 GetMinLength(BridgeID bridge_id);
-#ifndef DOXYGEN_SKIP
+#ifndef DOXYGEN_AI_DOCS
/**
* Internal function to help BuildBridge in case of road.
*/
diff --git a/src/ai/api/ai_event_types.hpp b/src/ai/api/ai_event_types.hpp
index 41cbc1965..0bebb53b7 100644
--- a/src/ai/api/ai_event_types.hpp
+++ b/src/ai/api/ai_event_types.hpp
@@ -282,7 +282,7 @@ public:
* Get the type of the offered engine.
* @return The type the engine has.
*/
-#ifdef DOXYGEN_SKIP
+#ifdef DOXYGEN_AI_DOCS
AIVehicle::VehicleType GetVehicleType();
#else
int32 GetVehicleType();
diff --git a/src/ai/api/ai_info_docs.hpp b/src/ai/api/ai_info_docs.hpp
index f821b43f6..74edcfbb4 100644
--- a/src/ai/api/ai_info_docs.hpp
+++ b/src/ai/api/ai_info_docs.hpp
@@ -10,7 +10,7 @@
/** @file ai_info_docs.hpp Description of the functions an AI can/must provide in AIInfo. */
/* This file exists purely for doxygen purposes. */
-#ifdef DOXYGEN_SKIP
+#ifdef DOXYGEN_AI_DOCS
/**
* 'Abstract' class of the class AIs/AI libraries use to register themselves.
*
diff --git a/src/ai/api/ai_list.hpp b/src/ai/api/ai_list.hpp
index ce1c8e04e..05f7aeb4c 100644
--- a/src/ai/api/ai_list.hpp
+++ b/src/ai/api/ai_list.hpp
@@ -239,7 +239,7 @@ public:
*/
void KeepList(AIList *list);
-#ifndef DOXYGEN_SKIP
+#ifndef DOXYGEN_AI_DOCS
/**
* Used for 'foreach()' and [] get from Squirrel.
*/
@@ -280,7 +280,7 @@ public:
* list.Valuate(MyVal, 12);
*/
void Valuate(void *valuator_function, int params, ...);
-#endif /* DOXYGEN_SKIP */
+#endif /* DOXYGEN_AI_DOCS */
};
#endif /* AI_LIST_HPP */
diff --git a/src/ai/api/ai_object.hpp b/src/ai/api/ai_object.hpp
index 9f7d08864..48be653d5 100644
--- a/src/ai/api/ai_object.hpp
+++ b/src/ai/api/ai_object.hpp
@@ -38,6 +38,7 @@ class AIObject : public SimpleCountedObject {
friend void CcAI(const CommandCost &result, TileIndex tile, uint32 p1, uint32 p2);
friend class AIInstance;
friend class AIController;
+#ifndef DOXYGEN_AI_DOCS
protected:
/**
* Executes a raw DoCommand for the AI.
@@ -181,51 +182,45 @@ protected:
public:
/**
* Store the latest result of a DoCommand per company.
- * @note NEVER use this yourself in your AI!
* @param res The result of the last command.
*/
static void SetLastCommandRes(bool res);
/**
* Store a new_vehicle_id per company.
- * @note NEVER use this yourself in your AI!
* @param vehicle_id The new VehicleID.
*/
static void SetNewVehicleID(VehicleID vehicle_id);
/**
* Store a new_sign_id per company.
- * @note NEVER use this yourself in your AI!
* @param sign_id The new SignID.
*/
static void SetNewSignID(SignID sign_id);
/**
* Store a new_tunnel_endtile per company.
- * @note NEVER use this yourself in your AI!
* @param tile The new TileIndex.
*/
static void SetNewTunnelEndtile(TileIndex tile);
/**
* Store a new_group_id per company.
- * @note NEVER use this yourself in your AI!
* @param group_id The new GroupID.
*/
static void SetNewGroupID(GroupID group_id);
/**
* Store a allow_do_command per company.
- * @note NEVER use this yourself in your AI!
* @param allow The new allow.
*/
static void SetAllowDoCommand(bool allow);
/**
* Get the pointer to store log message in.
- * @note NEVER use this yourself in your AI!
*/
static void *&GetLogPointer();
+#endif /* DOXYGEN_AI_DOCS */
};
#endif /* AI_OBJECT_HPP */
diff --git a/src/ai/api/ai_order.hpp b/src/ai/api/ai_order.hpp
index 10e47993a..cc2e0cc73 100644
--- a/src/ai/api/ai_order.hpp
+++ b/src/ai/api/ai_order.hpp
@@ -480,12 +480,12 @@ public:
*/
static bool RemoveOrder(VehicleID vehicle_id, OrderPosition order_position);
-#ifndef DOXYGEN_SKIP
+#ifndef DOXYGEN_AI_DOCS
/**
* Internal function to help SetOrderFlags.
*/
static bool _SetOrderFlags();
-#endif /* DOXYGEN_SKIP */
+#endif /* DOXYGEN_AI_DOCS */
/**
* Changes the order flags of the given order.
diff --git a/src/ai/api/ai_tunnel.hpp b/src/ai/api/ai_tunnel.hpp
index f1d8beae3..b788f4511 100644
--- a/src/ai/api/ai_tunnel.hpp
+++ b/src/ai/api/ai_tunnel.hpp
@@ -65,7 +65,7 @@ public:
*/
static TileIndex GetOtherTunnelEnd(TileIndex tile);
-#ifndef DOXYGEN_SKIP
+#ifndef DOXYGEN_AI_DOCS
/**
* Internal function to help BuildTunnel in case of road.
*/
@@ -75,7 +75,7 @@ public:
* Internal function to help BuildTunnel in case of road.
*/
static bool _BuildTunnelRoad2();
-#endif /* DOXYGEN_SKIP */
+#endif /* DOXYGEN_AI_DOCS */
/**
* Builds a tunnel starting at start. The direction of the tunnel depends