summaryrefslogtreecommitdiff
path: root/src/encyclopedia.rs
diff options
context:
space:
mode:
authortroido <troido@protonmail.com>2020-02-08 19:22:00 +0100
committertroido <troido@protonmail.com>2020-02-08 19:22:00 +0100
commitb56add981c2f520789b97d1ee6f71dae41e8c900 (patch)
treedca7d8795c2a51f56173153c286c4dadcf8daff4 /src/encyclopedia.rs
parent3ebe9e6f792a0457c6f3b37b6e9d92c83f8694e2 (diff)
no templates in the world; only pre-entities
Diffstat (limited to 'src/encyclopedia.rs')
-rw-r--r--src/encyclopedia.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/encyclopedia.rs b/src/encyclopedia.rs
index 5cdf90c..6851a06 100644
--- a/src/encyclopedia.rs
+++ b/src/encyclopedia.rs
@@ -2,7 +2,7 @@
use std::collections::HashMap;
use serde_json::Value;
use crate::assemblage::Assemblage;
-use crate::componentwrapper::ComponentWrapper;
+use crate::componentwrapper::PreEntity;
use crate::template::Template;
#[derive(Default, Clone)]
@@ -20,7 +20,7 @@ impl Encyclopedia {
Ok(Encyclopedia{items})
}
- pub fn construct(&self, template: &Template) -> Result<Vec<ComponentWrapper>, &'static str> {
+ pub fn construct(&self, template: &Template) -> Result<PreEntity, &'static str> {
let assemblage = self.items.get(&template.name).ok_or("unknown assemblage name")?;
assemblage.instantiate(&template.args, &template.kwargs)
}