Switch to C++17.

Also change namespace definitions to nested ones.
This commit is contained in:
Guillaume Jacquemin 2024-07-14 16:28:17 +02:00
parent bbf457beb6
commit 53c58ba979
Signed by: williamjcm
SSH key fingerprint: SHA256:AYLOg+iTV0ElElnlu4vqM4edFazVdRiuQB0Y5LoKc4A
107 changed files with 223 additions and 227 deletions

View file

@ -14,7 +14,7 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.
set(CMAKE_CXX_STANDARD 14)
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_CXX_EXTENSIONS OFF)

View file

@ -25,7 +25,7 @@
using namespace Corrade;
using namespace Containers::Literals;
namespace mbst { namespace GameData {
namespace mbst::GameData {
struct Accessory {
Containers::StringView name;
@ -780,4 +780,4 @@ static const std::map<std::int32_t, Accessory> accessories{
// endregion
};
}}
}

View file

@ -25,7 +25,7 @@
using namespace Corrade;
using namespace Containers::Literals;
namespace mbst { namespace GameData {
namespace mbst::GameData {
struct ArmourSet {
Containers::StringView name;
@ -58,4 +58,4 @@ static const std::map<std::int32_t, ArmourSet> armour_sets {
{27, {"Axial Core X-Type"_s, false}},
};
}}
}

View file

@ -23,7 +23,7 @@
using namespace Corrade;
using namespace Containers::Literals;
namespace mbst { namespace GameData {
namespace mbst::GameData {
static const std::map<std::int32_t, Containers::StringView> mission_id_map {{
// Story missions
@ -59,4 +59,4 @@ static const std::map<std::int32_t, Containers::StringView> mission_id_map {{
{400, "Challenge 3 - Gates of Ascension"_s}
}};
}}
}

View file

@ -16,7 +16,7 @@
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <https://www.gnu.org/licenses/>.
namespace mbst { namespace GameData {
namespace mbst::GameData {
enum MaterialID : std::int32_t {
VerseSteel = 0xC3500,
@ -48,4 +48,4 @@ enum MaterialID : std::int32_t {
IsolatedVoidParticle = 0xDBBA5,
};
}}
}

View file

@ -22,7 +22,7 @@
using namespace Corrade;
using namespace Containers::Literals;
namespace mbst { namespace GameData {
namespace mbst::GameData {
struct StoryProgressPoint {
std::int32_t id{};
@ -112,4 +112,4 @@ static const Corrade::Containers::Array<StoryProgressPoint> story_progress
}
};
}}
}

View file

@ -25,7 +25,7 @@
using namespace Corrade;
using namespace Containers::Literals;
namespace mbst { namespace GameData {
namespace mbst::GameData {
extern const std::map<std::int32_t, Containers::StringView> builtin_style_names
#ifdef STYLENAMES_DEFINITION
@ -162,4 +162,4 @@ extern const std::map<std::int32_t, Containers::StringView> builtin_style_names
#endif
;
}}
}

View file

@ -25,7 +25,7 @@ using namespace Corrade;
using namespace Containers::Literals;
namespace mbst { namespace GameData {
namespace mbst::GameData {
// region Melee
static const std::map<std::int32_t, Containers::StringView> melee_grips {
@ -433,4 +433,4 @@ static const std::map<std::int32_t, Containers::StringView> elauncher_pods {
};
// endregion
}}
}

View file

@ -24,7 +24,7 @@
using namespace Corrade;
using namespace Magnum;
namespace mbst { namespace GameObjects {
namespace mbst::GameObjects {
struct Accessory {
std::int32_t attachIndex = -1;
@ -37,4 +37,4 @@ struct Accessory {
Vector3 localScale{1.0f};
};
}}
}

View file

@ -24,7 +24,7 @@
using namespace Corrade;
namespace mbst { namespace GameObjects {
namespace mbst::GameObjects {
struct ArmourPart {
enum class Slot {
@ -39,4 +39,4 @@ struct ArmourPart {
Containers::Array<Accessory> accessories;
};
}}
}

View file

@ -24,7 +24,7 @@
using namespace Corrade;
using namespace Magnum;
namespace mbst { namespace GameObjects {
namespace mbst::GameObjects {
enum class BulletLauncherAttachmentStyle {
#define c(enumerator, enumstr) enumerator,
@ -46,4 +46,4 @@ struct BulletLauncherAttachment {
Vector3 relativeScale;
};
}}
}

View file

@ -25,7 +25,7 @@
using namespace Corrade;
using namespace Magnum;
namespace mbst { namespace GameObjects {
namespace mbst::GameObjects {
struct CustomStyle {
Containers::String name;
@ -50,4 +50,4 @@ struct CustomStyle {
} type = Type::Unknown;
};
}}
}

View file

@ -23,7 +23,7 @@
using namespace Magnum;
namespace mbst { namespace GameObjects {
namespace mbst::GameObjects {
struct Decal {
std::int32_t id = -1;
@ -38,4 +38,4 @@ struct Decal {
bool wrap = false;
};
}}
}

View file

@ -16,7 +16,7 @@
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <https://www.gnu.org/licenses/>.
namespace mbst { namespace GameObjects {
namespace mbst::GameObjects {
struct Joints {
float neck = 0.0f;
@ -29,4 +29,4 @@ struct Joints {
float lowerLegs = 0.0f;
};
}}
}

View file

@ -34,7 +34,7 @@
using namespace Containers::Literals;
namespace mbst { namespace GameObjects {
namespace mbst::GameObjects {
Mass::Mass(Containers::StringView path) {
auto split = Utility::Path::split(path);
@ -402,4 +402,4 @@ Mass::getTuningCategory(Containers::StringView big_node_prop_name, std::int32_t&
}
}
}}
}

View file

@ -42,7 +42,7 @@
using namespace Corrade;
using namespace Magnum;
namespace mbst { namespace GameObjects {
namespace mbst::GameObjects {
class Mass {
public:
@ -213,4 +213,4 @@ class Mass {
Containers::String _account;
};
}}
}

View file

@ -29,7 +29,7 @@
using namespace Containers::Literals;
namespace mbst { namespace GameObjects {
namespace mbst::GameObjects {
Containers::ArrayView<ArmourPart>
Mass::armourParts() {
@ -448,4 +448,4 @@ Mass::writeArmourCustomStyle(std::size_t index) {
return writeCustomStyle(_armour.customStyles[index], index, armour_styles);
}
}}
}

View file

@ -29,7 +29,7 @@
using namespace Containers::Literals;
namespace mbst { namespace GameObjects {
namespace mbst::GameObjects {
void
Mass::getDecals(Containers::ArrayView<Decal> decals, Gvas::Types::ArrayProperty* decal_array) {
@ -153,4 +153,4 @@ Mass::writeAccessories(Containers::ArrayView<Accessory> accessories, Gvas::Types
}
}
}}
}

View file

@ -26,7 +26,7 @@
using namespace Containers::Literals;
namespace mbst { namespace GameObjects {
namespace mbst::GameObjects {
Joints&
Mass::jointSliders() {
@ -408,4 +408,4 @@ Mass::writeFrameCustomStyle(std::size_t index) {
return writeCustomStyle(_frame.customStyles[index], index, frame_styles);
}
}}
}

View file

@ -27,7 +27,7 @@
using namespace Containers::Literals;
namespace mbst { namespace GameObjects {
namespace mbst::GameObjects {
Containers::ArrayView<CustomStyle>
Mass::globalStyles() {
@ -155,4 +155,4 @@ Mass::writeCustomStyle(const CustomStyle& style, std::size_t index, Gvas::Types:
return true;
}
}}
}

View file

@ -28,7 +28,7 @@
using namespace Containers::Literals;
namespace mbst { namespace GameObjects {
namespace mbst::GameObjects {
Containers::ArrayView<Weapon>
Mass::meleeWeapons() {
@ -385,4 +385,4 @@ Mass::writeWeaponType(Containers::StringView prop_name, Containers::ArrayView<We
return true;
}
}}
}

View file

@ -31,7 +31,7 @@
using namespace Corrade;
using namespace Containers::Literals;
namespace mbst { namespace GameObjects {
namespace mbst::GameObjects {
Profile::Profile(Containers::StringView path):
_profile(path)
@ -318,4 +318,4 @@ Profile::getResource(Containers::StringView container, GameData::MaterialID id)
return it != mats_prop->items.end() ? dynamic_cast<Gvas::Types::ResourceItemValue*>(it->get())->quantity : 0;
}
}}
}

View file

@ -26,7 +26,7 @@
using namespace Corrade;
namespace mbst { namespace GameObjects {
namespace mbst::GameObjects {
class Profile {
public:
@ -89,4 +89,4 @@ class Profile {
Containers::String _lastError;
};
}}
}

View file

@ -16,7 +16,7 @@
#include "Weapon.h"
namespace mbst { namespace GameObjects {
namespace mbst::GameObjects {
Weapon::Weapon(const Weapon& other) {
name = other.name;
@ -51,4 +51,4 @@ Weapon::operator=(const Weapon& other) {
return *this;
}
}}
}

View file

@ -29,7 +29,7 @@
using namespace Corrade;
using namespace Magnum;
namespace mbst { namespace GameObjects {
namespace mbst::GameObjects {
struct Weapon {
Weapon() = default;
@ -63,4 +63,4 @@ struct Weapon {
Color4 effectColour{0.0f};
};
}}
}

View file

@ -24,7 +24,7 @@
using namespace Corrade;
namespace mbst { namespace GameObjects {
namespace mbst::GameObjects {
struct WeaponPart {
WeaponPart() = default;
@ -64,4 +64,4 @@ struct WeaponPart {
Containers::Array<Accessory> accessories{};
};
}}
}

View file

@ -27,7 +27,7 @@
using namespace Corrade;
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
using PropertyArray = Containers::Array<Types::UnrealPropertyBase::ptr>;
using PropertyArrayView = Containers::ArrayView<Types::UnrealPropertyBase::ptr>;
@ -50,4 +50,4 @@ class AbstractUnrealCollectionProperty {
PropertySerialiser& serialiser) = 0;
};
}}
}

View file

@ -26,7 +26,7 @@
using namespace Corrade;
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
using StringArrayView = Containers::ArrayView<const Containers::String>;
@ -46,4 +46,4 @@ class AbstractUnrealProperty {
BinaryIo::Writer& writer, PropertySerialiser& serialiser) = 0;
};
}}
}

View file

@ -27,7 +27,7 @@
using namespace Corrade;
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
class AbstractUnrealStruct {
public:
@ -43,4 +43,4 @@ class AbstractUnrealStruct {
std::size_t& bytes_written) = 0;
};
}}
}

View file

@ -23,7 +23,7 @@
#include "ArrayProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
Types::UnrealPropertyBase::ptr
ArrayProperty::deserialiseProperty(Containers::StringView name, Containers::StringView type, std::size_t value_length,
@ -76,4 +76,4 @@ ArrayProperty::serialiseProperty(Types::UnrealPropertyBase::ptr& prop, std::size
return ret;
}
}}
}

View file

@ -24,7 +24,7 @@
using namespace Corrade;
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
class ArrayProperty : public UnrealProperty<Types::ArrayProperty> {
public:
@ -38,4 +38,4 @@ class ArrayProperty : public UnrealProperty<Types::ArrayProperty> {
BinaryIo::Writer& writer, PropertySerialiser& serialiser) override;
};
}}
}

View file

@ -20,7 +20,7 @@
#include "BoolProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
StringArrayView
BoolProperty::types() {
@ -70,4 +70,4 @@ BoolProperty::serialise(Types::UnrealPropertyBase::ptr& prop, std::size_t& bytes
return true;
}
}}
}

View file

@ -25,7 +25,7 @@
using namespace Corrade;
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
class BoolProperty : public AbstractUnrealProperty {
public:
@ -41,4 +41,4 @@ class BoolProperty : public AbstractUnrealProperty {
PropertySerialiser& serialiser) override;
};
}}
}

View file

@ -20,7 +20,7 @@
#include "ByteProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
StringArrayView
ByteProperty::types() {
@ -31,7 +31,7 @@ ByteProperty::types() {
Types::UnrealPropertyBase::ptr
ByteProperty::deserialise(Containers::StringView name, Containers::StringView type, std::size_t value_length,
BinaryIo::Reader& reader, PropertySerialiser& serialiser)
BinaryIo::Reader& reader, PropertySerialiser& serialiser)
{
auto prop = Containers::pointer<Types::ByteProperty>();
@ -91,4 +91,4 @@ ByteProperty::serialise(Types::UnrealPropertyBase::ptr& prop, std::size_t& bytes
return true;
}
}}
}

View file

@ -23,7 +23,7 @@
#include "../Types/ByteProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
class ByteProperty : public AbstractUnrealProperty {
public:
@ -39,4 +39,4 @@ class ByteProperty : public AbstractUnrealProperty {
PropertySerialiser& serialiser) override;
};
}}
}

View file

@ -20,7 +20,7 @@
#include "ColourProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
Types::UnrealPropertyBase::ptr
ColourProperty::deserialiseProperty(Containers::StringView name, Containers::StringView type, std::size_t value_length,
@ -56,4 +56,4 @@ ColourProperty::serialiseProperty(Types::UnrealPropertyBase::ptr& prop, std::siz
return true;
}
}}
}

