Skip to content

Instantly share code, notes, and snippets.

@koma5
Last active July 2, 2022 19:59
Show Gist options
  • Select an option

  • Save koma5/4eccd9251d5874d454a197958e78135c to your computer and use it in GitHub Desktop.

Select an option

Save koma5/4eccd9251d5874d454a197958e78135c to your computer and use it in GitHub Desktop.
tampermonkey script to change unit of balance on freebitco.in
// ==UserScript==
// @name change unit of balance on freebitco.in
// @namespace http://5th.ch/
// @version 0.5
// @description change unit of balance on freebitco.in
// @author @koma5
// @match https://freebitco.in/*
// @grant none
// @downloadURL https://gist.githubusercontent.com/koma5/4eccd9251d5874d454a197958e78135c/raw/change_unit_of_balance_freebitco.in.js
// @updateURL https://gist.githubusercontent.com/koma5/4eccd9251d5874d454a197958e78135c/raw/change_unit_of_balance_freebitco.in.js
// ==/UserScript==
(function() {
'use strict';
function changeDOM() {
var unitMap = {mBTC : { unit : 'mBTC', factor : 1e3 },
satoshi : { unit : 'satoshi', factor : 1e8 },
microBTC : { unit : 'μBTC', factor : 1e6 }
};
var unitChoice = unitMap.microBTC;
var balanceLi = document.getElementById("balance").parentNode;
//remove eventListener otherwise we run into a loop
balanceLi.removeEventListener('DOMNodeInserted', changeDOM);
var balance = document.getElementById("balance").innerHTML;
balance *= unitChoice.factor;
//remove balance and textnode
while (balanceLi.hasChildNodes()) {
balanceLi.removeChild(balanceLi.firstChild);
}
//recreate balance span
var balanceSpan = document.createElement("span");
balanceSpan.setAttribute('id', 'balance');
var balanceSpanText = document.createTextNode(balance);
balanceSpan.appendChild(balanceSpanText);
//recreate textnode
var balanceLiUnitText = document.createTextNode(' ' + unitChoice.unit);
//insert balance and textnode into existing and empty blanaceli
balanceLi.appendChild(balanceSpan);
balanceLi.appendChild(balanceLiUnitText);
//readd removed eventListener
balanceLi.addEventListener('DOMNodeInserted', changeDOM, false);
console.log('changed to ' + balance + ' ' + unitChoice.unit);
}
changeDOM();
var balanceLi = document.getElementById("balance").parentNode;
balanceLi.addEventListener('DOMNodeInserted', changeDOM, false);
})();
@yacineops

Copy link
Copy Markdown

i need to Doubling bet only after a losing 4times Consecutive loss

if the result =4 times lose exemple :

You BET HI so you lose 0.00000001 BTC You BET HI so you lose 0.00000001 BTC You BET HI so you lose 0.00000001 BTC You BET HI so you lose 0.00000001 BTC

@yacineops

Copy link
Copy Markdown

i need to Doubling bet only after a losing 4times Consecutive loss

if the result =4 times

@rubensadm

rubensadm commented Apr 23, 2020 via email

Copy link
Copy Markdown

@yacineops

yacineops commented Apr 23, 2020

Copy link
Copy Markdown

hello ..How to change the settings in the script ?
I didn't understand how to modify it in script

@rubensadm

rubensadm commented Apr 23, 2020 via email

Copy link
Copy Markdown

@rubensadm

rubensadm commented Apr 23, 2020 via email

Copy link
Copy Markdown

@rubensadm

rubensadm commented Jun 19, 2020 via email

Copy link
Copy Markdown

@rubensadm

rubensadm commented Jun 19, 2020 via email

Copy link
Copy Markdown

@uniconeapps1

uniconeapps1 commented Nov 18, 2020

Copy link
Copy Markdown

Great script but I can't withdraw, it says "The withdrawal amount is greater than your account balance" what do I do? if it did work I was going to donate!

@leeloader

Copy link
Copy Markdown

Hello I need Edit balance script that is withdrawable freebitco.in

@JesterCastle

Copy link
Copy Markdown

Hello I need Edit balance script that is withdrawable freebitco.in

Script Still Works Just Needs to Be Made able to Withdrawal as it reads 0.04BTC BUT ITS A FASLE READ.
Please help as I'm trying my everything to get off the streets as a I'm a disabled veteran with zero family!?? Please 🙏🙏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment