diff options
author | San Jacobs | 2025-10-02 13:32:38 +0200 |
---|---|---|
committer | San Jacobs | 2025-10-02 13:32:38 +0200 |
commit | e7291bc1e3dfff7793a22e5350f74584947bb459 (patch) | |
tree | f65c6f11a084d784be205ba597c7c5addc110823 /src | |
parent | 44c9db3ff6445cf9e58dd5f18a33a95581fbdd14 (diff) | |
download | tafl-e7291bc1e3dfff7793a22e5350f74584947bb459.tar.gz tafl-e7291bc1e3dfff7793a22e5350f74584947bb459.tar.bz2 tafl-e7291bc1e3dfff7793a22e5350f74584947bb459.zip |
Adjustments
Diffstat (limited to 'src')
-rw-r--r-- | src/main.odin | 2 | ||||
-rw-r--r-- | src/tafl/Inter_24pt-Medium.ttf | bin | 0 -> 342936 bytes | |||
-rw-r--r-- | src/tafl/tafl.odin | 10 |
3 files changed, 6 insertions, 6 deletions
diff --git a/src/main.odin b/src/main.odin index 7533cab..334ac08 100644 --- a/src/main.odin +++ b/src/main.odin @@ -5,7 +5,7 @@ import t "tafl" main :: proc() { - width, height : i32 = 1920, 1080 + width, height : int = 1920, 1080 t.start_window(width, height, "tafl test") diff --git a/src/tafl/Inter_24pt-Medium.ttf b/src/tafl/Inter_24pt-Medium.ttf Binary files differnew file mode 100644 index 0000000..5c88739 --- /dev/null +++ b/src/tafl/Inter_24pt-Medium.ttf diff --git a/src/tafl/tafl.odin b/src/tafl/tafl.odin index a83be1e..2b3993e 100644 --- a/src/tafl/tafl.odin +++ b/src/tafl/tafl.odin @@ -6,7 +6,7 @@ import "core:strings" import rl "vendor:raylib" import "core:c" -__DEFAULT_FONT_FILE :: #load("../../res/Inter_24pt-Medium.ttf") +__DEFAULT_FONT_FILE :: #load("Inter_24pt-Medium.ttf") tafl_elements : [4096]Tafl tafl_elements_count : int @@ -496,11 +496,11 @@ position_pass :: proc() { } } -start_window :: proc(width, height : i32, title : cstring, fps_target : int = 60) { +start_window :: proc(width, height : int, title : cstring, fps_target : int = 60) { rl.SetWindowMinSize(800,600) rl.SetTargetFPS(60) rl.SetConfigFlags({.WINDOW_RESIZABLE}) - rl.InitWindow(width, height, title) + rl.InitWindow(i32(width), i32(height), title) DEFAULT_FONT = rl.LoadFontFromMemory(".ttf", raw_data(__DEFAULT_FONT_FILE), i32(len(__DEFAULT_FONT_FILE)), i32(FONT_SIZE), nil, 0) } @@ -512,8 +512,8 @@ resized :: proc() -> (resized: bool) { return rl.IsWindowResized() } -get_window_size :: proc() -> (i32, i32) { - return rl.GetScreenWidth(), rl.GetScreenHeight() +get_window_size :: proc() -> (int, int) { + return int(rl.GetScreenWidth()), int(rl.GetScreenHeight()) } process_features :: proc() { |