1 /*
2  * This file is part of liblcf. Copyright (c) 2021 liblcf authors.
3  * https://github.com/EasyRPG/liblcf - https://easyrpg.org
4  *
5  * liblcf is Free/Libre Open Source Software, released under the MIT License.
6  * For the full copyright and license information, please view the COPYING
7  * file that was distributed with this source code.
8  */
9 
10 #ifndef LCF_SAVEOPT_H
11 #define LCF_SAVEOPT_H
12 
13 namespace lcf {
14 namespace rpg {
15 class Database;
16 };
17 
18 /**
19  * Options to configure how LDB file is saved
20  */
21 enum class SaveOpt {
22 	eNone = 0,
23 	ePreserveHeader = 1
24 };
25 
26 constexpr SaveOpt operator|(SaveOpt l, SaveOpt r) { return SaveOpt(int(l) | int(r)); }
27 constexpr SaveOpt operator&(SaveOpt l, SaveOpt r) { return SaveOpt(int(l) & int(r)); }
28 constexpr SaveOpt operator^(SaveOpt l, SaveOpt r) { return SaveOpt(int(l) ^ int(r)); }
29 constexpr SaveOpt operator~(SaveOpt l) { return SaveOpt(~int(l)); }
30 
31 /**
32  * Which LCF file format to write
33  */
34 enum class EngineVersion {
35 	e2k = 0,
36 	e2k3 = 1
37 };
38 
39 EngineVersion GetEngineVersion(const lcf::rpg::Database& db);
40 
41 } //namespace lcf
42 
43 #endif
44 
45