BlueBeard.OpenMod 0.1.0-ci.24

This is a prerelease version of BlueBeard.OpenMod.
dotnet add package BlueBeard.OpenMod --version 0.1.0-ci.24
                    
NuGet\Install-Package BlueBeard.OpenMod -Version 0.1.0-ci.24
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="BlueBeard.OpenMod" Version="0.1.0-ci.24" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="BlueBeard.OpenMod" Version="0.1.0-ci.24" />
                    
Directory.Packages.props
<PackageReference Include="BlueBeard.OpenMod" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add BlueBeard.OpenMod --version 0.1.0-ci.24
                    
#r "nuget: BlueBeard.OpenMod, 0.1.0-ci.24"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package BlueBeard.OpenMod@0.1.0-ci.24
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=BlueBeard.OpenMod&version=0.1.0-ci.24&prerelease
                    
Install as a Cake Addin
#tool nuget:?package=BlueBeard.OpenMod&version=0.1.0-ci.24&prerelease
                    
Install as a Cake Tool

BlueBeard.OpenMod

OpenMod host adapter for BlueBeard.Core abstractions. Implements ILogger, IChat, IPermissions, ITaskDispatcher, IPlayer, and IPlayerEvents against OpenMod / Unturned APIs.

Usage

In your OpenModUnturnedPlugin.OnLoadAsync:

using BlueBeard.OpenMod;
using BlueBeard.Core.Abstractions;
using Microsoft.Extensions.Logging;
using OpenMod.API.Eventing;
using OpenMod.API.Permissions;
using OpenMod.API.Users;
using OpenMod.Core.Permissions;
using OpenMod.Unturned.Plugins;
using OpenMod.Unturned.Users;

public class MyPlugin : OpenModUnturnedPlugin
{
    private readonly ILogger<MyPlugin> _logger;
    private readonly IPermissionChecker _permissionChecker;
    private readonly IPermissionRoleStore _permissionRoleStore;
    private readonly IUnturnedUserDirectory _userDirectory;
    private readonly IEventBus _eventBus;

    public MyPlugin(
        ILogger<MyPlugin> logger,
        IPermissionChecker permissionChecker,
        IPermissionRoleStore permissionRoleStore,
        IUnturnedUserDirectory userDirectory,
        IEventBus eventBus,
        IServiceProvider serviceProvider) : base(serviceProvider)
    {
        _logger = logger;
        _permissionChecker = permissionChecker;
        _permissionRoleStore = permissionRoleStore;
        _userDirectory = userDirectory;
        _eventBus = eventBus;
    }

    protected override async UniTask OnLoadAsync()
    {
        OpenModBootstrap.Install(
            logger: _logger,
            permissionChecker: _permissionChecker,
            permissionRoleStore: _permissionRoleStore,
            userDirectory: _userDirectory,
            eventBus: _eventBus,
            component: this);

        // Now BlueBeard libraries can use BlueBeardHost services freely:
        BlueBeardHost.Logger.Log("Hello from BlueBeard");
    }

    protected override async UniTask OnUnloadAsync()
    {
        OpenModBootstrap.Uninstall();
    }
}

Async / sync seam

OpenMod's IPermissionChecker.CheckPermissionAsync is async; IPermissions.HasPermission is sync. The adapter blocks via .GetAwaiter().GetResult() — safe on the Unturned main thread because permission backends are typically in-memory or fast file-backed.

Permission grant defaults

OpenMod returns PermissionGrantResult.Default for unconfigured nodes (deny-by-default), which OpenModPermissions translates to false. RocketMod's permissive default does not carry over — register every required permission in OpenMod explicitly.

Wrapping a connected user

Convert an OpenMod UnturnedUser to the abstraction with OpenModPlayer.From(user). Use OpenModPlayer.Console for the server console.

Product Compatible and additional computed target framework versions.
.NET Framework net481 is compatible. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.1.0-ci.24 86 7/4/2026
0.1.0-ci.23 87 6/25/2026
0.1.0-ci.22 90 5/8/2026
0.1.0-ci.20 64 5/7/2026
0.1.0-ci.19 67 5/7/2026