chore(all): fix warnings

This commit is contained in:
lisk77 2025-11-02 13:14:41 +01:00
parent c7f0412eff
commit 81bc1cb790
14 changed files with 471 additions and 513 deletions

View file

@ -1,17 +1,19 @@
use comet::prelude::*;
// This function will only be called once before the event loop starts.
#[allow(unused_variables)]
fn setup(app: &mut App, renderer: &mut Renderer2D) {}
// This function will be called on every tick after the event loop starts.
#[allow(unused_variables)]
fn update(app: &mut App, renderer: &mut Renderer2D, dt: f32) {}
fn main() {
// This creates a window with the title "Hello world".
// Note: You can call your functions differently if you want to though it is advised to use
// `setup` and `update` as the names.
// You can also replace `Renderer2D` with any other struct that implements the `Renderer` trait.
App::new()
.with_title("Hello world")
.run::<Renderer2D>(setup, update);
}
// This creates a window with the title "Hello world".
// Note: You can call your functions differently if you want to though it is advised to use
// `setup` and `update` as the names.
// You can also replace `Renderer2D` with any other struct that implements the `Renderer` trait.
App::new()
.with_title("Hello world")
.run::<Renderer2D>(setup, update);
}

View file

@ -43,6 +43,7 @@ fn setup(app: &mut App, renderer: &mut Renderer2D) {
}
}
#[allow(unused_variables)]
fn update(app: &mut App, renderer: &mut Renderer2D, dt: f32) {}
fn main() {

View file

@ -26,6 +26,7 @@ fn setup(app: &mut App, renderer: &mut Renderer2D) {
);
}
#[allow(unused_variables)]
fn update(app: &mut App, renderer: &mut Renderer2D, dt: f32) {
// Getting the windows size
let size = renderer.size();

View file

@ -18,6 +18,7 @@ fn setup(app: &mut App, renderer: &mut Renderer2D) {
app.add_component(e0, render);
}
#[allow(unused_variables)]
fn update(app: &mut App, renderer: &mut Renderer2D, dt: f32) {
renderer.render_scene_2d(app.scene_mut())
}