Fix window size
This commit is contained in:
parent
4f96be8fa6
commit
924df55e18
12
src/ui.rs
12
src/ui.rs
@ -7,7 +7,15 @@ struct Position2D(i32, i32);
|
|||||||
|
|
||||||
fn main() -> Result<(), Box<dyn Error>> {
|
fn main() -> Result<(), Box<dyn Error>> {
|
||||||
App::new()
|
App::new()
|
||||||
.add_plugins(DefaultPlugins)
|
.add_plugins(DefaultPlugins.set(WindowPlugin {
|
||||||
|
window: WindowDescriptor {
|
||||||
|
title: "DLA Static 2D Render".to_string(),
|
||||||
|
width: 800.,
|
||||||
|
height: 800.,
|
||||||
|
..default()
|
||||||
|
},
|
||||||
|
..default()
|
||||||
|
}))
|
||||||
.add_startup_system(setup_ui)
|
.add_startup_system(setup_ui)
|
||||||
.add_startup_system(read_csv)
|
.add_startup_system(read_csv)
|
||||||
.run();
|
.run();
|
||||||
@ -47,7 +55,7 @@ fn read_csv(
|
|||||||
|
|
||||||
for Position2D(x, y) in positions {
|
for Position2D(x, y) in positions {
|
||||||
// Rectangle
|
// Rectangle
|
||||||
let rect_size = 10.0;
|
let rect_size = 5.0;
|
||||||
println!("{} {}", x, y);
|
println!("{} {}", x, y);
|
||||||
|
|
||||||
commands.spawn(SpriteBundle {
|
commands.spawn(SpriteBundle {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user