Advertisement
coinwalk

lg

Jun 18th, 2019
199
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 16.81 KB | None | 0 0
  1. $('#body').css('background', 'linear-gradient(45deg, #111111 0%, #111111 50%, #111111 100%)');
  2. $('#main').css('min-width', '100%');
  3. $('#header').css('display', 'none');
  4. $('#news').css('display', 'none');
  5. $('#content').css('background', 'none');
  6. $('#gameContainer').html('<h2 style="margin: 0px; color: green;">BOT Luckygames Dice - Exclusive Edition</h2> <br><span id="notification">...</span><br><br> <span id="notification1">...</span><br> <span style="float: left;"><input id="basebetAmount" value="0.00000001" style="background: none; text-align: center; color: #fff; border: 1px solid #fff;" placeholder="basebetAmount" autocomplete="off"> <input id="overBalance" value="0.00000000" style="background: none; text-align: center; color: #fff; border: 1px solid #fff;" placeholder="overBalance" autocomplete="off"> <input id="underBalance" value="0.00000000" style="background: none; text-align: center; color: #fff; border: 1px solid #fff;" placeholder="underBalance" autocomplete="off"></span> <span style="float: right;"><button id="min" onclick="min();" style="border: 1px solid #fff; padding: 2px;">Min</button> <button id="play" style="border: 1px solid #fff; padding: 2px;">Start</button> <button id="reset" onclick="reset();" style="border: 1px solid #fff; padding: 2px;">Reset</button> <button id="showChart" style="border: 1px solid #fff; padding: 2px;">Show Chart</button> <button id="showStatic" style="border: 1px solid #fff; padding: 2px;">Show Static</button> <button id="showLog" style="border: 1px solid #fff; padding: 2px;">Show Log</button></span><br><br> <div id="static">...</div><br> <div style="float: left;" id="chart" style="height: 320px;"></div> <div style="float: right;" id="log"></div><br>');
  7. $('#gameContainer').css('width', '80%');
  8. $('#gameContainer').css('height', '100%');
  9. $('#gameContainer').css('color', '#fff');
  10. $('#gameContainer').css('font-size', '16px');
  11. $('#gameContainer').css('margin', 'auto');
  12. $('#gameContainer').css('padding', '0px');
  13. $('#notification').html('Bot has applied!');
  14. $('#static').css('text-align', 'center');
  15. $('#controlContainer').css('display', 'none');
  16. $('#listContainer').css('display', 'none');
  17. $('#frontText').css('display', 'none');
  18. $('#footer').css('display', 'none');
  19. $('#notification').html('Bot has applied');
  20. $('#notification1').html('______Base Bet______ ___Target Balance___ _Stop Lost Balance_');
  21. $('#static').html('...');
  22. $('#log').css('background', '#1C1C1C');
  23. $('#log').css('overflow', 'auto');
  24. $('#log').css('width', '35%');
  25. $('#log').css('height', '390px');
  26. //$('#log').css('text-align', 'center');
  27. $('#log').css('float', 'right');
  28. $('#log').css('color', '#fff');
  29. //$('#log').css('margin-top', '20px');
  30. $('#log').css('padding', '5px');
  31. $('#log').css('font-size', '14px');
  32. $('#log').css('border', '1px solid grey');
  33. $('#log').css('border-top-left-radius', '3px');
  34. $('#log').css('border-bottom-left-radius', '3px');
  35. $('#chart').width('63.7%');
  36. log('BOT has applied!');
  37. $('.inputBox input')['css']('background', 'none');
  38. $('.inputBox input')['css']('border', '1px solid green');
  39. $('.inputBox input')['css']('-webkit-box-shadow', 'none');
  40. document.getElementById('chart').hidden = true;
  41. document.getElementById('static').hidden = true;
  42. document.getElementById('log').hidden = true;
  43. randomizeSeed();
  44. console.clear();
  45. var run = false;
  46. hideChart = true;
  47. hideStatic = true;
  48. hideLog = true;
  49. sbalance = parseFloat(document.getElementById('balance').value);
  50. basebetAmount = 0;
  51. betAmount = 0;
  52. maxbetAmount = 0;
  53. prediction = 0;
  54. direction = '';
  55. chance = 0;
  56. balance = 0;
  57. overBalance = 0;
  58. underBalance = 0;
  59. bet = 0;
  60. win = 0;
  61. lose = 0;
  62. winStreak = 0;
  63. loseStreak = 0;
  64. maxWinStreak = 0;
  65. maxLoseStreak = 0;
  66. lossAmount = 0;
  67. loseAmount = 0;
  68. maxloseAmount = 0;
  69. wagered = 0;
  70. profitWagered = 0;
  71. profit = 0;
  72. profitt = 0;
  73. largestProfit = 0;
  74. startTime = new Date();
  75. onTime = 0;
  76. playTime = 0;
  77. playDay = 0;
  78. playHour = 0;
  79. playMinute = 0;
  80. playSecond = 0;
  81. speed = 0;
  82. round = 0;
  83. roundd = 0;
  84. seed = 111;
  85. runseed = 0;
  86. changeseed = Math.floor(10);
  87. dsp = [];
  88. chart = '';
  89. color = '';
  90. runLog = 0;
  91. n = Math.floor(6);
  92. $.getScript('https://canvasjs.com/assets/script/canvasjs.min.js').done(function (script, textStatus) {
  93. dps = [{
  94. x: 0,
  95. y: 0
  96. }
  97. ];
  98. chart = new CanvasJS.Chart('chart', {
  99. //backgroundColor: "#F5DEB3",
  100. backgroundColor: "#1C1C1C",
  101. //backgroundColor: "transparent",
  102. theme: 'light1',
  103. zoomEnabled: true,
  104. axisX: {
  105. //title: 'Bet',
  106. includeZero: false,
  107. },
  108. axisY: {
  109. //title: 'Profit',
  110. includeZero: false,
  111. },
  112. title: {
  113. //text: 'Dice Vip Ultimate - Exclusive Edition',
  114. fontColor: 'green',
  115. fontSize: 2e1,
  116. padding: 2e1
  117. },
  118. data: [{
  119. type: 'line',
  120. dataPoints: dps
  121. }
  122. ]
  123. });
  124. chart.render();
  125. });
  126. function updateChart(bet, profit, color) {
  127. dps.push({
  128. x: bet,
  129. y: profit,
  130. color: color
  131. });
  132. if (dps[dps.length - 2]) {
  133. dps[dps.length - 2].lineColor = color;
  134. }
  135. if (dps.length > 1e3) {
  136. dps.shift();
  137. }
  138. chart.render();
  139. }
  140. function min() {
  141. $('#basebetAmount').val((0.00000001).toFixed(8));
  142. }
  143. $('#play').on('click', function () {
  144. run == true ? play(this, "Start", false, false) : play(this, "Stop", true, true);
  145. basebetAmount = parseFloat($('#basebetAmount').val());
  146. overBalance = parseFloat($('#overBalance').val());
  147. underBalance = parseFloat($('#underBalance').val());
  148. betAmount = basebetAmount;
  149. prediction = Math.floor((Math.random() * (98 - 1 + 1)) + 1);
  150. direction = 'under';
  151. chance = prediction;
  152. $('#basebetAmount').val(basebetAmount.toFixed(8));
  153. $('#overBalance').val(overBalance.toFixed(8));
  154. $('#underBalance').val(underBalance.toFixed(8));
  155. doBet();
  156. });
  157. function play(e, d, v) {
  158. $(e).html(d);
  159. run = v;
  160. $('#basebetAmount').prop('disabled', v);
  161. $('#overBalance').prop('disabled', v);
  162. $('#underBalance').prop('disabled', v);
  163. $('#min').prop('disabled', v);
  164. $('#reset').prop('disabled', v);
  165. }
  166. $('#showChart').on('click', function () {
  167. hideChart == true ? showChart(this, "Hide Chart", false) : showChart(this, "Show Chart", true);
  168. });
  169. function showChart(e, d, v) {
  170. $(e).html(d);
  171. hideChart = v;
  172. document.getElementById('chart').hidden = v;
  173. }
  174. $('#showStatic').on('click', function () {
  175. hideStatic == true ? showStatic(this, "Hide Static", false) : showStatic(this, "Show Static", true);
  176. });
  177. function showStatic(e, d, v) {
  178. $(e).html(d);
  179. hideStatic = v;
  180. document.getElementById('static').hidden = v;
  181. }
  182. $('#showLog').on('click', function () {
  183. hideLog == true ? showLog(this, "Hide Log", false) : showLog(this, "Show Log", true);
  184. });
  185. function showLog(e, d, v) {
  186. $(e).html(d);
  187. hideLog = v;
  188. document.getElementById('log').hidden = v;
  189. }
  190.  
  191. function log(string) {
  192. $('<p style="margin: 0px;">' + string + '</p>').appendTo('#log');
  193. }
  194. function reset() {
  195. randomizeSeed();
  196. sbalance = parseFloat(document.getElementById('balance').value);
  197. basebetAmount = 0;
  198. betAmount = 0;
  199. maxbetAmount = 0;
  200. prediction = 0;
  201. direction = '';
  202. chance = 0;
  203. balance = 0;
  204. overBalance = 0;
  205. underBalance = 0;
  206. bet = 0;
  207. win = 0;
  208. lose = 0;
  209. winStreak = 0;
  210. loseStreak = 0;
  211. maxWinStreak = 0;
  212. maxLoseStreak = 0;
  213. lossAmount = 0;
  214. loseAmount = 0;
  215. maxloseAmount = 0;
  216. wagered = 0;
  217. profitWagered = 0;
  218. profit = 0;
  219. profitt = 0;
  220. largestProfit = 0;
  221. startTime = new Date();
  222. onTime = 0;
  223. playTime = 0;
  224. playDay = 0;
  225. playHour = 0;
  226. playMinute = 0;
  227. playSecond = 0;
  228. speed = 0;
  229. round = 0;
  230. roundd = 0;
  231. dsp = [];
  232. chart = '';
  233. color = '';
  234. n = Math.floor(6);
  235. runLog = 0;
  236. $('#log p').remove();
  237. $.getScript('https://canvasjs.com/assets/script/canvasjs.min.js').done(function (script, textStatus) {
  238. dps = [{
  239. x: 0,
  240. y: 0
  241. }
  242. ];
  243. chart = new CanvasJS.Chart('chart', {
  244. //backgroundColor: "#F5DEB3",
  245. backgroundColor: "#1C1C1C",
  246. //backgroundColor: "transparent",
  247. theme: 'light1',
  248. zoomEnabled: true,
  249. axisX: {
  250. //title: 'Bet',
  251. includeZero: false,
  252. },
  253. axisY: {
  254. //title: 'Profit',
  255. includeZero: false,
  256. },
  257. title: {
  258. //text: 'Dice Vip Ultimate - Exclusive Edition',
  259. fontColor: 'green',
  260. fontSize: 2e1,
  261. padding: 2e1
  262. },
  263. data: [{
  264. type: 'line',
  265. dataPoints: dps
  266. }
  267. ]
  268. });
  269. chart.render();
  270. });
  271. $('#notification').html('Bot has reset');
  272. $('#static').html('...');
  273. log('BOT has reset!');
  274. return;
  275. }
  276. function doBet() {
  277. if (run === true) {
  278. jQuery.ajax({
  279. url: "https://"+user.domain+"/play/",
  280. type: "POST",
  281. dataType: "html",
  282. timeout: 6e4,
  283. data: {
  284. game: "dice",
  285. coin: $('#coin').val(),
  286. betAmount: betAmount,
  287. prediction: prediction,
  288. direction: direction,
  289. clientSeed: $('#clientSeed').val(),
  290. serverSeedHash: $('#serverSeedHash').html(),
  291. session: getCookie("SESSION"),
  292. //action: "playBet",
  293. hash: user.hash
  294. },
  295. success: function (data) {
  296. var data = JSON.parse(data);
  297. if (data.result === true) {
  298. //randomizeSeed();
  299. bet++;
  300. onTime = new Date().getTime();
  301. playTime = onTime - startTime;
  302. playDay = Math.floor(playTime / (1e3 * 6e1 * 6e1 * 24));
  303. playHour = Math.floor((playTime % (1e3 * 6e1 * 6e1 * 24)) / (1e3 * 6e1 * 6e1));
  304. playMinute = Math.floor((playTime % (1e3 * 6e1 * 6e1)) / (1e3 * 6e1));
  305. playSecond = Math.floor((playTime % (1e3 * 6e1)) / 1e3);
  306. speed = parseFloat((bet / playTime) * 1000);
  307. balance = parseFloat(data.balance);
  308. wagered += parseFloat(betAmount);
  309. profit += parseFloat(data.profit);
  310. profitWagered = (wagered * 0.1) / 1e2;
  311. profitt = 100*(balance-sbalance)/sbalance;
  312. if (profit > largestProfit) {
  313. largestProfit = profit;
  314. }
  315. if (data.gameResult === 'win') {
  316. /**********************************************///randomizeSeed();
  317. win++;
  318. winStreak++;
  319. loseStreak = 0;
  320. color = 'green';
  321. } else {
  322. lose++;
  323. loseStreak++;
  324. winStreak = 0;
  325. color = 'red';
  326. }
  327. if (winStreak >= maxWinStreak) {
  328. maxWinStreak = winStreak;
  329. }
  330. if (loseStreak >= maxLoseStreak) {
  331. maxLoseStreak = loseStreak;
  332. }
  333. if (betAmount >= maxbetAmount) {
  334. maxbetAmount = betAmount;
  335. }
  336. loseAmount = largestProfit - profit;
  337. if (loseAmount >= maxloseAmount) {
  338. maxloseAmount = loseAmount;
  339. }
  340. runLog++;
  341. if (runLog > 1e2) {
  342. runLog = 0;
  343. $('#log p').remove();
  344. }
  345. log('<font style="color: ' + color + ';">' + betAmount.toFixed(8) + ' ' + direction + ' ' + prediction + ' -> ' + data.resultNumber + ' ' + data.gameResult + ' ' + parseFloat(data.profit).toFixed(8) + '</font>');
  346. $('#log').stop().animate({ scrollTop: $('#log')[0].scrollHeight });
  347. $('#serverSeedHash').html(data.serverSeedHash);
  348. //$('#notification').html('Bot on running: ' + prediction + ' : ' + direction);
  349. $('#notification').html('Bot on running');
  350. $('#static').html('<span style="float: left;">Game = dice</span> <span style="float: center;">Bet Amount : Prediction : Direction = ' + betAmount.toFixed(8) + ' : ' + prediction + ' : ' + direction + '</span> <span style="float: right;">Coin = ' + $('#coin').val() + '</span><br> <span style="float: left;">Time = ' + playDay + 'd:' + playHour + 'h:' + playMinute + 'm:' + playSecond + 's</span> <span style="float: center;">Roll = ' + data.resultNumber + ' : ' + data.gameResult + '</span> <span style="float: right;">Speed = ' + speed.toFixed(2) + '</span><br> <span style="float: left;">Balance = ' + balance.toFixed(8) + '</span> <span style="float: center;">Bet = ' + bet + ' : Win = ' + win + ' : Lose = ' + lose + '</span> <span style="float: right;">Wagered = ' + wagered.toFixed(8) + '</span><br> <span style="float: left;">Profit = ' + profit.toFixed(8) + ' (' + profitt.toFixed(2) + '%)</span> <span style="float: right;">Profit Wagered = ' + profitWagered.toFixed(8) + '</span><br> <span style="float: left;">Win Streak = ' + winStreak + '</span> <span style="float: center;">Loss Amount = ' + loseAmount.toFixed(8) + ' : Max Loss Amount = ' + maxloseAmount.toFixed(8) + '</span> <span style="float: right;">Lose Streak = ' + loseStreak + '</span><br> <span style="float: left;">Max Win Streak = ' + maxWinStreak + '</span> <span style="float: center;">Max Bet Amount = ' + maxbetAmount.toFixed(8) + '</span> <span style="float: right;">Max Lose Streak = ' + maxLoseStreak + '</span>');
  351. updateChart(bet, profit, color);
  352. if (betAmount >= balance) {
  353. stop();
  354. $('#notification').html('You lose');
  355. alert('You lose')
  356. log('You lose!')
  357. return;
  358. } else {
  359. if (overBalance != 0 && balance >= overBalance) {
  360. stop();
  361. $('#notification').html('Over balance - Target Balance achieved');
  362. alert('Over balance - Target Balance achieved')
  363. log('Over balance!')
  364. return;
  365. } else if (underBalance != 0 && balance <= underBalance) {
  366. stop();
  367. $('#notification').html('Under balance - balance under Stop Lost Balance');
  368. alert('Under balance - balance under Stop Lost Balance')
  369. log('Under balance!')
  370. return;
  371. } else {
  372. if (profit >= largestProfit) {
  373. //if (data.gameResult === 'win') {
  374. var rdseedd = Math.floor(Math.random() * (2 - 0 + 1)) + 0;
  375. switch(rdseedd) {
  376. case 0:
  377. $('#clientSeed').val(generateClientSeed());
  378. break;
  379. case 1:
  380. $('#clientSeed').val((Math['random']() * (1000000000000000000000 - 1) + 1).toFixed(0));
  381. break;
  382. case 2:
  383. $('#clientSeed').val((Math['random']() * (100 - 1) + 1).toFixed(0));
  384. break;
  385. default:
  386. }
  387. var rd = Math.floor((Math.random() * (2 - 1 + 1)) + 1);
  388. if (rd == 1) {
  389. prediction = Math.floor((Math.random() * (98 - 1 + 1)) + 1);
  390. direction = 'under';
  391. chance = prediction;
  392. } else {
  393. prediction = Math.floor((Math.random() * (98 - 1 + 1)) + 1);
  394. direction = 'over';
  395. chance = 99 - prediction;
  396. }
  397. //round = 0;
  398. lossAmount = 0;
  399. //n = Math.floor((Math.random() * (6 - 4 + 1)) + 4);
  400. betAmount = basebetAmount;
  401. } else {
  402.  
  403. var rdd = Math.floor((Math.random() * (2 - 1 + 1)) + 1);
  404. if (rdd == 1) {
  405. prediction = Math.floor((Math.random() * (98 - 1 + 1)) + 1);
  406. direction = 'under';
  407. chance = prediction;
  408. } else {
  409. prediction = Math.floor((Math.random() * (98 - 1 + 1)) + 1);
  410. direction = 'over';
  411. chance = 99 - prediction;
  412. }
  413.  
  414. lossAmount = largestProfit - profit;
  415. var betbetAmount = lossAmount/(96/chance-1);
  416. if (chance < 30 && chance > 0) {
  417. betAmount = betbetAmount;
  418. } else {
  419. betAmount = basebetAmount;
  420. }
  421. if (betAmount < 0.00000001) {
  422. betAmount = 0.00000001;
  423. }
  424. }
  425. }
  426. }
  427. doBet();
  428. } else {
  429. randomizeSeed();
  430. setInterval(doBet(), 1e3);
  431. }
  432. },
  433. error: function (xhr, ajaxOptions, throwagerednError) {
  434. randomizeSeed();
  435. setInterval(doBet(), 1e3);
  436. },
  437. timeout: function (xhr, ajaxOptions, throwagerednError) {
  438. randomizeSeed();
  439. setInterval(doBet(), 1e3);
  440. },
  441. abetort: function (xhr, ajaxOptions, throwagerednError) {
  442. randomizeSeed();
  443. setInterval(doBet(), 1e3);
  444. }
  445. });
  446. } else {
  447. $('#notification').html('Bot has stopped');
  448. log('BOT has stopped!');
  449. return;
  450. }
  451. }
  452. function generateSeed(length) {
  453. let seed = '';
  454. const charset = 'abcdef0123456789';
  455. const array = new Uint32Array(length);
  456. window.crypto.getRandomValues(array);
  457. for (const val of array) {
  458. seed += charset.charAt(val % 11);
  459. }
  460. return seed;
  461. }
  462. function generateClientSeed() {
  463. return generateSeed(32);
  464. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement