summaryrefslogtreecommitdiff
path: root/src/main.rs
diff options
context:
space:
mode:
authorHampusM <hampus@hampusmat.com>2024-08-17 13:44:22 +0200
committerHampusM <hampus@hampusmat.com>2024-08-17 13:44:22 +0200
commitad238a5b3c49ec8e12463a43db9b3a726d1a7657 (patch)
tree34cec4dfe73edc437b6c1c68f34b8cab45436970 /src/main.rs
parent60f6a0b7783d6d3684f22f8def3c1097963aa3ff (diff)
chore: create camera entity with position component
Diffstat (limited to 'src/main.rs')
-rw-r--r--src/main.rs7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/main.rs b/src/main.rs
index 81d9b6c..a93efa1 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -89,7 +89,12 @@ fn main() -> Result<(), Box<dyn Error>>
MaterialFlags::builder().use_ambient_color(true).build(),
));
- engine.spawn((Camera { current: true, ..Default::default() },));
+ engine.spawn((
+ Camera { current: true, ..Default::default() },
+ Position {
+ position: Vec3 { x: 0.0, y: 0.0, z: 3.0 },
+ },
+ ));
engine.add_sole(GlobalLight::default())?;