CoolFace
Apppublic

HugoDzz/rust-sandbox

sourceHugging Facemitupdated 3y agoView on Hugging Face
11likes
setup.rs18 linesDownload Raw Back to src
1use crate::utils::constants::{GAME_RESOLUTION_X, GAME_RESOLUTION_Y};2use bevy::prelude::*;3use bevy_pixel_camera::PixelCameraBundle;4 5/*6 7    🦀 Add a new entity with the camera components8 9*/10 11pub fn setup(mut commands: Commands) {12    commands.spawn(PixelCameraBundle::from_resolution(13        GAME_RESOLUTION_X as i32,14        GAME_RESOLUTION_Y as i32,15        true,16    ));17}18