diff options
Diffstat (limited to 'src/map.rs')
-rw-r--r-- | src/map.rs | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/map.rs b/src/map.rs index 31bc9a3dbe38..dd1fe1c6347e 100644 --- a/src/map.rs +++ b/src/map.rs @@ -1,9 +1,9 @@ //! Implements a map graph and world logic -use crate::data::{Node, Link}; -use std::collections::BTreeMap; +use crate::data::{Link, Node}; use async_std::sync::Arc; - +use serde::{Deserialize, Serialize}; +use std::collections::BTreeMap; /// A map that people fight on /// @@ -11,9 +11,12 @@ use async_std::sync::Arc; /// the map nodes are placed, how much spacing there is, etc. All /// this information is encoded in the same structs because it's /// static, and just more convenient. +#[derive(Serialize, Deserialize)] pub struct Map { /// Node IDs mapped to node objects nodes: BTreeMap<u16, Arc<Node>>, /// Link IDs mapped to link objects links: BTreeMap<u16, Arc<Link>>, } + +impl Map {} |