Skip to content

Commit 055f780

Browse files
committed
Bind.EMPTY over Bind.Empty :3
1 parent 1aa30e2 commit 055f780

File tree

4 files changed

+7
-7
lines changed

4 files changed

+7
-7
lines changed

src/main/kotlin/com/lambda/config/settings/complex/KeybindSetting.kt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ class KeybindSetting(
9393

9494
sameLine()
9595
smallButton("Unbind") {
96-
value = Bind.Empty
96+
value = Bind.EMPTY
9797
listening = false
9898
}
9999
onItemHover(ImGuiHoveredFlags.Stationary) {
@@ -116,7 +116,7 @@ class KeybindSetting(
116116
if ((it.isPressed && !isModKey) || (it.isReleased && isModKey)) {
117117
when (it.translated) {
118118
KeyCode.Escape -> {}
119-
KeyCode.Backspace, KeyCode.Delete -> value = Bind.Empty
119+
KeyCode.Backspace, KeyCode.Delete -> value = Bind.EMPTY
120120
else -> value = Bind(it.keyCode, it.modifiers, -1)
121121
}
122122

@@ -138,7 +138,7 @@ class KeybindSetting(
138138
optional(boolean("mouse button")) { isMouseButton ->
139139
executeWithResult {
140140
val isMouse = if (isMouseButton != null) isMouseButton().value() else false
141-
var bind = Bind.Empty
141+
var bind = Bind.EMPTY
142142
if (isMouse) {
143143
val num = try {
144144
name().value().toInt()
@@ -193,6 +193,6 @@ data class Bind(
193193
"Key Code: $key, Modifiers: ${truemods.joinToString(separator = "+") { it.name }}, Mouse Button: ${Mouse.entries.getOrNull(mouse) ?: "None"}"
194194

195195
companion object {
196-
val Empty = Bind(0, 0, -1)
196+
val EMPTY = Bind(0, 0, -1)
197197
}
198198
}

src/main/kotlin/com/lambda/module/HudModule.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ abstract class HudModule(
2929
val customWindow: Boolean = false,
3030
alwaysListening: Boolean = false,
3131
enabledByDefault: Boolean = false,
32-
defaultKeybind: Bind = Bind.Empty,
32+
defaultKeybind: Bind = Bind.EMPTY,
3333
) : Module(name, description, tag, alwaysListening, enabledByDefault, defaultKeybind), Layout {
3434
val backgroundColor by setting("Background Color", Color(0, 0, 0, 0))
3535
val outline by setting("Show Outline", false)

src/main/kotlin/com/lambda/module/Module.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ abstract class Module(
118118
val tag: ModuleTag,
119119
private val alwaysListening: Boolean = false,
120120
enabledByDefault: Boolean = false,
121-
defaultKeybind: Bind = Bind.Empty,
121+
defaultKeybind: Bind = Bind.EMPTY,
122122
autoDisable: Boolean = false
123123
) : Nameable, Muteable, Configurable(ModuleConfig), Automated by AutomationConfig {
124124
private val isEnabledSetting = setting("Enabled", enabledByDefault) { false }

src/main/kotlin/com/lambda/module/modules/player/Scaffold.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ object Scaffold : Module(
6161
private val bridgeRange by setting("Bridge Range", 5, 0..5, 1, "The range at which blocks can be placed to help build support for the player", unit = " blocks").group(Group.General)
6262
private val onlyBelow by setting("Only Below", true, "Restricts bridging to only below the player to avoid place spam if it's impossible to reach the supporting position") { bridgeRange > 0 }.group(Group.General)
6363
private val descend by setting("Descend", KeyCode.Unbound, "Lower the place position by one to allow the player to lower y level").group(Group.General)
64-
private val descendAmount by setting("Descend Amount", 1, 1..5, 1, "The amount to lower the place position by when descending", unit = " blocks") { descend != Bind.Empty }.group(Group.General)
64+
private val descendAmount by setting("Descend Amount", 1, 1..5, 1, "The amount to lower the place position by when descending", unit = " blocks") { descend != Bind.EMPTY }.group(Group.General)
6565
override val buildConfig = BuildSettings(this, Group.Build).apply {
6666
editTyped(::pathing, ::stayInRange, ::collectDrops) {
6767
defaultValue(false)

0 commit comments

Comments
 (0)