Bitcoin Forum
July 28, 2024, 10:57:39 AM *
News: Help 1Dq create 15th anniversary forum artwork.
 
  Home Help Search Login Register More  
  Show Posts
Pages: « 1 2 3 4 5 [6] 7 8 9 10 11 »
101  Economy / Marketplace / Re: Do you want to invest in crypto? on: May 27, 2019, 03:54:35 AM
Frankly speaking, in the present world, Cryptos are turning out to be safest option when it comes to investment. So any sensible person for sure will be eager to make investment in the Crypto world. However, we need to be extremely sure about the way we do it. I prefer doing it via Crypto Broker. As I feel this is the way I can avoid unnecessary situation and scenarios, which eventually leads to results that I wish to achieve in overall frame.
102  Economy / Trading Discussion / Re: What is the best way for me to invest $700,000 into cryptos? on: May 27, 2019, 03:48:34 AM
Honestly do not directly purchase it. You will not be all that comfortable. If you instead do Crypto Trading, you not only get more freedom due to leverages but also it is something that you can benefit even if the price is going negative. This is something I really wish to do in future as compared to how I have done it currently with getting stuck due to higher price purchase. So I will only suggest this only not to make same mistake like me or others.
103  Alternate cryptocurrencies / Altcoin Discussion / Re: Any Decent Exchanges? on: May 27, 2019, 03:35:30 AM
I think there are many Crypto Exchanges out there worthy of trying but we obviously need to be selective with which to go with. It makes very little sense for us to try new. So ultimately we need to select out of the top available options only. It obviously includes Coinbase, Binance and such other exchanges. Ultimately, it is all about going for something that we are comfortable and secure with, I really don’t think we have to worry about anything else at all.
104  Economy / Speculation / Re: Can Bitcoin hit 100k in 2020? on: May 27, 2019, 03:21:01 AM
I don’t think there is any logical way to say about this. But one thing is for sure and that is the popularity of Cryptos. It is for sure on high and for obvious reasons too. So we could see something like that a very much realistic possibility. However, there is just nothing that can be guaranteed. So we have to avoid that fixed mind set. One important aspect is keeping up with Crypto News, which will for sure benefit us in long run.
105  Economy / Trading Discussion / Re: One type of trading strategy on: May 23, 2019, 03:56:59 PM
We should avoid becoming one way pony-tail. If we do then we will only struggle. So that’s where we have to be extremely careful about everything. I get it all rolling easily with having strategies that allows me to operate in any market situation. As with that I can make good and consistent profits. I also use some Trading Tools, which only adds up to how I work and brings so much benefits to me in any situation.
106  Other / Beginners & Help / Re: Earning interest on cryptos on: May 23, 2019, 03:51:32 PM
Frankly speaking, I am not in favour of this at all. I feel there is so much to gain in other ways. I would say Lending Platform are good options. We can even just save it with how current market is going, it will still help us get benefit, so there are just so many things that we can do and benefit from as well. Ultimately our attempt should be to go for something that’s safer, simpler and easier to work through. It’s all that is needed for us.
107  Other / Beginners & Help / Re: Hi can a Beginner make Profit? on: May 23, 2019, 03:49:06 PM
If you are starting up here, it is better if you begin up getting proper knowledge. If you do that accurately, then it will lead you towards making profits. So getting Crypto Knowledge is must in order to be able to succeed and achieve results that are worthy. If we are not going to get this education part right, it will just not get us anywhere, so it is vital that we focus on that aspect. It will be the route to help us with making money and good amount of money as well.
108  Alternate cryptocurrencies / Altcoin Discussion / Re: 5 Ways to Earn Crypto without investing or mining on: May 23, 2019, 03:46:11 PM
I don’t think there is any genuine way when it comes to going without investment, as you already ruled our mining which is obvious other way for all this. But anyhow, I would say that Airdrop Campaign, is only other logical way to earn without investment at all. But of course, we have to ensure that we do everything in proper way with joining only the Best ones and that with proper system, reputation and potential instead of pulling it all randomly.
109  Economy / Trading Discussion / Re: Trading Beginner on: May 16, 2019, 02:20:56 AM
If we are just starting up in Crypto trading, then the most important part is to plan and keep the right level of risk/money management. It is only way that we can make profits, and do it consistently.

It is no way possible otherwise. And it is important that we understand the value of it because that way only we will be able to gain rewards and benefit. I won’t be easy doable with hard work and dedication. But of course, not everyone is capable of it.
110  Economy / Trading Discussion / Re: Which Trading Bot do you use ? Are you glad from it And Is it Safe ? on: May 16, 2019, 02:05:44 AM
I don’t really have highest preference when it comes to using Trading bots, as I feel they are not all that beneficial at all. But I know a lot of my friends are interested in using it and do it because they have no option.

A lot of people don’t have time from their busy schedule to do it and that is why Trading Bots becomes obvious option. I won’t suggest but I have seen friends using Gekko but I haven’t used it that actively myself to be clear.
111  Economy / Trading Discussion / Re: A better way to invest in cryptocurrency. on: May 16, 2019, 01:57:56 AM
In my view, the best way is through trading since it’s how you can gain in almost every and any situation. Although, I am not entirely against the Crypto dealing directly, but it is often too risky and challenging, so that’s where I have so much more preference with Crypto Broker, where not only there are benefits like leverages and bonuses but also a lot more. This is all really what makes life easier and simpler and also is far more beneficial too.
112  Other / Beginners & Help / Re: Best Blockchain Books, Bitcoin Movies And Documentaries on: May 16, 2019, 01:53:55 AM
I believe all these are so so important aspect for anyone interested in Crypto industry. As because of this one can easily understand a lot of things which normally is hard to understand.

I would suggest this for all Blockchain Books, while here you can also find out about Documentaries as well. So that is something very special and makes life easier for everyone who is starting up in this massive Crypto industry and are struggling to know the right direction for it.
113  Other / Off-topic / Re: What are your favorite websites? on: May 16, 2019, 01:46:50 AM
Although, there are favourite sites according to different things but since here most have Crypto mindset, I would say my favourite site is Cryptolinks, and that is because I find everything here. I don’t think I will ever be getting this from anywhere else.

So this is where and why it is so important to be following such sites, where so many benefits are for people, especially for the Crypto lovers like me. I have really found it simpler.
114  Alternate cryptocurrencies / Announcements (Altcoins) / 0xbitconnect 📌 A Trust Less Platform Built On The Ethereum Protocol 📌 on: May 12, 2019, 03:27:14 PM





What is 0xbitconnect?

A fully transparent and trust-less decentralized application built on Ethereum, exposing the potential of 0xbitcoin. Once a smart contract is verified on the blockchain it is immutable, meaning it can never be changed. 0xbitconnect, connects the characteristics of bitcoin with smart contract capabilities. Buy tokens, earn from buys and sells, have fun, and most important be free.


How the platform works?


0xbitconnect.co, is a trust less platform built on the Ethereum protocol giving the first use case to 0xbitcoin. By purchasing coins, coin holders will be receiving dividends from buys and sells. With the current low supply of 0xBTC, there will be volatility. This is beneficial for coin holders.


Verified Source Code

Code:
/**
 * Source Code first verified at https://etherscan.io on Thursday, March 21, 2019
 (UTC) */

pragma solidity 0.4.25;

contract ERC20Interface {

  function totalSupply() public constant returns(uint);

  function balanceOf(address tokenOwner) public constant returns(uint balance);

  function allowance(address tokenOwner, address spender) public constant returns(uint remaining);

  function transfer(address to, uint tokens) public returns(bool success);

  function approve(address spender, uint tokens) public returns(bool success);

  function transferFrom(address from, address to, uint tokens) public returns(bool success);
  event Transfer(address indexed from, address indexed to, uint tokens);
  event Approval(address indexed tokenOwner, address indexed spender, uint tokens);

}

