From 86ddbbd163377bf8f50462e84d7dc6204c812367 Mon Sep 17 00:00:00 2001 From: Tom Barrett Date: Fri, 24 Nov 2017 07:34:07 -0600 Subject: -made men not public, made path just given --- src/list.rs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/list.rs') diff --git a/src/list.rs b/src/list.rs index 1383394..f9990b1 100644 --- a/src/list.rs +++ b/src/list.rs @@ -1,4 +1,5 @@ use std::thread::{spawn, JoinHandle}; +use std::slice::Iter; extern crate pancurses; @@ -10,7 +11,7 @@ use character::Character; use constants::Colors; pub struct List{ - pub men : Vec, + men : Vec, impassable_locations : Vec, threads : Vec>)>> } @@ -96,6 +97,10 @@ impl List { } } + pub fn get_men(&self) -> Iter { + self.men.iter() + } + fn get_free_locations(&mut self, location : Location) -> Vec<(Location, usize)> { let mut potential_locations = location.neighbours(Vec::new()); -- cgit v1.2.3