A few months ago, I published an aimbot & esp for shellshock.io on greasyfork.com. It gets around 150-400 installs per day. Has 10k+ installs in total as of writing. In this post, I will be explaining how it was done. This post will be split into 3 parts. The first part will cover what an aimbot requires to work. Second, the development of the aimbot. And third, the development of the ESP (or vision through walls). This post could be helpful for peeps wondering how cheats for web games are made. I would suggest looking through the code of the script while reading to better understand this post. You can find it here.
Starting off
What are the things an aimbot requires to work? The positions of players in the game and a way to set the local player’s aim. How do you find these? You can look for them in the main JS file of the game. How do you find the js file? View the source of the HTML page and search for .js
and use some basic logic.
Going further and looking into the loadJS
function reveals that the game uses an XHR to fetch the js file. This is useful for us. We can proxy XHR, inject our code into the fetched js file and let the game run it.
This part of the script takes care of proxying XMLHttpRequest
and injecting our needed code.
Now that we have a way to modify the main game file, it’s time to find the two things our aimbot needs to work. How do I find the players list? It all comes down to reasoning and logic. How will anyone store players? Either as an object or an array. Shellshock stores it as an array. How do you find this array? You can look for = []
in the beautified version of the js file and use a little bit of guesswork to figure out which one could be the player list. In our case, the highlighted variable in the code below was the players list.
Note: You should never use the exact var name in your script cos var names change whenever the code is rebuilt (aka update is pushed by the developers). You should use regular expressions to find the var names.
We can similarly find a way to set the aim of our local player by a little bit of reasoning and guesswork. We know that the aim change when the mouse moves. In browser-based FPS games, movementX
and movementY
properties of the MouseEvent
object are used to change the aim when the cursor moves. Searching for movementX
, we find this function that has a health check to determine if our local player is alive. This local player object also has yaw and pitch properties which we can alter to change the aim.
We now have access to everything our aimbot needs. Time to move on to next part!
Making it aim
This is pretty EZ to do. You just find the closest player to you, calculate its yaw and pitch from your local player, and then set the aim of your local player. There are also a few checks to prevent aiming at your teammates. Below is the code for finding the nearest player and aiming at it.
The interesting part here is the Math.radAdd
function. It solves a major problem. Without it, some hits won’t be registered. It was an issue with my script for a long time. There were many complaints about it. The thing was that the game stores the yaw up to some fixed precision. Math.radAdd
automatically reduces the precision to what the game expects, thus solving the issue.
Making the ESP
ESP is by far the simplest thing one. All you have to do is attach a box to the player models and tell the game engine to render it on top of everything. Shellshock.io uses Babylon.JS for rendering and Babylon provides a very easy-to-use interface for telling which objects to render on top of everything.
The script also shows a line between your local player and the enemies. It is good for keeping an eye on eggies behind you. But I won’t be going over the creation of that. This post has been pretty big already. It’s also not that important in my opinion. If you are just starting out creating scripts for web games, I think this should’ve given you great insight into how things are done already. Thank you for reading! Keep scripting!
THANKS FOR HELPING
i got a 45 shell streak with this! sadly there are no effects after the 10 kills
very good
man this hack is really good and i just wanna thank you for this hack and i really appreciate it thank you so much
nice
PLEASEEEEEEEEEE DO JUMPAR:IO HAAAAAAAACK
pls make a script that uses less battery and does make your ping so high
exelente
i dont know how to do aimbot
ya it working
Good
cool nice
cool
i love it
nice
COOOOL
i guess is good
awesome script i have been using them for awhile now. I would love to see a script for digdig.io were you can zoom out and see the whole map. also is there any way that the shell shockers script could only lock on when zoomed in?
yo this is so good
awesome
hi i like hack
Nice
thanks
cool
i just love you
it the best
i like aimbot
NICE
Can you do a free skin script for shellshock.io cuz other skin scripts only show that you have that skin while when others in the game look at you, you dont have any skins.
it so super duper cool aimbot is so cool
me gusto pero no lo que me aparese
it is a good hack but I can’t get it to work
cool beans
idk if its just my computer because it won’t let me go to shell, but if i remove it, it lets me. fix?
wow thx tysm this is legit
super good
thx im gonna try it and hop it works
si pero no me gusta la z
i love youuuuuuuuuuuuuuuuuuuuuu
porfa no lo puedo funcionar
i really like this hack works well
Best script ever!!
WOW AMAZING
muy bueno shell shockers
so good legit:)
nice :=)
esta muy bien el hack
Best script¡¡¡
very nice but wish u can change the controlls for the aimbot
es un buen hack lo amo
AWESOME
so op
your the best like omg
good
ya it works
yo this is so fken so sos much more luvable forn dis game
good
cool
I get read your own article. It’s extremely helpful. We will benefit a great deal from the item. Fluent
emm my suggestion is to detect if the enemy is behind wall or not behind wall in the aimbot. otherwise the aimbot will brings you to a enemy behind wall and then an enemy that is beside you and can see you killed you
this is a great hack and probably the only one that works good job man keep it up your already 1 step ahead of all the other people who create hacks.
it’s great but the resolution is garbage when enabled hacks
thanks
thanks
its good
nice it works
wow nice
nice
Would there be a way to add an ESP for the grenades on the ground? So you could see them too? If so could u show us how it works in a post like this one, or is it pretty much the same as with the players?
wow great
cool
nice
hi this actually works
nice work
works
pls make this cheat better by only tracking enemies that arent through walls lol
good explanation
nice aimbot but maybe it can improve
thank you so much i hope this works
help! it keeps saying adblocker And i dont have one. i also whitelised and still doesnt work.
pretty cool bro
pretty cool bro
this is awsome
very good I would say, got a kill streak of 52! though i don’t like when i go to shell shockers this screen apear, what ever its good.
Cool I like it but I want 100000 eggs so hard. But aimbot coool
yo all goods cheat my bro
very nice
awesome it worked
so gd 72 kill sreak
very cool
thanks for aimbot
worked
very nice
You could maby add a inf ammo or something like that and the aimbot is cool
Infinite ammo is not possible.
good
It is very usefull,thanks!
Yes so getting be honest the hack is good i am about to buy it but their is 1 requirment the thing i donot like about hack is it uses the nearest enemy to aim which sucks and many times i tried to aim the near person and the person behinde it kill me even i am try to aim the behinde one person in past i used to buy a hack from a person he makes the aimbot in a way that when we aim an enemy no issue if near or far an d click right mouse button i mean hold the right mouse button it directly lock the aim to that enemy ignoring the enemy infront if him and behinde him which is easier to use and make easier to use aimbot so i better suggust you to inckude this in your hack as soon as possible so i can Buy it 🙂 hey Developer if you read this and understood what i mean to change in hack let me have a replay
Yes so getting be honest the hack is good i am about to buy it but their is 1 requirment the thing i donot like about hack is it uses the nearest enemy to aim which sucks and many times i tried to aim the near person and the person behinde it kill me even i am try to aim the behinde one person in past i used to buy a hack from a person he makes the aimbot in a way that when we aim an enemy no issue if near or far an d click right mouse button i mean hold the right mouse button it directly lock the aim to that enemy ignoring the enemy infront if him and behinde him which is easier to use and make easier to use aimbot so i better suggust you to inckude this in your hack as soon as possible so i can Buy it 🙂 hey Developer if you read this and understood what i mean to change in hack let me have a replay