Freeciv-3.3
Loading...
Searching...
No Matches
rscompat.h
Go to the documentation of this file.
1/***********************************************************************
2 Freeciv - Copyright (C) 1996 - A Kjeldberg, L Gregersen, P Unold
3 This program is free software; you can redistribute it and/or modify
4 it under the terms of the GNU General Public License as published by
5 the Free Software Foundation; either version 2, or (at your option)
6 any later version.
7
8 This program is distributed in the hope that it will be useful,
9 but WITHOUT ANY WARRANTY; without even the implied warranty of
10 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 GNU General Public License for more details.
12***********************************************************************/
13#ifndef FC__RSCOMPAT_H
14#define FC__RSCOMPAT_H
15
16#ifdef __cplusplus
17extern "C" {
18#endif /* __cplusplus */
19
20/* utility */
21#include "support.h"
22
23/* server */
24#include "ruleload.h"
25#include "settings.h"
26
27#define RULESET_COMPAT_CAP "+Freeciv-3.2-ruleset"
28
35
36void rscompat_init_info(struct rscompat_info *info);
37
38int rscompat_check_capabilities(struct section_file *file, const char *filename,
39 const struct rscompat_info *info);
41 const char *filename,
42 const struct rscompat_info *info);
43
44bool rscompat_names(struct rscompat_info *info);
45
46void rscompat_postprocess(struct rscompat_info *info);
47
48/* General upgrade functions that should be kept to avoid regressions in
49 * corner case handling. */
51
52/* Functions from ruleset.c made visible to rscompat.c */
54 struct rscompat_info *compat,
55 const char *sec,
56 const char *sub,
57 const char *rfor);
58
59/* Functions specific to 3.2 -> 3.3 transition */
60const char *rscompat_utype_flag_name_3_3(const char *old_name);
61const char *rscompat_universal_name_3_3(const char *old_name);
62const char *rscompat_effect_name_3_3(const char *old_name);
63
64const char *blocked_by_old_name_3_3(const char *new_name);
65const char *ui_name_old_name_3_3(const char *new_name);
66
68
69bool load_action_ui_name_3_3(struct section_file *file, int act,
70 const char *entry_name,
71 struct rscompat_info *compat);
72
73#ifdef __cplusplus
74}
75#endif /* __cplusplus */
76
77#endif /* FC__RSCOMPAT_H */
char * incite_cost
Definition comments.c:76
const char * entry_name(const struct entry *pentry)
bool load_action_ui_name_3_3(struct section_file *file, int act, const char *entry_name, struct rscompat_info *compat)
Definition rscompat.c:748
void rscompat_civil_war_effects_3_3(struct section_file *game_rs)
Definition rscompat.c:716
const char * rscompat_effect_name_3_3(const char *old_name)
Definition rscompat.c:659
const char * ui_name_old_name_3_3(const char *new_name)
Definition rscompat.c:692
bool rscompat_names(struct rscompat_info *info)
Definition rscompat.c:345
void rscompat_postprocess(struct rscompat_info *info)
Definition rscompat.c:457
const char * rscompat_utype_flag_name_3_3(const char *old_name)
Definition rscompat.c:635
int rscompat_check_capabilities(struct section_file *file, const char *filename, const struct rscompat_info *info)
Definition rscompat.c:70
struct requirement_vector * lookup_req_list(struct section_file *file, struct rscompat_info *compat, const char *sec, const char *sub, const char *rfor)
Definition ruleload.c:656
void rscompat_enablers_add_obligatory_hard_reqs(void)
Definition rscompat.c:290
const char * blocked_by_old_name_3_3(const char *new_name)
Definition rscompat.c:671
const char * rscompat_universal_name_3_3(const char *old_name)
Definition rscompat.c:647
void rscompat_init_info(struct rscompat_info *info)
Definition rscompat.c:61
bool rscompat_check_cap_and_version(struct section_file *file, const char *filename, const struct rscompat_info *info)
Definition rscompat.c:135
void(* rs_conversion_logger)(const char *msg)
Definition ruleload.h:42
static struct compatibility compat[]
Definition savecompat.c:112
bool compat_mode
Definition rscompat.h:31
rs_conversion_logger log_cb
Definition rscompat.h:32