Added window size limits and cursor rendering...
This commit is contained in:
parent
3c4816c6ee
commit
4b274bf2e5
@ -445,7 +445,12 @@ package body core is
|
||||
echo (comment, "-- -- Window title : Xorana");
|
||||
echo (comment, "-- -- Window width : 1800");
|
||||
echo (comment, "-- -- Window height : 900");
|
||||
--
|
||||
ray.open_window (1800, 900, c_string ("Xorana"));
|
||||
ray.hide_cursor;
|
||||
--
|
||||
ray.set_window_minimal_size (640, 480);
|
||||
ray.set_window_maximal_size (3840, 2160);
|
||||
--
|
||||
--~echo (comment, "-- Initializing Raylib audio device data...");
|
||||
--~ray.open_audio_device;
|
||||
@ -483,6 +488,7 @@ package body core is
|
||||
--
|
||||
echo (comment, "-- Deinitializing Raylib window data...");
|
||||
ray.close_window;
|
||||
ray.show_cursor;
|
||||
--
|
||||
echo (success, "Deinitialized core components.");
|
||||
end deinitialize;
|
||||
|
@ -264,10 +264,10 @@ begin
|
||||
|
||||
core.cursor_mode := core.cursor_none;
|
||||
|
||||
ui.active := ui.style'val (faction.enumeration'pos (chad.trait (player.index).kind) + 1);
|
||||
|
||||
world.load ("heyo");
|
||||
|
||||
ui.active := ui.style'val (faction.enumeration'pos (chad.trait (player.index).kind) + 1);
|
||||
|
||||
gameplay_loop: loop
|
||||
core.synchronize;
|
||||
--
|
||||
|
@ -172,11 +172,13 @@ package ray is
|
||||
|
||||
procedure window_icon (icon : in image) with import => true, convention => c, external_name => "SetWindowIcon";
|
||||
|
||||
--~void SetWindowMinSize(int width, int height);
|
||||
--~void SetWindowMaxSize(int width, int height);
|
||||
--~void SetWindowSize(int width, int height);
|
||||
--~void ShowCursor(void);
|
||||
--~void HideCursor(void);
|
||||
procedure show_cursor with import => true, convention => c, external_name => "ShowCursor";
|
||||
procedure hide_cursor with import => true, convention => c, external_name => "HideCursor";
|
||||
|
||||
procedure set_window_minimal_size (width, height : in integer) with import => true, convention => c, external_name => "SetWindowMinSize";
|
||||
procedure set_window_maximal_size (width, height : in integer) with import => true, convention => c, external_name => "SetWindowMaxSize";
|
||||
procedure set_window_size (width, height : in integer) with import => true, convention => c, external_name => "SetWindowSize";
|
||||
|
||||
--~double GetTime(void);
|
||||
--~void OpenURL(const char *url);
|
||||
function load_text (file : in string) return char_array with import => true, convention => c, external_name => "LoadFileText";
|
||||
|
@ -256,6 +256,8 @@ package body ui is
|
||||
end if;
|
||||
end loop;
|
||||
--
|
||||
draw (cursor, core.cursor.x, core.cursor.y);
|
||||
--
|
||||
if read_text_box /= "--" then
|
||||
draw_popup_box;
|
||||
end if;
|
||||
|
Loading…
Reference in New Issue
Block a user