From df632447fd95d8040819220c2c7a6f138766eb50 Mon Sep 17 00:00:00 2001 From: rasul Date: Sun, 5 Apr 2020 15:55:25 -0500 Subject: [PATCH] document Zone struct --- src/world/zone.rs | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/world/zone.rs b/src/world/zone.rs index 8b55e3d..592acf0 100644 --- a/src/world/zone.rs +++ b/src/world/zone.rs @@ -9,12 +9,22 @@ use serde_derive::{Deserialize, Serialize}; use crate::id::Id; use crate::world::{Area, AreaType}; +/// A collection of rooms and/or other zones. #[derive(Debug, Deserialize, Serialize)] pub struct Zone { + /// Unique identifier for the zone pub id: Id, + + /// Identifier of the parent zone pub parent: Id, + + /// Name of the zone pub name: String, + + /// Whether players in the zone should be visible on where to the parent pub users_visible: bool, + + /// Areas contained inside this zone pub areas: HashSet, }