maybe I have git lfs working?

main
Jordan Orelli 2 years ago
parent d8d42a6dbb
commit c814bd3053

2
.gitattributes vendored

@ -0,0 +1,2 @@
*.kra filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text

5
.gitignore vendored

@ -1 +1,6 @@
# rust compiler output
/target
# krita temporary files
*.kra~
*.png~

BIN
art/grid-texture.kra (Stored with Git LFS)

Binary file not shown.

BIN
assets/grid-texture.png (Stored with Git LFS)

Binary file not shown.

@ -0,0 +1 @@
# a cube

@ -2,13 +2,26 @@ use bevy::prelude::*;
fn startup(
mut commands: Commands,
assets: Res<AssetServer>,
mut meshes: ResMut<Assets<Mesh>>,
mut materials: ResMut<Assets<StandardMaterial>>,
) {
//
let texture = assets.load("grid-texture.png");
//
let material = materials.add(StandardMaterial {
base_color_texture: Some(texture),
alpha_mode: AlphaMode::Opaque,
unlit: true,
..default()
});
// ground plane
commands.spawn(PbrBundle {
mesh: meshes.add(shape::Plane::from_size(5.0).into()),
material: materials.add(Color::rgb(0.3, 0.5, 0.3).into()),
material,
// material: materials.add(Color::rgb(0.3, 0.5, 0.3).into()),
..default()
});
@ -20,6 +33,7 @@ fn startup(
..default()
});
// single light source
commands.spawn(PointLightBundle {
point_light: PointLight {
intensity: 1500.0,
@ -30,6 +44,7 @@ fn startup(
..default()
});
// put a camera in the scene
commands.spawn(Camera3dBundle {
transform: Transform::from_xyz(-2.0, 2.5, 5.0).looking_at(Vec3::ZERO, Vec3::Y),
..default()

Loading…
Cancel
Save