aboutsummaryrefslogtreecommitdiff
path: root/stockton-levels/src/traits/models.rs
diff options
context:
space:
mode:
Diffstat (limited to 'stockton-levels/src/traits/models.rs')
-rw-r--r--stockton-levels/src/traits/models.rs10
1 files changed, 6 insertions, 4 deletions
diff --git a/stockton-levels/src/traits/models.rs b/stockton-levels/src/traits/models.rs
index ede7f78..7d1b896 100644
--- a/stockton-levels/src/traits/models.rs
+++ b/stockton-levels/src/traits/models.rs
@@ -18,6 +18,8 @@
use na::Vector3;
use std::ops::Range;
+use super::{HasFaces, HasBrushes};
+
#[derive(Debug, Clone)]
pub struct Model {
pub mins: Vector3<f32>,
@@ -26,9 +28,9 @@ pub struct Model {
pub brushes_idx: Range<u32>,
}
-pub trait HasModels<'a> {
- type ModelsIter: Iterator<Item = &'a Model>;
+pub trait HasModels: HasFaces + HasBrushes {
+ type ModelsIter<'a>: Iterator<Item = &'a Model>;
- fn models_iter(&'a self) -> Self::ModelsIter;
- fn get_model(&'a self, index: u32) -> &'a Model;
+ fn models_iter<'a>(&'a self) -> Self::ModelsIter<'a>;
+ fn get_model<'a>(&'a self, index: u32) -> &'a Model;
}