Qube's Game Framework - The dreaded GUI

Started by Qube, April 09, 2019, 01:19:33

Previous topic - Next topic

Qube

IT'S DONE!!! ;D

Just over two months ago I started this project :o - Squeezing in every bit of spare time I had I'm finally finished with phase 1 of the project ( the GUI and GUI designer ).

Quick outline of how it all flows.

The GUI designer - A bit of a nightmare at times to write and 50% more code wise than the actual GUI :



You can save the window to reload at a later date for any additional tweaks :



The designer also creates the full source code for the window and control logic. You can save the source code or dump it into the clipboard for easy pasting direct into your app :



Let's create a super simple test of a window with a text box and a button. When you click the button is simply adds "Hello" into the text box :



The designer outputs the code to create the window and gadgets :



And also creates the logic for all possible events for each gadget in that window with a little helper text :



But as all we want is the action from a button click we'll delete most of it and add to the button click action :



Here's what the main control loop looks like to control the GUI. Simply insert your created GUI and off you go :

I've split it up into sections in case I need to do any custom work in between ( you never know ).

#Note : The "qGameFramework" handles setting up the screen and stuff, hence why no commands are in this example.



The final working result of this advanced test :



Thrilling I know :P

I'm sure I'll be adding more gadgets and features over time but for now I have everything I need to build the game tools I want. It's a massive time saver to visually do a GUI and have the source code spat out as all you have to do then is code where needed.

Now I can start on my next project which is a shiny new map maker with some swishy wishy features ;D
Mac Studio M1 Max ( 10 core CPU - 24 core GPU ), 32GB LPDDR5, 512GB SSD,
Beelink SER7 Mini Gaming PC, Ryzen 7 7840HS 8-Core 16-Thread 5.1GHz Processor, 32G DDR5 RAM 1T PCIe 4.0 SSD
MSI MEG 342C 34" QD-OLED Monitor

Until the next time.

iWasAdam

Just, really well done on completing this  8)
No suggestions, just admiration.

Steve Elliott

Great stuff.  Congrats on completing  :D
Win11 64Gb 12th Gen Intel i9 12900K 3.2Ghz Nvidia RTX 3070Ti 8Gb
Win11 16Gb 12th Gen Intel i5 12450H 2Ghz Nvidia RTX 2050 8Gb
Win11  Pro 8Gb Celeron Intel UHD Graphics 600
Win10/Linux Mint 16Gb 4th Gen Intel i5 4570 3.2GHz, Nvidia GeForce GTX 1050 2Gb
macOS 32Gb Apple M2Max
pi5 8Gb
Spectrum Next 2Mb

Dabz

Intel Core i5 6400 2.7GHz, NVIDIA GeForce GTX 1070 (8GB), 16Gig DDR4 RAM, 256GB SSD, 1TB HDD, Windows 10 64bit

Qube

Thanks :) took way longer than anticipated. I first thought about 3 weeks and not over two months :o - At least I can get on with the good stuff now ;D
Mac Studio M1 Max ( 10 core CPU - 24 core GPU ), 32GB LPDDR5, 512GB SSD,
Beelink SER7 Mini Gaming PC, Ryzen 7 7840HS 8-Core 16-Thread 5.1GHz Processor, 32G DDR5 RAM 1T PCIe 4.0 SSD
MSI MEG 342C 34" QD-OLED Monitor

Until the next time.

Rick Nasher

Very nice. Way to go Qube!  8)

Time to serve yourself a brewski!  ;)
_______________________________________
B3D + physics + shaders + X-platform = AGK!
:D ..ALIENBREED *LIVES* (thanks to Qube).. :D
_______________________________________