Unlimited Dropper

gfagedewfwfwefe

  1. // ==UserScript==
  2. // @name Unlimited Dropper
  3. // @namespace http://tampermonkey.net/
  4. // @version 0.8
  5. // @description gfagedewfwfwefe
  6. // @author
  7. // @icon
  8. // @match https://starve.io/*
  9. // @grant none
  10.  
  11.  
  12. // ==/UserScript==
  13.  
  14. // Lea deteniadamente para modificar las KEYs si lo hace mal el script se danara
  15. // Linea 403 y 739 Para el auto hit ! se activa con E
  16. // Linea 399 Para craftear automaticamente ! se activa con Q
  17. // Linea 401 Para craftear vendas ! se activa con X
  18. // Linea 756 Para poner ultima construccion ! se activa con V
  19. // Linea 754 Para dropear el ultimo item dropea por defecto madera ! se activa con C
  20. // Linea 659 662 665 668 invendario por defecto configurelo a su gusto
  21. // Siempre sera de dia ??
  22. // Mapa incluido ???
  23. //
  24.  
  25.  
  26. // ALERTA 3
  27. (() => {
  28. const backgroundImageURL = "";
  29.  
  30. const background = {
  31. ready: false,
  32. image: new Image()
  33. };
  34.  
  35. let _fillText = CanvasRenderingContext2D.prototype.fillText;
  36. let _fillRect = CanvasRenderingContext2D.prototype.fillRect;
  37. let _alert = window.alert;
  38. let _toString = Function.prototype.toString;
  39.  
  40.  
  41. let fillText = function () {
  42. if (arguments[0] == "You are dead") {// You are dead
  43. arguments[0] = "You are dead";
  44.  
  45. this.fillStyle = gradient;
  46.  
  47.  
  48. }
  49. return _fillText.apply(this, arguments);
  50. };
  51. let fillRect = function () {
  52. if (arguments[0] > 10 && arguments[0] > 10 && background.ready){
  53. this.fillStyle = "rgba(87,89,93)";
  54. this.setTransform(1, 0, 0, 1, 0, 0);
  55.  
  56. }
  57. return _fillRect.apply(this, arguments);
  58. };
  59. let alert = function () {
  60. return _alert.call(this, "Extension detection was triggered. Please refresh.");
  61. };
  62. let toString = function () {
  63. if (this == CanvasRenderingContext2D.prototype.fillText) return _toString.call(_fillText);
  64. if (this == CanvasRenderingContext2D.prototype.fillRect) return _toString.call(_fillRect);
  65. if (this == window.alert) return _toString.call(_alert);
  66. if (this == Function.prototype.toString) return _toString.call(_toString);
  67. return _toString.call(this);
  68. };
  69.  
  70.  
  71. fillText.__proto__ = _fillText.prototype;
  72. fillText.prototype = _fillText.prototype;
  73. fillRect.__proto__ = _fillRect.prototype;
  74. fillRect.prototype = _fillRect.prototype;
  75. toString.__proto__ = _toString.prototype;
  76. toString.prototype = _toString.prototype;
  77.  
  78.  
  79. CanvasRenderingContext2D.prototype.fillText = fillText;
  80. CanvasRenderingContext2D.prototype.fillRect = fillRect;
  81. window.alert = alert;
  82. Function.prototype.toString = toString;
  83.  
  84. document.currentScript && document.currentScript.remove();
  85. })();
  86.  
  87. // ALERTA 2
  88. (() => {
  89. const backgroundImageURL = "";
  90.  
  91. const background = {
  92. ready: false,
  93. image: new Image()
  94. };
  95.  
  96. let _fillText = CanvasRenderingContext2D.prototype.fillText;
  97. let _fillRect = CanvasRenderingContext2D.prototype.fillRect;
  98. let _alert = window.alert;
  99. let _toString = Function.prototype.toString;
  100.  
  101.  
  102. let fillText = function () {
  103. if (arguments[0] == "A sandstorm is approaching in a few seconds.") {// A sandstorm is approaching in a few seconds.
  104. arguments[0] = "A sandstorm is approaching in a few seconds.";
  105.  
  106. this.fillStyle = gradient;
  107.  
  108.  
  109. }
  110. return _fillText.apply(this, arguments);
  111. };
  112. let fillRect = function () {
  113. if (arguments[0] > 10 && arguments[0] > 10 && background.ready){
  114. this.fillStyle = "rgba(87,89,93)";
  115. this.setTransform(1, 0, 0, 1, 0, 0);
  116.  
  117. }
  118. return _fillRect.apply(this, arguments);
  119. };
  120. let alert = function () {
  121. return _alert.call(this, "Extension detection was triggered. Please refresh.");
  122. };
  123. let toString = function () {
  124. if (this == CanvasRenderingContext2D.prototype.fillText) return _toString.call(_fillText);
  125. if (this == CanvasRenderingContext2D.prototype.fillRect) return _toString.call(_fillRect);
  126. if (this == window.alert) return _toString.call(_alert);
  127. if (this == Function.prototype.toString) return _toString.call(_toString);
  128. return _toString.call(this);
  129. };
  130.  
  131.  
  132. fillText.__proto__ = _fillText.prototype;
  133. fillText.prototype = _fillText.prototype;
  134. fillRect.__proto__ = _fillRect.prototype;
  135. fillRect.prototype = _fillRect.prototype;
  136. toString.__proto__ = _toString.prototype;
  137. toString.prototype = _toString.prototype;
  138.  
  139.  
  140. CanvasRenderingContext2D.prototype.fillText = fillText;
  141. CanvasRenderingContext2D.prototype.fillRect = fillRect;
  142. window.alert = alert;
  143. Function.prototype.toString = toString;
  144.  
  145. document.currentScript && document.currentScript.remove();
  146. })();
  147.  
  148. // ALERTA 2
  149.  
  150. var c = document.getElementById("game_canvas");
  151. var ctx = c.getContext("2d");
  152. var gradient = ctx.createLinearGradient(0, 0, c.width, 0);
  153. gradient.addColorStop("0"," magenta");
  154. gradient.addColorStop("0.5", "blue");
  155. gradient.addColorStop("1.0", "red");
  156.  
  157. (() => {
  158. const backgroundImageURL = "";
  159.  
  160. const background = {
  161. ready: false,
  162. image: new Image()
  163. };
  164.  
  165. let _fillText = CanvasRenderingContext2D.prototype.fillText;
  166. let _fillRect = CanvasRenderingContext2D.prototype.fillRect;
  167. let _alert = window.alert;
  168. let _toString = Function.prototype.toString;
  169.  
  170.  
  171. let fillText = function () {
  172.  
  173. if (arguments[0]== "A blizzard is approaching in a few seconds.") {//A blizzard is approaching in a few seconds.
  174. (arguments[0] = "A blizzard is approaching in a few seconds.");
  175.  
  176. this.fillStyle = gradient;
  177.  
  178. }
  179.  
  180.  
  181. return _fillText.apply(this, arguments);
  182.  
  183.  
  184. };
  185. let fillRect = function () {
  186. if (arguments[2] > 10 && arguments[2] > 10 && background.ready){
  187. this.fillStyle = "rgba(87,89,93)";
  188. this.setTransform(1, 0, 0, 1, 0, 0);
  189.  
  190. }
  191. return _fillRect.apply(this, arguments);
  192. };
  193. let alert = function () {
  194. return _alert.call(this, "Extension detection was triggered. Please refresh.");
  195. };
  196. let toString = function () {
  197. if (this == CanvasRenderingContext2D.prototype.fillText) return _toString.call(_fillText);
  198. if (this == CanvasRenderingContext2D.prototype.fillRect) return _toString.call(_fillRect);
  199. if (this == window.alert) return _toString.call(_alert);
  200. if (this == Function.prototype.toString) return _toString.call(_toString);
  201. return _toString.call(this);
  202. };
  203.  
  204.  
  205. fillText.__proto__ = _fillText.prototype;
  206. fillText.prototype = _fillText.prototype;
  207. fillRect.__proto__ = _fillRect.prototype;
  208. fillRect.prototype = _fillRect.prototype;
  209. toString.__proto__ = _toString.prototype;
  210. toString.prototype = _toString.prototype;
  211.  
  212.  
  213. CanvasRenderingContext2D.prototype.fillText = fillText;
  214. CanvasRenderingContext2D.prototype.fillRect = fillRect;
  215. window.alert = alert;
  216. Function.prototype.toString = toString;
  217.  
  218. document.currentScript && document.currentScript.remove();
  219. })();
  220.  
  221.  
  222.  
  223. //MAPA LATAM
  224. var version = ("Synex Above All");
  225.  
  226. jQuery(document).ready(function(){
  227. document.title = ('' + " " + version);
  228. jQuery("a[href='https://iogames.space']").hide();
  229.  
  230. jQuery('#nickname_input').css({"color": "#ff4d00","font-size":"35","background-color":"#000000"});
  231. jQuery('#chat_input').css({"color": "#000000","font-size":"35","background-color":"#ff9d00"});
  232. jQuery('#game_canvas').css("image-rendering","initial");
  233. jQuery('#trevda').css("visibility","hidden");
  234. jQuery("link[rel='shortcut icon']").attr("href", "");
  235. jQuery("#loading").css({"background-color": "","color":"#ff4d00"});
  236. jQuery("body").on("contextmenu",function(e){
  237. return false;
  238. });
  239.  
  240.  
  241. jQuery("body").append ('<img draggable="false" id="myNewImage" border="7" src="https://i.ibb.co/h7PpgGV/map-verdee.png">')
  242. jQuery("body").append ('<p id="hrs"></p>')
  243. jQuery('body').append('<p id="ratata"> <fondo><img style="margin: -50px 40px " width="100" height= "100" " src="" ></fondo> </p>');
  244. jQuery('body').append('<p id="author"><a target="_blank" href=""></a></p>');
  245.  
  246. jQuery("#author").animate({right: '55px'}).css({
  247. cursor: "url(https://i.ibb.co/jHsYYxp/32.png), pointer",
  248. boxSizing: "border-box",
  249. borderRadius: "8px",
  250. backgroundColor: "ad0c24",
  251. boxShadow: "0px 5px #ad0c24",
  252. paddingLeft: "100px",
  253. paddingRight: "100px",
  254. webkitTouchCallout: "none",
  255. webkitUserSelect: "none",
  256. khtmlUserSelect: "none",
  257. mozUserSelect: "none",
  258. msUserSelect: "none",
  259. userSelect: "none",
  260. position: "absolute",
  261. color:"#FFFFFF",
  262. fontFamily:"Baloo Paaji",
  263. position: "absolute",
  264. right:"55px",
  265. bottom:"30px",
  266.  
  267. });
  268.  
  269. jQuery("#myNewImage").animate({right: '10px'}).css({
  270. cursor: "url(https://i.ibb.co/jHsYYxp/32.png), default",
  271. opacity: "100%",
  272. imageRendering: "initial",
  273. webkitTouchCallout: "none",
  274. webkitUserSelect: "none",
  275. khtmlUserSelect: "none",
  276. mozUserSelect: "none",
  277. msUserSelect: "none",
  278. userSelect: "none",
  279. position: "absolute",
  280. right:"10px",
  281. bottom:"130px",
  282. width: "180px",
  283. height: "180px",
  284. });
  285.  
  286. jQuery("#ratata").animate({right: '1px'}).css({
  287. cursor: "url(https://i.ibb.co/jHsYYxp/32.png), default",
  288. boxSizing: "border-box",
  289. borderRadius: "0px",
  290. backgroundColor: "#000000",
  291. boxShadow: "0px 8px #000000",
  292. paddingLeft: "0px",
  293. paddingRight: "0px",
  294. webkitTouchCallout: "none",
  295. webkitUserSelect: "none",
  296. khtmlUserSelect: "none",
  297. mozUserSelect: "none",
  298. msUserSelect: "none",
  299. userSelect: "none",
  300. position: "absolute",
  301. color:"#FFFFFF",
  302. fontFamily:"Arial Black",
  303. position: "absolute",
  304. right:"45px",
  305. bottom:"50px",
  306.  
  307. });
  308. });
  309. // funciones rapidas
  310.  
  311. (function() {
  312. //polyfills
  313. window.console._log=window.console.log;
  314. function Event(e, t) {
  315. (this.script = e), (this.target = t), (this._cancel = !1), (this._replace = null), (this._stop = !1);
  316. }
  317. (Event.prototype.preventDefault = function () {
  318. this._cancel = !0;
  319. }),
  320. (Event.prototype.stopPropagation = function () {
  321. this._stop = !0;
  322. }),
  323. (Event.prototype.replacePayload = function (e) {
  324. this._replace = e;
  325. });
  326. var callbacks = [],
  327. addBeforeScriptExecuteListener = function (e) {
  328. if (!e instanceof Function) throw new Error("El controlador de eventos debe ser una funcion dea");
  329. callbacks.push(e);
  330. },
  331. removeBeforeScriptExecuteListener = function (e) {
  332. for (var t = callbacks.length; t--; ) callbacks[t] === e && callbacks.splice(t, 1);
  333. },
  334. addev = window.addEventListener.bind(window),
  335. rmev = window.removeEventListener.bind(window);
  336. (window.addEventListener = function () {
  337. "beforescriptexecute" === arguments[0].toLowerCase() ? addBeforeScriptExecuteListener(arguments[1]) : addev.apply(null, arguments);
  338. }),
  339. (window.removeEventListener = function () {
  340. "beforescriptexecute" === arguments[0].toLowerCase() ? removeBeforeScriptExecuteListener(arguments[1]) : rmev.apply(null, arguments);
  341. });
  342. var dispatch = function (e, t) {
  343. var r = new Event(e, t);
  344. if (window.onbeforescriptexecute instanceof Function)
  345. try {
  346. window.onbeforescriptexecute(r);
  347. } catch (e) {
  348. console.error(e);
  349. }
  350. for (var n = 0; n < callbacks.length && !r._stop; n++)
  351. try {
  352. callbacks[n](r);
  353. } catch (e) {
  354. console.error(e);
  355. }
  356. return r;
  357. },
  358. observer = new MutationObserver((e) => {
  359. for (var t = 0; t < e.length; t++)
  360. for (var r = 0; r < e[t].addedNodes.length; r++) {
  361. var n = e[t].addedNodes[r];
  362. if ("SCRIPT" === n.tagName) {
  363. var o = dispatch(n, e[t].target);
  364. o._cancel ? n.remove() : "string" == typeof o._replace && (n.textContent = o._replace);
  365. }
  366. }
  367. });
  368. observer.observe(document, { childList: !0, subtree: !0 });
  369.  
  370. //options
  371. let craftImg,craftItems,craftHelperE;
  372. const weapons=[0,57,5,6,30,19,9,62,63,64,65,66,67,68,69,70,92,93,12,13,14,15,33,16,17,34,18];
  373. const swords=[57,0,5,6,30,19,9,62,63];
  374. const spears=[12,13,14,15,33,16,17,34,18];
  375. const pickAxes=[8,1,3,4,31,32];
  376. const Builds=[10,119,136,0];
  377. const helms=[60, 59, 44, 43, 61, 27, 26, 25, 58];
  378. let lastDropItemId=103,isAttacking=false;
  379. let lastBuild=`[10,119,136,0]`;
  380. let enemyList;
  381. let enemy;
  382. let oldClothing;
  383. let dayTime;
  384. let events={blizzard:{status:false,in:false},sandStorm:{status:false,in:false}};
  385. let myPlayerId;
  386. let myPlayer;
  387. let playerStatus;
  388. let myInventory;
  389. let aimbot=false;
  390. let options={
  391. circleTimerFuncName:"fh",
  392. showLastPlayerUI:true,
  393. timeoutLastPlayerUI:undefined
  394. };
  395.  
  396. let ws;
  397. let circleTime;
  398. const lastplayers=["Player1","Player2",];
  399. let commands={lastCraftCommand:{keyCode:"KeyE",wsSend:"[7,49]"},//Letra para el ultimo crafteo solo cambie la "Q"
  400. //meatCraft:{keyCode:"KeyN",wsSend:"[5,136]"},
  401. bandageCraft:{keyCode:"KeyX",wsSend:"[7,54]"},//Letra para craftear la venda al pasar por una mesa rapido solo cmabien "X"
  402. //fillBottle:{keyCode:"KeyB",wsSend:"[7,111]"},
  403. autoClick:{keyCode:"KeyE",active:false,wsSend:0}//Letra con la que quiere activar el auto hit solo cambie la "E"
  404.  
  405. }
  406. let oldfunc={};
  407. let newfunc={};
  408. //Optiones
  409. //Funciones
  410. function run(){
  411. history.pushState('id', 'id', '/?id=1');
  412. }
  413. const dist2d = (p1, p2) => {
  414. return Math.sqrt((p1.x-p2.x)**2 + (p1.y-p2.y)**2);
  415. }
  416.  
  417. const calcAngle = (p1, p2) => {
  418. var dy = p1.y - p2.y;
  419. var dx = p2.x - p1.x;
  420. var theta = Math.atan2(dy, dx);
  421. theta *= 180 / Math.PI;
  422. return theta;
  423. }
  424. const angle360 = (p1,p2) => {
  425. var theta = calcAngle(p1,p2);
  426. if (theta < 0) theta = 360 + theta;
  427. return theta;
  428. }
  429. function checkInEnemyRange(range){
  430. let dist=dist2d(myPlayer,enemy);
  431. if(dist<range){
  432. return true;
  433. }
  434. return false;
  435. }
  436.  
  437. function checkAlly(id){
  438. return Object.values(window.p)[21].some((ally)=>{
  439. return ally==id
  440. });
  441. }
  442. function autoHelm(){
  443. helms.some((helm)=>{
  444. return myInventory.some((item)=>{
  445. if(helm==item.id && Object.values(myPlayer)[63]!==item.id){
  446. oldClothing=Object.values(myPlayer)[63];
  447. //ws.send(['[5,'+item.id+']']);
  448. return true;
  449. }
  450. return true ;
  451. });
  452. });}
  453. function viewCraftHelper(craftHelperID){
  454. if(craftHelper.length>0 && craftHelperID<craftHelper.length){
  455. craftImg.innerHTML="";
  456. craftItems.innerHTML="";
  457. craftImg.insertAdjacentHTML('beforeend',`<img class="img_recipe" id="img_1" src=${craftHelper[craftHelperID].imgSrc} style="display: inline-block;">`);
  458. craftHelper[craftHelperID].items.forEach((item)=>{
  459. craftItems.insertAdjacentHTML('beforeend',`<div><img class="inv" id="inv1" src="${item.imgSrc}" style="display: inline-block; vertical-align: middle;"><span style="background-color: black;">${item.number}</span></div>`);
  460.  
  461. });
  462. }
  463. }
  464. function prev(){
  465. craftHelperID--;
  466. if(craftHelperID<0){
  467. craftHelperID=craftHelper.length-1;
  468. }
  469. craftHelper.length>1 && viewCraftHelper(craftHelperID);
  470. }
  471. function next(){
  472. craftHelperID++;
  473. if(craftHelperID>=craftHelper.length){
  474. craftHelperID=0;
  475. }
  476. craftHelper.length>1 && viewCraftHelper(craftHelperID);
  477. }
  478. function remove(){
  479. if(craftHelper.length>1){
  480. craftHelper.splice(craftHelperID,1);
  481. prev();
  482. }else if(craftHelper.length==1){viewCraftHelper(0);}
  483. }
  484. //funciones
  485. //hooks
  486. oldfunc.webSocket=window.WebSocket;
  487. window.WebSocket=newfunc.webSocket=new Proxy(window.WebSocket,{
  488. construct:function(target,args){
  489. enemy=undefined;
  490. ws = new target(...args);
  491. setTimeout(()=>{
  492. myInventory=Object.values(Object.values(window.p)[35])[4];
  493. var event = document.createEvent('Event');
  494. event.data=[22,0];
  495. event.initEvent('message', true, true);
  496. ws.dispatchEvent(event);},2000);
  497. const messageHandler = (e) => {
  498. if ("string" === typeof e.data){
  499. e = JSON.parse(e.data);
  500. switch (e[0]) {
  501. case 2:
  502. lastplayers.unshift(e[2]+" uwu "+e[1]) && lastplayers.length>5 && lastplayers.pop();
  503. options.showLastPlayerUI=true;
  504. options.timeoutLastPlayerUI && clearTimeout(options.timeoutLastPlayerUI);
  505. options.timeoutLastPlayerUI=setTimeout(()=>{options.showLastPlayerUI=true;},50000);
  506. break;
  507. case 3:
  508. myPlayerId=e[9];
  509. events.blizzard.status=Boolean(e[27]);
  510. events.sandStorm.status=Boolean(e[26]);
  511. playerStatus={hp:d[1],food:d[2],temp:d[3],water:d[4], air:d[5], heat:d[6]};
  512. break;
  513. }
  514. }else{
  515. var d = new Uint8Array(e.data);
  516. switch (d[0]) {
  517. case 16:
  518. circleTime=Date.now();
  519. playerStatus={hp:d[1],food:d[2],temp:d[3],water:d[4], air:d[5], heat:d[6]};
  520. if(d[6]===0){
  521. ws.send('[5,136]');
  522. }
  523. break;
  524. case 17:
  525. myPlayer=undefined;
  526. enemyList=undefined;
  527. break;
  528. case 20:aa
  529. dayTime= dayTime ? (window.console._log(Date.now()-dayTime),Date.now()):Date.now();
  530. break;
  531. case 22:
  532. if(d[1]==1 &&!(e.data instanceof Array)){
  533. setTimeout(()=>{var event = document.createEvent('Event');
  534. event.data=[22,0];
  535. event.initEvent('message', true, true);
  536. ws.dispatchEvent(event);},2000);
  537. }
  538. break;
  539. case 36:
  540. if(d[1]===1){
  541. myInventory && myInventory.some((item)=>{
  542. if(item.id==47 || item.id==48){
  543. oldClothing=Object.values(myPlayer)[63];
  544. Object.values(myPlayer)[63]!== item.id && ws.send(['[5,'+item.id+']']);
  545. }
  546. });
  547. }else if(Object.values(myPlayer)[63]==47 || Object.values(myPlayer)[63]==48){
  548. Number.isInteger(oldClothing) && ws.send('[5,'+(oldClothing?oldClothing:Object.values(myPlayer)[63])+']');
  549. }
  550.  
  551. break;
  552. case 37:
  553. if(playerStatus && playerStatus.hp>d[1] && playerStatus.food!== 2 && playerStatus.temp!== 3 && playerStatus.water!== 4 && playerStatus.air!== 5 && playerStatus.heat!== 6 && !events.blizzard.in){
  554. autoHelm();
  555. }
  556. playerStatus ? playerStatus.hp=d[1]: playerStatus={hp:d[1]};
  557. playerStatus ? playerStatus.food=d[2]: playerStatus={food:d[2]};
  558. playerStatus ? playerStatus.temp=d[3]: playerStatus={temp:d[3]};
  559. playerStatus ? playerStatus.water=d[4]: playerStatus={water:d[4]};
  560. playerStatus ? playerStatus.air=d[5]: playerStatus={air:d[5]};
  561. playerStatus ? playerStatus.heat=d[6]: playerStatus={heat:d[6]};
  562. break;
  563. case 68:
  564. events.sandStorm.status= (d[1]==1) ? (true) : (false);
  565. break;
  566. case 69:
  567. events.blizzard.status= (d[1]==1) ? (true) : (false);
  568. break;
  569. case 70:
  570. events.blizzard.in= (d[1]==1) ? (true) : (false);
  571. break;
  572. }
  573. }
  574. };
  575.  
  576. const closeHandler = (event) => {
  577. console.log('Close', event);
  578. aimbot=true;
  579. enemyList=undefined;
  580. myPlayer=undefined;
  581. myInventory=undefined;
  582. ws.removeEventListener('message', messageHandler);
  583. ws.removeEventListener('close', closeHandler);
  584. ws.send= oldfunc['ws.send'];
  585. };
  586. ws.addEventListener('message', messageHandler);
  587. ws.addEventListener('close', closeHandler);
  588.  
  589. oldfunc['ws.send']=ws.send;
  590. newfunc['ws.send']= ws.send= new Proxy(ws.send, {
  591. apply: function(target, _this, _arguments) {
  592. if(typeof _arguments[0]==='string' ){
  593. let arr
  594. try{
  595. arr =JSON.parse(_arguments[0]);
  596. }catch(err){}
  597. if(arr){
  598. if(arr[0]===document.getElementById('nickname_input').value){
  599. arr[1]=arr[1]*8;
  600. arr[2]=arr[2]*8;
  601. _arguments[0]=JSON.stringify(arr);
  602. }else if(arr[0]===7){
  603. target.apply(_this, ['[5,28]']);
  604. commands.lastCraftCommand.wsSend=_arguments[0];
  605. }else if(arr[0]===3){
  606. commands.autoClick.wsSend=arr[1];
  607. }else if(arr[0]===4){
  608. isAttacking=true;
  609. }else if(arr[0]===14){
  610. isAttacking=false;
  611. }else if(arr[0]===38){ //Extractores
  612. arr[1]=255;
  613. _arguments[0]=JSON.stringify(arr);
  614. }else if(arr[0]===10){
  615. lastBuild=_arguments[0];
  616. }else if(arr[0]===12){//Horno fuego
  617. arr[1]=100;
  618. _arguments[0]=JSON.stringify(arr);
  619. }else if(arr[0]===22){//Molino
  620. arr[1]=255;
  621. _arguments[0]=JSON.stringify(arr);
  622. }else if(arr[0]===25){//Horno de harian
  623. arr[1]=31;
  624. _arguments[0]=JSON.stringify(arr);
  625. }else if(arr[0]===24){//Harina de horno
  626. arr[1]=31;
  627. _arguments[0]=JSON.stringify(arr);
  628. }else if(arr[0]===28){
  629. lastDropItemId=arr[1];
  630. }else if(arr[0]===5){
  631. if(myInventory && weapons.includes(arr[1])){
  632. autoHelm();
  633. }
  634. }
  635. }
  636. }
  637. ws.readyState === ws.OPEN && Function.prototype.apply.apply(target, [_this, _arguments]);
  638. }
  639. });
  640. return ws;
  641. }
  642. });
  643. oldfunc['array.push'] = Array.prototype.push;
  644. newfunc['array.push'] = Array.prototype.push= new Proxy(Array.prototype.push, {
  645. apply: function(target, _this, _arguments) {
  646. const data=_arguments[0];
  647. if (data && data.type != null && data.id != null && data.x && data.y && data.update && myPlayer==undefined) {
  648. if(enemyList==undefined){
  649. enemyList=_this;
  650. }
  651. let id=data[Object.keys(data)[1]];
  652. if(id===myPlayerId){
  653. myPlayer=data;
  654. }
  655. }else if(data && data.hasOwnProperty('id') && typeof data.info==='object' && 'active' in data.info && 'state' in data.info && arguments.callee.caller.arguments[0] instanceof Array){
  656. if(myInventory==undefined){
  657.  
  658. }
  659. if(weapons.includes(data.id) && _this.length>1){ //Lugar del PICO (Para cambiar la ubicacion cambie "weapons" por "helms" Ejemplo (helms.includes(data.id) = (weapons.includes(data.id) )
  660. _this.splice(0, 0,data);
  661. return data;
  662. }else if(helms.includes(data.id) && _this.length>2){ // lugar del ESPADA o LANZA
  663. _this.splice(1, 0,data);
  664. return data;
  665. }else if(pickAxes.includes(data.id) && _this.length>3){ //Lugar del CASCO
  666. _this.splice(2, 0,data);
  667. return data;
  668. }else if(_this.length>3){//Lugar de items recien crafteados (linea 374 Puede cambiar este lugar 3 es igual a la posicion 4 en el juego y 4 es igual a la posicion 5 en el juego Recuerde que la posicion 123 estan ocupadas
  669. _this.splice(3, 0,data);
  670. return data;
  671. }
  672. }
  673. return Function.prototype.apply.apply(target, [_this, _arguments]);
  674. }
  675. });
  676. oldfunc['Math.asin'] = Math.acos;
  677. newfunc['Math.asin'] = Math.acos= new Proxy(Math.acos, {
  678. apply: function(target, _this, _arguments) {
  679. let ret=Function.prototype.apply.apply(target, [_this, _arguments]);
  680. if(arguments.callee.caller.caller.caller.name==='update' && aimbot && weapons && weapons.includes(myPlayer.right)){
  681. let args=arguments.callee.caller.arguments[0];
  682. let a=arguments.callee.caller.arguments[0];
  683. let e=arguments.callee.caller.arguments[1];
  684. let sing=(0 > (a.x * e.y) - (a.y * e.x)) ? -1 : 1
  685. let angle=findEnemyAngle(ret*sing);
  686. return angle*sing;
  687. }
  688. if(isAttacking){
  689. //ws.send("[14]");
  690. isAttacking=false;
  691. }
  692. return ret;
  693. }
  694. });
  695.  
  696. oldfunc['canvas.fillRect'] = CanvasRenderingContext2D.prototype.fillRect;
  697. newfunc['canvas.fillRect'] = CanvasRenderingContext2D.prototype.fillRect= new Proxy(CanvasRenderingContext2D.prototype.fillRect, {
  698. apply: function(target, _this, _arguments) {
  699. if(arguments.callee.caller && arguments.callee.caller.name===options.circleTimerFuncName && _this.fillStyle==="#669bb1"){
  700. _this.fillStyle = aimbot? "green" : "red";
  701. _this.font = "10px Arial";
  702. _this.fillText(`${circleTime? (5-(Date.now()-circleTime)/1000).toFixed(1):'5'}`,_arguments[0]+180,_arguments[1]+20);
  703. if(options.showLastPlayerUI){
  704. lastplayers.forEach((p,i)=>{
  705. _this.fillText(p,_arguments[0]+180,_arguments[1]+20+i*30-180);
  706. });
  707. }
  708. _this.fillStyle="#669bb1"
  709. }else if(arguments.callee.caller && arguments.callee.caller.name===options.circleTimerFuncName && _this.fillStyle==="#69a148"){
  710. _this.fillStyle = aimbot? "green" : "red";
  711. _this.font = "10px Arial";
  712. _this.fillText(`Blizzard:${events.blizzard.status ?'ON':'OFF'}`,_arguments[0]-180,_arguments[1]+15);
  713. _this.fillText(`Sand Storm:${events.sandStorm.status ?'ON':'OFF'}`,_arguments[0]-180,_arguments[1]-15);
  714.  
  715. _this.fillStyle="#69a148"
  716. }
  717. return Function.prototype.apply.apply(target, [_this, _arguments]);
  718. }
  719. });
  720. //hooks
  721. //handler
  722. window.addEventListener('beforescriptexecute',e => {
  723. if (e.script.src.includes('c10') && e.target.tagName=='BODY') {
  724. e.preventDefault();
  725. fetch('https://starve.io/js/c10.js').then(response=>response.text()).then((dataStr) => {
  726. const script=dataStr.replace(new RegExp('([a-z]*=new [a-z]*;)([a-z]*=new [a-z]*;)','gi'),'window.r=$1window.p=$2');
  727. const b = new Blob([script], { type: 'text/javascript' });
  728. const u = URL.createObjectURL(b);
  729. const s = document.createElement('script');
  730. s.src = u;
  731. document.body.appendChild(s);
  732. document.body.removeChild(s);
  733. URL.revokeObjectURL(u);
  734. })
  735. }
  736. });
  737. document.addEventListener('keydown', (event)=>{
  738. if( document.getElementById('chat_block').style.display!=='inline-block' && myPlayer!==undefined){
  739. if(event.code==="KeyQ"){//Letra con la que quiere activar el auto hit solo cambie la E
  740. let autoClickF=()=>{
  741. if(commands.autoClick.active){
  742. ws.send(`[4,${commands.autoClick.wsSend}]`);
  743. ws.send("[14]");
  744. setTimeout(autoClickF,550);
  745. }
  746. }
  747.  
  748.  
  749. commands.autoClick.active=!commands.autoClick.active;
  750. autoClickF();
  751. setTimeout(autoClickF,550);
  752. }else if(event.code==='KeyH'){//aimbot no trabaja srry
  753. aimbot=!aimbot;
  754. }else if(event.code==='KeyV'){//con que tecla desea dropear
  755. ws.send('[28,'+lastDropItemId+']');
  756. }else if(event.code==='KeyR' && lastBuild){//con que tecla desea poner la ultima construccion
  757. const arr=JSON.parse(lastBuild);
  758. arr[2]=commands.autoClick.wsSend;
  759. ws.send(JSON.stringify(arr));
  760. }else{
  761. for (const [key, value] of Object.entries(commands)) {
  762. if(value.keyCode===event.code){
  763. ws.send(value.wsSend);
  764. }
  765. }
  766. }
  767. }
  768. });
  769. document.addEventListener("DOMContentLoaded", function(event) {
  770.  
  771.  
  772.  
  773.  
  774.  
  775. document.getElementsByClassName('content')[0].addEventListener('click',(e)=>{
  776. if(e.target instanceof HTMLImageElement){
  777. document.querySelectorAll('.recipe >img').forEach((e,i)=>{{
  778.  
  779. }
  780. });}
  781. });
  782. viewCraftHelper(0);
  783.  
  784. document.getElementById('game_canvas').addEventListener('contextmenu', function(e) {d
  785. ws.send(`[5,7]`);
  786. commands.autoClick.active=false;
  787. });
  788.  
  789. });
  790. document.addEventListener('click', (event)=>{
  791. commands.autoClick.active=false;
  792. })();})();1
  793.  
  794. //aparte

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址