[Robot-JS] TriggerBot - All Resolutions [Code Only]
[Robot-JS] TriggerBot - All Resolutions [Code Only]---------------------------------------------------------------------------------------------------------------------------------------------------------------------
This uses Robot-JS, and automation tool.
Why Javascript?
Most automation tools are detected by Blizzard, but Java is so common on systems that it's hard to detect.
Is it safe?
Yes, it runs using Node, which is a common background service for webservices.
Code:
"use strict";
var robot = require("robot-js");
var mouse = robot.Mouse();
var keyboard = robot.Keyboard();
mouse.autoDelay.min = 1;
mouse.autoDelay.max = 1;
var img = robot.Image();
var targetColor = [0xF2361B,0xEF3519,0xEE4131,0xED4233,0xEE4031,0xCF8790,0xCF878F,0xD92411,0xDC2613,0xA24D53,0xA84547,0xB25C62,0xAB545B];
var pixelColor = robot.Color();
var i = 0;
var k = 0;
var data,r2,g2,b2,r1,g1,b1,s;
if (robot.Screen.synchronize()) {
robot.Screen.setCompositing (false);
robot.Screen.grabScreen(img);
}
var w = img.getWidth()/2;
var h = img.getHeight()/2;
var searchSize = .97;
var step = 3;
console.log("Only single monitor is supported. Please run CMD as administrator (prevents Overwatch from seeing CMD's actions). Change SearchSize and Step to your liking, SearchSize should be between .90 and .99, the bigger SearchSize is, the smaller the search box. Step is how many pixels to skip, will result in a faster scan but slower response. Center is: " + w + ", " + h);
while(1)
{
s = robot.Mouse.getState();
if(s[robot.BUTTON_X2])
bang();
}
function bang()
{
robot.Screen.grabScreen(img, Math****und(searchSize * w), Math****und(searchSize * h), Math****und((1-searchSize) * w), Math****und((1-searchSize) * h));
data = img.getData();
for(i = 0; i < img.getLength(); i+=step)
{
if(similar((data[i] & 0x00FFFFFF).toString(16).toUpperCase(),15) )
{
keyboard.click(robot.KEY_N);
return;
}
}
return;
}
function similar (aneighbor, atolerance)
{
if(atolerance == undefined)
{
atolerance = 10;
}
r2 = parseInt(aneighbor.substr(0,2), 16);
g2 = parseInt(aneighbor.substr(2,2), 16);
b2 = parseInt(aneighbor.substr(4,2), 16);
for(k = 0; k < targetColor.length; k++)
{
r1 = parseInt(targetColor[k].toString(16).toUpperCase().substr(0,2), 16);
g1 = parseInt(targetColor[k].toString(16).toUpperCase().substr(2,2), 16);
b1 = parseInt(targetColor[k].toString(16).toUpperCase().substr(4,2), 16);
if (Math.abs(r1 - r2) <= atolerance && Math.abs(g1 - g2) <= atolerance && Math.abs(b1 - b2) <= atolerance)
{
//console.log(r2 + " " + b2 + " " + g2 + " " + r1 + " " + b1 + " " + g1);
return true;
}
}
return false;
1) Go to the NodeJS website and install the latest version for windows.
2) Create a folder on your desktop called 'Overwatch'
3) Open 'Search' and type CMD (command prompt)
4) use this command without quotes "cd C:\Users\[user]\Desktop\Overwatch" (replace [user] with your PC username)
5) type without quotes "npm install robot-js" and press enter, wait for it to finish.
6) copy the code from OP and paste into a notepad file
7) File > Save as > 'All File types' > Trigger.js (save it in the same Overwatch folder)
Open Overwatch
9) Go to command prompt again, if you closed it redo the command from step 4) if you didn't close it then just type without quotes "node Trigger.js"
10) enjoy
2) Create a folder on your desktop called 'Overwatch'
3) Open 'Search' and type CMD (command prompt)
4) use this command without quotes "cd C:\Users\[user]\Desktop\Overwatch" (replace [user] with your PC username)
5) type without quotes "npm install robot-js" and press enter, wait for it to finish.
6) copy the code from OP and paste into a notepad file
7) File > Save as > 'All File types' > Trigger.js (save it in the same Overwatch folder)
Open Overwatch
9) Go to command prompt again, if you closed it redo the command from step 4) if you didn't close it then just type without quotes "node Trigger.js"
10) enjoy
This is not the best aimbot, but it is currently the safest option.
I'm not responsible if you get banned.
Enjoy,
SuperHaxors
Nguồn : http://www.mpgh.net/forum/showthread.php?t=1130825&s=04de05e05351990a25ad0a3fa2581d13
0 comments:
Post a Comment