一款 Fabric 模组,允许你:
- 自定义更多集成服务器设置(在线模式、PvP、最大玩家数、MOTD)
- 在 MOTD 中使用连字符 (
&) 代替节符号 (§) 和变量(例如${username}、${world})来进行 格式化代码 - 在游戏中途更改设置(包括端口),并在不退出世界的情况下停止服务器
- 全局保存或按世界保存设置(它们会自动加载,且按世界设置的优先级高于全局设置,全局设置的优先级高于系统默认值)
- 使用
/op和/deop命令单独更改谁可以使用作弊功能,并在单人游戏中无需开放局域网即可使用作弊(替换了“允许作弊”按钮) - 管理封禁(使用
/ban、/ban-ip、/banlist、/pardon和/pardon-ip)并使用/whitelist管理白名单玩家(使用/whitelist on/off来启用/禁用) - 通过隧道将你的服务器暴露到局域网之外,而无需进行端口转发(目前仅支持 ngrok)
它还允许你按回车键启动局域网世界,不会强制改变游戏模式(例如,即使在生存模式下创建的世界,以创造模式离开的玩家在重新加入时仍会处于创造模式),并扩展了 /publish 命令,现在也可以在游戏中途更改设置(使用端口 -1 可以随机化端口号):
/publish [<port>] [<onlineMode>] [<pvpEnabled>] [<maxPlayers>] [<defaultGameMode>] [<tunnel>] [<motd>]
/publish [perworld|global|system] [<port>] [<onlineMode>] [<pvpEnabled>] [<maxPlayers>] [<defaultGameMode>] [<tunnel>] [<motd>]
/publish stop
它需要 Fabric Loader 和 Cloth Config API,但不需要 Fabric API。
它已被移植到 Fabric 支持的所有 Minecraft 版本(快照除外)! 我暂时没有计划亲自将其移植到 Forge,但非常欢迎你给我发送拉取请求。
MOTD 格式化代码和变量的说明
在 MOTD 中,连字符 (&) 会被替换为节符号 (§),以便你输入 格式化代码(例如 &9Hello, &a&lworld! 会使 Hello, 变为蓝色,world! 变为绿色和粗体)。
你可以连续使用两个连字符 (&&) 来获得实际的连字符 (&)。
以下变量将使用 Apache Commons Text 的 StringSubstitutor 进行展开:
${username}– 主机的用户名(例如 “DimiDimit”)${world}– 世界名称(例如 “New World”)
已保存设置的说明
设置可以按世界保存或全局保存。当打开“开放局域网”屏幕时,设置会按照上述顺序自动加载,也可以使用加载按钮手动加载。
如果未指定要使用的已保存设置(perworld、global 或 system),则在使用 /publish 命令时,如果世界尚未开放给局域网,则使用相同的顺序;如果世界已经开放给局域网,则使用当前值而不是任何已保存的设置。
指定已保存设置会使用这些特定设置,或者如果尚未保存则使用系统默认值,而不会检查其他设置,即使世界已经开放给局域网(例如,如果指定了 perworld 但没有保存按世界设置,则将使用系统默认值,即使存在已保存的全局设置也是如此)。
作为参数指定的设置将覆盖已保存的设置或当前值(例如 /publish perworld 12345 false 将使用按世界设置,但端口将为 12345 且在线模式将被禁用)。
全局设置存储在 .minecraft/config/customlan.toml 中,而按世界设置存储在世界目录下的 data/customlan.dat 中。
/op 和 /deop 的说明
/op 和 /deop 的工作方式与专用服务器相同。
你也可以对自己(主机)使用它们。这样做会在世界上添加/移除“作弊”标签(就像你 NBT 编辑了 allowCommands 字段一样),并且你可以在不开放局域网的情况下使用这些命令,从而取代原版开放局域网、作弊、退出世界并重新进入的方法。
操作员信息按世界持久化存储在该世界目录内的 ops.json 文件中。若要允许操作员分配和移除其他操作员,以及封禁和白名单玩家,请将他们在 ops.json 文件中的 level 更改为 3 或更高(默认为 2,而级别 4 允许他们使用 /publish)。作为主机,你始终可以分配和移除操作员,即使你自己不是操作员。
封禁和白名单的说明
这些命令也像专用服务器一样工作,尽管你不能封禁或白名单主机。
启用白名单不会踢出所有非白名单玩家(即 enforce-whitelist 始终为 false)。
使用的文件也是按世界的,并且与专用服务器相同——banned-players.json、banned-ips.json、whitelist.json——不过白名单是否启用存储在 data/customlan.dat 中。
A Fabric mod that allows you to:
- Customize more of your integrated server (Online Mode, PvP, Max Players, MOTD)
- Use ampersands (
&) for formatting codes instead of section signs (§) and variables (e.g.${username},${world}) in the MOTD - Change the settings mid-game (including the port) and stop the server without quitting the world
- Save the settings globally or per-world (they are loaded automatically with per-world settings taking priority over the global ones, which take priority over the system defaults)
- Change who can use cheats individually using the
/opand/deopcommands and cheat in singleplayer without opening to LAN (replaces the Allow Cheats button) - Manage bans with
/ban,/ban-ip,/banlist,/pardonand/pardon-ip, and whitelist players with/whitelist(use/whitelist on/offto enable/disable) - Expose your server outside of your LAN without port forwarding using tunnels (currently only ngrok is supported)
It also allows you to start the LAN world by pressing Enter, doesn't force the gamemode (e.g. anyone who left in Creative mode will still be in Creative when they join even if the world is set to Survival), and extends the /publish command, which can now change settings mid-game as well (use a port of -1 to randomize it):
/publish [<port>] [<onlineMode>] [<pvpEnabled>] [<maxPlayers>] [<defaultGameMode>] [<tunnel>] [<motd>]
/publish [perworld|global|system] [<port>] [<onlineMode>] [<pvpEnabled>] [<maxPlayers>] [<defaultGameMode>] [<tunnel>] [<motd>]
/publish stop
It requires Fabric Loader and Cloth Config API, but Fabric API is not required.
It has been backported to all Minecraft versions supported by Fabric (except the snapshots)! I'm not planning on porting it to Forge myself for now, but you're more than welcome to send me a pull request.
Explanation of MOTD formatting codes and variables
In the MOTD, ampersands (&) are replaced with section signs (§) to allow you to enter formatting codes (e.g. &9Hello, &a&lworld! makes Hello, blue and world! green and bold).
You can use two ampersands in a row (&&) to get an actual ampersand (&).
The following variables will be expanded using Apache Commons Text's StringSubstitutor:
${username}– the host's username (e.g. “DimiDimit”)${world}– the world's name (e.g. “New World”)
Explanation of saved settings
The settings can be saved per-world or globally. When the Open to LAN screen is opened, the settings are loaded automatically in that order, and they can also be loaded manually using the Load buttons.
Using the /publish command without specifying which saved settings to use (perworld, global or system) uses the same order if the world hasn't been opened to LAN, or the current values instead of any saved settings if it has.
Specifying the saved settings uses those particular settings or the system defaults if they haven't been saved, without checking any others, even if the world has been opened to LAN (e.g. if perworld is specified and no per-world settings are saved, the system defaults will be used even if there are saved global settings).
The settings specified as arguments will override the saved settings or current values (e.g. /publish perworld 12345 false will use the per-world settings, except that the port will be 12345 and online mode will be disabled).
The global settings are stored in .minecraft/config/customlan.toml, while the per-world ones are stored in data/customlan.dat in the respective world's directory.
Explanation of /op and /deop
/op and /deop work like in dedicated servers.
You can also use them on yourself, the host. Doing this will add/remove the “Cheats” label on the world (as if you've NBT edited the allowCommands field), and you can use these commands without opening to LAN as well, replacing the Vanilla method of opening to LAN, cheating, quitting the world and entering it again.
Operators are persisted per-world in an ops.json file inside that world's directory. To allow operators to assign and remove other operators, as well as ban and whitelist players, change their level in the ops.json file to 3 or higher (the default is 2, while level 4 allows them to use /publish). You, as the host, can always assign and remove operators, even if you're not an operator yourself.
Explanation of bans and whitelists
These commands also work like in dedicated servers, though you cannot ban or whitelist the host.
Enabling the whitelist does not kick all non-whitelisted players (i.e. enforce-whitelist is always false).
The files used are also per-world and the same as on dedicated servers—banned-players.json, banned-ips.json, whitelist.json—though whether the whitelist is enabled is stored in data/customlan.dat.
下载 Custom LAN
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Custom LAN
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Custom LAN
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Custom LAN
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Custom LAN
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Custom LAN
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Custom LAN
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Custom LAN
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Custom LAN
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 Custom LAN
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
使玩家举报按钮通过消息而非索引进行查找,以提高可靠性。
关于这个资源的讨论、问题反馈与使用心得
还没有讨论,来发第一帖吧
你是这个资源的作者?登录后可认领此资源。
相似资源
模组
显示你正在注视的方块的信息。(适用于 Minecraft 1.16+ 的 Hwyla/Waila 分支)
模组
查看物品与配方
模组
在游戏画面角落显示附近世界地形、玩家、生物和实体的地图。可创建路径点,帮助你找到标记过的位置。
模组
使用 JavaScript 编辑配方、添加自定义物品、编写世界事件!
模组
AE2:一款流行的自动化与存储模组
模组
添加区块认领和玩家组队功能,并与 Xaero's Minimap 和 World Map 集成
评论 0
登录后参与评分
还没有评论,来抢沙发吧