Good FrameWork Rate it 10/10
To answer it simply install it to follow the instructions simply !
The answer is sadly wrong. Thats what I did i do not understand how to make it work, thats reason i asked for help…
P.S. Lets use our mind a little bit
Show me the resource and the customer and I would say where are the concerns …
i downloaded and installed it like any other resource, but it only says usage , i dont how what im supposed to do. I am trying to make a menu like this https://gyazo.com/669f7edecd9552ae2fb6e1201ccb57c5
like where tf do i write the usage, do i have to do anything with the warmenu.lua, what do i do with the api?
You have an example of menu in the tab “use” then all the APIs are list and indicate the values also and if with this you can not do it we can not help you more without making your menu in your place Sadly
At worst download a script with a menu in Warmenu and train you to better understand the operation
so where do i put the api code? and where do i put the usage code? is it a client.lua or server.lua
client.lua
both?
Yes the warmenu is a customer and the use is done in client also
Hi there I was wondering how I could make this menu usable only by a certain group. This is what I’v got so far but it doesn’t work. Can anyone help? I’m pretty new to this.
local Tunnel = module("vrp", "lib/Tunnel")
local Proxy = module("vrp", "lib/Proxy")
vRP = Proxy.getInterface("vRP")
MySQL = module("vrp_mysql", "MySQL")
Citizen.CreateThread(function()
WarMenu.CreateMenu('main', 'Do /onduty')
WarMenu.CreateMenu('ems', 'EMS')
WarMenu.CreateSubMenu('closeMenu', 'main', 'Are you sure?')
while true do
if WarMenu.IsMenuOpened('main') then
if WarMenu.MenuButton('EMS', 'ems') then -- Open LEO Menu
if WarMenu.MenuButton('Exit', 'closeMenu') then -- Exit Menu
end
end
WarMenu.Display()
elseif WarMenu.IsMenuOpened('ems') then
if WarMenu.Button("Spawn Stretcher") then
ExecuteCommand("spawnstr")
WarMenu.Display()
elseif WarMenu.Button("Push Stretcher") then
ExecuteCommand("pushstr")
WarMenu.Display()
elseif WarMenu.Button("Put/take Stretcher Out of car") then
ExecuteCommand("togglestr")
WarMenu.Display()
elseif WarMenu.Button("Open Ambulance Doors") then
ExecuteCommand("openbaydoors")
WarMenu.Display()
elseif WarMenu.Button("Get into Stretcher") then
ExecuteCommand("getintostr")
WarMenu.Display()
end
WarMenu.Display()
elseif WarMenu.IsMenuOpened('closeMenu') then
if WarMenu.Button('Yes') then
WarMenu.CloseMenu()
elseif WarMenu.MenuButton('No', 'main') then
end
WarMenu.Display()
elseif IsControlJustReleased(0, 100) then --[
local user_id = vRP.getUserId({source})
local player = vRP.getUserSource({user_id})
if vRP.hasGroup({user_id,"Medico"}) then
WarMenu.OpenMenu('main')
end
end
Citizen.Wait(0)
end
end)
This is my _resource.lua
resource_manifest_version '44febabe-d386-4d18-afbe-5e627f4af937'
description 'FiveM Lua Menu Framework'
dependency "vrp"
client_script {
'warmenu.lua'
}
server_script {
"@vrp/lib/utils.lua",
'ems.lua'
}
Is there any possibility to make a certain menu available just for EMS, for example ?
I’m trying to add some kind of group permission, but I’m not good enough to make it work.
Update 0.9.9
- Added new
WarMenu.SetTitle()
API - Added
WarMenu.MenuButton
subText optional parameter - Updated manifest format
Update 0.9.10
- Added new
WarMenu.CurrentOption()
API
Update 0.9.11
- Fixed drawing numbers as button text
Update 0.9.12
- Introduced significant performance boost
From~0.4 ms
to~0.02 ms
(~20x times faster!)
(sorry, I was young and stupid)
Update 0.9.14
- Improved button mapping
- Improved controller support
When I’m trying to name a submenu “Køretøj”, the ø looks weird.
Can I do something to make it look like other letters?
I’m using in-game font, so I guess it’s not possible.
Did you ever get this working?
Okay, thanks.