contract _0xBitconnect {
  using SafeMath
  for uint;

  /*=================================
  =            MODIFIERS            =
  =================================*/

  modifier onlyHolders() {
    require(myFrontEndTokens() > 0);
    _;
  }

  modifier dividendHolder() {
    require(myDividends(true) > 0);
    _;
  }

  modifier onlyAdministrator() {
    address _customerAddress = msg.sender;
    require(administrators[_customerAddress]);
    _;
  }

  /*==============================
  =            EVENTS            =
  ==============================*/

  event onTokenPurchase(
    address indexed customerAddress,
    uint incoming,
    uint8 dividendRate,
    uint tokensMinted,
    address indexed referredBy
  );

  event UserDividendRate(
    address user,
    uint divRate
  );

  event onTokenSell(
    address indexed customerAddress,
    uint tokensBurned,
    uint earned
  );

  event onReinvestment(
    address indexed customerAddress,
    uint reinvested,
    uint tokensMinted
  );

  event onWithdraw(
    address indexed customerAddress,
    uint withdrawn
  );

  event Transfer(
    address indexed from,
    address indexed to,
    uint tokens
  );

  event Approval(
    address indexed tokenOwner,
    address indexed spender,
    uint tokens
  );

  event Allocation(
    uint toBankRoll,
    uint toReferrer,
    uint toTokenHolders,
    uint toDivCardHolders,
    uint forTokens
  );

  event Referral(
    address referrer,
    uint amountReceived
  );

  /*=====================================
  =            CONSTANTS                =
  =====================================*/

  uint8 constant public decimals = 18;

  uint constant internal magnitude = 2 ** 64;

  uint constant internal MULTIPLIER = 1140;

  uint constant internal MIN_TOK_BUYIN = 0.0001 ether;
  uint constant internal MIN_TOKEN_SELL_AMOUNT = 0.0001 ether;
  uint constant internal MIN_TOKEN_TRANSFER = 1e10;
  uint constant internal referrer_percentage = 25;
  uint constant internal MAX_SUPPLY = 1e25;

  ERC20Interface internal _0xBTC;

  uint public stakingRequirement = 100e18;

  /*================================
   =          CONFIGURABLES         =
   ================================*/

  string public name = "0xBitconnect";
  string public symbol = "0xBCC";

  address internal bankrollAddress;

  _0xBitconnectDividendCards divCardContract;

  /*================================
   =            DATASETS            =
   ================================*/

  // Tracks front & backend tokens
  mapping(address => uint) internal frontTokenBalanceLedger_;
  mapping(address => uint) internal dividendTokenBalanceLedger_;
  mapping(address =>
    mapping(address => uint))
  public allowed;

  // Tracks dividend rates for users
  mapping(uint8 => bool) internal validDividendRates_;
  mapping(address => bool) internal userSelectedRate;
  mapping(address => uint8) internal userDividendRate;

  // Payout tracking
  mapping(address => uint) internal referralBalance_;
  mapping(address => int256) internal payoutsTo_;

  uint public current0xbtcInvested;

  uint internal tokenSupply = 0;
  uint internal divTokenSupply = 0;

  uint internal profitPerDivToken;

  mapping(address => bool) public administrators;

  bool public regularPhase = false;

  /*=======================================
  =            PUBLIC FUNCTIONS           =
  =======================================*/
  constructor(address _bankrollAddress, address _divCardAddress, address _btcAddress)
  public {
    bankrollAddress = _bankrollAddress;
    divCardContract = _0xBitconnectDividendCards(_divCardAddress);
    _0xBTC = ERC20Interface(_btcAddress);

    administrators[msg.sender] = true; // Helps with debugging!

    validDividendRates_[10] = true;
    validDividendRates_[20] = true;
    validDividendRates_[30] = true;

    userSelectedRate[bankrollAddress] = true;
    userDividendRate[bankrollAddress] = 30;

  /*=======================================
  =             INITIAL HEAVEN            =
  =======================================*/

    uint initiallyAssigned = 3*10**24;

    address heavenA = 0xA7cDc6cF8E8a4db39bc03ac675662D6E2F8F84f3;
    address heavenB = 0xbC539A28e85c587987297da7039949eA23b51723;

    userSelectedRate[heavenA] = true;
    userDividendRate[heavenA] = 30;

    userSelectedRate[heavenB] = true;
    userDividendRate[heavenB] = 30;

    tokenSupply = tokenSupply.add(initiallyAssigned);
    divTokenSupply = divTokenSupply.add(initiallyAssigned.mul(30));

    profitPerDivToken = profitPerDivToken.add((initiallyAssigned.mul(magnitude)).div(divTokenSupply));
    
    payoutsTo_[heavenA] += (int256)((profitPerDivToken * (initiallyAssigned.div(3)).mul(userDividendRate[heavenA])));
    payoutsTo_[heavenB] += (int256)((profitPerDivToken * (initiallyAssigned.div(3)).mul(userDividendRate[heavenB])));
    payoutsTo_[bankrollAddress] += (int256)((profitPerDivToken * (initiallyAssigned.div(3)).mul(userDividendRate[bankrollAddress])));


    frontTokenBalanceLedger_[heavenA] = frontTokenBalanceLedger_[heavenA].add(initiallyAssigned.div(3));
    dividendTokenBalanceLedger_[heavenA] = dividendTokenBalanceLedger_[heavenA].add((initiallyAssigned.div(3)).mul(userDividendRate[heavenA]));

    frontTokenBalanceLedger_[heavenB] = frontTokenBalanceLedger_[heavenB].add(initiallyAssigned.div(3));
    dividendTokenBalanceLedger_[heavenB] = dividendTokenBalanceLedger_[heavenB].add((initiallyAssigned.div(3)).mul(userDividendRate[heavenB]));

    frontTokenBalanceLedger_[bankrollAddress] = frontTokenBalanceLedger_[bankrollAddress].add(initiallyAssigned.div(3));
    dividendTokenBalanceLedger_[bankrollAddress] = dividendTokenBalanceLedger_[bankrollAddress].add((initiallyAssigned.div(3)).mul(userDividendRate[bankrollAddress]));


  }

  /**
   * Same as buy, but explicitly sets your dividend percentage.
   * If this has been called before, it will update your `default' dividend
   *   percentage for regular buy transactions going forward.
   */
  function buyAndSetDivPercentage(uint _0xbtcAmount, address _referredBy, uint8 _divChoice, string providedUnhashedPass)
  public
  returns(uint) {

    require(regularPhase);

    // Dividend percentage should be a currently accepted value.
    require(validDividendRates_[_divChoice]);

    // Set the dividend fee percentage denominator.
    userSelectedRate[msg.sender] = true;
    userDividendRate[msg.sender] = _divChoice;
    emit UserDividendRate(msg.sender, _divChoice);

    // Finally, purchase tokens.
    purchaseTokens(_0xbtcAmount, _referredBy, false);
  }

  // All buys except for the above one require regular phase.

  function buy(uint _0xbtcAmount, address _referredBy)
  public
  returns(uint) {
    require(regularPhase);
    address _customerAddress = msg.sender;
    require(userSelectedRate[_customerAddress]);
    purchaseTokens(_0xbtcAmount, _referredBy, false);
  }

  function buyAndTransfer(uint _0xbtcAmount, address _referredBy, address target)
  public {
    bytes memory empty;
    buyAndTransfer(_0xbtcAmount, _referredBy, target, empty, 20);
  }

  function buyAndTransfer(uint _0xbtcAmount, address _referredBy, address target, bytes _data)
  public {
    buyAndTransfer(_0xbtcAmount, _referredBy, target, _data, 20);
  }

  // Overload
  function buyAndTransfer(uint _0xbtcAmount, address _referredBy, address target, bytes _data, uint8 divChoice)
  public {
    require(regularPhase);
    address _customerAddress = msg.sender;
    uint256 frontendBalance = frontTokenBalanceLedger_[msg.sender];
    if (userSelectedRate[_customerAddress] && divChoice == 0) {
      purchaseTokens(_0xbtcAmount, _referredBy, false);
    } else {
      buyAndSetDivPercentage(_0xbtcAmount, _referredBy, divChoice, "0x0");
    }
    uint256 difference = SafeMath.sub(frontTokenBalanceLedger_[msg.sender], frontendBalance);
    transferTo(msg.sender, target, difference, _data);
  }

  // No Fallback functionality
  function () public {
    revert();
  }

  function reinvest()
  dividendHolder()
  public {
    require(regularPhase);
    uint _dividends = myDividends(false);

    // Pay out requisite `virtual' dividends.
    address _customerAddress = msg.sender;
    payoutsTo_[_customerAddress] += (int256)(_dividends * magnitude);

    _dividends += referralBalance_[_customerAddress];
    referralBalance_[_customerAddress] = 0;

    uint _tokens = purchaseTokens(_dividends.div(1e10), address(0), true); //to 8 Decimals

    // Fire logging event.
    emit onReinvestment(_customerAddress, _dividends, _tokens);
  }

  function exit()
  public {
    require(regularPhase);
    // Retrieve token balance for caller, then sell them all.
    address _customerAddress = msg.sender;
    uint _tokens = frontTokenBalanceLedger_[_customerAddress];

    if (_tokens > 0) sell(_tokens);

    withdraw(_customerAddress);
  }

  function withdraw(address _recipient)
  dividendHolder()
  public {
    require(regularPhase);
    // Setup data
    address _customerAddress = msg.sender;
    uint _dividends = myDividends(false);

    // update dividend tracker
    payoutsTo_[_customerAddress] += (int256)(_dividends * magnitude);

    // add ref. bonus
    _dividends += referralBalance_[_customerAddress];
    referralBalance_[_customerAddress] = 0;

    if (_recipient == address(0x0)) {
      _recipient = msg.sender;
    }

    _dividends = _dividends.div(1e10); //to 8 decimals
    _0xBTC.transfer(_recipient, _dividends);

    // Fire logging event.
    emit onWithdraw(_recipient, _dividends);
  }

  // Sells front-end tokens.
  function sell(uint _amountOfTokens)
  onlyHolders()
  public {
    require(regularPhase);

    require(_amountOfTokens <= frontTokenBalanceLedger_[msg.sender]);

    uint _frontEndTokensToBurn = _amountOfTokens;

    // Calculate how many dividend tokens this action burns.
    // Computed as the caller's average dividend rate multiplied by the number of front-end tokens held.
    // As an additional guard, we ensure that the dividend rate is between 2 and 50 inclusive.
    uint userDivRate = getUserAverageDividendRate(msg.sender);
    require((2 * magnitude) <= userDivRate && (50 * magnitude) >= userDivRate);
    uint _divTokensToBurn = (_frontEndTokensToBurn.mul(userDivRate)).div(magnitude);

    // Calculate 0xbtc received before dividends
    uint _0xbtc = tokensTo0xbtc_(_frontEndTokensToBurn);

    if (_0xbtc > current0xbtcInvested) {
      // Well, congratulations, you've emptied the coffers.
      current0xbtcInvested = 0;
    } else {
      current0xbtcInvested = current0xbtcInvested - _0xbtc;
    }

    // Calculate dividends generated from the sale.
    uint _dividends = (_0xbtc.mul(getUserAverageDividendRate(msg.sender)).div(100)).div(magnitude);

    // Calculate 0xbtc receivable net of dividends.
    uint _taxed0xbtc = _0xbtc.sub(_dividends);

    // Burn the sold tokens (both front-end and back-end variants).
    tokenSupply = tokenSupply.sub(_frontEndTokensToBurn);
    divTokenSupply = divTokenSupply.sub(_divTokensToBurn);

    // Subtract the token balances for the seller
    frontTokenBalanceLedger_[msg.sender] = frontTokenBalanceLedger_[msg.sender].sub(_frontEndTokensToBurn);
    dividendTokenBalanceLedger_[msg.sender] = dividendTokenBalanceLedger_[msg.sender].sub(_divTokensToBurn);

    // Update dividends tracker
    int256 _updatedPayouts = (int256)(profitPerDivToken * _divTokensToBurn + (_taxed0xbtc * magnitude));
    payoutsTo_[msg.sender] -= _updatedPayouts;

    // Let's avoid breaking arithmetic where we can, eh?
    if (divTokenSupply > 0) {
      // Update the value of each remaining back-end dividend token.
      profitPerDivToken = profitPerDivToken.add((_dividends * magnitude) / divTokenSupply);
    }

    // Fire logging event.
    emit onTokenSell(msg.sender, _frontEndTokensToBurn, _taxed0xbtc);
  }

  /**
   * Transfer tokens from the caller to a new holder.
   * No charge incurred for the transfer. We'd make a terrible bank.
   */
  function transfer(address _toAddress, uint _amountOfTokens)
  onlyHolders()
  public
  returns(bool) {
    require(_amountOfTokens >= MIN_TOKEN_TRANSFER &&
      _amountOfTokens <= frontTokenBalanceLedger_[msg.sender]);
    bytes memory empty;
    transferFromInternal(msg.sender, _toAddress, _amountOfTokens, empty);
    return true;

  }

  function approve(address spender, uint tokens)
  public
  returns(bool) {
    address _customerAddress = msg.sender;
    allowed[_customerAddress][spender] = tokens;

    // Fire logging event.
    emit Approval(_customerAddress, spender, tokens);

    // Good old ERC20.
    return true;
  }

  /**
   * Transfer tokens from the caller to a new holder: the Used By Smart Contracts edition.
   * No charge incurred for the transfer. No seriously, we'd make a terrible bank.
   */
  function transferFrom(address _from, address _toAddress, uint _amountOfTokens)
  public
  returns(bool) {
    // Setup variables
    address _customerAddress = _from;
    bytes memory empty;
    // Make sure we own the tokens we're transferring, are ALLOWED to transfer that many tokens,
    // and are transferring at least one full token.
    require(_amountOfTokens >= MIN_TOKEN_TRANSFER &&
      _amountOfTokens <= frontTokenBalanceLedger_[_customerAddress] &&
      _amountOfTokens <= allowed[_customerAddress][msg.sender]);

    transferFromInternal(_from, _toAddress, _amountOfTokens, empty);

    // Good old ERC20.
    return true;

  }

  function transferTo(address _from, address _to, uint _amountOfTokens, bytes _data)
  public {
    if (_from != msg.sender) {
      require(_amountOfTokens >= MIN_TOKEN_TRANSFER &&
        _amountOfTokens <= frontTokenBalanceLedger_[_from] &&
        _amountOfTokens <= allowed[_from][msg.sender]);
    } else {
      require(_amountOfTokens >= MIN_TOKEN_TRANSFER &&
        _amountOfTokens <= frontTokenBalanceLedger_[_from]);
    }

    transferFromInternal(_from, _to, _amountOfTokens, _data);
  }

  // Who'd have thought we'd need this thing floating around?
  function totalSupply()
  public
  view
  returns(uint256) {
    return tokenSupply;
  }

  /*----------  ADMINISTRATOR ONLY FUNCTIONS  ----------*/

  function startRegularPhase()
  onlyAdministrator
  public {
    regularPhase = true;
  }

  // The death of a great man demands the birth of a great son.
  function setAdministrator(address _newAdmin, bool _status)
  onlyAdministrator()
  public {
    administrators[_newAdmin] = _status;
  }

  function setStakingRequirement(uint _amountOfTokens)
  onlyAdministrator()
  public {
    // This plane only goes one way, lads. Never below the initial.
    require(_amountOfTokens >= 100e18);
    stakingRequirement = _amountOfTokens;
  }

  function setName(string _name)
  onlyAdministrator()
  public {
    name = _name;
  }

  function setSymbol(string _symbol)
  onlyAdministrator()
  public {
    symbol = _symbol;
  }

  function changeBankroll(address _newBankrollAddress)
  onlyAdministrator
  public {
    bankrollAddress = _newBankrollAddress;
  }

  /*----------  HELPERS AND CALCULATORS  ----------*/

  function total0xbtcBalance()
  public
  view
  returns(uint) {
    return _0xBTC.balanceOf(address(this));
  }

  function total0xbtcReceived()
  public
  view
  returns(uint) {
    return current0xbtcInvested;
  }

  /**
   * Retrieves your currently selected dividend rate.
   */
  function getMyDividendRate()
  public
  view
  returns(uint8) {
    address _customerAddress = msg.sender;
    require(userSelectedRate[_customerAddress]);
    return userDividendRate[_customerAddress];
  }

  /**
   * Retrieve the total frontend token supply
   */
  function getFrontEndTokenSupply()
  public
  view
  returns(uint) {
    return tokenSupply;
  }

  /**
   * Retreive the total dividend token supply
   */
  function getDividendTokenSupply()
  public
  view
  returns(uint) {
    return divTokenSupply;
  }

  /**
   * Retrieve the frontend tokens owned by the caller
   */
  function myFrontEndTokens()
  public
  view
  returns(uint) {
    address _customerAddress = msg.sender;
    return getFrontEndTokenBalanceOf(_customerAddress);
  }

  /**
   * Retrieve the dividend tokens owned by the caller
   */
  function myDividendTokens()
  public
  view
  returns(uint) {
    address _customerAddress = msg.sender;
    return getDividendTokenBalanceOf(_customerAddress);
  }

  function myReferralDividends()
  public
  view
  returns(uint) {
    return myDividends(true) - myDividends(false);
  }

  function myDividends(bool _includeReferralBonus)
  public
  view
  returns(uint) {
    address _customerAddress = msg.sender;
    return _includeReferralBonus ? dividendsOf(_customerAddress) + referralBalance_[_customerAddress] : dividendsOf(_customerAddress);
  }

  function theDividendsOf(bool _includeReferralBonus, address _customerAddress)
  public
  view
  returns(uint) {
    return _includeReferralBonus ? dividendsOf(_customerAddress) + referralBalance_[_customerAddress] : dividendsOf(_customerAddress);
  }

  function getFrontEndTokenBalanceOf(address _customerAddress)
  view
  public
  returns(uint) {
    return frontTokenBalanceLedger_[_customerAddress];
  }

  function balanceOf(address _owner)
  view
  public
  returns(uint) {
    return getFrontEndTokenBalanceOf(_owner);
  }

  function getDividendTokenBalanceOf(address _customerAddress)
  view
  public
  returns(uint) {
    return dividendTokenBalanceLedger_[_customerAddress];
  }

  function dividendsOf(address _customerAddress)
  view
  public
  returns(uint) {
    return (uint)((int256)(profitPerDivToken * dividendTokenBalanceLedger_[_customerAddress]) - payoutsTo_[_customerAddress]) / magnitude;
  }

  // Get the sell price at the user's average dividend rate
  function sellPrice()
  public
  view
  returns(uint) {
    uint price;

    // Calculate the tokens received for 0.001 0xbtc.
    // Divide to find the average, to calculate the price.
    uint tokensReceivedFor0xbtc = btcToTokens_(0.001 ether);

    price = (1e18 * 0.001 ether) / tokensReceivedFor0xbtc;

    // Factor in the user's average dividend rate
    uint theSellPrice = price.sub((price.mul(getUserAverageDividendRate(msg.sender)).div(100)).div(magnitude));

    return theSellPrice;
  }

  // Get the buy price at a particular dividend rate
  function buyPrice(uint dividendRate)
  public
  view
  returns(uint) {
    uint price;

    // Calculate the tokens received for 100 finney.
    // Divide to find the average, to calculate the price.
    uint tokensReceivedFor0xbtc = btcToTokens_(0.001 ether);

    price = (1e18 * 0.001 ether) / tokensReceivedFor0xbtc;

    // Factor in the user's selected dividend rate
    uint theBuyPrice = (price.mul(dividendRate).div(100)).add(price);

    return theBuyPrice;
  }

  function calculateTokensReceived(uint _0xbtcToSpend)
  public
  view
  returns(uint) {
    uint fixedAmount = _0xbtcToSpend.mul(1e10);
    uint _dividends = (fixedAmount.mul(userDividendRate[msg.sender])).div(100);
    uint _taxed0xbtc = fixedAmount.sub(_dividends);
    uint _amountOfTokens = btcToTokens_(_taxed0xbtc);
    return _amountOfTokens;
  }

  // When selling tokens, we need to calculate the user's current dividend rate.
  // This is different from their selected dividend rate.
  function calculate0xbtcReceived(uint _tokensToSell)
  public
  view
  returns(uint) {
    require(_tokensToSell <= tokenSupply);
    uint _0xbtc = tokensTo0xbtc_(_tokensToSell);
    uint userAverageDividendRate = getUserAverageDividendRate(msg.sender);
    uint _dividends = (_0xbtc.mul(userAverageDividendRate).div(100)).div(magnitude);
    uint _taxed0xbtc = _0xbtc.sub(_dividends);
    return _taxed0xbtc.div(1e10);
  }

  /*
   * Get's a user's average dividend rate - which is just their divTokenBalance / tokenBalance
   * We multiply by magnitude to avoid precision errors.
   */

  function getUserAverageDividendRate(address user) public view returns(uint) {
    return (magnitude * dividendTokenBalanceLedger_[user]).div(frontTokenBalanceLedger_[user]);
  }

  function getMyAverageDividendRate() public view returns(uint) {
    return getUserAverageDividendRate(msg.sender);
  }

  /*==========================================
  =            INTERNAL FUNCTIONS            =
  ==========================================*/

  /* Purchase tokens with 0xbtc.
     During normal operation:
       0.5% should go to the master dividend card
       0.5% should go to the matching dividend card
       25% of dividends should go to the referrer, if any is provided. */
  function purchaseTokens(uint _incoming, address _referredBy, bool _reinvest)
  internal
  returns(uint) {

    require(_incoming.mul(1e10) >= MIN_TOK_BUYIN || msg.sender == bankrollAddress, "Tried to buy below the min 0xbtc buyin threshold.");

    uint toReferrer;
    uint toTokenHolders;
    uint toDivCardHolders;

    uint dividendAmount;

    uint tokensBought;

    uint remaining0xbtc = _incoming.mul(1e10);

    uint fee;

    // 1% for dividend card holders is taken off before anything else
    if (regularPhase) {
      toDivCardHolders = _incoming.mul(1e8);
      remaining0xbtc = remaining0xbtc.sub(toDivCardHolders);
    }

    /* Next, we tax for dividends:
       Dividends = (0xbtc * div%) / 100
       Important note: the 1% sent to div-card holders
                       is handled prior to any dividend taxes are considered. */

    // Calculate the total dividends on this buy
    dividendAmount = (remaining0xbtc.mul(userDividendRate[msg.sender])).div(100);

    remaining0xbtc = remaining0xbtc.sub(dividendAmount);

    // Calculate how many tokens to buy:
    tokensBought = btcToTokens_(remaining0xbtc);

    // This is where we actually mint tokens:
    require(tokenSupply.add(tokensBought) <= MAX_SUPPLY);
    tokenSupply = tokenSupply.add(tokensBought);
    divTokenSupply = divTokenSupply.add(tokensBought.mul(userDividendRate[msg.sender]));

    /* Update the total investment tracker
       Note that this must be done AFTER we calculate how many tokens are bought -
       because btcToTokens needs to know the amount *before* investment, not *after* investment. */

    current0xbtcInvested = current0xbtcInvested + remaining0xbtc;

    // Ccheck for referrals

    // 25% goes to referrers, if set
    // toReferrer = (dividends * 25)/100
    if (_referredBy != 0x0000000000000000000000000000000000000000 &&
      _referredBy != msg.sender &&
      frontTokenBalanceLedger_[_referredBy] >= stakingRequirement) {
      toReferrer = (dividendAmount.mul(referrer_percentage)).div(100);
      referralBalance_[_referredBy] += toReferrer;
      emit Referral(_referredBy, toReferrer);
    }

    // The rest of the dividends go to token holders
    toTokenHolders = dividendAmount.sub(toReferrer);

    fee = toTokenHolders * magnitude;
    fee = fee - (fee - (tokensBought.mul(userDividendRate[msg.sender]) * (toTokenHolders * magnitude / (divTokenSupply))));

    // Finally, increase the divToken value
    profitPerDivToken = profitPerDivToken.add((toTokenHolders.mul(magnitude)).div(divTokenSupply));
    payoutsTo_[msg.sender] += (int256)((profitPerDivToken * tokensBought.mul(userDividendRate[msg.sender])) - fee);

    // Update the buyer's token amounts
    frontTokenBalanceLedger_[msg.sender] = frontTokenBalanceLedger_[msg.sender].add(tokensBought);
    dividendTokenBalanceLedger_[msg.sender] = dividendTokenBalanceLedger_[msg.sender].add(tokensBought.mul(userDividendRate[msg.sender]));

    if (_reinvest == false) {
      //Lets receive the 0xbtc
      _0xBTC.transferFrom(msg.sender, address(this), _incoming);
    }

    // Transfer to div cards
    if (regularPhase) {
      _0xBTC.approve(address(divCardContract), toDivCardHolders.div(1e10));
      divCardContract.receiveDividends(toDivCardHolders.div(1e10), userDividendRate[msg.sender]);
    }

    // This event should help us track where all the 0xbtc is going
    emit Allocation(0, toReferrer, toTokenHolders, toDivCardHolders, remaining0xbtc);

    emit onTokenPurchase(msg.sender, _incoming, userDividendRate[msg.sender], tokensBought, _referredBy);

    // Sanity checking
    uint sum = toReferrer + toTokenHolders + toDivCardHolders + remaining0xbtc - _incoming.mul(1e10);
    assert(sum == 0);
  }

  // How many tokens one gets from a certain amount of 0xbtc.
  function btcToTokens_(uint _0xbtcAmount)
  public
  view
  returns(uint) {

    //0xbtcAmount expected as 18 decimals instead of 8

    require(_0xbtcAmount > MIN_TOK_BUYIN, "Tried to buy tokens with too little 0xbtc.");

    uint _0xbtcTowardsVariablePriceTokens = _0xbtcAmount;

    uint varPriceTokens = 0;

    if (_0xbtcTowardsVariablePriceTokens != 0) {

      uint simulated0xbtcBeforeInvested = toPowerOfThreeHalves(tokenSupply.div(MULTIPLIER * 1e6)).mul(2).div(3);
      uint simulated0xbtcAfterInvested = simulated0xbtcBeforeInvested + _0xbtcTowardsVariablePriceTokens;

      uint tokensBefore = toPowerOfTwoThirds(simulated0xbtcBeforeInvested.mul(3).div(2)).mul(MULTIPLIER);
      uint tokensAfter = toPowerOfTwoThirds(simulated0xbtcAfterInvested.mul(3).div(2)).mul(MULTIPLIER);

      /*  Investment IS already multiplied by 1e18; however, because this is taken to a power of (2/3),
         we need to multiply the result by 1e6 to get back to the correct number of decimals. */

      varPriceTokens = (1e6) * tokensAfter.sub(tokensBefore);
    }

    uint totalTokensReceived = varPriceTokens;

    assert(totalTokensReceived > 0);
    return totalTokensReceived;
  }

  // How much 0xBTC we get from selling N tokens
  function tokensTo0xbtc_(uint _tokens)
  public
  view
  returns(uint) {
    require(_tokens >= MIN_TOKEN_SELL_AMOUNT, "Tried to sell too few tokens.");

    /*
     *  i = investment, p = price, t = number of tokens
     *
     *  i_current = p_initial * t_current                   (for t_current <= t_initial)
     *  i_current = i_initial + (2/3)(t_current)^(3/2)      (for t_current >  t_initial)
     *
     *  t_current = i_current / p_initial                   (for i_current <= i_initial)
     *  t_current = t_initial + ((3/2)(i_current))^(2/3)    (for i_current >  i_initial)
     */

    uint tokensToSellAtVariablePrice = _tokens;

    uint _0xbtcFromVarPriceTokens;

    // Now, actually calculate:

    if (tokensToSellAtVariablePrice != 0) {

      /* Note: Unlike the sister function in btcToTokens, we don't have to calculate any "virtual" token count.

         We have the equations for total investment above; note that this is for TOTAL.
         To get the 0xbtc received from this sell, we calculate the new total investment after this sell.
         Note that we divide by 1e6 here as the inverse of multiplying by 1e6 in btcToTokens. */

      uint investmentBefore = toPowerOfThreeHalves(tokenSupply.div(MULTIPLIER * 1e6)).mul(2).div(3);
      uint investmentAfter = toPowerOfThreeHalves((tokenSupply - tokensToSellAtVariablePrice).div(MULTIPLIER * 1e6)).mul(2).div(3);

      _0xbtcFromVarPriceTokens = investmentBefore.sub(investmentAfter);
    }

    uint _0xbtcReceived = _0xbtcFromVarPriceTokens;

    assert(_0xbtcReceived > 0);
    return _0xbtcReceived;
  }

  function transferFromInternal(address _from, address _toAddress, uint _amountOfTokens, bytes _data)
  internal {
    require(regularPhase);
    require(_toAddress != address(0x0));
    address _customerAddress = _from;
    uint _amountOfFrontEndTokens = _amountOfTokens;

    // Withdraw all outstanding dividends first (including those generated from referrals).
    if (theDividendsOf(true, _customerAddress) > 0) withdrawFrom(_customerAddress);

    // Calculate how many back-end dividend tokens to transfer.
    // This amount is proportional to the caller's average dividend rate multiplied by the proportion of tokens being transferred.
    uint _amountOfDivTokens = _amountOfFrontEndTokens.mul(getUserAverageDividendRate(_customerAddress)).div(magnitude);

    if (_customerAddress != msg.sender) {
      // Update the allowed balance.
      // Don't update this if we are transferring our own tokens (via transfer or buyAndTransfer)
      allowed[_customerAddress][msg.sender] -= _amountOfTokens;
    }

    // Exchange tokens
    frontTokenBalanceLedger_[_customerAddress] = frontTokenBalanceLedger_[_customerAddress].sub(_amountOfFrontEndTokens);
    frontTokenBalanceLedger_[_toAddress] = frontTokenBalanceLedger_[_toAddress].add(_amountOfFrontEndTokens);
    dividendTokenBalanceLedger_[_customerAddress] = dividendTokenBalanceLedger_[_customerAddress].sub(_amountOfDivTokens);
    dividendTokenBalanceLedger_[_toAddress] = dividendTokenBalanceLedger_[_toAddress].add(_amountOfDivTokens);

    // Recipient inherits dividend percentage if they have not already selected one.
    if (!userSelectedRate[_toAddress]) {
      userSelectedRate[_toAddress] = true;
      userDividendRate[_toAddress] = userDividendRate[_customerAddress];
    }

    // Update dividend trackers
    payoutsTo_[_customerAddress] -= (int256)(profitPerDivToken * _amountOfDivTokens);
    payoutsTo_[_toAddress] += (int256)(profitPerDivToken * _amountOfDivTokens);

    uint length;

    assembly {
      length: = extcodesize(_toAddress)
    }

    if (length > 0) {
      // its a contract
      // note: at ethereum update ALL addresses are contracts
      ERC223Receiving receiver = ERC223Receiving(_toAddress);
      receiver.tokenFallback(_from, _amountOfTokens, _data);
    }

    // Fire logging event.
    emit Transfer(_customerAddress, _toAddress, _amountOfFrontEndTokens);
  }

  // Called from transferFrom. Always checks if _customerAddress has dividends.
  function withdrawFrom(address _customerAddress)
  internal {
    // Setup data
    uint _dividends = theDividendsOf(false, _customerAddress);

    // update dividend tracker
    payoutsTo_[_customerAddress] += (int256)(_dividends * magnitude);

    // add ref. bonus
    _dividends += referralBalance_[_customerAddress];
    referralBalance_[_customerAddress] = 0;

    _dividends = _dividends.div(1e10); //to 8 decimals
    _0xBTC.transfer(_customerAddress, _dividends); //8 decimals correction

    // Fire logging event.
    emit onWithdraw(_customerAddress, _dividends);
  }

  /*=======================
   =   MATHS FUNCTIONS    =
   ======================*/

  function toPowerOfThreeHalves(uint x) public pure returns(uint) {
    // m = 3, n = 2
    // sqrt(x^3)
    return sqrt(x ** 3);
  }

  function toPowerOfTwoThirds(uint x) public pure returns(uint) {
    // m = 2, n = 3
    // cbrt(x^2)
    return cbrt(x ** 2);
  }

  function sqrt(uint x) public pure returns(uint y) {
    uint z = (x + 1) / 2;
    y = x;
    while (z < y) {
      y = z;
      z = (x / z + z) / 2;
    }
  }

  function cbrt(uint x) public pure returns(uint y) {
    uint z = (x + 1) / 3;
    y = x;
    while (z < y) {
      y = z;
      z = (x / (z * z) + 2 * z) / 3;
    }
  }
}

/*=======================
 =     INTERFACES       =
 ======================*/


interface _0xBitconnectDividendCards {
  function ownerOf(uint /*_divCardId*/ ) external pure returns(address);

  function receiveDividends(uint amount, uint divCardRate) external;
}

interface _0xBitconnectBankroll {
  function receiveDividends(uint amount) external;
}


interface ERC223Receiving {
  function tokenFallback(address _from, uint _amountOfTokens, bytes _data) external returns(bool);
}

// Think it's safe to say y'all know what this is.

library SafeMath {

  function mul(uint a, uint b) internal pure returns(uint) {
    if (a == 0) {
      return 0;
    }
    uint c = a * b;
    assert(c / a == b);
    return c;
  }

  function div(uint a, uint b) internal pure returns(uint) {
    // assert(b > 0); // Solidity automatically throws when dividing by 0
    uint c = a / b;
    // assert(a == b * c + a % b); // There is no case in which this doesn't hold
    return c;
  }

  function sub(uint a, uint b) internal pure returns(uint) {
    assert(b <= a);
    return a - b;
  }

  function add(uint a, uint b) internal pure returns(uint) {
    uint c = a + b;
    assert(c >= a);
    return c;
  }
}


0xbitcoin.org



Decentralized Exchange




Dice Game


The Dice Game requires a 2 steps process first to be executed:

