Skip to content

Re-order module properties, clean them up, fix typos and remove a dead link #257

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Mar 4, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
package com.lambda.client.module.modules.chat

import com.lambda.client.LambdaMod
import com.lambda.client.event.listener.listener
import com.lambda.client.module.Category
import com.lambda.client.module.Module
import com.lambda.client.util.text.MessageDetection
import com.lambda.client.util.text.MessageSendHelper
import com.lambda.client.util.text.SpamFilters
import com.lambda.client.event.listener.listener
import net.minecraft.util.text.TextComponentString
import net.minecraftforge.client.event.ClientChatReceivedEvent
import java.util.concurrent.ConcurrentHashMap
import java.util.regex.Pattern

object AntiSpam : Module(
name = "AntiSpam",
category = Category.CHAT,
description = "Removes spam and advertising from the chat",
category = Category.CHAT,
showOnArray = false
) {
private val mode by setting("Mode", Mode.REPLACE)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
package com.lambda.client.module.modules.chat

import com.lambda.client.commons.interfaces.DisplayEnum
import com.lambda.client.module.Category
import com.lambda.client.module.Module
import com.lambda.client.util.TimeUtils
import com.lambda.client.util.color.EnumTextColor
import com.lambda.client.util.text.format
import com.lambda.client.util.threads.safeListener
import com.lambda.client.commons.interfaces.DisplayEnum
import net.minecraft.util.text.TextComponentString
import net.minecraftforge.client.event.ClientChatReceivedEvent

object ChatTimestamp : Module(
name = "ChatTimestamp",
category = Category.CHAT,
description = "Shows the time a message was sent beside the message",
category = Category.CHAT,
showOnArray = false
) {
private val color by setting("Color", EnumTextColor.GRAY)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ import kotlin.math.min

object CustomChat : Module(
name = "CustomChat",
category = Category.CHAT,
description = "Add a custom ending to your message!",
category = Category.CHAT,
showOnArray = false,
modulePriority = 200
) {
Expand All @@ -25,7 +25,7 @@ object CustomChat : Module(
}

private enum class TextMode {
NAME, ON_TOP, WEBSITE, CUSTOM
NAME, ON_TOP, CUSTOM
}

private val modifier = newMessageModifier(
Expand Down Expand Up @@ -57,7 +57,6 @@ object CustomChat : Module(
private fun getText() = when (textMode) {
TextMode.NAME -> "ʟᴀᴍʙᴅᴀ"
TextMode.ON_TOP -> "ʟᴀᴍʙᴅᴀ ᴏɴ ᴛᴏᴘ"
TextMode.WEBSITE -> "lambda-client.com"
TextMode.CUSTOM -> customText
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ import org.spongepowered.asm.mixin.injection.callback.CallbackInfo

object ExtraChatHistory : Module(
name = "ExtraChatHistory",
alias = arrayOf("InfiniteChat", "InfiniteChatHistory"),
category = Category.CHAT,
description = "Show more messages in the chat history",
category = Category.CHAT,
alias = arrayOf("InfiniteChat", "InfiniteChatHistory"),
showOnArray = false
) {
private val maxMessages by setting("Max Message", 1000, 100..5000, 100)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
package com.lambda.client.module.modules.chat

import com.lambda.client.commons.utils.MathUtils
import com.lambda.client.manager.managers.MessageManager.newMessageModifier
import com.lambda.client.module.Category
import com.lambda.client.module.Module
import com.lambda.client.util.text.MessageDetection
import com.lambda.client.commons.utils.MathUtils
import kotlin.math.min

object FancyChat : Module(
name = "FancyChat",
category = Category.CHAT,
description = "Makes messages you send fancy",
category = Category.CHAT,
showOnArray = false,
modulePriority = 100
) {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
package com.lambda.client.module.modules.chat

import com.lambda.client.commons.extension.ceilToInt
import com.lambda.client.manager.managers.LambdaMojiManager
import com.lambda.client.module.Category
import com.lambda.client.module.Module
import com.lambda.client.util.graphics.GlStateUtils
import com.lambda.client.util.graphics.texture.MipmapTexture
import com.lambda.client.commons.extension.ceilToInt
import net.minecraft.client.renderer.GlStateManager
import net.minecraft.client.renderer.Tessellator
import net.minecraft.client.renderer.vertex.DefaultVertexFormats
import org.lwjgl.opengl.GL11.*

object LambdaMoji : Module(
name = "LambdaMoji",
description = "Add emojis to chat using LambdaMoji, courtesy of the EmojiAPI.",
description = "Add emojis to chat using LambdaMoji, courtesy of the EmojiAPI",
category = Category.CHAT
) {
@JvmStatic
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package com.lambda.client.module.modules.chat

import com.lambda.client.event.events.ConnectionEvent
import com.lambda.client.event.listener.listener
import com.lambda.client.module.Category
import com.lambda.client.module.Module
import com.lambda.client.util.MovementUtils.isMoving
Expand All @@ -19,7 +20,7 @@ import java.util.concurrent.CopyOnWriteArrayList

object LoginMessage : Module(
name = "LoginMessage",
description = "Sends a given message(s) to public chat on login.",
description = "Sends a given message(s) to public chat on login",
category = Category.CHAT,
showOnArray = false,
modulePriority = 150
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import com.lambda.client.module.Module
*/
object PortalChat : Module(
name = "PortalChat",
category = Category.CHAT,
description = "Allows you to open GUIs in portals",
category = Category.CHAT,
showOnArray = false
)
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,20 @@ package com.lambda.client.module.modules.client

import com.lambda.client.event.events.BaritoneSettingsInitEvent
import com.lambda.client.event.events.RenderRadarEvent
import com.lambda.client.event.listener.listener
import com.lambda.client.module.Category
import com.lambda.client.module.Module
import com.lambda.client.util.BaritoneUtils
import com.lambda.client.util.color.ColorHolder
import com.lambda.client.util.graphics.RenderUtils2D
import com.lambda.client.util.math.Vec2d
import com.lambda.client.util.threads.safeListener
import com.lambda.client.event.listener.listener
import net.minecraft.util.math.BlockPos

object Baritone : Module(
name = "Baritone",
category = Category.CLIENT,
description = "Configures Baritone settings",
category = Category.CLIENT,
showOnArray = false,
alwaysEnabled = true
) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,12 @@ package com.lambda.client.module.modules.client

import com.google.gson.Gson
import com.google.gson.reflect.TypeToken
import com.lambda.client.LambdaMod
import com.lambda.client.capeapi.Cape
import com.lambda.client.capeapi.CapeType
import com.lambda.client.capeapi.CapeUser
import com.lambda.client.LambdaMod
import com.lambda.client.commons.extension.synchronized
import com.lambda.client.commons.utils.ConnectionUtils
import com.lambda.client.gui.clickgui.LambdaClickGui
import com.lambda.client.module.Category
import com.lambda.client.module.Module
Expand All @@ -16,8 +18,6 @@ import com.lambda.client.util.color.ColorHolder
import com.lambda.client.util.color.DyeColors
import com.lambda.client.util.threads.BackgroundScope
import com.lambda.client.util.threads.defaultScope
import com.lambda.client.commons.extension.synchronized
import com.lambda.client.commons.utils.ConnectionUtils
import kotlinx.coroutines.Dispatchers
import kotlinx.coroutines.launch
import kotlinx.coroutines.withContext
Expand All @@ -38,8 +38,8 @@ import kotlin.math.sin

object Capes : Module(
name = "Capes",
category = Category.CLIENT,
description = "Controls the display of Lambda capes",
category = Category.CLIENT,
showOnArray = false,
enabledByDefault = true
) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import com.lambda.client.module.Module

object ChatSetting : Module(
name = "ChatSetting",
category = Category.CLIENT,
description = "Configures chat message manager",
category = Category.CLIENT,
showOnArray = false,
alwaysEnabled = true
) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,20 @@ package com.lambda.client.module.modules.client

import com.lambda.client.LambdaMod
import com.lambda.client.event.events.ModuleToggleEvent
import com.lambda.client.event.listener.listener
import com.lambda.client.module.Category
import com.lambda.client.module.Module
import com.lambda.client.util.TickTimer
import com.lambda.client.util.text.MessageSendHelper
import com.lambda.client.util.text.format
import com.lambda.client.event.listener.listener
import net.minecraft.util.text.TextFormatting
import net.minecraftforge.fml.common.gameevent.TickEvent
import org.lwjgl.opengl.Display

object CommandConfig : Module(
name = "CommandConfig",
category = Category.CLIENT,
description = "Configures client chat related stuff",
category = Category.CLIENT,
showOnArray = false,
alwaysEnabled = true
) {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
package com.lambda.client.module.modules.client

import com.lambda.client.LambdaMod
import com.lambda.client.commons.interfaces.DisplayEnum
import com.lambda.client.event.events.ConnectionEvent
import com.lambda.client.event.listener.listener
import com.lambda.client.gui.AbstractLambdaGui
import com.lambda.client.module.AbstractModule
import com.lambda.client.module.Category
Expand All @@ -20,8 +22,6 @@ import com.lambda.client.util.text.formatValue
import com.lambda.client.util.threads.BackgroundScope
import com.lambda.client.util.threads.defaultScope
import com.lambda.client.util.threads.safeListener
import com.lambda.client.commons.interfaces.DisplayEnum
import com.lambda.client.event.listener.listener
import kotlinx.coroutines.Dispatchers
import kotlinx.coroutines.launch
import net.minecraftforge.fml.common.gameevent.TickEvent
Expand All @@ -40,7 +40,7 @@ internal object Configurations : AbstractModule(
private const val defaultPreset = "default"

private val autoSaving by setting("Auto Saving", true)
private val savingFeedBack by setting("Saving FeedBack", false, { autoSaving })
private val savingFeedBack by setting("Log autosaves in chat", false, { autoSaving })
private val savingInterval by setting("Interval", 10, 1..30, 1, { autoSaving }, description = "Frequency of auto saving in minutes")
val serverPreset by setting("Server Preset", false)
private val guiPresetSetting = setting("Gui Preset", defaultPreset)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ import java.awt.GraphicsEnvironment
object CustomFont : Module(
name = "CustomFont",
description = "Use different GUI fonts",
showOnArray = false,
category = Category.CLIENT,
showOnArray = false,
enabledByDefault = true
) {
private const val DEFAULT_FONT_NAME = "Fira Sans"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import com.lambda.client.util.color.ColorHolder
object GuiColors : Module(
name = "GuiColors",
description = "Customize gui colors",
showOnArray = false,
category = Category.CLIENT,
showOnArray = false,
alwaysEnabled = true
) {
private val primarySetting by setting("Primary Color", ColorHolder(108, 0, 43, 255))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ import java.util.*
object MenuShader : Module(
name = "MenuShader",
description = "Shows a shader on the main menu",
showOnArray = false,
category = Category.CLIENT,
showOnArray = false,
enabledByDefault = true
) {
private val mode by setting("Mode", Mode.SET)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import com.lambda.client.module.Module
object Plugins : Module(
name = "Plugins",
description = "Config for plugins",
showOnArray = false,
category = Category.CLIENT,
showOnArray = false,
alwaysEnabled = true
) {
private val tokenSetting by setting("Github Token", "")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import net.minecraftforge.fml.common.gameevent.TickEvent
@CombatManager.CombatModule
object AimBot : Module(
name = "AimBot",
description = "Automatically aims at entities for you.",
description = "Automatically aims at entities for you",
category = Category.COMBAT,
modulePriority = 20
) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,10 @@ import net.minecraftforge.fml.common.gameevent.TickEvent

object AutoArmor : Module(
name = "AutoArmor",
category = Category.COMBAT,
description = "Automatically equips armour",
category = Category.COMBAT,
modulePriority = 500
) {

private val delay by setting("Delay", 5, 1..10, 1)

private val timer = TickTimer(TimeUnit.TICKS)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
package com.lambda.client.module.modules.combat

import com.lambda.client.commons.extension.synchronized
import com.lambda.client.event.SafeClientEvent
import com.lambda.client.event.events.ConnectionEvent
import com.lambda.client.event.listener.listener
import com.lambda.client.module.Category
import com.lambda.client.module.Module
import com.lambda.client.util.TickTimer
Expand All @@ -10,17 +12,15 @@ import com.lambda.client.util.text.MessageSendHelper
import com.lambda.client.util.text.MessageSendHelper.sendServerMessage
import com.lambda.client.util.text.formatValue
import com.lambda.client.util.threads.safeListener
import com.lambda.client.commons.extension.synchronized
import com.lambda.client.event.listener.listener
import net.minecraft.entity.player.EntityPlayer
import net.minecraftforge.client.event.ClientChatReceivedEvent
import net.minecraftforge.fml.common.gameevent.TickEvent
import java.util.*

object AutoEZ : Module(
name = "AutoEZ",
category = Category.COMBAT,
description = "Sends an insult in chat after killing someone"
description = "Sends an insult in chat after killing someone",
category = Category.COMBAT
) {
private const val UNCHANGED = "Unchanged"
private const val NAME = "\$NAME"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
package com.lambda.client.module.modules.combat

import com.lambda.client.commons.utils.MathUtils.reverseNumber
import com.lambda.client.event.SafeClientEvent
import com.lambda.client.event.events.GuiEvent
import com.lambda.client.event.listener.listener
import com.lambda.client.manager.managers.FriendManager
import com.lambda.client.manager.managers.PlayerPacketManager
import com.lambda.client.manager.managers.PlayerPacketManager.sendPlayerPacket
Expand All @@ -15,8 +17,6 @@ import com.lambda.client.util.items.swapToSlot
import com.lambda.client.util.math.Vec2f
import com.lambda.client.util.threads.runSafe
import com.lambda.client.util.threads.safeListener
import com.lambda.client.commons.utils.MathUtils.reverseNumber
import com.lambda.client.event.listener.listener
import net.minecraft.enchantment.EnchantmentHelper
import net.minecraft.entity.player.EntityPlayer
import net.minecraft.init.Enchantments
Expand All @@ -28,10 +28,9 @@ import net.minecraftforge.fml.common.gameevent.TickEvent

object AutoMend : Module(
name = "AutoMend",
category = Category.COMBAT,
description = "Automatically mends armour"
description = "Automatically mends armour",
category = Category.COMBAT
) {

private val autoThrow by setting("Auto Throw", true)
private val throwDelay = setting("Throw Delay", 2, 0..5, 1, description = "Number of ticks between throws to allow absorption")
private val autoSwitch by setting("Auto Switch", true)
Expand Down
Loading