equal
deleted
inserted
replaced
47 use mapgen::{theme::Theme, MapGenerator}; |
47 use mapgen::{theme::Theme, MapGenerator}; |
48 use std::path::Path; |
48 use std::path::Path; |
49 |
49 |
50 if let Some(ref state) = self.game_state { |
50 if let Some(ref state) = self.game_state { |
51 self.camera.position = state.land.play_box().center(); |
51 self.camera.position = state.land.play_box().center(); |
52 |
52 |
53 let theme = |
53 let theme = |
54 Theme::load(Path::new("../../share/hedgewars/Data/Themes/Cheese/")).unwrap(); |
54 Theme::load(Path::new("../../share/hedgewars/Data/Themes/Cheese/")).unwrap(); |
55 let texture = MapGenerator::new().make_texture(&state.land, &theme); |
55 let texture = MapGenerator::new().make_texture(&state.land, &theme); |
56 if let Some(ref mut renderer) = self.renderer { |
56 if let Some(ref mut renderer) = self.renderer { |
57 renderer.init(&texture); |
57 renderer.init(&texture); |