45 return (min + floor(roll * (max - min + 1)));
91 return direction8_name(dir);
131 new_dir =
dir_cw(new_dir);
153 char *deprecated_since)
158 if (deprecated_since != NULL && replacement != NULL) {
160 "Use \"%s\" instead", method, deprecated_since, replacement);
161 }
else if (replacement != NULL) {
163 "Use \"%s\" instead", method, replacement);
const Direction * api_utilities_dir_cw(lua_State *L, Direction dir)
const char * api_utilities_fc_version(lua_State *L)
const char * api_utilities_dir2str(lua_State *L, Direction dir)
int api_utilities_random(lua_State *L, int min, int max)
const Direction * api_utilities_opposite_dir(lua_State *L, Direction dir)
void api_utilities_log_base(lua_State *L, int level, const char *message)
const Direction * api_utilities_str2dir(lua_State *L, const char *dir)
void api_utilities_deprecation_warning(lua_State *L, char *method, char *replacement, char *deprecated_since)
int api_utilities_direction_id(lua_State *L, Direction dir)
const Direction * api_utilities_dir_ccw(lua_State *L, Direction dir)
bool are_deprecation_warnings_enabled(void)
#define log_deprecation_always(message,...)
const Direction * luascript_dir(enum direction8 dir)
void luascript_log(struct fc_lua *fcl, enum log_level level, const char *format,...)
struct fc_lua * luascript_get_fcl(lua_State *L)
#define LUASCRIPT_CHECK_STATE(L,...)
#define LUASCRIPT_CHECK_ARG_NIL(L, value, narg, type,...)
#define LUASCRIPT_CHECK(L, check, msg,...)
enum direction8 Direction
enum direction8 opposite_direction(enum direction8 dir)
enum direction8 dir_ccw(enum direction8 dir)
bool is_valid_dir(enum direction8 dir)
enum direction8 dir_cw(enum direction8 dir)
struct setting_list * level[OLEVELS_NUM]
int fc_strcasecmp(const char *str0, const char *str1)
const char * freeciv_name_version(void)