Wont win a fortune, but it will win.
当前为
// ==UserScript==
// @name Dudemaus's DiceBot for Bitsler
// @namespace dicebotforbitslerbydudemaus
// @version 0.2
// @description Wont win a fortune, but it will win.
// @author Dudemaus
// @match *://www.bitsler.com/play/dice/*
// @match https://www.bitsler.com/play
// @match https://www.bitsler.com/play/dice*
// @require http://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js
// @grant GM_xmlhttpRequest
// @grant GM_info
// @grant GM_setValue
// @grant GM_getValue
// @grant GM_addStyle
// ==/UserScript==
//////JQuery Compatibility statement//////
this.$ = this.jQuery = jQuery.noConflict(true);
//////JQuery Compatibility statement//////
var countLosses = document.querySelectorAll('#history-my-bets-dice .text-danger').length;
var countWins = document.querySelectorAll('#history-my-bets-dice .text-success').length;
var winRatio = (countWins / 20) * 100;
//wait for the page to load.
window.onload = function() {
document.getElementById('game-row').insertAdjacentHTML('beforebegin',
'<br><div id="dicebot-container" class="tab-content tab-content-xs" style="border-style: solid;width: 400px;border-color: #D1D1D1;border-radius: 4px;border-style: solid;border-width: 1px; padding-bottom: 9px;padding-left: 9px;padding-right: 9px; margin-left: 118px; padding-top: 9px;display:block"><div id="dicebotinnerwrap"><center><img src="http://i.imgur.com/fVx0BdR.png" /></center></div><br><input type="text" name="betNumberOne" ID="betNumberOne" style="text-align:center;"> Bet #1 (base bet)<br><input type="text" name="betNumberTwo" ID="betNumberTwo" style="text-align:center;"> Bet #2<br><input type="text" name="betNumberThree" ID="betNumberThree" style="text-align:center;"> Bet #3<br><input type="text" name="betNumberFour" ID="betNumberFour" style="text-align:center;"> Bet #4<br><button id="setBet" value="set bet"></div>');
//when set bet button is clicked, set the bet.
document.getElementById('setBet').addEventListener("click", function() {
var countLosses = document.querySelectorAll('#history-my-bets-dice .text-danger').length;
var countWins = document.querySelectorAll('#history-my-bets-dice .text-success').length;
var winRatio = (countWins / 20) * 100;
var betOne = document.getElementById('betNumberOne').value;
var betTwo = document.getElementById('betNumberTwo').value;
var betThree = document.getElementById('betNumberThree').value;
var betFour = document.getElementById('betNumberFour').value;
var winChance = document.getElementById('editable-chance').innerText;
});
//document.getElementById('amount').value = betOne;
};
//NOTES
// code to roll dice - both the next two lines are required.
// $("#btn-bet-dice, #btn-bet-start-pilot-dice, #btn-bet-start-fast-dice").button("loading");
// play();