Permalink
Browse files

Add permissions to the connection submenu

  • Loading branch information...
TomGrobbe committed Sep 7, 2018
1 parent fb2b2a4 commit 804cbb7c20804b7e09706aaa42e16554b3d4aaf7
Showing with 7 additions and 2 deletions.
  1. +1 −0 vMenu/Permission.cs
  2. +4 −2 vMenu/menus/MiscSettings.cs
  3. +1 −0 vMenuServer/MainServer.cs
  4. +1 −0 vMenuServer/config/permissions.cfg
@@ -238,6 +238,7 @@ public enum Permission
MSThermalVision,
MSLocationBlips,
MSPlayerBlips,
MSConnectionMenu,
// Voice Chat
VCMenu,
@@ -112,8 +112,10 @@ private void CreateMenu()
// Always allowed
menu.AddItem(speedKmh);
menu.AddItem(speedMph);
menu.AddItem(connectionSubmenuBtn);
if (cf.IsAllowed(Permission.MSConnectionMenu))
{
menu.AddItem(connectionSubmenuBtn);
}
if (cf.IsAllowed(Permission.MSShowCoordinates))
{
menu.AddItem(coords);
@@ -297,6 +297,7 @@ public class MainServer : BaseScript
"MSNightVision",
"MSThermalVision",
"MSLocationBlips",
"MSConnectionMenu",
// Voice Chat
"VCMenu",
@@ -346,6 +346,7 @@ add_ace builtin.everyone "vMenu.MiscSettings.All" allow
#add_ace builtin.everyone "vMenu.MiscSettings.NightVision" allow
#add_ace builtin.everyone "vMenu.MiscSettings.ThermalVision" allow
#add_ace builtin.everyone "vMenu.MiscSettings.LocationBlips" allow
#add_ace builtin.everyone "vMenu.MiscSettings.ConnectionMenu" allow

0 comments on commit 804cbb7

Please sign in to comment.