vMenu Docs

Example Plugin, C#

The C# version of the vMenu Enhanced example plugin.

What is it

The C# version of the example plugin. Resource name vMenu.ExamplePlugin.CSharp.

Where do I look

FileContains
client/Main.csThe menu, translations and gates
server/Main.csPermissions and settings
fxmanifest.luaThe manifest. Every client DLL is listed under files
Directory.Build.propsThe resource name and output folders
Directory.Packages.propsThe plugin API version

API docs: C# setup.

Building this example

  1. Install the .NET 10 SDK.
  2. Run dotnet build -c Release in this folder.
  3. Copy build/vMenu.ExamplePlugin.CSharp/ into your server's resources folder and ensure it.

Making your own plugin

  1. Create two class library projects targeting net10.0, one for the client and one for the server.
  2. Add the NuGet packages at the vMenu Enhanced version your server runs:
    dotnet add Client package vMenu.Enhanced.ClientAPI --version <your vMenu version>
    dotnet add Server package vMenu.Enhanced.ServerAPI --version <your vMenu version>
  3. Build each into its own folder, client/ and server/, with CopyLocalLockFileAssemblies on. Directory.Build.props shows how.
  4. Write an fxmanifest.lua that lists every client DLL under files, then ensure the resource. The C# setup page has the full manifest.

On this page