adding weapon menu
This commit is contained in:
@@ -0,0 +1,64 @@
|
||||
local menu = MenuV:CreateMenu(false, 'Weapon Customizer', 'topleft', 0, 195, 227, 'size-125', 'default', 'menuv', 'example_namespace')
|
||||
|
||||
if IsWeaponValid(GetHashKey("weapon_g17")) then
|
||||
local g17 = menu:AddButton({ icon = '🔫', label = 'Glock 17', value = customize, description = 'Edit your Weapon' })
|
||||
|
||||
g17:On('select', function(item, value)
|
||||
ExecuteCommand("g17")
|
||||
end)
|
||||
end
|
||||
|
||||
if IsWeaponValid(GetHashKey("weapon_mpx")) then
|
||||
local mpx = menu:AddButton({ icon = '🔫', label = 'Sig Sauer MPX', value = customize, description = 'Edit your Weapon' })
|
||||
|
||||
mpx:On('select', function(item, value)
|
||||
ExecuteCommand("mpx")
|
||||
end)
|
||||
end
|
||||
|
||||
if IsWeaponValid(GetHashKey("weapon_pp19")) then
|
||||
local pp19 = menu:AddButton({ icon = '🔫', label = 'PP-19-01', value = customize, description = 'Edit your Weapon' })
|
||||
|
||||
pp19:On('select', function(item, value)
|
||||
ExecuteCommand("pp19")
|
||||
end)
|
||||
end
|
||||
|
||||
if IsWeaponValid(GetHashKey("weapon_m870")) then
|
||||
local m870 = menu:AddButton({ icon = '🔫', label = 'Remington 870', value = customize, description = 'Edit your Weapon' })
|
||||
|
||||
m870:On('select', function(item, value)
|
||||
ExecuteCommand("m870")
|
||||
end)
|
||||
end
|
||||
|
||||
if IsWeaponValid(GetHashKey("weapon_mk18")) then
|
||||
local mk18 = menu:AddButton({ icon = '🔫', label = 'MK18', value = customize, description = 'Edit your Weapon' })
|
||||
|
||||
mk18:On('select', function(item, value)
|
||||
ExecuteCommand("mk18")
|
||||
end)
|
||||
end
|
||||
|
||||
if IsWeaponValid(GetHashKey("weapon_m45a1")) then
|
||||
local m45a1 = menu:AddButton({ icon = '🔫', label = 'M45A1', value = customize, description = 'Edit your Weapon' })
|
||||
|
||||
m45a1:On('select', function(item, value)
|
||||
ExecuteCommand("m45a1")
|
||||
end)
|
||||
end
|
||||
|
||||
if IsWeaponValid(GetHashKey("weapon_mcx")) then
|
||||
local mcx = menu:AddButton({ icon = '🔫', label = 'MCX', value = customize, description = 'Edit your Weapon' })
|
||||
|
||||
mcx:On('select', function(item, value)
|
||||
ExecuteCommand("mcx")
|
||||
end)
|
||||
end
|
||||
|
||||
RegisterCommand('weapons', function(source, args, RawCommand)
|
||||
local ped = GetPlayerPed(-1)
|
||||
MenuV:OpenMenu(menu)
|
||||
end)
|
||||
|
||||
menu:OpenWith('KEYBOARD', 'F1')
|
||||
@@ -0,0 +1,8 @@
|
||||
fx_version 'cerulean'
|
||||
games {'gta5'}
|
||||
description 'markomods addon weapon menu'
|
||||
|
||||
client_script '@menuv/menuv.lua'
|
||||
|
||||
client_script 'client/main.lua'
|
||||
|
||||
Reference in New Issue
Block a user