(svn r12883) [NoAI] -Fix r12880: move two own-defined typedefs to ai_types.hpp too noai
authortruebrain
Thu, 24 Apr 2008 23:53:05 +0000
branchnoai
changeset 10341 08f39ee90bdf
parent 10339 ce6cd68d9eb8
child 10343 0ccd326f082e
(svn r12883) [NoAI] -Fix r12880: move two own-defined typedefs to ai_types.hpp too
src/ai/api/ai_bridge.hpp
src/ai/api/ai_object.hpp
src/ai/api/ai_types.hpp
--- a/src/ai/api/ai_bridge.hpp	Thu Apr 24 23:39:18 2008 +0000
+++ b/src/ai/api/ai_bridge.hpp	Thu Apr 24 23:53:05 2008 +0000
@@ -9,9 +9,6 @@
 #include "ai_vehicle.hpp"
 #include "ai_error.hpp"
 
-/** In OpenTTD Core 'BridgeID' is called 'BridgeType', so map it to make this API more logic. */
-typedef BridgeType BridgeID;
-
 /**
  * Class that handles all bridge related functions.
  */
--- a/src/ai/api/ai_object.hpp	Thu Apr 24 23:39:18 2008 +0000
+++ b/src/ai/api/ai_object.hpp	Thu Apr 24 23:53:05 2008 +0000
@@ -11,11 +11,6 @@
 #include "ai_types.hpp"
 
 /**
- * The type (an alias) for all errors the AI API knows.
- */
-typedef uint AIErrorType;
-
-/**
  * The callback function for Mode-classes.
  */
 typedef bool (AIModeProc)(TileIndex tile, uint32 p1, uint32 p2, uint procc, CommandCost costs);
--- a/src/ai/api/ai_types.hpp	Thu Apr 24 23:39:18 2008 +0000
+++ b/src/ai/api/ai_types.hpp	Thu Apr 24 23:53:05 2008 +0000
@@ -22,6 +22,10 @@
 typedef uint16 TownID;
 typedef uint16 VehicleID;
 
+/* Types we defined ourself, as the OpenTTD core doesn't have them (yet) */
+typedef uint AIErrorType;
+typedef BridgeType BridgeID; //!< Map BridgeType to BridgeID, as we use ID everywhere, OpenTTD core doesn't...
+
 #ifndef _SQUIRREL_H_
 /* Life becomes easier when we can tell about a function it needs the VM, but
  *  without really including 'squirrel.h'. */