FiveM CoraUI LUA Version

FiveM-CoraUI

Library written in typescript to create menus on FiveM
Support LUA version

Link : GitHub - hoyame/coraui at lua

Example

RegisterCommand('testMenu', function() 
    exports.coraui:CreateMenu({
        name = 'Feff',
        subtitle = 'Principal',
        glare = true,
        buttons = {
            { name = "Submenu uruspu", onClick = function()
                exports.coraui:CreateSubmenu("uruspu")
            end},

            { name = "Submenu sujuc", onClick = function()
                exports.coraui:CreateSubmenu("sujuc")
            end},

            { name = "Checkbox", checkbox = function(bool)
                print(bool)
            end},

            { name = "Rightlabel", rightText = "~g~260 000 $", onClick = function()

            end},

            { name = "Slider", onSlide = function(z)
                print("Button clicked  " .. z)
            end, slider = {"ananasikim", "sikimiyalla", "sitch"}},

            { name = "Close", onClick = function()
                exports.coraui:CloseMenu()
            end}
        },

        submenus = {
            ["uruspu"] = {
                name = "uruspu",
                subtitle = 'Secondaire 1',
                glare = true,
                buttons = {
                    { name = "uruspu1" },
                    { name = "uruspu2" }
                }
            },

            ["sujuc"] = {
                name = "sujuc",
                subtitle = 'Secondaire 2',
                glare = true,
                buttons = {
                    { name = "sujuc1" },
                    { name = "sujuc2" }
                }
            }
        }
    }) 
end)

Requirements

  • coraui (not rename/delete)
2 Likes

What about resmon?

my eyes, my love for low resmon, ur hurting it! :cry:

1 Like

anyway having a low resmon is not essential, especially that 0.32ms only during the opening, I do not know if there is a way to use DrawRect without consuming CPU :confused:

no, better decision is going with HTML / JS / CSS

2 Likes

It is difficult to create something beautiful that fits all server styles in html/css, I had already tried but it did not result in something beautiful

you would like a nice menu in html/css ?

because if you are many to ask, I pay a ui designer and I make the library and I publish it :slight_smile:

Well, to be honest I think there is nothing else fitting to FiveM than making the UI in HTML - I guess no server will be needing a UI in pure LUA because it just makes it unplayable taking in consideration all the other resources that are already not optimized.

IF you can comeup with something new, something that is better than the ox_lib or ESX_MENU_DEFUALT / DIALOG / LIST (maybe also easier to use) then go for it. But just think of all the others alternative - it would’nt be useful if you make something there already exists.
Cheers!

I didn’t create it to please this community, but because I needed it. If you had taken the time to look at the code, it’s written in TypeScript. Is there a way to easily create a menu in TypeScript? Are there any default ports for esx-menu or RageUI/Native UI?

No, there is no possibility of creating a menu other than going through Lua. The goal was to create a game mode entirely written in TypeScript, so I created this library solely for that purpose and decided to publish it at the request of certain people. If you don’t want to use it, don’t use it, I don’t care :slight_smile: