免费插件

Cui Generator

崔发电机

帮助开发人员通过一行代码管理 GUI 操作

服务器管理管理工具utility

原作者:bazuka5801 · 查看 uMod 官方页面 ↗

插件介绍

帮助开发人员通过一行代码管理 GUI 操作

This plugin is for use with the CuiBuilder program.

The usual way to create a GUI for a plugin: Come up with UI/UX, draw in the image editor, then carefully move element by element into the code, okay moved, now you need to update it all every 5 seconds with a new value for each player - "Oh my God, how difficult it is"

Immediately throw the layout in CuiBuilder, throw commands on the buttons and put {N} where we will change the value, press Ctrl E (export CuiDB.json) we throw the database guishek in data/CuiGenerator, reload this plugin-CuiGenerator and we can easily add GUI to different players, with different arguments and change the same arguments by calling DrawUI or DrawUIWithEx again.

This is the smallest part of what CuiGenerator can do, it is very well optimized, if you call DrawUI in a row with the same arguments, the request to create a GUI will be sent to the player only 1 time.Next, changing the arguments: a laborious work was carried out and a smart algorithm was written that changes only those elements that affected the argument, let's say you have two pictures that are superimposed on each other, if you change the one that is behind, the front will remain on the front layer.

主要用途

主要用于服务器管理、管理工具、utility等服务端功能。 本插件由 bazuka5801 发布,当前目录记录版本为 v3.1.60,uMod 累计下载 9,504 次。

适用场景

  • 需要管理、审计或维护能力的服务器

功能分类

服务器管理管理工具utility
查看 uMod 官方英文简介

Helps developer manage GUI manipulations in single line of code

官方配置示例

[PluginReference]
private Plugin CuiGenerator;
       
private void DrawUI(BasePlayer player, string plugin, string funcName, params object[] args)
{
    CuiGenerator?.Call("DrawUI",player, plugin, funcName, args);
}

private void DrawUIWIthEx(BasePlayer player, string plugin,  string funcName, CuiElementContainer additionalContainer, params object[] args)
{
    CuiGenerator?.Call("DrawUIWIthEx",player, plugin, funcName, additionalContainer, args);
}

private void DestroyUI(BasePlayer player, string plugin, string funcName)
{
    CuiGenerator?.Call("DestroyUI",player, plugin, funcName);
}
[ChatCommand("craft")]
private void cmdChatCraft(BasePlayer player, string command, string[] args)
{
    if (args.Length > 0 && args[0] == "close")
    {
        DestroyUI(player, "mycraft", "menu")
        return;
    }
   
    // Arguments: player, plugin name, function name
    DrawUI(player, "mycraft", "menu");
}

更新日志

最新版本: v3.1.60
最后版本发布: 2020-06-18
最后更新(条目): 2026-07-18

本站记录 uMod 官方插件信息。完整的历史更新日志请参阅 uMod 官方页面

安装方法

  1. 确认服务器已安装 Oxide / uMod 或兼容的 Carbon 框架。
  2. 登录本站后点击"下载",由 uMod 官方地址获取作者发布的文件。
  3. 将 .cs 文件放入服务器的 oxide/plugins 目录。
  4. 观察服务端控制台,确认插件编译并成功加载。
  5. 具体配置、权限、指令和依赖请查看原作者的 uMod 页面。

使用前注意

  • Rust 更新后,请先确认插件是否仍兼容当前服务端版本。
  • 修改配置前建议备份原配置文件,并在测试服验证后再部署到正式服。
  • 若插件依赖其他扩展或库,以 uMod 原作者页面的最新说明为准。
  • 本站中文内容用于辅助理解,遇到版本差异时以官方英文文档和源码为准。
来源说明

中文介绍由 uMod 官方简介翻译整理。插件著作权、许可证、完整文档和最新发布状态均以原作者及 uMod 官方页面为准。