Skip to content

Commit

Permalink
Merge pull request #10 from sotakoira/008
Browse files Browse the repository at this point in the history
008
  • Loading branch information
sotakoira authored Jul 5, 2021
2 parents aca8a53 + f92a9bc commit 63ec704
Showing 1 changed file with 22 additions and 1 deletion.
23 changes: 22 additions & 1 deletion src/main/kotlin/rat/poison/ui/DisableDetected.kt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,12 @@ package rat.poison.ui

import com.badlogic.gdx.graphics.Color
import rat.poison.curSettings
import rat.poison.game.CSGO.csgoEXE
import rat.poison.game.me
import rat.poison.game.netvars.NetVarOffsets.flFlashMaxAlpha
import rat.poison.game.offsets.ClientOffsets.bOverridePostProcesing
import rat.poison.overlay.opened
import rat.poison.scripts.visuals.disableAllEsp
import rat.poison.ui.tabs.boxEspTab
import rat.poison.ui.tabs.espTabbedPane
import rat.poison.ui.tabs.footStepsEspTab
Expand Down Expand Up @@ -51,4 +56,20 @@ fun disableDetectedUpdate() {
mainTabbedPane.disableTab(ranksTab, bool)
}

}
optionsTab.disableDetected.changed { _, _ ->
disableAllEsp()
if (curSettings["DISABLE_POST_PROCESSING"].strToBool()) {
if (csgoEXE.boolean(bOverridePostProcesing)) {
csgoEXE[bOverridePostProcesing] = false
}
}
// kinda ghetto but who cares, you don't expect end user to spam the checkbox so
if (curSettings["ENABLE_REDUCED_FLASH"].strToBool()) {
if ((me > 0) && (csgoEXE.float(me + flFlashMaxAlpha) < 255F)) {
csgoEXE[me + flFlashMaxAlpha] = 255F
}
}
}

}

0 comments on commit 63ec704

Please sign in to comment.