View file

@ -24,7 +24,7 @@
using namespace Corrade;
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
class ColourProperty : public UnrealProperty<Types::ColourStructProperty> {
public:
@ -38,4 +38,4 @@ class ColourProperty : public UnrealProperty<Types::ColourStructProperty> {
BinaryIo::Writer& writer, PropertySerialiser& serialiser) override;
};
}}
}

View file

@ -20,7 +20,7 @@
#include "DateTimeProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
Types::UnrealPropertyBase::ptr
DateTimeProperty::deserialiseProperty(Containers::StringView name, Containers::StringView type,
@ -51,4 +51,4 @@ DateTimeProperty::serialiseProperty(Types::UnrealPropertyBase::ptr& prop, std::s
return true;
}
}}
}

View file

@ -22,7 +22,7 @@
#include "../Types/DateTimeStructProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
class DateTimeProperty : public UnrealProperty<Types::DateTimeStructProperty> {
public:
@ -36,4 +36,4 @@ class DateTimeProperty : public UnrealProperty<Types::DateTimeStructProperty> {
BinaryIo::Writer& writer, PropertySerialiser& serialiser) override;
};
}}
}

View file

@ -20,7 +20,7 @@
#include "EnumProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
StringArrayView
EnumProperty::types() {
@ -71,4 +71,4 @@ EnumProperty::serialise(Types::UnrealPropertyBase::ptr& prop, std::size_t& bytes
return true;
}
}}
}

