Change font
This commit is contained in:
Binary file not shown.
@@ -1,5 +1,4 @@
|
|||||||
pub const WINDOW_TITLE: &str = "Solitaire Chess";
|
pub const WINDOW_TITLE: &str = "Solitaire Chess";
|
||||||
pub const HEADING_TEXT: &str = "Solitaire Chess";
|
|
||||||
pub const VOLUME: f32 = 0.1; // Between 0 and 1
|
pub const VOLUME: f32 = 0.1; // Between 0 and 1
|
||||||
pub const SCREEN_HEIGHT_MIN: f32 = 200.0;
|
pub const SCREEN_HEIGHT_MIN: f32 = 200.0;
|
||||||
pub const SCREEN_HEIGHT_MAX: f32 = 10000.0;
|
pub const SCREEN_HEIGHT_MAX: f32 = 10000.0;
|
||||||
@@ -25,6 +24,7 @@ pub const BUTTON_WIDTH_MULTIPLIER: f32 = 0.20;
|
|||||||
// Gap between the bottom of the row and the first row of buttons
|
// Gap between the bottom of the row and the first row of buttons
|
||||||
pub const BOTTOM_BUTTON_ROW_OFFSET_MULTIPLIER: f32 = 0.3;
|
pub const BOTTOM_BUTTON_ROW_OFFSET_MULTIPLIER: f32 = 0.3;
|
||||||
|
|
||||||
|
pub const HEADING_TEXT: &str = "Solitaire Chess";
|
||||||
pub const RESET_BUTTON_TEXT: &str = "RESET";
|
pub const RESET_BUTTON_TEXT: &str = "RESET";
|
||||||
pub const NEXT_BUTTON_TEXT: &str = "NEXT";
|
pub const NEXT_BUTTON_TEXT: &str = "NEXT";
|
||||||
pub const RULES_BUTTON_TEXT: &str = "RULES";
|
pub const RULES_BUTTON_TEXT: &str = "RULES";
|
||||||
|
|||||||
@@ -220,7 +220,7 @@ impl Game {
|
|||||||
};
|
};
|
||||||
draw_multiline_text_ex(
|
draw_multiline_text_ex(
|
||||||
rules,
|
rules,
|
||||||
self.board_rect.x + 0.05 * self.square_width,
|
self.board_rect.x + 0.5 * self.square_width,
|
||||||
self.board_rect.y + 0.5 * (self.board_rect.h - measurement.height)
|
self.board_rect.y + 0.5 * (self.board_rect.h - measurement.height)
|
||||||
- 2. * measurement.offset_y,
|
- 2. * measurement.offset_y,
|
||||||
Some(2.),
|
Some(2.),
|
||||||
|
|||||||
+1
-1
@@ -62,7 +62,7 @@ async fn init() -> Game {
|
|||||||
mode,
|
mode,
|
||||||
};
|
};
|
||||||
|
|
||||||
let font_ttf = include_bytes!("../assets/caskaydia.ttf");
|
let font_ttf = include_bytes!("../assets/Junction-regular.otf");
|
||||||
let Ok(font) = load_ttf_font_from_bytes(font_ttf) else {
|
let Ok(font) = load_ttf_font_from_bytes(font_ttf) else {
|
||||||
panic!("Failed to load font");
|
panic!("Failed to load font");
|
||||||
};
|
};
|
||||||
|
|||||||
+1
-1
@@ -1 +1 @@
|
|||||||
cargo build --target wasm32-unknown-unknown --release && scp target/wasm32-unknown-unknown/release/sol_chess.wasm potato@neophyte.me:~/site/games/sol_chess/.
|
cargo build -p sol_chess --target wasm32-unknown-unknown --release && scp target/wasm32-unknown-unknown/release/sol_chess.wasm potato@neophyte.me:~/site/games/sol_chess/.
|
||||||
|
|||||||
+1
-1
@@ -43,7 +43,7 @@ build_web() {
|
|||||||
echo "Archive directory: ${ARCHIVE_DIR}"
|
echo "Archive directory: ${ARCHIVE_DIR}"
|
||||||
|
|
||||||
set -x
|
set -x
|
||||||
cargo build --target wasm32-unknown-unknown ${BUILD_PROFILE_SWITCH}
|
cargo build -p ${BINARY_NAME} --target wasm32-unknown-unknown ${BUILD_PROFILE_SWITCH}
|
||||||
set +x
|
set +x
|
||||||
if [ $? -ne 0 ]; then
|
if [ $? -ne 0 ]; then
|
||||||
echo "Wasm build failed"
|
echo "Wasm build failed"
|
||||||
|
|||||||
Reference in New Issue
Block a user