Merge branch 'fix-no-robots-bugs' into 'master'
No robots was displayed on the grid, it's now fix See merge request mhart/DancingDroids!53
This commit is contained in:
		
						commit
						20038880f3
					
				@ -253,8 +253,9 @@ fn main() -> Result<(), Box<dyn std::error::Error>> {
 | 
				
			|||||||
    let raw_conf = open_file(matches.value_of("file").unwrap_or("two_robots.txt"))?;
 | 
					    let raw_conf = open_file(matches.value_of("file").unwrap_or("two_robots.txt"))?;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    let mut robot_pool: Vec<robot::Robot> = Vec::new();
 | 
					    let mut robot_pool: Vec<robot::Robot> = Vec::new();
 | 
				
			||||||
    let world: world::World = match matches.is_present("random-world") {
 | 
					    let mut world: world::World = parse_config(raw_conf, &mut robot_pool)?;
 | 
				
			||||||
        false => parse_config(raw_conf, &mut robot_pool)?,
 | 
					    world = match matches.is_present("random-world") {
 | 
				
			||||||
 | 
					        false => world,
 | 
				
			||||||
        true => world::random_world(),
 | 
					        true => world::random_world(),
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user