View file

@ -23,7 +23,7 @@
#include "../Types/EnumProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
class EnumProperty : public AbstractUnrealProperty {
public:
@ -39,4 +39,4 @@ class EnumProperty : public AbstractUnrealProperty {
PropertySerialiser& serialiser) override;
};
}}
}

View file

@ -20,7 +20,7 @@
#include "FloatProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
StringArrayView
FloatProperty::types() {
@ -65,4 +65,4 @@ FloatProperty::serialise(Types::UnrealPropertyBase::ptr& prop, std::size_t& byte
return true;
}
}}
}

View file

@ -23,7 +23,7 @@
#include "../Types/FloatProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
class FloatProperty : public AbstractUnrealProperty {
public:
@ -39,4 +39,4 @@ class FloatProperty : public AbstractUnrealProperty {
PropertySerialiser& serialiser) override;
};
}}
}

View file

@ -22,7 +22,7 @@
using namespace Containers::Literals;
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
Types::UnrealPropertyBase::ptr
GuidProperty::deserialiseProperty(Containers::StringView name, Containers::StringView type, std::size_t value_length,
@ -53,4 +53,4 @@ GuidProperty::serialiseProperty(Types::UnrealPropertyBase::ptr& prop, std::size_
return true;
}
}}
}

View file

@ -22,7 +22,7 @@
#include "../Types/GuidStructProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
class GuidProperty : public UnrealProperty<Types::GuidStructProperty> {
public:
@ -36,4 +36,4 @@ class GuidProperty : public UnrealProperty<Types::GuidStructProperty> {
BinaryIo::Writer& writer, PropertySerialiser& serialiser) override;
};
}}
}

View file

@ -20,7 +20,7 @@
#include "IntProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
Types::UnrealPropertyBase::ptr
IntProperty::deserialiseProperty(Containers::StringView name, Containers::StringView type, std::size_t value_length,
@ -73,4 +73,4 @@ IntProperty::serialiseProperty(Types::UnrealPropertyBase::ptr& prop, std::size_t
return true;
}
}}
}

View file

@ -22,7 +22,7 @@
#include "../Types/IntProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
class IntProperty : public UnrealProperty<Types::IntProperty> {
public:
@ -36,4 +36,4 @@ class IntProperty : public UnrealProperty<Types::IntProperty> {
BinaryIo::Writer& writer, PropertySerialiser& serialiser) override;
};
}}
}

View file

@ -24,7 +24,7 @@
using namespace Containers::Literals;
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
Types::UnrealPropertyBase::ptr
MapProperty::deserialiseProperty(Containers::StringView name, Containers::StringView type, std::size_t value_length,
@ -156,4 +156,4 @@ MapProperty::serialiseProperty(Types::UnrealPropertyBase::ptr& prop, std::size_t
return true;
}
}}
}

View file

@ -22,7 +22,7 @@
#include "../Types/MapProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
class MapProperty : public UnrealProperty<Types::MapProperty> {
public:
@ -36,4 +36,4 @@ class MapProperty : public UnrealProperty<Types::MapProperty> {
BinaryIo::Writer& writer, PropertySerialiser& serialiser) override;
};
}}
}

View file

