][NT3L][G3NC][ Posted May 1, 2020 Share Posted May 1, 2020 // ==UserScript== // @name BC Game Hotkeys // @namespace http://tampermonkey.net/ // @version 188% // @description BC Game Hotkeys // @author ][NT3L][G3NC][ // @match https://bc.game/* // @grant none // @require http://code.jquery.com/jquery-latest.js // ==/UserScript==\ var baseLight = document.createElement("input"); baseLight.type="text"; baseLight.size=10; baseLight.addEventListener('keydown', sexyKeys); baseLight.addEventListener('input', inputHandler); baseLight.placeholder="Hot Keys"; baseLight.setAttribute("style", "text-align:center;font-size:18px;position:absolute;top:530px;right:470px;border:2px solid cyan;"); document.body.appendChild(baseLight); var autoLight = document.createElement("input"); autoLight.type="Button"; autoLight.value="Help"; autoLight.size=3; autoLight.onclick = getHelp; autoLight.setAttribute("style", "text-align:center;font-size:10px;position:absolute;top:528px;right:430px;height:32px;border:2px solid purple;"); document.body.appendChild(autoLight); var box = document.createElement( 'div' ); box.style.background = 'white'; box.hidden = true; box.style.border = '2px solid blue'; box.style.padding = '4px'; box.style.position = 'absolute'; box.style.top = '250px'; box.style.right = '450px'; box.style.maxWidth = '600px'; box.style.fontSize = "14px"; box.innerHTML = "<b><u>Crash HotKeys</u></b></br><b>A: </b>1/2x</br><b>S: </b>2x</br><b>SPACE: </b>Bet/Escape</br></br><b><u>Pro HotKeys</u></b></br><b>Q: </b>1/2x</br><b>W: </b>2x</br><b>R: </b>RED</br><b>G: </b>GREEN</br>"; document.body.appendChild( box ); function getHelp() { if(document.URL.substr(16) == "roll") { box.innerHTML = "<b><u>Roll HotKeys</u></b></br><b>A: </b>1/2x</br><b>S: </b>2x</br><b>SPACE: </b>Bet</br><b>Q: </b>Low</br><b>W: </b>High</br>"; document.body.appendChild(box); } else if(document.URL.substr(16) == "crash") { box.innerHTML = "<b><u>Crash HotKeys</u></b></br><b>A: </b>1/2x</br><b>S: </b>2x</br><b>SPACE: </b>Bet/Escape</br></br><b><u>Pro HotKeys</u></b></br><b>Q: </b>1/2x</br><b>W: </b>2x</br><b>R: </b>RED</br><b>G: </b>GREEN</br>"; document.body.appendChild(box); } else if(document.URL.substr(16) == "plinko") { box.innerHTML = "<b><u>Plinko HotKeys</u></b></br><b>A: </b>1/2x</br><b>S: </b>2x</br><b>SPACE: </b>Betl</br>"; document.body.appendChild(box); } else if(document.URL.substr(16) == "video-poker") { box.innerHTML = "<b><u>videoPoker HotKeys</u></b></br><b>A: </b>1/2x</br><b>S: </b>2x</br><b>SPACE: </b>Bet</br></br><b><u>Card HotKeys</u></b></br><b>1-5</b></br>"; document.body.appendChild(box); } if(box.hidden == true) { box.hidden = false; } else { box.hidden = true; } } function inputHandler(event) { baseLight.value = ""; } function sexyKeys(event) { if(document.URL.substr(16) == "crash") { if (event.keyCode == 65) { try { document.querySelector("#crash-controls > form > div:nth-child(1) > div > div > div.xinput-after > button:nth-child(2)").click(); } catch(err) { //console.log("SomeShit"); } } else if (event.keyCode == 83) { try { document.querySelector("#crash-controls > form > div:nth-child(1) > div > div > div.xinput-after > button:nth-child(3)").click(); } catch(err) { //console.log("SomeShit"); } } else if (event.keyCode == 32) { try { document.querySelector("#crash-escape").click(); } catch(err) { try { document.querySelector("#crash-next").click(); } catch(err) { try { document.querySelector("#crash-bet").click(); } catch(err) { //console.log("SomeShit"); } } } } else if (event.keyCode == 81) { try { document.querySelector("#crash-war-controls > div.flex-between.main-box > div.bet-input > div > div > div > div.xinput-after > button:nth-child(2)").click(); } catch(err) { document.querySelector("#crash-war-controls > div > div.flex-middle.switch-wrap > div > div").click(); } } else if (event.keyCode == 87) { try { document.querySelector("#crash-war-controls > div.flex-between.main-box > div.bet-input > div > div > div > div.xinput-after > button:nth-child(3)").click(); } catch(err) { document.querySelector("#crash-war-controls > div > div.flex-middle.switch-wrap > div > div").click(); } } else if (event.keyCode == 82) { try { document.querySelector("#crash-war-controls > div.flex-between.main-box > div.bet-buttons > div.flex-between > div:nth-child(1) > button").click(); } catch(err) { document.querySelector("#crash-war-controls > div > div.flex-middle.switch-wrap > div > div").click(); } } else if (event.keyCode == 71) { try { document.querySelector("#crash-war-controls > div.flex-between.main-box > div.bet-buttons > div.flex-between > div:nth-child(2) > button").click(); } catch(err) { document.querySelector("#crash-war-controls > div > div.flex-middle.switch-wrap > div > div").click(); } } } else if (document.URL.substr(16) == "roll") { if (event.keyCode == 65) { try { document.querySelector("#roll-controls > form > div:nth-child(1) > div > div > div.xinput-after > button:nth-child(2)").click(); } catch(err) { //console.log("SomeShit"); } } else if (event.keyCode == 83) { try { document.querySelector("#roll-controls > form > div:nth-child(1) > div > div > div.xinput-after > button:nth-child(3)").click(); } catch(err) { //console.log("SomeShit"); } } else if(event.keyCode == 81) { try { document.querySelector("#roll-controls > div > div.low-height > div > div.xtabs-navs > div:nth-child(2)").click(); } catch(err) { //console.log("SomeShit"); } } else if (event.keyCode == 87) { try { document.querySelector("#roll-controls > div > div.low-height > div > div.xtabs-navs > div:nth-child(1)").click(); } catch(err) { //console.log("SomeShit"); } } else if (event.keyCode == 32) { try { document.querySelector("#roll-controls > div > div.bet-button > button").click(); } catch(err) { //console.log("SomeShit"); } } } else if (document.URL.substr(16) == "plinko") { if (event.keyCode == 65) { try { document.querySelector("#plinko-controls > form > div.bet-input.xform-item > div > div > div.xinput-after > button:nth-child(2)").click(); } catch(err) { //console.log("SomeShit"); } } else if (event.keyCode == 83) { try { document.querySelector("#plinko-controls > form > div.bet-input.xform-item > div > div > div.xinput-after > button:nth-child(3)").click(); } catch(err) { //console.log("SomeShit"); } } else if(event.keyCode == 32) { try { document.querySelector("#plinko-controls > div > div.bet-button > button").click(); } catch(err) { //console.log("SomeShit"); } } } else if (document.URL.substr(16) == "video-poker") { if (event.keyCode == 65) { try { document.querySelector("#videoPoker-controls > form > div.buttons > button:nth-child(3)").click(); } catch(err) { //console.log("SomeShit"); } } else if (event.keyCode == 83) { try { document.querySelector("#videoPoker-controls > form > div.buttons > button:nth-child(4)").click(); } catch(err) { //console.log("SomeShit"); } } else if(event.keyCode == 32) { try { document.querySelector("#videoPoker-controls > div > div.bet-button > button").click(); } catch(err) { //console.log("SomeShit"); } } else if (event.keyCode == 49) { try { document.querySelector("#videoPoker-game > div.videoPoker-panel > div > div:nth-child(1) > div.card-face.card-front").click() } catch(err) { //console.log("SomeShit"); } } else if (event.keyCode == 50) { try { document.querySelector("#videoPoker-game > div.videoPoker-panel > div > div:nth-child(2) > div.card-face.card-front").click() } catch(err) { //console.log("SomeShit"); } } else if (event.keyCode == 51) { try { document.querySelector("#videoPoker-game > div.videoPoker-panel > div > div:nth-child(3) > div.card-face.card-front").click() } catch(err) { //console.log("SomeShit"); } } else if (event.keyCode == 52) { try { document.querySelector("#videoPoker-game > div.videoPoker-panel > div > div:nth-child(4) > div.card-face.card-front").click() } catch(err) { //console.log("SomeShit"); } } else if (event.keyCode == 53) { try { document.querySelector("#videoPoker-game > div.videoPoker-panel > div > div:nth-child(5) > div.card-face.card-front").click() } catch(err) { //console.log("SomeShit"); } } } } Link to comment Share on other sites More sharing options...
ViolaTNT Posted May 2, 2020 Share Posted May 2, 2020 thx for sharing!! Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.