Size
17.7 KB
Version
1.1.1
Created
Oct 30, 2025
Updated
about 1 month ago
1// ==UserScript==
2// @name Shell Shockers Aimbot + ESP + Noclip
3// @description A new extension
4// @version 1.1.1
5// @match https://*.shellshock.io/*
6// @run-at document-start
7// @grant none
8// ==/UserScript==
9(function() {
10 'use strict';
11
12 console.log('[Shell Shockers Aimbot] Extension loaded');
13
14 // Settings
15 const settings = {
16 aimbotEnabled: true,
17 aimbotKey: 'b',
18 espEnabled: true,
19 espKey: 'v',
20 espLinesEnabled: true,
21 espLinesKey: 'n',
22 noclipEnabled: false,
23 noclipKey: 'm',
24 aimbotSmoothness: 3,
25 aimOnRightClick: false
26 };
27
28 // Store settings globally
29 window.settings = settings;
30 window.aimbotActive = settings.aimbotEnabled;
31 window.espActive = settings.espEnabled;
32 window.espLinesActive = settings.espLinesEnabled;
33 window.noclipActive = settings.noclipEnabled;
34
35 // Intercept Worker creation to catch game code
36 const OriginalWorker = window.Worker;
37 window.Worker = class extends OriginalWorker {
38 constructor(...args) {
39 console.log('[Shell Shockers Aimbot] Worker intercepted:', args[0]);
40 super(...args);
41 }
42 };
43
44 // Intercept script loading
45 const originalCreateElement = document.createElement;
46 document.createElement = function(tagName) {
47 const element = originalCreateElement.call(document, tagName);
48
49 if (tagName.toLowerCase() === 'script') {
50 const originalSetAttribute = element.setAttribute.bind(element);
51 element.setAttribute = function(name, value) {
52 if (name === 'src' && typeof value === 'string') {
53 console.log('[Shell Shockers Aimbot] Script loading:', value);
54 }
55 return originalSetAttribute(name, value);
56 };
57 }
58
59 return element;
60 };
61
62 // Override XMLHttpRequest to intercept game code
63 const OriginalXHR = XMLHttpRequest;
64 XMLHttpRequest = function() {
65 const xhr = new OriginalXHR();
66 const originalOpen = xhr.open;
67 const originalSend = xhr.send;
68
69 xhr.open = function(method, url, ...rest) {
70 this._url = url;
71 console.log('[Shell Shockers Aimbot] XHR Open:', url);
72 return originalOpen.call(this, method, url, ...rest);
73 };
74
75 xhr.send = function(...args) {
76 const self = this;
77
78 this.addEventListener('readystatechange', function() {
79 if (self.readyState === 4 && self.status === 200) {
80 const url = self._url || '';
81 const response = self.responseText;
82
83 // Check if this is the game code
84 if (response && response.length > 100000 && response.includes('Vector3')) {
85 console.log('[Shell Shockers Aimbot] Found game code! Length:', response.length);
86
87 try {
88 const modifiedCode = injectAimbotCode(response);
89
90 // Override response properties
91 Object.defineProperty(self, 'responseText', {
92 writable: true,
93 value: modifiedCode
94 });
95 Object.defineProperty(self, 'response', {
96 writable: true,
97 value: modifiedCode
98 });
99
100 console.log('[Shell Shockers Aimbot] Code modified successfully!');
101 } catch (e) {
102 console.error('[Shell Shockers Aimbot] Error modifying code:', e);
103 }
104 }
105 }
106 });
107
108 return originalSend.apply(this, args);
109 };
110
111 return xhr;
112 };
113 XMLHttpRequest.prototype = OriginalXHR.prototype;
114
115 // Override fetch
116 const originalFetch = window.fetch;
117 window.fetch = async function(...args) {
118 const url = typeof args[0] === 'string' ? args[0] : args[0]?.url;
119
120 if (url) {
121 console.log('[Shell Shockers Aimbot] Fetch:', url);
122 }
123
124 const response = await originalFetch.apply(this, args);
125
126 // Check if this is a JavaScript file
127 if (url && url.includes('.js')) {
128 const clonedResponse = response.clone();
129 const text = await clonedResponse.text();
130
131 // Check if this is the game code
132 if (text.length > 100000 && text.includes('Vector3')) {
133 console.log('[Shell Shockers Aimbot] Found game code via fetch! Length:', text.length);
134
135 try {
136 const modifiedCode = injectAimbotCode(text);
137 return new Response(modifiedCode, {
138 status: response.status,
139 statusText: response.statusText,
140 headers: response.headers
141 });
142 } catch (e) {
143 console.error('[Shell Shockers Aimbot] Error modifying fetched code:', e);
144 }
145 }
146 }
147
148 return response;
149 };
150
151 function injectAimbotCode(code) {
152 console.log('[Shell Shockers Aimbot] Starting code injection...');
153
154 try {
155 // Find variable names using regex patterns
156 const babylonMatch = /new ([a-zA-Z_$][a-zA-Z0-9_$]*)\.Vector3/.exec(code);
157 const playersMatch = /([a-zA-Z_$][a-zA-Z0-9_$]*)=\[\],\{\}/.exec(code);
158 const myPlayerMatch = /"fire":document\.pointerLockElement&&([^&]+)&&/.exec(code);
159
160 if (!babylonMatch) {
161 console.error('[Shell Shockers Aimbot] Could not find Babylon variable');
162 return code;
163 }
164 if (!playersMatch) {
165 console.error('[Shell Shockers Aimbot] Could not find players array');
166 return code;
167 }
168 if (!myPlayerMatch) {
169 console.error('[Shell Shockers Aimbot] Could not find myPlayer variable');
170 return code;
171 }
172
173 const BABYLON = babylonMatch[1];
174 const players = playersMatch[1];
175 const myPlayer = myPlayerMatch[1];
176
177 console.log('[Shell Shockers Aimbot] Found variables:', { BABYLON, players, myPlayer });
178
179 // Aimbot injection code
180 const aimbotCode = `
181// === AIMBOT INJECTION START ===
182(function() {
183 console.log('[Shell Shockers Aimbot] Aimbot initialized!');
184
185 // Toggle message
186 function showToggleMessage(feature, enabled) {
187 let msg = document.getElementById('aimbot-toggle-msg');
188 if (!msg) {
189 msg = document.createElement('div');
190 msg.id = 'aimbot-toggle-msg';
191 msg.style.cssText = 'position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);background:rgba(0,0,0,0.9);color:#fff;padding:30px 50px;border-radius:15px;font-size:28px;font-weight:bold;z-index:99999;pointer-events:none;border:3px solid #0f0;box-shadow:0 0 20px rgba(0,255,0,0.5);';
192 document.body.appendChild(msg);
193 }
194 msg.textContent = feature + ': ' + (enabled ? 'ON' : 'OFF');
195 msg.style.display = 'block';
196 setTimeout(() => { msg.style.display = 'none'; }, 1500);
197 }
198
199 // Keyboard controls
200 document.addEventListener('keydown', (e) => {
201 if (e.key.toLowerCase() === 'b') {
202 window.aimbotActive = !window.aimbotActive;
203 showToggleMessage('AIMBOT', window.aimbotActive);
204 console.log('[Aimbot] Toggled:', window.aimbotActive);
205 }
206 if (e.key.toLowerCase() === 'v') {
207 window.espActive = !window.espActive;
208 showToggleMessage('ESP', window.espActive);
209 console.log('[ESP] Toggled:', window.espActive);
210 }
211 if (e.key.toLowerCase() === 'n') {
212 window.espLinesActive = !window.espLinesActive;
213 showToggleMessage('ESP LINES', window.espLinesActive);
214 console.log('[ESP Lines] Toggled:', window.espLinesActive);
215 }
216 if (e.key.toLowerCase() === 'm') {
217 window.noclipActive = !window.noclipActive;
218 showToggleMessage('NOCLIP', window.noclipActive);
219 console.log('[Noclip] Toggled:', window.noclipActive);
220 }
221 });
222
223 // Main aimbot function
224 window.doAimbot = function(me, allPlayers) {
225 try {
226 if (!me || !allPlayers || !Array.isArray(allPlayers)) return;
227
228 // Noclip functionality
229 if (window.noclipActive && me.actor && me.actor.body) {
230 // Disable collision detection
231 if (me.actor.body.checkCollisions !== false) {
232 me.actor.body.checkCollisions = false;
233 console.log('[Noclip] Enabled collision bypass');
234 }
235 } else if (me.actor && me.actor.body && me.actor.body.checkCollisions === false) {
236 me.actor.body.checkCollisions = true;
237 console.log('[Noclip] Disabled collision bypass');
238 }
239
240 // Aimbot functionality
241 if (window.aimbotActive) {
242 let closestEnemy = null;
243 let closestDist = Infinity;
244
245 // Find closest enemy
246 for (let i = 0; i < allPlayers.length; i++) {
247 const p = allPlayers[i];
248 if (!p || !p.actor || !p.actor.mesh) continue;
249 if (p === me) continue;
250 if (p.team === me.team) continue;
251 if (!p.hp || p.hp <= 0) continue;
252
253 const dx = p.x - me.x;
254 const dy = p.y - me.y;
255 const dz = p.z - me.z;
256 const dist = Math.sqrt(dx*dx + dy*dy + dz*dz);
257
258 if (dist < closestDist) {
259 closestDist = dist;
260 closestEnemy = p;
261 }
262 }
263
264 // Aim at closest enemy
265 if (closestEnemy && closestDist < 150) {
266 const weaponVelocity = me.weapon?.subClass?.velocity || 1;
267 const travelTime = closestDist / weaponVelocity;
268
269 // Predict enemy position
270 const targetX = closestEnemy.x + (closestEnemy.dx || 0) * travelTime;
271 const targetY = closestEnemy.y + (closestEnemy.dy || 0) * travelTime + 0.6;
272 const targetZ = closestEnemy.z + (closestEnemy.dz || 0) * travelTime;
273
274 const deltaX = targetX - me.x;
275 const deltaY = targetY - me.y;
276 const deltaZ = targetZ - me.z;
277
278 const vec = new ${BABYLON}.Vector3(deltaX, deltaY, deltaZ).normalize();
279 const targetYaw = -Math.atan2(vec.z, vec.x) + Math.PI / 2;
280 const targetPitch = Math.max(-1.5, Math.min(1.5, -Math.asin(vec.y)));
281
282 // Smooth aiming
283 const smooth = window.settings?.aimbotSmoothness || 3;
284 me.yaw += (targetYaw - me.yaw) / smooth;
285 me.pitch += (targetPitch - me.pitch) / smooth;
286 }
287 }
288
289 // ESP functionality
290 if (window.espActive) {
291 for (let i = 0; i < allPlayers.length; i++) {
292 const p = allPlayers[i];
293 if (!p || !p.actor || !p.actor.mesh) continue;
294 if (p === me) continue;
295
296 const isTeammate = p.team === me.team;
297 const color = isTeammate ? new ${BABYLON}.Color3(0, 1, 0) : new ${BABYLON}.Color3(1, 0, 0);
298
299 // Create ESP box
300 if (!p._espBox) {
301 const box = ${BABYLON}.MeshBuilder.CreateBox('esp_' + i, {size: 2}, p.actor.scene);
302 box.material = new ${BABYLON}.StandardMaterial('espMat_' + i, p.actor.scene);
303 box.material.emissiveColor = color;
304 box.material.wireframe = true;
305 box.material.alpha = 0.8;
306 box.parent = p.actor.mesh;
307 box.renderingGroupId = 1;
308 box.isPickable = false;
309 p._espBox = box;
310 }
311 p._espBox.isVisible = true;
312 p._espBox.material.emissiveColor = color;
313
314 // Create ESP lines
315 if (window.espLinesActive) {
316 if (!p._espLine) {
317 const origin = new ${BABYLON}.Vector3(0, 0, 0);
318 const line = ${BABYLON}.MeshBuilder.CreateLines('espLine_' + i, {
319 points: [origin, p.actor.mesh.position],
320 updatable: true
321 }, p.actor.scene);
322 line.color = color;
323 line.renderingGroupId = 1;
324 line.isPickable = false;
325 p._espLine = line;
326 }
327 p._espLine.isVisible = true;
328 p._espLine.color = color;
329
330 // Update line position
331 const origin = new ${BABYLON}.Vector3(0, 0, 0);
332 ${BABYLON}.MeshBuilder.CreateLines('espLine_' + i, {
333 points: [origin, p.actor.mesh.position],
334 instance: p._espLine
335 });
336 } else {
337 if (p._espLine) p._espLine.isVisible = false;
338 }
339 }
340 } else {
341 // Hide all ESP
342 for (let i = 0; i < allPlayers.length; i++) {
343 const p = allPlayers[i];
344 if (p && p._espBox) p._espBox.isVisible = false;
345 if (p && p._espLine) p._espLine.isVisible = false;
346 }
347 }
348 } catch (err) {
349 console.error('[Aimbot Error]', err);
350 }
351 };
352})();
353// === AIMBOT INJECTION END ===
354`;
355
356 // Find render loop and inject call
357 const renderLoopRegex = /\.runRenderLoop\(function\(\)\{/;
358 const renderMatch = renderLoopRegex.exec(code);
359
360 if (!renderMatch) {
361 console.error('[Shell Shockers Aimbot] Could not find render loop');
362 return code;
363 }
364
365 console.log('[Shell Shockers Aimbot] Found render loop at position:', renderMatch.index);
366
367 // Inject aimbot code at the start
368 let modifiedCode = aimbotCode + '\n' + code;
369
370 // Calculate adjusted position
371 const adjustedPos = renderMatch.index + aimbotCode.length + 1;
372
373 // Inject aimbot call in render loop
374 const aimbotCall = `try{if(typeof window.doAimbot==='function'){window.doAimbot(${myPlayer},${players});}}catch(e){console.error('[Aimbot Call Error]',e);}`;
375 modifiedCode = modifiedCode.slice(0, adjustedPos + renderMatch[0].length) +
376 aimbotCall +
377 modifiedCode.slice(adjustedPos + renderMatch[0].length);
378
379 console.log('[Shell Shockers Aimbot] Code injection complete!');
380 return modifiedCode;
381
382 } catch (error) {
383 console.error('[Shell Shockers Aimbot] Injection error:', error);
384 return code;
385 }
386 }
387
388 // Create UI
389 function createUI() {
390 const ui = document.createElement('div');
391 ui.id = 'aimbot-ui';
392 ui.style.cssText = 'position:fixed;top:10px;left:10px;background:rgba(0,0,0,0.85);color:#0f0;padding:15px;border-radius:10px;font-family:monospace;font-size:14px;z-index:99998;border:2px solid #0f0;box-shadow:0 0 15px rgba(0,255,0,0.6);min-width:250px;';
393 ui.innerHTML = `
394 <div style="font-weight:bold;margin-bottom:10px;color:#0f0;text-shadow:0 0 5px #0f0;font-size:16px;text-align:center;">🎯 SHELL SHOCKERS AIMBOT</div>
395 <div style="margin:5px 0;padding:5px;background:rgba(0,255,0,0.1);border-radius:5px;">Press <b style="color:#ff0;">B</b> - Toggle Aimbot</div>
396 <div style="margin:5px 0;padding:5px;background:rgba(0,255,0,0.1);border-radius:5px;">Press <b style="color:#ff0;">V</b> - Toggle ESP</div>
397 <div style="margin:5px 0;padding:5px;background:rgba(0,255,0,0.1);border-radius:5px;">Press <b style="color:#ff0;">N</b> - Toggle ESP Lines</div>
398 <div style="margin:5px 0;padding:5px;background:rgba(0,255,0,0.1);border-radius:5px;">Press <b style="color:#ff0;">M</b> - Toggle Noclip</div>
399 <div style="margin-top:10px;font-size:12px;opacity:0.8;text-align:center;border-top:1px solid #0f0;padding-top:8px;">Status: <span style="color:#0f0;font-weight:bold;">ACTIVE</span></div>
400 `;
401 document.body.appendChild(ui);
402 console.log('[Shell Shockers Aimbot] UI created');
403 }
404
405 // Initialize UI when DOM is ready
406 if (document.readyState === 'loading') {
407 document.addEventListener('DOMContentLoaded', createUI);
408 } else {
409 setTimeout(createUI, 1000);
410 }
411
412 console.log('[Shell Shockers Aimbot] Ready! Waiting for game to load...');
413
414})();