You must approve to the Dice contract the amount of tokens to Bet from your wallet (Automatic Prompt) and then Roll.

The Dice Contract requires that you call the Roll button again or the Finish bet button in the next 500 blocks to enclose the dice roll, if not your bet will be cancelled


Lottery Game


The Lottery Game requires a 2 steps process first to be executed:

You must approve to the Dice contract the amount of tokens to Bet from your wallet (Automatic Prompt) and then Roll.

The Lottery Contract will only allow any user to take a ticket per wallet per period.

Join our community

115  Alternate cryptocurrencies / Altcoin Discussion / Re: Is this really better than Bitcoin? on: May 10, 2019, 01:21:57 PM
So should I buy this or Bitcoin  Grin Grin Grin
116  Alternate cryptocurrencies / Service Discussion (Altcoins) / Shirk Fashion Outfit - Join Competition & Win Upto $1000 In BTC on: May 09, 2019, 09:41:09 PM
 



Bitcoin came as a joke which several people were not willing to invest in because of the fear that it was going nowhere. However, after 10 years of existence, bitcoin is everyone’s delight. From online shopping to tuition payment, travels, real estate, online games, car hire, website hosting, and paying for meals at restaurants, everybody now makes use of bitcoin.

Despite the popularity of bitcoin, many are yet to know about bitcoin, cryptocurrencies, altcoins and blockchain technology as a concept. At cryptooutfit, we see cryptocurrency as the future of e-commerce and online transactions. That is why we are using our fashion brand "SHIRK" to create awareness about crypto vigorously.

