DEVELOPMENT ENVIRONMENT

~liljamo/deck-builder

4fada74d49e3a80aba6948b0aba1f199935cab46 — Jonni Liljamo 1 year, 7 months ago 54992d4
feat(client): click thing for cards
1 files changed, 5 insertions(+), 0 deletions(-)

M client/src/plugins/game/card/mod.rs
M client/src/plugins/game/card/mod.rs => client/src/plugins/game/card/mod.rs +5 -0
@@ 150,6 150,11 @@ fn on_spawn_card(
                OnPointer::<Out>::target_component_mut::<Transform>(|_out, transform| {
                    transform.translation.y -= 0.2;
                }),
                OnPointer::<Click>::target_component_mut::<VisualCard>(|click, card| {
                    if click.button == PointerButton::Primary {
                        println!("clickered");
                    }
                }),
            )
        );
        commands.entity(entity).with_children(|parent| {