@ -25,7 +25,7 @@
using namespace Containers::Literals;
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
Types::UnrealPropertyBase::ptr
ResourceProperty::deserialiseProperty(Containers::StringView name, Containers::StringView type,
@ -107,4 +107,4 @@ ResourceProperty::serialiseProperty(Types::UnrealPropertyBase::ptr& prop, std::s
return true;
}
}}
}

View file

@ -22,7 +22,7 @@
#include "../Types/ResourceItemValue.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
class ResourceProperty : public UnrealProperty<Types::ResourceItemValue> {
public:
@ -36,4 +36,4 @@ class ResourceProperty : public UnrealProperty<Types::ResourceItemValue> {
BinaryIo::Writer& writer, PropertySerialiser& serialiser) override;
};
}}
}

View file

@ -20,7 +20,7 @@
#include "RotatorProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
Types::UnrealPropertyBase::ptr
RotatorProperty::deserialiseProperty(Containers::StringView name, Containers::StringView type, std::size_t value_length,
@ -53,4 +53,4 @@ RotatorProperty::serialiseProperty(Types::UnrealPropertyBase::ptr& prop, std::si
return true;
}
}}
}

View file

@ -22,7 +22,7 @@
#include "../Types/RotatorStructProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
class RotatorProperty : public UnrealProperty<Types::RotatorStructProperty> {
public:
@ -36,4 +36,4 @@ class RotatorProperty : public UnrealProperty<Types::RotatorStructProperty> {
BinaryIo::Writer& writer, PropertySerialiser& serialiser) override;
};
}}
}

View file

@ -16,7 +16,7 @@
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <https://www.gnu.org/licenses/>.
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
class AbstractUnrealCollectionProperty;
class AbstractUnrealProperty;
@ -41,4 +41,4 @@ class UnrealProperty;
class Vector2DProperty;
class VectorProperty;
}}
}

View file

@ -21,7 +21,7 @@
#include "SetProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
Types::UnrealPropertyBase::ptr
SetProperty::deserialiseProperty(Containers::StringView name, Containers::StringView type, std::size_t value_length,
@ -82,4 +82,4 @@ SetProperty::serialiseProperty(Types::UnrealPropertyBase::ptr& prop, std::size_t
return true;
}
}}
}

View file

@ -22,7 +22,7 @@
#include "../Types/SetProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
class SetProperty : public UnrealProperty<Types::SetProperty> {
public:
@ -36,4 +36,4 @@ class SetProperty : public UnrealProperty<Types::SetProperty> {
BinaryIo::Writer& writer, PropertySerialiser& serialiser) override;
};
}}
}

View file

@ -20,7 +20,7 @@
#include "StringProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
StringArrayView
StringProperty::types() {
@ -74,4 +74,4 @@ StringProperty::serialise(Types::UnrealPropertyBase::ptr& prop, std::size_t& byt
return true;
}
}}
}

View file

@ -23,7 +23,7 @@
#include "../Types/StringProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
class StringProperty : public AbstractUnrealProperty {
public:
@ -39,4 +39,4 @@ class StringProperty : public AbstractUnrealProperty {
PropertySerialiser& serialiser) override;
};
}}
}

View file

@ -25,7 +25,7 @@
#include "Struct.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
StringArrayView
Struct::types() {
@ -242,4 +242,4 @@ Struct::writeStructValue(Types::StructProperty* prop, std::size_t& bytes_written
return true;
}
}}
}

View file

@ -25,7 +25,7 @@
#include "../Types/StructProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
class Struct : public AbstractUnrealProperty, public AbstractUnrealCollectionProperty {
public:
@ -52,4 +52,4 @@ class Struct : public AbstractUnrealProperty, public AbstractUnrealCollectionPro
PropertySerialiser& serialiser);
};
}}
}

View file

@ -23,7 +23,7 @@
#include "TextProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
Types::UnrealPropertyBase::ptr
TextProperty::deserialiseProperty(Containers::StringView name, Containers::StringView type, std::size_t value_length,
@ -91,4 +91,4 @@ TextProperty::serialiseProperty(Types::UnrealPropertyBase::ptr& prop, std::size_
return true;
}
}}
}

View file

@ -22,7 +22,7 @@
#include "../Types/TextProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
class TextProperty : public UnrealProperty<Types::TextProperty> {
public:
@ -36,4 +36,4 @@ class TextProperty : public UnrealProperty<Types::TextProperty> {
BinaryIo::Writer& writer, PropertySerialiser& serialiser) override;
};
}}
}

View file

