well404.Shop 0.2.2

dotnet add package well404.Shop --version 0.2.2
                    
NuGet\Install-Package well404.Shop -Version 0.2.2
                    
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="well404.Shop" Version="0.2.2" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="well404.Shop" Version="0.2.2" />
                    
Directory.Packages.props
<PackageReference Include="well404.Shop" />
                    
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 well404.Shop --version 0.2.2
                    
#r "nuget: well404.Shop, 0.2.2"
                    
#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 well404.Shop@0.2.2
                    
#: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=well404.Shop&version=0.2.2
                    
Install as a Cake Addin
#tool nuget:?package=well404.Shop&version=0.2.2
                    
Install as a Cake Tool

well404.Shop

Unturned / OpenMod 物品商店插件 —— 玩家用货币买卖物品与自定义组合包,支持按权限组的购买折扣。

well404.Shopwell404 OpenMod 插件家族 的商店模块。它通过全局 IEconomyProvider 结算交易,因此依赖 well404.Economy (安装本插件时会自动一并安装)。

功能

  • 🛒 配置驱动的商品目录:单物品或自定义组合包(bundle)
  • 💵 买入 / 卖出双向定价(价格设为 0 即表示不可买 / 不可卖)
  • 🏷️ 基于权限的购买折扣分级(如 VIP 9 折、MVP 8 折,默认关闭)
  • 🌐 可选 Web 管理面板:可视化编辑商品、按名称/ID 搜索游戏物品(配合 well404.WebPanel)

安装

openmod install well404.Shop

本插件硬依赖 well404.Economy,openmod install 会自动解析并一并安装它。 重启服务器或执行 openmod reload 后生效。

命令

命令 别名 说明
/buy <id> [数量] 从商店购买物品 / 组合包
/sell <id> [数量] 把物品 / 组合包卖给商店
/shop /market 列出全部商品及买卖价

配置 (config.yaml)

discounts:
  enabled: false        # 是否启用按权限折扣
  tiers:                # 权限字符串 -> 购买价乘数(0 < m <= 1);玩家取其所持权限中最低(最优)乘数
    well404.shop.vip: 0.9
    well404.shop.mvp: 0.8
items:
  - id: medkit          # /buy /sell 使用的商店 ID
    name: "Medkit"
    type: item          # item(单物品)| bundle(组合包)
    itemId: 13          # Unturned 物品资源 ID(type: item)
    amount: 1           # 每购买单位的物品数量
    buyPrice: 50        # 买入价(0 = 不可买)
    sellPrice: 20       # 卖出价(0 = 不可卖)
  - id: starter
    name: "Starter Kit"
    type: bundle        # 组合包
    contents:
      - itemId: 13
        amount: 2
      - itemId: 81
        amount: 1
    buyPrice: 100
    sellPrice: 0

折扣权限(如 well404.shop.vip)由服务器管理员自行授予权限组即可,无需在插件内声明。

Web 管理面板

安装 well404.WebPanel 后,Shop 会自动注册「商店」模块:增删改商品目录、搜索游戏物品资源以快速填入物品 ID、配置折扣分级。未安装面板时插件照常通过命令工作。

well404 OpenMod 插件家族

插件 说明
well404.Economy 货币经济核心,全局 IEconomyProvider 供币
well404.Shop 物品商店,买卖物品 / 组合包,依赖 Economy
well404.WebPanel 通用 Web 管理面板,供各插件挂载可视化管理模块

完整文档、配置示例与本地调试说明见 GitHub 仓库docs/

许可

CC BY-NC-SA 4.0 © well404

Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 was computed.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
.NET Core netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.1 is compatible. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos was computed. 
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.2.2 47 6/11/2026
0.2.1 51 6/11/2026
0.2.0 47 6/11/2026
0.1.0 47 6/10/2026