Barotrauma 潜渊症

Barotrauma 潜渊症

338 个评价
Lua For Barotrauma (with xpath patch)
2
2
2
2
2
   
奖励
收藏
已收藏
取消收藏
文件大小
发表于
更新日期
169.332 MB
2022 年 8 月 31 日 上午 6:21
10 月 2 日 上午 6:50
63 项改动说明 ( 查看 )

订阅以下载
Lua For Barotrauma (with xpath patch)

在 shangjiaxuan 的 1 个合集中
Project Harmony
14 件物品
描述
这是一个修改版本的Lua mod ( https://psteamcommunity.yuanyoumao.com/sharedfiles/filedetails/?id=2559634234 ),合并了github上的增加部分重载物品功能的pr:
https://github.com/Regalis11/Barotrauma/pull/9779

可以作为合并之前先体验功能的版本。本mod需要用和客户端lua一样的安装方法(或者自己复制所有dll和需要的json到游戏目录)。

这个mod合并的pr增加了如下写mod物品的功能:

<override>
<item identifier="screwdriver">
<inherit identifier="screwdriver" package="">
<replace sel="./Price/@baseprice">100</replace>
<del sel="./Fabricate"/>
<add sel=".">
<!-- original uranium rod -->
<Fabricate suitablefabricators="fabricator" requiredtime="15">
<RequiredSkill identifier="electrical" level="25" />
<RequiredItem identifier="uranium" />
<RequiredItem identifier="steel" />
<RequiredItem identifier="lead" />
</Fabricate>
</add>
</inherit>
</item>
</override>
<override>
<item identifier="wrench" inherit="wrench">
<sprite texture="xxxx" yyyyyyy>
</item>
</override>

即通过xpath指定物品属性修改,以及允许原本的"子类"逻辑适用在重载同一个id的情况下。

本mod更新或者游戏本体更新时,需要重新安装客户端lua。

如果存在使用本功能重载人类属性的mod(如更新了的witd),如果在安装本mod时启用会导致启动服务器时客户端加载服务器大厅失败(因为大厅需要人类头像)。需要暂时禁用人物修改的mod,安装客户端组件后就可以正常运行。

当前实现如果一个mod对同一个id的多个重载,游戏将崩溃(windows 访问错误0xc0000005, linux segmentation fault.)并且没有任何提示和记录。这是因为目前没有对这个问题进行检查,而继承逻辑依赖一个包只有一个物品。在遇到这种情况时函数将发生无限递归,导致栈溢出。正常mod不会在一个mod实现一个物品的多个重载,但是在mod开发过程中可能会写错导致出现这种问题。后续更新会对这个情况进行正确的错误处理。

如果游戏启动后左上角没有版本号,命令行出现大量无贴图的物品,很可能就是游戏更新导致本mod客户端组件失效,需要重新安装客户端组件(适用上面情形)。

这个版本经过了上游Lua mod原作者的同意。本mod处于开发阶段,因此目前可能会有一些bug。欢迎提issue。

就像所有修改、基于原本游戏代码的mod,这个mod的代码版权归属潜渊症游戏开发商Undertow Games & FakeFish,仅可以用于潜渊症游戏和对应mod的开发。
热门讨论 查看全部(2)
11
5 月 8 日 下午 12:40
Suggestions
shangjiaxuan
10
2024 年 11 月 6 日 上午 2:12
Bug reports
shangjiaxuan
224 条留言
[R.P.C.]Ashuryx 10 月 12 日 上午 7:13 
so do i run this with my lua?
Evil 9 月 23 日 下午 11:15 
Lua For Barotrauma (with XPath Patch) - Support Official Implementation!

Hey Barotrauma modders! 🌊 Our community creates epic modpacks, but managing 100+ mods means slow loads and XML conflicts. Lua For Barotrauma (with XPath Patch), implements the override+inherit system from PR #9779, letting mods merge cleanly, reduce XML bloat, and speed up loading by up to 80%. It’s a game-changer for big modpacks!
I’ve proposed making this an official feature in the Barotrauma Github And Discord. Help get it built into the game!

Support my post (2 links for devs, github - main!):
{链接已删除}
{链接已删除}

Subscribe to support this mod and push for official integration. Let’s make Barotrauma’s modding scene unstoppable! 💪
Tags: modpack, lua, xpath, optimization, community, barotrauma-devs
Gotve 9 月 17 日 上午 11:31 
please update for v1.10.5.0
PBL 9 月 14 日 上午 11:06 
whats the comand to install it once you host the server?
<†>Baigle1<†>™ 6 月 25 日 上午 9:48 
Great concept, I wonder how many mods rely on this and why it hasn't been implemented in with normal Lua?
冷南羽 6 月 18 日 上午 5:48 
难绷 更新了 然后游戏也更新了 又用不了 (悲)
Zannen 5 月 23 日 下午 12:31 
Ooh nice, has anyone tested if the Mudraptor mod works now?
会防空的树 5 月 9 日 上午 1:35 
终于更新了 感动:steamhappy:
shangjiaxuan  [作者] 5 月 8 日 下午 12:42 
Updated for 1.8.8. Not thoroughly tested though.
shangjiaxuan  [作者] 5 月 7 日 下午 5:24