@ -25,7 +25,7 @@
#include "AbstractUnrealProperty.h"
#include "../Types/StructProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
template<typename T>
class UnrealProperty : public AbstractUnrealProperty {
@ -73,4 +73,4 @@ class UnrealProperty : public AbstractUnrealProperty {
BinaryIo::Writer& writer, PropertySerialiser& serialiser) = 0;
};
}}
}

View file

@ -20,7 +20,7 @@
#include "Vector2DProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
Types::UnrealPropertyBase::ptr
Vector2DProperty::deserialiseProperty(Containers::StringView name, Containers::StringView type,
@ -53,4 +53,4 @@ Vector2DProperty::serialiseProperty(Types::UnrealPropertyBase::ptr& prop, std::s
return true;
}
}}
}

View file

@ -22,7 +22,7 @@
#include "../Types/Vector2DStructProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
class Vector2DProperty : public UnrealProperty<Types::Vector2DStructProperty> {
public:
@ -36,4 +36,4 @@ class Vector2DProperty : public UnrealProperty<Types::Vector2DStructProperty> {
BinaryIo::Writer& writer, PropertySerialiser& serialiser) override;
};
}}
}

View file

@ -21,7 +21,7 @@
#include "VectorProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
Types::UnrealPropertyBase::ptr
VectorProperty::deserialiseProperty(Containers::StringView name, Containers::StringView type, std::size_t value_length,
@ -54,4 +54,4 @@ VectorProperty::serialiseProperty(Types::UnrealPropertyBase::ptr& prop, std::siz
return true;
}
}}
}

View file

@ -22,7 +22,7 @@
#include "../Types/VectorStructProperty.h"
namespace Gvas { namespace Serialisers {
namespace Gvas::Serialisers {
class VectorProperty : public UnrealProperty<Types::VectorStructProperty> {
public:
@ -36,4 +36,4 @@ class VectorProperty : public UnrealProperty<Types::VectorStructProperty> {
BinaryIo::Writer& writer, PropertySerialiser& serialiser) override;
};
}}
}

View file

@ -23,7 +23,7 @@
#include "UnrealPropertyBase.h"
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct ArrayProperty : public UnrealPropertyBase {
using ptr = Containers::Pointer<ArrayProperty>;
@ -47,4 +47,4 @@ struct ArrayProperty : public UnrealPropertyBase {
Containers::Array<UnrealPropertyBase::ptr> items;
};
}}
}

View file

@ -23,7 +23,7 @@
using namespace Corrade;
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct BoolProperty : public UnrealProperty<bool> {
using ptr = Containers::Pointer<BoolProperty>;
@ -34,4 +34,4 @@ struct BoolProperty : public UnrealProperty<bool> {
}
};
}}
}

View file

@ -25,7 +25,7 @@
using namespace Corrade;
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct ByteProperty : public UnrealProperty<Containers::Array<char>> {
using ptr = Containers::Pointer<ByteProperty>;
@ -41,4 +41,4 @@ struct ByteProperty : public UnrealProperty<Containers::Array<char>> {
Containers::String enumValue;
};
}}
}

View file

@ -23,7 +23,7 @@
using namespace Corrade;
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct ColourStructProperty : public StructProperty {
using ptr = Containers::Pointer<ColourStructProperty>;
@ -34,4 +34,4 @@ struct ColourStructProperty : public StructProperty {
float r = 0.0f, g = 0.0f, b = 0.0f, a = 0.0f;
};
}}
}

View file

@ -23,7 +23,7 @@
using namespace Corrade;
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct DateTimeStructProperty : public StructProperty {
using ptr = Containers::Pointer<DateTimeStructProperty>;
@ -36,4 +36,4 @@ struct DateTimeStructProperty : public StructProperty {
std::int64_t timestamp = 0;
};
}}
}

View file

@ -24,7 +24,7 @@
using namespace Corrade;
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct EnumProperty : public UnrealProperty<Containers::String> {
using ptr = Containers::Pointer<EnumProperty>;
@ -37,4 +37,4 @@ struct EnumProperty : public UnrealProperty<Containers::String> {
Containers::String enumType;
};
}}
}

View file

@ -23,7 +23,7 @@
using namespace Corrade;
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct FloatProperty : public UnrealProperty<float> {
using ptr = Containers::Pointer<FloatProperty>;
@ -34,4 +34,4 @@ struct FloatProperty : public UnrealProperty<float> {
}
};
}}
}

View file

