summaryrefslogtreecommitdiffhomepage
path: root/serialize/ground-atlas.hpp
blob: e74792a5092a6b85dd0bd0c4de9808cc14ffa5a1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#pragma once
#include "compat/borrowed-ptr.hpp"
#include <nlohmann/json_fwd.hpp>

namespace floormat {

struct ground_def;
struct ground_cell;
class ground_atlas;

} // namespace floormat

namespace nlohmann {

template<>
struct adl_serializer<floormat::ground_def> final {
    static void to_json(json& j, const floormat::ground_def& x);
    static void from_json(const json& j, floormat::ground_def& x);
};

template<>
struct adl_serializer<floormat::bptr<floormat::ground_atlas>> final {
    static void to_json(json& j, const floormat::bptr<const floormat::ground_atlas>& x);
    static void from_json(const json& j, floormat::bptr<floormat::ground_atlas>& x);
};

template<>
struct adl_serializer<floormat::ground_cell> final {
    static void to_json(json& j, const floormat::ground_cell& x);
    static void from_json(const json& j, floormat::ground_cell& x);
};

} // namespace nlohmann