File tree Expand file tree Collapse file tree
src/main/kotlin/com/lambda Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -39,6 +39,7 @@ import com.lambda.imgui.ImGui
3939import com.lambda.imgui.ImGui.closeCurrentPopup
4040import com.lambda.imgui.flag.ImGuiCol
4141import com.lambda.imgui.flag.ImGuiStyleVar
42+ import com.lambda.imgui.type.ImBoolean
4243import com.lambda.imgui.flag.ImGuiWindowFlags
4344import com.lambda.interaction.BaritoneHandler
4445import com.lambda.module.ModuleRegistry
@@ -264,22 +265,19 @@ object MenuBar {
264265 private fun ImGuiBuilder.buildModulesMenu () {
265266 menu(" Module Tag" ) {
266267 ModuleTag .defaults.forEach { tag ->
267- menuItem (tag.name, selected = ModuleTag .isTagShown(tag)) {
268+ checkbox (tag.name, ImBoolean ( ModuleTag .isTagShown(tag) )) {
268269 ModuleTag .toggleTag(tag)
269270 }
270271 }
271272 }
272273 separator()
273- // By Tag → quick enable/disable per module
274+ // By Tag → toggle whether each module is shown in the ClickGui layout
274275 ModuleTag .defaults.forEach { tag ->
275276 menu(tag.name) {
276277 ModuleRegistry .modules
277278 .filter { it.tag == tag }
278279 .forEach { module ->
279- menuItem(module.name, selected = module.isEnabled) {
280- module.toggle()
281- }
282- // Optionally, offer a "Settings..." item to focus this module’s details UI.
280+ checkbox(module.name, module.showInClickGui::value)
283281 }
284282 }
285283 }
Original file line number Diff line number Diff line change @@ -344,7 +344,7 @@ object ClickGuiLayout : Loadable, Config(
344344 }
345345
346346 ModuleRegistry .modules
347- .filter { it.tag == tag }
347+ .filter { it.tag == tag && it.showInClickGui.value }
348348 .forEach { with (ModuleEntry (it)) { buildLayout() } }
349349
350350 val vis = snapOverlays[tag.name]
Original file line number Diff line number Diff line change @@ -146,6 +146,7 @@ abstract class Module(
146146 .onRelease { if (disableOnRelease) disable() }
147147 val disableOnReleaseSetting = setting(" Disable On Release" , false ) { false }
148148 val drawSetting = setting(" Draw" , true , " Draws the module in the module list hud element" ) { false }
149+ val showInClickGui = setting(" Show In ClickGui" , true , " Shows the module in the ClickGui layout" ) { false }
149150
150151 var isEnabled by isEnabledSetting
151152 private set
You can’t perform that action at this time.
0 commit comments