@ -26,7 +26,7 @@
using namespace Corrade;
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct GenericStructProperty : public StructProperty {
using ptr = Containers::Pointer<GenericStructProperty>;
@ -56,4 +56,4 @@ struct GenericStructProperty : public StructProperty {
Containers::Array<UnrealPropertyBase::ptr> properties;
};
}}
}

View file

@ -24,7 +24,7 @@
using namespace Corrade;
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct GuidStructProperty : public StructProperty {
using ptr = Containers::Pointer<GuidStructProperty>;
@ -37,4 +37,4 @@ struct GuidStructProperty : public StructProperty {
Containers::StaticArray<16, char> guid{ValueInit};
};
}}
}

View file

@ -23,7 +23,7 @@
using namespace Corrade;
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct IntProperty : public UnrealProperty<std::int32_t> {
using ptr = Containers::Pointer<IntProperty>;
@ -34,4 +34,4 @@ struct IntProperty : public UnrealProperty<std::int32_t> {
}
};
}}
}

View file

@ -25,7 +25,7 @@
using namespace Corrade;
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct MapProperty : public UnrealPropertyBase {
using ptr = Containers::Pointer<MapProperty>;
@ -46,4 +46,4 @@ struct MapProperty : public UnrealPropertyBase {
Containers::Array<KeyValuePair> map;
};
}}
}

View file

@ -23,7 +23,7 @@
using namespace Corrade;
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct NoneProperty : UnrealPropertyBase {
using ptr = Containers::Pointer<NoneProperty>;
@ -35,4 +35,4 @@ struct NoneProperty : UnrealPropertyBase {
}
};
}}
}

View file

@ -23,7 +23,7 @@
using namespace Corrade;
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct ResourceItemValue : public StructProperty {
using ptr = Containers::Pointer<ResourceItemValue>;
@ -41,4 +41,4 @@ struct ResourceItemValue : public StructProperty {
std::int32_t quantity = 0;
};
}}
}

View file

@ -23,7 +23,7 @@
using namespace Corrade;
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct RotatorStructProperty : public StructProperty {
using ptr = Containers::Pointer<RotatorStructProperty>;
@ -36,4 +36,4 @@ struct RotatorStructProperty : public StructProperty {
float x = 0.0f, y = 0.0f, z = 0.0f;
};
}}
}

View file

@ -25,7 +25,7 @@
using namespace Corrade;
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct SetProperty : public UnrealPropertyBase {
using ptr = Containers::Pointer<SetProperty>;
@ -47,4 +47,4 @@ struct SetProperty : public UnrealPropertyBase {
Containers::Array<UnrealPropertyBase::ptr> items;
};
}}
}

View file

@ -25,7 +25,7 @@
using namespace Corrade;
using namespace Containers::Literals;
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct StringProperty : public UnrealProperty<Containers::String> {
using ptr = Containers::Pointer<StringProperty>;
@ -35,4 +35,4 @@ struct StringProperty : public UnrealProperty<Containers::String> {
}
};
}}
}

View file

@ -25,7 +25,7 @@
using namespace Corrade;
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct StructProperty : public UnrealPropertyBase {
using ptr = Containers::Pointer<StructProperty>;
@ -39,4 +39,4 @@ struct StructProperty : public UnrealPropertyBase {
Containers::String structType;
};
}}
}

View file

@ -25,7 +25,7 @@
using namespace Corrade;
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct TextProperty : public UnrealProperty<Containers::String> {
using ptr = Containers::Pointer<TextProperty>;
@ -40,4 +40,4 @@ struct TextProperty : public UnrealProperty<Containers::String> {
Containers::Array<Containers::String> data;
};
}}
}

View file

@ -16,7 +16,7 @@
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <https://www.gnu.org/licenses/>.
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct UnrealPropertyBase;
template<typename T>
@ -42,4 +42,4 @@ struct TextProperty;
struct Vector2DStructProperty;
struct VectorStructProperty;
}}
}

View file

@ -22,7 +22,7 @@
using namespace Corrade;
namespace Gvas { namespace Types {
namespace Gvas::Types {
template<typename T>
struct UnrealProperty : public UnrealPropertyBase {
@ -31,4 +31,4 @@ struct UnrealProperty : public UnrealPropertyBase {
T value;
};
}}
}

View file

@ -24,7 +24,7 @@
using namespace Corrade;
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct UnrealPropertyBase {
using ptr = Containers::Pointer<UnrealPropertyBase>;
@ -36,4 +36,4 @@ struct UnrealPropertyBase {
std::size_t valueLength = 0;
};
}}
}

View file

