-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Embedded the game assets in the binary
- Loading branch information
1 parent
dc11211
commit 4fac60e
Showing
5 changed files
with
141 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../../assets/kenney_racing-pack/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../../assets/level1.tmx |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,108 @@ | ||
// SPDX-License-Identifier: GPL-3.0-or-later | ||
// Copyright (C) 2024 Daniel Thompson | ||
|
||
use bevy::asset::embedded_asset; | ||
|
||
#[derive(Default)] | ||
pub struct Plugin; | ||
|
||
impl bevy::prelude::Plugin for Plugin { | ||
fn build(&self, app: &mut bevy::prelude::App) { | ||
embedded_asset!(app, "src/", "level1.tmx"); | ||
|
||
embedded_asset!(app, "src/", "kenney_racing-pack/PNG/Cars/car_red_5.png"); | ||
embedded_asset!(app, "src/", "kenney_racing-pack/PNG/Cars/car_blue_1.png"); | ||
embedded_asset!(app, "src/", "kenney_racing-pack/PNG/Cars/car_yellow_3.png"); | ||
embedded_asset!(app, "src/", "kenney_racing-pack/PNG/Cars/car_green_4.png"); | ||
embedded_asset!( | ||
app, | ||
"src/", | ||
"kenney_racing-pack/Spritesheets/spritesheet_tiles.png" | ||
); | ||
embedded_asset!( | ||
app, | ||
"src/", | ||
"kenney_racing-pack/Spritesheets/spritesheet_tiles.png" | ||
); | ||
embedded_asset!( | ||
app, | ||
"src/", | ||
"kenney_racing-pack/Spritesheets/spritesheet_tiles.png" | ||
); | ||
embedded_asset!( | ||
app, | ||
"src/", | ||
"kenney_racing-pack/Spritesheets/spritesheet_tiles.png" | ||
); | ||
embedded_asset!( | ||
app, | ||
"src/", | ||
"kenney_racing-pack/PNG/Tiles/Grass/land_grass01.png" | ||
); | ||
embedded_asset!( | ||
app, | ||
"src/", | ||
"kenney_racing-pack/PNG/Tiles/Grass/land_grass02.png" | ||
); | ||
embedded_asset!( | ||
app, | ||
"src/", | ||
"kenney_racing-pack/PNG/Tiles/Grass/land_grass03.png" | ||
); | ||
embedded_asset!( | ||
app, | ||
"src/", | ||
"kenney_racing-pack/PNG/Tiles/Grass/land_grass04.png" | ||
); | ||
embedded_asset!( | ||
app, | ||
"src/", | ||
"kenney_racing-pack/PNG/Tiles/Grass/land_grass05.png" | ||
); | ||
embedded_asset!( | ||
app, | ||
"src/", | ||
"kenney_racing-pack/PNG/Tiles/Grass/land_grass06.png" | ||
); | ||
embedded_asset!( | ||
app, | ||
"src/", | ||
"kenney_racing-pack/PNG/Tiles/Grass/land_grass07.png" | ||
); | ||
embedded_asset!( | ||
app, | ||
"src/", | ||
"kenney_racing-pack/PNG/Tiles/Grass/land_grass08.png" | ||
); | ||
embedded_asset!( | ||
app, | ||
"src/", | ||
"kenney_racing-pack/PNG/Tiles/Grass/land_grass09.png" | ||
); | ||
embedded_asset!( | ||
app, | ||
"src/", | ||
"kenney_racing-pack/PNG/Tiles/Grass/land_grass10.png" | ||
); | ||
embedded_asset!( | ||
app, | ||
"src/", | ||
"kenney_racing-pack/PNG/Tiles/Grass/land_grass11.png" | ||
); | ||
embedded_asset!( | ||
app, | ||
"src/", | ||
"kenney_racing-pack/PNG/Tiles/Grass/land_grass12.png" | ||
); | ||
embedded_asset!( | ||
app, | ||
"src/", | ||
"kenney_racing-pack/PNG/Tiles/Grass/land_grass13.png" | ||
); | ||
embedded_asset!( | ||
app, | ||
"src/", | ||
"kenney_racing-pack/PNG/Tiles/Grass/land_grass14.png" | ||
); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters