This mod adds cross-platform events for adding Sodium/Embeddium options menu integration. For example, you can add an option page to Embeddium on Forge, Fabric Sodium 0.5 on 1.20.1, and Fabric/NeoForge Sodium 0.6 on 1.21.1 with one event:
OptionGUIConstruction.EVENT.register((pages) -> pages.add(new TestOptionPage()));
If you're an end user, and you don't have this mod installed already as a library for another Sodium addon, you can install it alongside Reese's Options to get improved category menu, with drop-down support so that it's easier to navigate. This will take effect even for mods that don't use this API and inject into Sodium options directly.
This mod is partially a fork of the Embeddium categories API and options events, with heavy changes to support upstream Sodium. While it makes changes to the Reese's Sodium Options menu, it does so via mixin for compatibility reasons, so you will need to install both.
Using the API
First, you will need to add this mod to your dev environment, using the Maven release for Curseforge or Modrinth.
modImplementation("maven.modrinth:sodium-options-api:version")
Then, this mod provides three events in toni.sodiumoptionsapi.api:
- OptionGUIConstruction.EVENT, called once in the GUI constructor, allows adding entire pages. This is probably the one you want.
- OptionPageConstruction.EVENT, called for each OptionPage. Use this if you want to add a group of toggles to the performance tab or something.
- OptionGroupConstruction.EVENT, called for each group of options. Use this if you want to insert a single option into an existing group, or modify the vanilla ones.
本站是资源分享站,资源均来自于互联网和用户自发分享,仅供学习和交流使用。如有版权问题,请联系管理员删除。
操作
创作者
待认领资源
成为此资源的创作者
其他链接
最近更新资源
阿卡迪亚的天启:天选之歌
热度 752 | 1 周前更新
机械动力:航空学 - All of Create - Aeronautics
热度 731 | 1 周前更新
天空开拓者:耕云纪元
热度 608 | 1 周前更新
更好的MC Better MC [FORGE] BMC4
热度 570 | 1 周前更新
剑痕纪元
热度 2109 | 1 周前更新
咒术回战(咒术战斗) - Jujutsu Kaisen (Sorcery Fight)
热度 3659 | 2 周前更新
机械动力:工业与牧歌 - Create: Industry and Pastoral
热度 4959 | 2 周前更新
虚饰作品-Fictional
热度 5003 | 3 周前更新
猎杀:历史 1949 - Hunt: History 1949
热度 2325 | 3 周前更新
更好的MC Better MC [NEOFORGE] BMC5
热度 2513 | 3 周前更新
ATM10:空岛 - All the Mods 10: To the Sky
热度 1126 | 3 周前更新
方块宝可梦x纪元(Cobblemon x Era)
热度 5837 | 3 周前更新
评论区 (0)
登录 后才能发表评论
快来发表第一条评论吧!