@ -23,7 +23,7 @@
using namespace Corrade;
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct Vector2DStructProperty : public StructProperty {
using ptr = Containers::Pointer<Vector2DStructProperty>;
@ -36,4 +36,4 @@ struct Vector2DStructProperty : public StructProperty {
float x = 0.0f, y = 0.0f;
};
}}
}

View file

@ -23,7 +23,7 @@
using namespace Corrade;
namespace Gvas { namespace Types {
namespace Gvas::Types {
struct VectorStructProperty : public StructProperty {
using ptr = Containers::Pointer<VectorStructProperty>;
@ -36,4 +36,4 @@ struct VectorStructProperty : public StructProperty {
float x = 0.0f, y = 0.0f, z = 0.0f;
};
}}
}

View file

@ -26,7 +26,7 @@
#include "Export.h"
namespace mbst { namespace ImportExport {
namespace mbst::ImportExport {
static Containers::String last_export_error;
@ -124,4 +124,4 @@ exportStyle(Containers::StringView mass_name, mbst::GameObjects::CustomStyle& st
return true;
}
}}
}

View file

@ -22,10 +22,10 @@
using namespace Corrade;
namespace mbst { namespace ImportExport {
namespace mbst::ImportExport {
auto lastExportError() -> Containers::StringView;
bool exportStyle(Containers::StringView mass_name, GameObjects::CustomStyle& style);
}}
}

View file

@ -30,7 +30,7 @@
#include "Import.h"
namespace mbst { namespace ImportExport {
namespace mbst::ImportExport {
static Containers::String last_import_error;
@ -183,4 +183,4 @@ importStyle(Containers::StringView filename) {
return Utility::move(style);
}
}}
}

View file

@ -22,10 +22,10 @@
using namespace Corrade;
namespace mbst { namespace ImportExport {
namespace mbst::ImportExport {
auto lastImportError() -> Containers::StringView;
auto importStyle(Containers::StringView filename) -> Containers::Optional<GameObjects::CustomStyle>;
}}
}

View file

@ -18,19 +18,19 @@
#include <cstdint>
namespace mbst { namespace ImportExport { namespace Keys {
namespace mbst::ImportExport::Keys {
enum CustomStyle: std::uint8_t {
Name = 0, // type: string
Colour = 1, // type: Magnum::Color4
Metallic = 2, // type: float
Gloss = 3, // type: float
Glow = 4, // type: bool
PatternId = 5, // type: std::int32_t
PatternOpacity = 6, // type: float
PatternOffset = 7, // type: Magnum::Vector2
Name = 0, // type: string
Colour = 1, // type: Magnum::Color4
Metallic = 2, // type: float
Gloss = 3, // type: float
Glow = 4, // type: bool
PatternId = 5, // type: std::int32_t
PatternOpacity = 6, // type: float
PatternOffset = 7, // type: Magnum::Vector2
PatternRotation = 8, // type: float
PatternScale = 9, // type: float
PatternScale = 9, // type: float
};
}}}
}

View file

@ -23,7 +23,7 @@
using namespace Corrade;
namespace mbst { namespace Managers {
namespace mbst::Managers {
struct Backup {
Containers::String filename;
@ -40,4 +40,4 @@ struct Backup {
Containers::Array<Containers::String> includedFiles;
};
}}
}

View file

@ -33,7 +33,7 @@
#include "BackupManager.h"
namespace mbst { namespace Managers {
namespace mbst::Managers {
BackupManager::BackupManager():
_root{""}
@ -335,4 +335,4 @@ BackupManager::scanSubdir(Containers::StringView subdir) {
depth--;
}
}}
}

View file

@ -29,7 +29,7 @@
using namespace Corrade;
namespace mbst { namespace Managers {
namespace mbst::Managers {
class BackupManager {
public:
@ -60,4 +60,4 @@ class BackupManager {
Vfs::Directory<Backup> _root;
};
}}
}

View file

@ -26,7 +26,7 @@
using namespace Containers::Literals;
namespace mbst { namespace Managers {
namespace mbst::Managers {
MassManager::MassManager(Containers::StringView account, bool demo):
_account{account}, _demo{demo}
@ -268,4 +268,4 @@ MassManager::deleteStagedMass(Containers::StringView filename) {
return true;
}
}}
}

View file

@ -26,7 +26,7 @@
using namespace Corrade;
namespace mbst { namespace Managers {
namespace mbst::Managers {
class MassManager {
public:
@ -60,4 +60,4 @@ class MassManager {
std::map<Containers::String, Containers::String> _stagedMasses;
};
}}
}

Some files were not shown because too many files have changed in this diff Show more