A little about SHIRK

SHIRK is our fashion designer brand, with the mission to create awareness about cryptocurrency using visual concepts. We employ a minimalist approach to design by professionally fitting crypto logos on casual wears, in such a way as to not make it look loathsome. We make it very subtle that even those who do not have crypto knowledge would mistake it for a designer label. This approach creates curiosity among those who have not heard about crypto.

We have various apparels specially customized with high-end materials. This is why we are different from other crypto merchant stores. We have a unique taste for fashion and express this taste through our designs. Some of the designs in our stock include Short Sleeve Bitcoin Embroidery Tee, Short Sleeve Ethereum Embroidery Tee, Short Sleeve Litecoin Embroidery Tee, etc. We will keep enriching our store several more eye-catching designs.

We also carry out free shipping to our customers. Just use the code “WIN1000” at checkout to receive this benefit. We offer a 30-day free refund so long as the item is unused, undamaged, and in its original packaging. Once we have your receipt or proof of purchase and your item meets the refund conditions, we will refund your money or exchange the item for another one.

$1000 Raffle Competition

We are organizing a competition to spread the news on crypto further. Every of our customer is allowed to participate in the contest as many times as he/she wants and at the end, there are 10 winners selected in the competition with upto $1000 prize in BTC or any preferred Cryptocurrency by the winner.

