Hi Im going through the quick start on https://bevyengine.org/learn/quick-start/getting-started/ecs/
I have copied the
fn add_people(mut commands: Commands) {
commands.spawn((Person, Name("Elaina Proctor".to_string())));
commands.spawn((Person, Name("Renzo Hume".to_string())));
commands.spawn((Person, Name("Zayna Nieves".to_string())));
}
function into rustrover and while it compiles just fine its strangely giving the Trait Component is not implemented for (Person, Name)error on the first one only
https://i.imgur.com/WlRaAyw.png
there is definitely something funny going on environment wise and there is nothing on google about it, so i was wondering if anyone here had a similar issue/fix
full main.rs file just in case
use bevy::prelude::*;
fn main() {
App::new()
.add_systems(Startup, add_people)
.run();
}
fn add_people(mut commands: Commands){
commands.spawn((Person, Name("Elaina Proctor".to_string())));
commands.spawn((Person, Name("Renzo Hume".to_string())));
commands.spawn((Person, Name("Zayna Nieves".to_string())));
}
#[derive(Component)]
struct Person;
#[derive(Component)]
struct Name(String);