Bitcoin Forum
May 04, 2024, 08:54:51 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: can anyone help getting my payout script to work for ethercrash  (Read 150 times)
vanbacon (OP)
Newbie
*
Offline Offline

Activity: 4
Merit: 0


View Profile
June 04, 2019, 09:30:38 PM
 #1

Hey I'm trying to create a simple script for ethercrash one that increases payout by 1 on every lose and resets upon win here is my current script it works but It increases payout by a multiplier much like martingale which I don't want.

here is my current working script need help fixing it to only add +1 to basepayout every lose

var baseBetInBits = 100; //base bet
var baseMultiplier = 2; //base multiplier
var baseBetInSatoshis = Math.round(baseBetInBits * 100);
var baseMultiplierInPercentage = Math.round(baseMultiplier * 100);
var currentBet = baseBetInSatoshis;
var currentMulti = baseMultiplierInPercentage;
var gamesLost = 0;
engine.on('game_starting', function (info) {
    if (gamesLost) {
        currentMulti = Math.round(currentMulti + baseMultiplierInPercentage);
        currentBet = baseBetInSatoshis;
    }
    else {
        currentBet = baseBetInSatoshis;
        currentMulti = baseMultiplierInPercentage;
    }
    engine.placeBet(currentBet, currentMulti);
console.log(currentBet, currentMulti);
});
engine.on('game_started', function (data) {
    //console.log('Game Started', data);
});
engine.on('game_crash', function (data) {
    if (data.game_crash < currentMulti) {
        gamesLost++;
    }
    else {
        gamesLost = 0;
    }
    console.log("GamesLost: " + gamesLost);
});
engine.on('player_bet', function (data) {
    //console.log('The player ', data.username, ' placed a bet. This player could be me Shocked.')
});
engine.on('cashed_out', function (resp) {
    //console.log('The player ', resp.username, ' cashed out. This could be me.');
});
engine.on('msg', function (data) {})
1714856091
Hero Member
*
Offline Offline

Posts: 1714856091

View Profile Personal Message (Offline)

Ignore
1714856091
Reply with quote  #2

1714856091
Report to moderator
There are several different types of Bitcoin clients. The most secure are full nodes like Bitcoin Core, but full nodes are more resource-heavy, and they must do a lengthy initial syncing process. As a result, lightweight clients with somewhat less security are commonly used.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
batang_bitcoin
Hero Member
*****
Offline Offline

Activity: 2968
Merit: 600


Eloncoin.org - Mars, here we come!


View Profile
June 05, 2019, 06:22:37 AM
 #2

I'm not a developer but if you still don't have someone to answer this, I think you to offer some money for this task to resolve the problem on your script. Because it seems that no one has ever got the attention of your problem. Try asking or moving this thread to 'Services', most of the developers are hanging out there waiting for offers like this and maybe someone is generous enough there to help your problem without asking for any fee.



 

 

 

 

 

 


▄▄████████▄▄
▄▄████████████████▄▄
▄██
████████████████████▄
▄███
██████████████████████▄
▄████
███████████████████████▄
███████████████████████▄
█████████████████▄███████
████████████████▄███████▀
██████████▄▄███▄██████▀
████████▄████▄█████▀▀
██████▄██████████▀
███▄▄█████
███████▄
██▄██████████████
░▄██████████████▀
▄█████████████▀
████████████
███████████▀
███████▀▀
.
▄▄███████▄▄
▄███████████████▄
▄███████████████████▄
▄██████████
███████████
▄███████████████████████▄
█████████████████████████
█████████████████████████
█████████████████████████
▀█
██████████████████████▀
▀██
███████████████████▀
▀███████████████████▀
▀█████████
██████▀
▀▀███████▀▀
.
 ElonCoin.org 
.
████████▄▄███████▄▄
███████▄████████████▌
██████▐██▀███████▀▀██
███████████████████▐█▌
████▄▄▄▄▄▄▄▄▄▄██▄▄▄▄▄
███▐███▀▄█▄█▀▀█▄█▄▀
███████████████████
█████████████▄████
█████████▀░▄▄▄▄▄
███████▄█▄░▀█▄▄░▀
███▄██▄▀███▄█████▄▀
▄██████▄▀███████▀
████████▄▀████▀
█████▄▄
.
"I could either watch it
happen or be a part of it"
▬▬▬▬▬
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!