SimpleAI
 All Classes Namespaces Files Functions Variables Typedefs Macros Groups Pages
Macros | Typedefs | Functions
Types.h File Reference
#include "Log.h"
#include <string>
#include <unordered_map>
#include <cassert>
#include <cstdio>
Include dependency graph for Types.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define ai_log(...)   ai::Log::info(__VA_ARGS__)
 Logging macro to provide your own loggers.
 
#define ai_log_error(...)   ai::Log::error(__VA_ARGS__)
 Logging macro to provide your own loggers.
 
#define ai_log_warn(...)   ai::Log::warn(__VA_ARGS__)
 Logging macro to provide your own loggers.
 
#define ai_log_debug(...)   ai::Log::debug(__VA_ARGS__)
 Logging macro to provide your own loggers.
 
#define ai_log_trace(...)   ai::Log::trace(__VA_ARGS__)
 Logging macro to provide your own loggers.
 
#define __PRETTY_FUNCTION__   __FUNCSIG__
 
#define ai_assert_always(condition,...)
 Provide your own assert - this is also executed in non DEBUG mode. More...
 
#define ai_assert(condition,...)
 Provide your own assert - this is only executed in DEBUG mode. More...
 
#define AI_STRINGIFY_INTERNAL(x)   #x
 
#define AI_STRINGIFY(x)   AI_STRINGIFY_INTERNAL(x)
 
#define AI_EXCEPTIONS   0
 If you want to use exceptions in your code and want them to be catched by the library just set this to 1.
 
#define AI_LUA_SANTITY   1
 Enable lua sanity checks by default.
 
#define SIMPLEAI_LIB
 
#define PRIChrId   PRId32
 

Typedefs

typedef int ai::CharacterId
 Defines the type of the id to identify an ai controlled entity. More...
 
typedef std::unordered_map
< std::string, std::string > 
ai::CharacterAttributes
 ICharacter attributes for the remote debugger.
 

Functions

template<class T , class S >
ai_assert_cast (const S object)
 If you compile with RTTI activated, you get additional sanity checks when using this macro to perform your static_cast calls.
 

Macro Definition Documentation

#define ai_assert (   condition,
  ... 
)

Provide your own assert - this is only executed in DEBUG mode.

See Also
ai_assert_always
#define ai_assert_always (   condition,
  ... 
)
Value:
if ( !(condition) ) { \
ai_log_error(__VA_ARGS__); \
ai_log_error("%s:%i", __FILE__, __LINE__); \
assert(condition); \
}
#define ai_log_error(...)
Logging macro to provide your own loggers.
Definition: Types.h:23

Provide your own assert - this is also executed in non DEBUG mode.