summaryrefslogtreecommitdiff
path: root/src/components/mod.rs
diff options
context:
space:
mode:
authortroido <troido@protonmail.com>2020-04-16 10:54:23 +0200
committertroido <troido@protonmail.com>2020-04-16 10:54:23 +0200
commit905c6b649521296bba609db5b5c9a39008d34325 (patch)
tree8d253de507b3663399e23819bf8b4a222e7b64a5 /src/components/mod.rs
parent43bde225ebbadd0b917ca87f3164a50455a2b588 (diff)
add visit whitelist to homeportal, save and dedup its data even though it is loaded from template
Diffstat (limited to 'src/components/mod.rs')
-rw-r--r--src/components/mod.rs10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/components/mod.rs b/src/components/mod.rs
index ae50edc..176f97a 100644
--- a/src/components/mod.rs
+++ b/src/components/mod.rs
@@ -29,7 +29,7 @@ pub use ear::{
Ear
};
-use std::collections::HashMap;
+use std::collections::{HashMap, HashSet};
use specs::{
DenseVecStorage,
@@ -229,9 +229,13 @@ pub struct Build {
#[derive(Component, Debug, Clone)]
pub struct Whitelist{
- pub allowed: HashMap<String, PlayerId>
+ pub allowed: HashMap<String, HashSet<PlayerId>>
}
-
+#[derive(Component, Debug, Clone)]
+pub struct Dedup {
+ pub id: String,
+ pub priority: i64
+}