Skip to content

Commit

Permalink
Update fonts again
Browse files Browse the repository at this point in the history
  • Loading branch information
benfrankel committed Dec 30, 2023
1 parent 5659211 commit 555daba
Show file tree
Hide file tree
Showing 14 changed files with 184 additions and 117 deletions.
279 changes: 173 additions & 106 deletions Cargo.lock

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ The following assets are made by [necrashter](https://github.com/necrashter/):

### Fonts
The following assets are made by [Pyrious](https://github.com/benfrankel/):
- The fonts (`PyriousPixel-R.ttf`, `PyriousPixel-B.ttf`, and `PyriousBlocky.ttf`) are licensed under [CC0](https://creativecommons.org/public-domain/cc0/).
- The fonts (`pypx.ttf`, `pypx-B.ttf`, and `pypx-T.ttf`) are licensed under [CC0](https://creativecommons.org/public-domain/cc0/).

### Images
- The splash screen image belongs to Bevy and is not covered by any of the licenses in this repository.
Expand Down
8 changes: 4 additions & 4 deletions assets/config.ron
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
max_width: Vw(40.0),
background_color: Rgba(red: 0.106, green: 0.118, blue: 0.122, alpha: 0.850),
text_color: Rgba(red: 1.000, green: 1.000, blue: 1.000, alpha: 1.000),
font_size: Px(14.0),
font_size: Px(16.0),
),

splash_screen: SplashScreenConfig(
Expand Down Expand Up @@ -47,20 +47,20 @@
info_bar_font_size: Px(32.0),

outline_panel_width: Px(280.0),
outline_panel_font_size: Px(14.0),
outline_panel_font_size: Px(16.0),
outline_panel_header_font_size: Px(24.0),

scene_view_background_color: Rgba(red: 0.500, green: 0.500, blue: 0.500, alpha: 1.000),

code_panel_height: Px(200.0),
code_panel_font_size: Px(14.0),
code_panel_font_size: Px(16.0),
code_panel_lines_max: 10,

upgrade_panel_width: Px(280.0),
upgrade_panel_header_font_size: Px(24.0),

upgrade_button_height: Px(56.0),
upgrade_button_font_size: Px(14.0),
upgrade_button_font_size: Px(16.0),

separator_width: Px(4.0),

Expand Down
Binary file removed assets/font/PyriousBlocky.ttf
Binary file not shown.
Binary file removed assets/font/PyriousPixel-B.ttf
Binary file not shown.
Binary file removed assets/font/PyriousPixel-R.ttf
Binary file not shown.
Binary file added assets/font/pypx-B.ttf
Binary file not shown.
Binary file added assets/font/pypx-T.ttf
Binary file not shown.
Binary file added assets/font/pypx.ttf
Binary file not shown.
Binary file removed assets/image/entity/text/PyriousPixel-B.png
Binary file not shown.
Binary file added assets/image/entity/text/pypx-T.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions src/simulation/sprite_pack.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ pub struct SpritePackAssets {
pub none: Handle<TextureAtlas>,

// Text
#[asset(texture_atlas(tile_size_x = 13.0, tile_size_y = 13.0, rows = 1, columns = 94))]
#[asset(path = "image/entity/text/PyriousPixel-B.png")]
#[asset(texture_atlas(tile_size_x = 12.0, tile_size_y = 12.0, rows = 1, columns = 94))]
#[asset(path = "image/entity/text/pypx-T.png")]
pub text: Handle<TextureAtlas>,

// 1-bit
Expand Down
2 changes: 1 addition & 1 deletion src/ui/code_typer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ impl Plugin for CodeTyperPlugin {

const FILLER_CODE: &str = concat!(
" to generate lines of code!
// Install TouchOfLifePlugin, then click to spawn entities.
// Click to spawn entities after installing TouchOfLifePlugin.
",
include_str!("code_typer.rs"),
Expand Down
6 changes: 3 additions & 3 deletions src/ui/font.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,19 +11,19 @@ impl Plugin for FontPlugin {
load_internal_binary_asset!(
app,
FONT_HANDLE,
"../../assets/font/PyriousPixel-R.ttf",
"../../assets/font/pypx.ttf",
|bytes: &[u8], _path: String| Font::try_from_bytes(bytes.to_vec()).unwrap()
);
load_internal_binary_asset!(
app,
BOLD_FONT_HANDLE,
"../../assets/font/PyriousPixel-B.ttf",
"../../assets/font/pypx-B.ttf",
|bytes: &[u8], _path: String| Font::try_from_bytes(bytes.to_vec()).unwrap()
);
load_internal_binary_asset!(
app,
HEADER_FONT_HANDLE,
"../../assets/font/PyriousBlocky.ttf",
"../../assets/font/pypx-T.ttf",
|bytes: &[u8], _path: String| Font::try_from_bytes(bytes.to_vec()).unwrap()
);

Expand Down

0 comments on commit 555daba

Please sign in to comment.