-
Notifications
You must be signed in to change notification settings - Fork 92
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
13 changed files
with
185 additions
and
262 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,38 +1,36 @@ | ||
# The virtual key code key which activates the aim bot when held | ||
aim_key=5 | ||
|
||
# The speed of the aim as a percentile, lower being slower, higher being faster | ||
# I recommend to not use 0.5 or greater due to massively increased flicks. | ||
speed=0.333 | ||
# Your in-game sensitivity. | ||
sensitivity=10.0 | ||
|
||
# The number of frames per second to capture the game at. | ||
# The higher this is, the faster the aim speed, relative to the sensitivity. | ||
fps=60 | ||
|
||
# Calculates aim box width by dividing screen width by this value | ||
box_width_divisor=4.0 | ||
box_width_divisor=10.0 | ||
# Calculates aim box height by dividing screen height by this value | ||
box_height_divisor=2.5 | ||
box_height_divisor=12.0 | ||
|
||
# Divides the box width/height by this value to use as a maximum possible aim snap. | ||
max_snap_divisor=2.0 | ||
|
||
# The RGB hex color code to use as a basis to aim at. | ||
# The RGB hex color codes to use as a basis to aim at. | ||
# | ||
# You should prefer magenta since it is a unique color not often used. | ||
# | ||
# Samples: | ||
# Red: ff0013 | ||
# Neon: 21d4d7 | ||
# Magenta: e23be9 | ||
target_color=e23be9 | ||
target_color=dd32db,db33d8,e23be9,d619dd,d200d6 | ||
|
||
# The amount of tolerance for the difference between the target color and the scanned screen color. | ||
target_color_tolerance=20 | ||
target_color_tolerance=16 | ||
|
||
# Checks if window title contains this. | ||
# Usually you want this set to "Overwatch". | ||
# | ||
# If you are color blocked (error 5), you can use | ||
# "Fullscreen Projector" in OBS and here. | ||
window_title_search=Fullscreen Projector | ||
window_title_search=Overwatch | ||
|
||
# The native mouse device ID, usually this should be 11. | ||
# The range is 11..20 for mouse IDs, and 1..10 for keyboard IDs. | ||
device_id=11 | ||
|
||
# A divisor for your screen dimensions, as a limit for maximum movement per aim. | ||
# Generally the default of 128 is fine, but raising it will reduce flicks, lowering may introduce more. | ||
max_distance_divisor=128 | ||
device_id=11 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
/* | ||
* Free, open-source undetected color cheat for Overwatch! | ||
* Copyright (C) 2017 Thomas G. Nappo | ||
* | ||
* This program is free software: you can redistribute it and/or modify | ||
* it under the terms of the GNU Affero General Public License as published by | ||
* the Free Software Foundation, either version 3 of the License, or | ||
* (at your option) any later version. | ||
* | ||
* This program is distributed in the hope that it will be useful, | ||
* but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
* GNU Affero General Public License for more details. | ||
* | ||
* You should have received a copy of the GNU Affero General Public License | ||
* along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
*/ | ||
|
||
package com.overwatcheat | ||
|
||
import com.overwatcheat.Overwatcheat.SETTINGS | ||
import it.unimi.dsi.fastutil.ints.IntOpenHashSet | ||
import it.unimi.dsi.fastutil.ints.IntSet | ||
|
||
object Colors { | ||
|
||
private val set: IntSet = IntOpenHashSet() | ||
|
||
fun colorMatches(rgb: Int) = set.contains(rgb) | ||
|
||
fun init() { | ||
val tolerance = SETTINGS.targetColorTolerance | ||
val rgbs = SETTINGS.targetColors | ||
for (rgb in rgbs) { | ||
val r = (rgb and 0xFF_00_00) ushr 16 | ||
val g = (rgb and 0x00_FF_00) ushr 8 | ||
val b = rgb and 0x00_00_FF | ||
|
||
for (ri in -tolerance..tolerance) { | ||
val nr = r + ri | ||
for (gi in -tolerance..tolerance) { | ||
val ng = g + gi | ||
for (bi in -tolerance..tolerance) { | ||
val nb = b + bi | ||
val nrgb = ((nr and 0xFF) shl 16) or ((ng and 0xFF) shl 8) or (nb and 0xFF) | ||
set.add(nrgb) | ||
} | ||
} | ||
} | ||
} | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.