To be eligible to participate in this competition, you need to buy one of our products on the site using the promo code “WIN1000” (this also adds a 15% discount). As soon as you fill the required amount, you will be entered into a live raffle (on Instagram). You can enter as many times as you want.

However, the entry is according to the checkout, not according to how many items you purchased. Once the entry time is up we will host a LIVE INSTAGRAM session, where winners will be picked randomly from the box. We have also released an exclusive Digital Gold Embroidery Tee for this competition, as when any customer purchase this item using the specialized code (WIN1000), it would enter their names twice into the raffle. And that means a higher chance of winning the prize. Nevertheless, only 60 of such chances are available; so hurry up and leverage the limited slots to improve your chances of winning the prize.

All details about the Raffle competition is available at https://cryptooutfit.co.uk/pages/1000-raffle or you can follow us on Instagram @cryptooutfit

Our Coupon codes

Our product stocks are limited, and we cannot guarantee that you will get one if you do not place your order on time. However, since the products are a bit expensive when you add shipping, we have decided to lessen the cost for you by offering you exclusive discount codes. The first of our coupon code is "WIN1000" which gives you 15% at checkout.

We equally have another coupon code with a higher discount of 25% available at the same time. Unfortunately, this does not qualify you for the raffle draw.
117  Economy / Economics / Re: Bitcoin can be useful for a troubled economy on: May 09, 2019, 05:20:30 PM
It’s hard to say how helpful it will be for the future but it’s obviously simple to know that it’s hugely popular at present. If we just go by the Bitcoin History, it shows that it always has being unstable and that is one major reason why big players are still hesitant to join in it. If the stability comes in then we will absolutely move towards getting the much needed comfort and easiness. It is just impossible without it.
118  Economy / Trading Discussion / Re: The reason people do not want to invest in crypto on: May 09, 2019, 05:15:31 PM
There is a risk factor which often turns a lot of people down in terms of investment in the Crypto industry, but otherwise this is a great place for investors. We just need to make sure that we have right options selected in order to invest, especially with the Upcoming ICOs. And if we do that then we will for sure be able to get things working nicely to benefit from. If we still fear then we should move to smaller investment first before we make more into it.
119  Alternate cryptocurrencies / Altcoin Discussion / Re: Income from crypto trading. on: May 09, 2019, 05:12:56 PM
I like trading of all styles not just Crypto. But I would say without any doubt that Crypto Trading is very cool and beneficial especially if it’s done in accurate and sensible way. I am able to work it out so very smoothly thanks to strategies that I can stick with.

However, all this works if we have a quality Crypto Broker to work with. So our priority needs to be towards that to be able to generate income and able to withdraw/use without fear.
120  Other / Beginners & Help / Re: Hi can a Beginner make Profit? on: May 09, 2019, 05:11:22 PM
This is pretty childish question, to say the least. It doesn’t matter if you are a beginner or expert, if you do things right then you can make profits and there is really no rocket science with it. We just need to use right technique and make sure that we stick to it.

One simple tip I will give is to follow major Crypto News, as it is something that will help in ensuring that the results are better for everyone involved, and will only help with performance.
Pages: « 1 2 3 4 5 [6] 7 8 9 10 11 »
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!