1 /* !!!! GENERATED FILE - DO NOT EDIT !!!! 2 * -------------------------------------- 3 * 4 * This file is part of liblcf. Copyright (c) 2021 liblcf authors. 5 * https://github.com/EasyRPG/liblcf - https://easyrpg.org 6 * 7 * liblcf is Free/Libre Open Source Software, released under the MIT License. 8 * For the full copyright and license information, please view the COPYING 9 * file that was distributed with this source code. 10 */ 11 12 #ifndef LCF_RPG_SAVEVEHICLELOCATION_H 13 #define LCF_RPG_SAVEVEHICLELOCATION_H 14 15 // Headers 16 #include "lcf/rpg/savemapeventbase.h" 17 #include <stdint.h> 18 #include <string> 19 #include "lcf/enum_tags.h" 20 #include "lcf/context.h" 21 #include <ostream> 22 #include <type_traits> 23 24 /** 25 * rpg::SaveVehicleLocation class. 26 */ 27 namespace lcf { 28 namespace rpg { 29 class SaveVehicleLocation : public SaveMapEventBase { 30 public: 31 enum VehicleType { 32 VehicleType_none = 0, 33 VehicleType_skiff = 1, 34 VehicleType_ship = 2, 35 VehicleType_airship = 3 36 }; 37 static constexpr auto kVehicleTypeTags = lcf::makeEnumTags<VehicleType>( 38 "none", 39 "skiff", 40 "ship", 41 "airship" 42 ); 43 44 int32_t vehicle = 0; 45 int32_t remaining_ascent = 0; 46 int32_t remaining_descent = 0; 47 std::string orig_sprite_name; 48 int32_t orig_sprite_id = 0; 49 }; 50 inline std::ostream& operator<<(std::ostream& os, SaveVehicleLocation::VehicleType code) { 51 os << static_cast<std::underlying_type_t<decltype(code)>>(code); 52 return os; 53 } 54 55 inline bool operator==(const SaveVehicleLocation& l, const SaveVehicleLocation& r) { 56 return l.vehicle == r.vehicle 57 && l.remaining_ascent == r.remaining_ascent 58 && l.remaining_descent == r.remaining_descent 59 && l.orig_sprite_name == r.orig_sprite_name 60 && l.orig_sprite_id == r.orig_sprite_id; 61 } 62 63 inline bool operator!=(const SaveVehicleLocation& l, const SaveVehicleLocation& r) { 64 return !(l == r); 65 } 66 67 std::ostream& operator<<(std::ostream& os, const SaveVehicleLocation& obj); 68 69 template <typename F, typename ParentCtx = Context<void,void>> 70 void ForEachString(SaveVehicleLocation& obj, const F& f, const ParentCtx* parent_ctx = nullptr) { 71 (void)obj; 72 (void)f; 73 (void)parent_ctx; 74 } 75 76 } // namespace rpg 77 } // namespace lcf 78 79 #endif 80