Skip to content

Commit

Permalink
Merge pull request #4 from Earthmark/earthmark-dev
Browse files Browse the repository at this point in the history
Fixed windows having a terminal in release, and rendering being broken by default.
  • Loading branch information
Earthmark authored Feb 27, 2022
2 parents c67ff54 + bcade57 commit 8c1269b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 14 deletions.
16 changes: 3 additions & 13 deletions src/level.rs
Original file line number Diff line number Diff line change
Expand Up @@ -169,8 +169,9 @@ impl Default for Level {
fn default() -> Self {
Self {
maze: Box::new(NullMaze),
dim_x: Default::default(),
dim_y: Default::default(),
// These must be different or the maze won't render.
dim_x: 0,
dim_y: 1,
axis: FocusedAxis::X,
joint: Default::default(),
wall: Default::default(),
Expand Down Expand Up @@ -228,16 +229,6 @@ impl Level {
new_off_axis
};

info!(
"Shifted off axis from {} to linear {} to {} with intermediate of {} with a limit of {}. Main is at {}",
current,
linear_current,
dest,
new_off_axis,
self.maze.dims(),
self.axis_current()
);

match self.axis {
FocusedAxis::X => self.dim_y = dest,
FocusedAxis::Y => self.dim_x = dest,
Expand Down Expand Up @@ -314,7 +305,6 @@ fn spawn_level_system(

fn level_generation_system(mut commands: Commands, query: Query<(Entity, &Level), Changed<Level>>) {
for (entity, level) in query.iter() {
info!("Spawning level");
commands.entity(entity).despawn_descendants();

commands.entity(entity).with_children(move |builder| {
Expand Down
2 changes: 1 addition & 1 deletion src/main.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//#![windows_subsystem = "windows"]
#![cfg_attr(not(debug_assertions), windows_subsystem = "windows")]

mod level;
mod maze;
Expand Down

0 comments on commit 8c1269b

Please sign in to comment.