Sponsored:   Color - Revolutionizing the Dapp Ecosystem, Bounty & Airdrop, Get 240,000 COL NOW!
Contract Overview
Balance: 13.092481488497200864 Ether
Ether Value: $3,900.25 (@ $297.90/ETH)
Transactions: 13371 txns
Token Tracker: Proof of Trevon James (PoTJ)
 Latest 25 txns from a total Of 13371 transactions
(+5 PendingTxns)

TxHash Age From To Value [TxFee]
0x81407c5f8db8e08a857831d175a420d493ecdec7edc6b16ab22ef8fd6659021a(pending)0xccfd0c63c6335c5db47e5ddf0cb850dca8d25e22  IN  0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether(pending)
0x72084e2a09c4f01919d58032aae32d14b2ceeb96a4ca6418a7381d155614626d(pending)0xa84944735b66e957fe385567dcc85975022fe68a  IN  0xc28e860c9132d55a184f9af53fc85e90aa3a01530.0001 Ether(pending)
0x42b7450e3a5c5642b5f6cc441724f3e86d7c0aa24603151fedffc5135406728b(pending)0xccfd0c63c6335c5db47e5ddf0cb850dca8d25e22  IN  0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether(pending)
0xf8476c1b4bc8800b6545e2a1e97bdc1ba42125b8c48e20100fc3b41618634aa8(pending)0xee30795b6046f18ae014ea612c05b9bc00b6f801  IN  0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether(pending)
0x72cf4674dabe92299bf0632797db1eb83f778ea31ae51736a75b9b9bdb47788d(pending)0xee30795b6046f18ae014ea612c05b9bc00b6f801  IN  0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether(pending)
0x586a7d00ddca840f0b4305712faeb37f47b2aa8d2250c3bbfa582bf63689c74c26 mins ago0xab8357856c5d104386d92e8834ff5f005b71794f  IN   0xc28e860c9132d55a184f9af53fc85e90aa3a01530.04 Ether0.0012751842
0xe6df0c9bf6529c37fc173e5070d4073062584c00c0883e3fe393f2f32a8b6ce42 days 54 mins ago0x2539e5ee8b93c8319232d3a7cddd03f009b3458f  IN   0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether0.000217295
0xf7ba1a37b39aa30e0d36c8beb2dd35edd0c12a16fcb92264e8c34d6b412761e22 days 1 hr ago0x2539e5ee8b93c8319232d3a7cddd03f009b3458f  IN   0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether0.00010656
0x98be8849bfd21faf69a807e4b11e17943d2383461a93dd089b7dc356c4eed6d25 days 11 hrs ago0x1f35e90d6de611183bb05fea9cbbb08f6ed37fc8  IN   0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether0.0002390245
0x1503c4e82d0d1b80ddaa1a953542b573f7caedf80abc38fdca16de746e1bc9916 days 15 hrs ago0x1f35e90d6de611183bb05fea9cbbb08f6ed37fc8  IN   0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether0.000794576
0x8a0118198e7cb3192b98cc412f0fd0af58b266501f67456d1b2efaf136345f6f10 days 6 hrs ago0xcb2b0eb210754bd93002faaca102092ef70b1d7e  IN   0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether0.0002564081
0x70d9a3b5209e90993d2b3a749a25fc349752593cb759a346a00c2397a593b92010 days 15 hrs ago0x33b0960a41cbd8d83e5ccc7567c3925f5c93b31d  IN   0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether0.0002314737
0xf7346b1bff3032e2a3d2996340e4ded454c0460bb19bd4954095f321fb211dda11 days 15 hrs ago0x1700749308f542bed70728c47f62a7ad71b79869  IN   0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether0.000077953
0xf9a2e59ad2d2f32c725518422db1a9f68077e75c706ccc75b92b16a373db8fcb11 days 17 hrs ago0x10b99966bf1548dbbcf92fbcfbad66e6fc3f6197  IN   0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether0.000043459
0x860a7251dfa2e2edc0f369dac648d748ef049b3445d3c35017400c85f21b270112 days 14 hrs ago0x404015fb24d90ee668e65798b821bfcd3b8e8f10  IN   0xc28e860c9132d55a184f9af53fc85e90aa3a01530.1 Ether0.00063442
0x68f5b64695d7595e9cd073a2c3e1d8dd2cdd1d69a20e388f2979009c8985376214 days 18 hrs ago0xab8357856c5d104386d92e8834ff5f005b71794f  IN   0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether0.000155906
0x2dd8325593ce2e530f5c9de79b2f4bf99c71ae3596f92595ad310fcf6c4149b414 days 21 hrs ago0x90eb14337ef38a1f73574674b785d57f2d66b353  IN   0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether0.0000956098
0xf4340029af1572006df4cdf95324eb784ae8d02075dc1bdfce9163910c497ada14 days 21 hrs ago0x90eb14337ef38a1f73574674b785d57f2d66b353  IN   0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether0.0001142203
0xa3aa0ddfd478ac6202d690b83a2194755130f529687f8bf4fa9bc6d725a9c1d615 days 4 hrs ago0x168efa40108330c4f85f0191be36169b53daa719  IN   0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether0.000173836
0xa9e7a34c5aa52ee66daf0613470f8c15e112d7a5eb5894ca833fe5d1f9570b9015 days 5 hrs ago0x46091f77b224576e224796de5c50e8120ad7d764  IN   0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether0.000217295
0xa0f912cd4412f65b6a4817a1f8eba4751c348ddd1c338c573f1f96ab7248151115 days 5 hrs ago0x46091f77b224576e224796de5c50e8120ad7d764  IN   0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether0.000148983
0xa679aabe0efe1aafcf8abf7d4792e3ad9880f4aeb5e42d7acd87ede62ff6020918 days 7 hrs ago0xbdadc63328ccc91e457f3a0325bfb444b4e0e744  IN   0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether0.000086918
0xa11ffe71a31f4556eed922d3b31272cb62a23f90ec701c03f938306e82cfca7c19 days 7 hrs ago0x097254e687e480b914ef83fa9d5089ed83fa3319  IN   0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether0.000173836
0xf2e45c12e2212846fc4bb93755d4581fb557703db2ea4854346e1675e2d5e05219 days 7 hrs ago0x097254e687e480b914ef83fa9d5089ed83fa3319  IN   0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether0.000198644
0xac22cd6469d7c327723cff61851bd6f0186b022b277314e4c7675a765f845c8e20 days 3 hrs ago0x3c77fd6b8dc453bdfb77d4e4b9f66bcb6b45a365  IN   0xc28e860c9132d55a184f9af53fc85e90aa3a01530 Ether0.000045682
[ Download CSV Export  ] 
 Internal Transactions as a result of Contract Execution
 Latest 25 Internal Txns, Click here to View More View All
ParentTxHash Block Age From To Value
0xe6df0c9bf6529c37fc173e5070d4073062584c00c0883e3fe393f2f32a8b6ce461513772 days 54 mins ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530x2539e5ee8b93c8319232d3a7cddd03f009b3458f0.129271802191185971 Ether
0x98be8849bfd21faf69a807e4b11e17943d2383461a93dd089b7dc356c4eed6d261310585 days 11 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530x1f35e90d6de611183bb05fea9cbbb08f6ed37fc80.012565300593978597 Ether
0x8a0118198e7cb3192b98cc412f0fd0af58b266501f67456d1b2efaf136345f6f610278310 days 6 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530xcb2b0eb210754bd93002faaca102092ef70b1d7e0.01680253827698845 Ether
0x70d9a3b5209e90993d2b3a749a25fc349752593cb759a346a00c2397a593b920610038110 days 15 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530x33b0960a41cbd8d83e5ccc7567c3925f5c93b31d0.015017330245924947 Ether
0xf9a2e59ad2d2f32c725518422db1a9f68077e75c706ccc75b92b16a373db8fcb609394611 days 17 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530x10b99966bf1548dbbcf92fbcfbad66e6fc3f61970.03147883973407406 Ether
0x2dd8325593ce2e530f5c9de79b2f4bf99c71ae3596f92595ad310fcf6c4149b4607530914 days 21 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530x90eb14337ef38a1f73574674b785d57f2d66b3530.126440777624628094 Ether
0xa3aa0ddfd478ac6202d690b83a2194755130f529687f8bf4fa9bc6d725a9c1d6607360215 days 4 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530x168efa40108330c4f85f0191be36169b53daa7190.003314510696059643 Ether
0xa9e7a34c5aa52ee66daf0613470f8c15e112d7a5eb5894ca833fe5d1f9570b90607343015 days 5 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530x46091f77b224576e224796de5c50e8120ad7d7640.046164765457057031 Ether
0xa679aabe0efe1aafcf8abf7d4792e3ad9880f4aeb5e42d7acd87ede62ff60209605506618 days 7 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530xbdadc63328ccc91e457f3a0325bfb444b4e0e7440.004378100498336619 Ether
0xa11ffe71a31f4556eed922d3b31272cb62a23f90ec701c03f938306e82cfca7c604920519 days 7 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530x097254e687e480b914ef83fa9d5089ed83fa33190.031855465275578585 Ether
0xb44fdb3113c66d281452e753a15b2a255149d532d5c2ed901906e52ad3d45756604405420 days 3 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530x3c77fd6b8dc453bdfb77d4e4b9f66bcb6b45a3650.000237490832432102 Ether
0xc4fd79234618e365869d1eaae84c05ff821ca8055a335e5bc81dfda028e50688604103420 days 15 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530xe34f13405be9d46cdf1aa0dbeee0c4888d18c27d0.012372838619046148 Ether
0x96ae182831623681d232b6970f331862624d6bd42baa0985eb424c01617525e4603528421 days 14 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530xe34f13405be9d46cdf1aa0dbeee0c4888d18c27d0.000121031143228882 Ether
0x8b6d0468c2c90411eafa78d0ef19ac7a0c8f612dbfc50c3baabe6495a719eed4602578923 days 5 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530xc6b7a8bb7afa8db86bd4c3acb68828f2021ac9190.000987778204318569 Ether
0xdb437d86766b04766317bbb16d4a494fbc8b6274932381e49906e747d4e9c79b602537923 days 7 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530x14a8cb9388b27dc94120db35dd4ceebd954f88510.000667338071331846 Ether
0x712b1b0cda75393899a63cc31a9b06961bf0cddbbae6a5182b1c1056c750d973601921524 days 8 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530x05f2c11996d73288abe8a31d8b593a693ff2e5d80.008863775072826273 Ether
0x8971d157a330e48b31c61ef3073bb6e35609111059a4887289da20dc1c30bb2a600760126 days 8 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530x21db5ce96df3b94a9def892b01f8a5a061630a9e0.001120206739739538 Ether
0xe8fe609bbc0e2a7e03d8c0f426b11cd2829347f0d87d1559c843bd4f3235cfe3600654926 days 12 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530x015268ec66b8c0b5fc5028bb2bb68dfb813e215a0.081234295753669881 Ether
0x8a86f4c992d047568d9fbc24d157a20c7d2e1158931233f8b05a6662fe448c1f600541026 days 16 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530xe34f13405be9d46cdf1aa0dbeee0c4888d18c27d0.000024978281647171 Ether
0x25d16e678730371820ea5f3cb9fd442c8c3625dfd762af373163a253f4c0c85f600151927 days 8 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530x7a5c4caf90e9211d7d474918f764ebdc2f9ec1a30.03858966865166441 Ether
0xe6923d88b00ff2f322ee3f6b08694112dd247203742450f5c8b2d5094e0c72da599529028 days 10 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530x3c77fd6b8dc453bdfb77d4e4b9f66bcb6b45a3650.000000705793456455 Ether
0x0b46a8eb7413b5560371660673d1c1e40bba98d935dc4798220d6cec0f84ad39599287028 days 20 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530x0aa8e03ff2d1fa286c614c876c56bcd224acdf250.034367314198984337 Ether
0x493eea794858e4328462deacf6fbeb5b821bf1586ddbae11b540947a08ddc035598643729 days 22 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530x368d4ae443d9db93755aab830c353d290321d7fe0.015193301239365355 Ether
0xbfc512f0a97d88335e2cc5eed09742d4741c7a699b365711cdb9b7d7743dffab598266530 days 14 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530x533b14f6d04ed3c63a68d5e80b7b1f6204fb42130.015534063683774267 Ether
0xd6aa3e9d99dc9d2a1d1a297a4b5e39bbd73cc59ab363cfc08a954938f9b2895d598251230 days 14 hrs ago0xc28e860c9132d55a184f9af53fc85e90aa3a01530xc29a36e3fdd7a2e7484f8142a1ae8baf86068b760.012886807003339853 Ether
[ Download CSV Export  ] 
Warning: The compiled contract might be susceptible to EventStructWrongData (very low-severity), NestedArrayFunctionCallDecoder (medium-severity) Solidity compiler bugs.

Contract Source Code Verified (Exact match)
Contract Name: POTJ
Compiler Version: v0.4.20+commit.3155dd80
Optimization Enabled: Yes
Runs (Optimiser):  200



  Contract Source Code   Find Similiar Contracts

pragma solidity ^0.4.20;

/*
* Trevon James Presents....
* https://potj.me/
* https://discord.gg/8FdGtS8
* Twitter: https://twitter.com/BitcoinTre
* YouTube: https://www.youtube.com/channel/UCWZbtMeOAb_qpEVUl551l7w
* 
* 
*
* Proof of Trevon James
* Don't Talk To Me Unless It's About Intangible Coins.
*
* -> What?
* Incorporated the strong points of different POW{x}, best config:
* [✓] 20% dividends for token purchase, shared among all token holders.
* [✓] 10% dividends for token transfer, shared among all token holders.
* [✓] 25% dividends for token selling.
* [✓] 7% dividends is given to referrer.
* [✓] 50 tokens to activate Masternodes.
*
*/

contract POTJ {


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

    /// @dev Only people with tokens
    modifier onlyBagholders {
        require(myTokens() > 0);
        _;
    }

    /// @dev Only people with profits
    modifier onlyStronghands {
        require(myDividends(true) > 0);
        _;
    }


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

    event onTokenPurchase(
        address indexed customerAddress,
        uint256 incomingEthereum,
        uint256 tokensMinted,
        address indexed referredBy,
        uint timestamp,
        uint256 price
    );

    event onTokenSell(
        address indexed customerAddress,
        uint256 tokensBurned,
        uint256 ethereumEarned,
        uint timestamp,
        uint256 price
    );

    event onReinvestment(
        address indexed customerAddress,
        uint256 ethereumReinvested,
        uint256 tokensMinted
    );

    event onWithdraw(
        address indexed customerAddress,
        uint256 ethereumWithdrawn
    );

    // ERC20
    event Transfer(
        address indexed from,
        address indexed to,
        uint256 tokens
    );


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

    string public name = "Proof of Trevon James";
    string public symbol = "PoTJ";
    uint8 constant public decimals = 18;

    /// @dev 15% dividends for token purchase
    uint8 constant internal entryFee_ = 20;

    /// @dev 10% dividends for token transfer
    uint8 constant internal transferFee_ = 10;

    /// @dev 25% dividends for token selling
    uint8 constant internal exitFee_ = 25;

    /// @dev 35% of entryFee_ (i.e. 7% dividends) is given to referrer
    uint8 constant internal refferalFee_ = 35;

    uint256 constant internal tokenPriceInitial_ = 0.00000001 ether;
    uint256 constant internal tokenPriceIncremental_ = 0.000000001 ether;
    uint256 constant internal magnitude = 2 ** 64;

    /// @dev proof of stake (defaults at 50 tokens)
    uint256 public stakingRequirement = 50e18;


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

    // amount of shares for each address (scaled number)
    mapping(address => uint256) internal tokenBalanceLedger_;
    mapping(address => uint256) internal referralBalance_;
    mapping(address => int256) internal payoutsTo_;
    uint256 internal tokenSupply_;
    uint256 internal profitPerShare_;


    /*=======================================
    =            PUBLIC FUNCTIONS           =
    =======================================*/

    /// @dev Converts all incoming ethereum to tokens for the caller, and passes down the referral addy (if any)
    function buy(address _referredBy) public payable returns (uint256) {
        purchaseTokens(msg.value, _referredBy);
    }

    /**
     * @dev Fallback function to handle ethereum that was send straight to the contract
     *  Unfortunately we cannot use a referral address this way.
     */
    function() payable public {
        purchaseTokens(msg.value, 0x0);
    }

    /// @dev Converts all of caller's dividends to tokens.
    function reinvest() onlyStronghands public {
        // fetch dividends
        uint256 _dividends = myDividends(false); // retrieve ref. bonus later in the code

        // pay out the dividends virtually
        address _customerAddress = msg.sender;
        payoutsTo_[_customerAddress] +=  (int256) (_dividends * magnitude);

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

        // dispatch a buy order with the virtualized "withdrawn dividends"
        uint256 _tokens = purchaseTokens(_dividends, 0x0);

        // fire event
        onReinvestment(_customerAddress, _dividends, _tokens);
    }

    /// @dev Alias of sell() and withdraw().
    function exit() public {
        // get token count for caller & sell them all
        address _customerAddress = msg.sender;
        uint256 _tokens = tokenBalanceLedger_[_customerAddress];
        if (_tokens > 0) sell(_tokens);

        // lambo delivery service
        withdraw();
    }

    /// @dev Withdraws all of the callers earnings.
    function withdraw() onlyStronghands public {
        // setup data
        address _customerAddress = msg.sender;
        uint256 _dividends = myDividends(false); // get ref. bonus later in the code

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

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

        // lambo delivery service
        _customerAddress.transfer(_dividends);

        // fire event
        onWithdraw(_customerAddress, _dividends);
    }

    /// @dev Liquifies tokens to ethereum.
    function sell(uint256 _amountOfTokens) onlyBagholders public {
        // setup data
        address _customerAddress = msg.sender;
        // russian hackers BTFO
        require(_amountOfTokens <= tokenBalanceLedger_[_customerAddress]);
        uint256 _tokens = _amountOfTokens;
        uint256 _ethereum = tokensToEthereum_(_tokens);
        uint256 _dividends = SafeMath.div(SafeMath.mul(_ethereum, exitFee_), 100);
        uint256 _taxedEthereum = SafeMath.sub(_ethereum, _dividends);

        // burn the sold tokens
        tokenSupply_ = SafeMath.sub(tokenSupply_, _tokens);
        tokenBalanceLedger_[_customerAddress] = SafeMath.sub(tokenBalanceLedger_[_customerAddress], _tokens);

        // update dividends tracker
        int256 _updatedPayouts = (int256) (profitPerShare_ * _tokens + (_taxedEthereum * magnitude));
        payoutsTo_[_customerAddress] -= _updatedPayouts;

        // dividing by zero is a bad idea
        if (tokenSupply_ > 0) {
            // update the amount of dividends per token
            profitPerShare_ = SafeMath.add(profitPerShare_, (_dividends * magnitude) / tokenSupply_);
        }

        // fire event
        onTokenSell(_customerAddress, _tokens, _taxedEthereum, now, buyPrice());
    }


    /**
     * @dev Transfer tokens from the caller to a new holder.
     *  Remember, there's a 15% fee here as well.
     */
    function transfer(address _toAddress, uint256 _amountOfTokens) onlyBagholders public returns (bool) {
        // setup
        address _customerAddress = msg.sender;

        // make sure we have the requested tokens
        require(_amountOfTokens <= tokenBalanceLedger_[_customerAddress]);

        // withdraw all outstanding dividends first
        if (myDividends(true) > 0) {
            withdraw();
        }

        // liquify 10% of the tokens that are transfered
        // these are dispersed to shareholders
        uint256 _tokenFee = SafeMath.div(SafeMath.mul(_amountOfTokens, transferFee_), 100);
        uint256 _taxedTokens = SafeMath.sub(_amountOfTokens, _tokenFee);
        uint256 _dividends = tokensToEthereum_(_tokenFee);

        // burn the fee tokens
        tokenSupply_ = SafeMath.sub(tokenSupply_, _tokenFee);

        // exchange tokens
        tokenBalanceLedger_[_customerAddress] = SafeMath.sub(tokenBalanceLedger_[_customerAddress], _amountOfTokens);
        tokenBalanceLedger_[_toAddress] = SafeMath.add(tokenBalanceLedger_[_toAddress], _taxedTokens);

        // update dividend trackers
        payoutsTo_[_customerAddress] -= (int256) (profitPerShare_ * _amountOfTokens);
        payoutsTo_[_toAddress] += (int256) (profitPerShare_ * _taxedTokens);

        // disperse dividends among holders
        profitPerShare_ = SafeMath.add(profitPerShare_, (_dividends * magnitude) / tokenSupply_);

        // fire event
        Transfer(_customerAddress, _toAddress, _taxedTokens);

        // ERC20
        return true;
    }


    /*=====================================
    =      HELPERS AND CALCULATORS        =
    =====================================*/

    /**
     * @dev Method to view the current Ethereum stored in the contract
     *  Example: totalEthereumBalance()
     */
    function totalEthereumBalance() public view returns (uint256) {
        return this.balance;
    }

    /// @dev Retrieve the total token supply.
    function totalSupply() public view returns (uint256) {
        return tokenSupply_;
    }

    /// @dev Retrieve the tokens owned by the caller.
    function myTokens() public view returns (uint256) {
        address _customerAddress = msg.sender;
        return balanceOf(_customerAddress);
    }

    /**
     * @dev Retrieve the dividends owned by the caller.
     *  If `_includeReferralBonus` is to to 1/true, the referral bonus will be included in the calculations.
     *  The reason for this, is that in the frontend, we will want to get the total divs (global + ref)
     *  But in the internal calculations, we want them separate.
     */
    function myDividends(bool _includeReferralBonus) public view returns (uint256) {
        address _customerAddress = msg.sender;
        return _includeReferralBonus ? dividendsOf(_customerAddress) + referralBalance_[_customerAddress] : dividendsOf(_customerAddress) ;
    }

    /// @dev Retrieve the token balance of any single address.
    function balanceOf(address _customerAddress) public view returns (uint256) {
        return tokenBalanceLedger_[_customerAddress];
    }

    /// @dev Retrieve the dividend balance of any single address.
    function dividendsOf(address _customerAddress) public view returns (uint256) {
        return (uint256) ((int256) (profitPerShare_ * tokenBalanceLedger_[_customerAddress]) - payoutsTo_[_customerAddress]) / magnitude;
    }

    /// @dev Return the sell price of 1 individual token.
    function sellPrice() public view returns (uint256) {
        // our calculation relies on the token supply, so we need supply. Doh.
        if (tokenSupply_ == 0) {
            return tokenPriceInitial_ - tokenPriceIncremental_;
        } else {
            uint256 _ethereum = tokensToEthereum_(1e18);
            uint256 _dividends = SafeMath.div(SafeMath.mul(_ethereum, exitFee_), 100);
            uint256 _taxedEthereum = SafeMath.sub(_ethereum, _dividends);

            return _taxedEthereum;
        }
    }

    /// @dev Return the buy price of 1 individual token.
    function buyPrice() public view returns (uint256) {
        // our calculation relies on the token supply, so we need supply. Doh.
        if (tokenSupply_ == 0) {
            return tokenPriceInitial_ + tokenPriceIncremental_;
        } else {
            uint256 _ethereum = tokensToEthereum_(1e18);
            uint256 _dividends = SafeMath.div(SafeMath.mul(_ethereum, entryFee_), 100);
            uint256 _taxedEthereum = SafeMath.add(_ethereum, _dividends);

            return _taxedEthereum;
        }
    }

    /// @dev Function for the frontend to dynamically retrieve the price scaling of buy orders.
    function calculateTokensReceived(uint256 _ethereumToSpend) public view returns (uint256) {
        uint256 _dividends = SafeMath.div(SafeMath.mul(_ethereumToSpend, entryFee_), 100);
        uint256 _taxedEthereum = SafeMath.sub(_ethereumToSpend, _dividends);
        uint256 _amountOfTokens = ethereumToTokens_(_taxedEthereum);

        return _amountOfTokens;
    }

    /// @dev Function for the frontend to dynamically retrieve the price scaling of sell orders.
    function calculateEthereumReceived(uint256 _tokensToSell) public view returns (uint256) {
        require(_tokensToSell <= tokenSupply_);
        uint256 _ethereum = tokensToEthereum_(_tokensToSell);
        uint256 _dividends = SafeMath.div(SafeMath.mul(_ethereum, exitFee_), 100);
        uint256 _taxedEthereum = SafeMath.sub(_ethereum, _dividends);
        return _taxedEthereum;
    }


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

    /// @dev Internal function to actually purchase the tokens.
    function purchaseTokens(uint256 _incomingEthereum, address _referredBy) internal returns (uint256) {
        // data setup
        address _customerAddress = msg.sender;
        uint256 _undividedDividends = SafeMath.div(SafeMath.mul(_incomingEthereum, entryFee_), 100);
        uint256 _referralBonus = SafeMath.div(SafeMath.mul(_undividedDividends, refferalFee_), 100);
        uint256 _dividends = SafeMath.sub(_undividedDividends, _referralBonus);
        uint256 _taxedEthereum = SafeMath.sub(_incomingEthereum, _undividedDividends);
        uint256 _amountOfTokens = ethereumToTokens_(_taxedEthereum);
        uint256 _fee = _dividends * magnitude;

        // no point in continuing execution if OP is a poorfag russian hacker
        // prevents overflow in the case that the pyramid somehow magically starts being used by everyone in the world
        // (or hackers)
        // and yes we know that the safemath function automatically rules out the "greater then" equasion.
        require(_amountOfTokens > 0 && SafeMath.add(_amountOfTokens, tokenSupply_) > tokenSupply_);

        // is the user referred by a masternode?
        if (
            // is this a referred purchase?
            _referredBy != 0x0000000000000000000000000000000000000000 &&

            // no cheating!
            _referredBy != _customerAddress &&

            // does the referrer have at least X whole tokens?
            // i.e is the referrer a godly chad masternode
            tokenBalanceLedger_[_referredBy] >= stakingRequirement
        ) {
            // wealth redistribution
            referralBalance_[_referredBy] = SafeMath.add(referralBalance_[_referredBy], _referralBonus);
        } else {
            // no ref purchase
            // add the referral bonus back to the global dividends cake
            _dividends = SafeMath.add(_dividends, _referralBonus);
            _fee = _dividends * magnitude;
        }

        // we can't give people infinite ethereum
        if (tokenSupply_ > 0) {
            // add tokens to the pool
            tokenSupply_ = SafeMath.add(tokenSupply_, _amountOfTokens);

            // take the amount of dividends gained through this transaction, and allocates them evenly to each shareholder
            profitPerShare_ += (_dividends * magnitude / tokenSupply_);

            // calculate the amount of tokens the customer receives over his purchase
            _fee = _fee - (_fee - (_amountOfTokens * (_dividends * magnitude / tokenSupply_)));
        } else {
            // add tokens to the pool
            tokenSupply_ = _amountOfTokens;
        }

        // update circulating supply & the ledger address for the customer
        tokenBalanceLedger_[_customerAddress] = SafeMath.add(tokenBalanceLedger_[_customerAddress], _amountOfTokens);

        // Tells the contract that the buyer doesn't deserve dividends for the tokens before they owned them;
        // really i know you think you do but you don't
        int256 _updatedPayouts = (int256) (profitPerShare_ * _amountOfTokens - _fee);
        payoutsTo_[_customerAddress] += _updatedPayouts;

        // fire event
        onTokenPurchase(_customerAddress, _incomingEthereum, _amountOfTokens, _referredBy, now, buyPrice());

        return _amountOfTokens;
    }

    /**
     * @dev Calculate Token price based on an amount of incoming ethereum
     *  It's an algorithm, hopefully we gave you the whitepaper with it in scientific notation;
     *  Some conversions occurred to prevent decimal errors or underflows / overflows in solidity code.
     */
    function ethereumToTokens_(uint256 _ethereum) internal view returns (uint256) {
        uint256 _tokenPriceInitial = tokenPriceInitial_ * 1e18;
        uint256 _tokensReceived =
         (
            (
                // underflow attempts BTFO
                SafeMath.sub(
                    (sqrt
                        (
                            (_tokenPriceInitial ** 2)
                            +
                            (2 * (tokenPriceIncremental_ * 1e18) * (_ethereum * 1e18))
                            +
                            ((tokenPriceIncremental_ ** 2) * (tokenSupply_ ** 2))
                            +
                            (2 * tokenPriceIncremental_ * _tokenPriceInitial*tokenSupply_)
                        )
                    ), _tokenPriceInitial
                )
            ) / (tokenPriceIncremental_)
        ) - (tokenSupply_);

        return _tokensReceived;
    }

    /**
     * @dev Calculate token sell value.
     *  It's an algorithm, hopefully we gave you the whitepaper with it in scientific notation;
     *  Some conversions occurred to prevent decimal errors or underflows / overflows in solidity code.
     */
    function tokensToEthereum_(uint256 _tokens) internal view returns (uint256) {
        uint256 tokens_ = (_tokens + 1e18);
        uint256 _tokenSupply = (tokenSupply_ + 1e18);
        uint256 _etherReceived =
        (
            // underflow attempts BTFO
            SafeMath.sub(
                (
                    (
                        (
                            tokenPriceInitial_ + (tokenPriceIncremental_ * (_tokenSupply / 1e18))
                        ) - tokenPriceIncremental_
                    ) * (tokens_ - 1e18)
                ), (tokenPriceIncremental_ * ((tokens_ ** 2 - tokens_) / 1e18)) / 2
            )
        / 1e18);

        return _etherReceived;
    }

    /// @dev This is where all your gas goes.
    function sqrt(uint256 x) internal pure returns (uint256 y) {
        uint256 z = (x + 1) / 2;
        y = x;

        while (z < y) {
            y = z;
            z = (x / z + z) / 2;
        }
    }


}

/**
 * @title SafeMath
 * @dev Math operations with safety checks that throw on error
 */
library SafeMath {

    /**
    * @dev Multiplies two numbers, throws on overflow.
    */
    function mul(uint256 a, uint256 b) internal pure returns (uint256) {
        if (a == 0) {
            return 0;
        }
        uint256 c = a * b;
        assert(c / a == b);
        return c;
    }

    /**
    * @dev Integer division of two numbers, truncating the quotient.
    */
    function div(uint256 a, uint256 b) internal pure returns (uint256) {
        // assert(b > 0); // Solidity automatically throws when dividing by 0
        uint256 c = a / b;
        // assert(a == b * c + a % b); // There is no case in which this doesn't hold
        return c;
    }

    /**
    * @dev Substracts two numbers, throws on overflow (i.e. if subtrahend is greater than minuend).
    */
    function sub(uint256 a, uint256 b) internal pure returns (uint256) {
        assert(b <= a);
        return a - b;
    }

    /**
    * @dev Adds two numbers, throws on overflow.
    */
    function add(uint256 a, uint256 b) internal pure returns (uint256) {
        uint256 c = a + b;
        assert(c >= a);
        return c;
    }

}

    Contract ABI  
[{"constant":true,"inputs":[{"name":"_customerAddress","type":"address"}],"name":"dividendsOf","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"name","outputs":[{"name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"_ethereumToSpend","type":"uint256"}],"name":"calculateTokensReceived","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"totalSupply","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"_tokensToSell","type":"uint256"}],"name":"calculateEthereumReceived","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"decimals","outputs":[{"name":"","type":"uint8"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"withdraw","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"sellPrice","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"stakingRequirement","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"_includeReferralBonus","type":"bool"}],"name":"myDividends","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"totalEthereumBalance","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"_customerAddress","type":"address"}],"name":"balanceOf","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"buyPrice","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"myTokens","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"symbol","outputs":[{"name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_toAddress","type":"address"},{"name":"_amountOfTokens","type":"uint256"}],"name":"transfer","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_amountOfTokens","type":"uint256"}],"name":"sell","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"exit","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_referredBy","type":"address"}],"name":"buy","outputs":[{"name":"","type":"uint256"}],"payable":true,"stateMutability":"payable","type":"function"},{"constant":false,"inputs":[],"name":"reinvest","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"payable":true,"stateMutability":"payable","type":"fallback"},{"anonymous":false,"inputs":[{"indexed":true,"name":"customerAddress","type":"address"},{"indexed":false,"name":"incomingEthereum","type":"uint256"},{"indexed":false,"name":"tokensMinted","type":"uint256"},{"indexed":true,"name":"referredBy","type":"address"},{"indexed":false,"name":"timestamp","type":"uint256"},{"indexed":false,"name":"price","type":"uint256"}],"name":"onTokenPurchase","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"customerAddress","type":"address"},{"indexed":false,"name":"tokensBurned","type":"uint256"},{"indexed":false,"name":"ethereumEarned","type":"uint256"},{"indexed":false,"name":"timestamp","type":"uint256"},{"indexed":false,"name":"price","type":"uint256"}],"name":"onTokenSell","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"customerAddress","type":"address"},{"indexed":false,"name":"ethereumReinvested","type":"uint256"},{"indexed":false,"name":"tokensMinted","type":"uint256"}],"name":"onReinvestment","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"customerAddress","type":"address"},{"indexed":false,"name":"ethereumWithdrawn","type":"uint256"}],"name":"onWithdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"from","type":"address"},{"indexed":true,"name":"to","type":"address"},{"indexed":false,"name":"tokens","type":"uint256"}],"name":"Transfer","type":"event"}]

  Contract Creation Code Switch To Opcodes View
606060405260408051908101604052601581527f50726f6f66206f6620547265766f6e204a616d65730000000000000000000000602082015260009080516200004d929160200190620000b7565b5060408051908101604052600481527f506f544a000000000000000000000000000000000000000000000000000000006020820152600190805162000097929160200190620000b7565b506802b5e3af16b18800006002553415620000b157600080fd5b6200015c565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620000fa57805160ff19168380011785556200012a565b828001600101855582156200012a579182015b828111156200012a5782518255916020019190600101906200010d565b50620001389291506200013c565b5090565b6200015991905b8082111562000138576000815560010162000143565b90565b610f8d806200016c6000396000f3006060604052600436106101105763ffffffff7c010000000000000000000000000000000000000000000000000000000060003504166265318b811461011e57806306fdde031461014f57806310d0ffdd146101d957806318160ddd146101ef5780632260937314610202578063313ce567146102185780633ccfd60b146102415780634b7503341461025657806356d399e814610269578063688abbf71461027c5780636b2f46321461029457806370a08231146102a75780638620410b146102c6578063949e8acd146102d957806395d89b41146102ec578063a9059cbb146102ff578063e4849b3214610335578063e9fad8ee1461034b578063f088d5471461035e578063fdb5a03e14610372575b61011b346000610385565b50005b341561012957600080fd5b61013d600160a060020a03600435166105ed565b60405190815260200160405180910390f35b341561015a57600080fd5b610162610628565b60405160208082528190810183818151815260200191508051906020019080838360005b8381101561019e578082015183820152602001610186565b50505050905090810190601f1680156101cb5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34156101e457600080fd5b61013d6004356106c6565b34156101fa57600080fd5b61013d6106f9565b341561020d57600080fd5b61013d6004356106ff565b341561022357600080fd5b61022b61073b565b60405160ff909116815260200160405180910390f35b341561024c57600080fd5b610254610740565b005b341561026157600080fd5b61013d61080c565b341561027457600080fd5b61013d610863565b341561028757600080fd5b61013d6004351515610869565b341561029f57600080fd5b61013d6108ac565b34156102b257600080fd5b61013d600160a060020a03600435166108ba565b34156102d157600080fd5b61013d6108d5565b34156102e457600080fd5b61013d610920565b34156102f757600080fd5b610162610932565b341561030a57600080fd5b610321600160a060020a036004351660243561099d565b604051901515815260200160405180910390f35b341561034057600080fd5b610254600435610b48565b341561035657600080fd5b610254610cc4565b61013d600160a060020a0360043516610cfb565b341561037d57600080fd5b610254610d07565b600033818080808080806103a461039d8c6014610dc2565b6064610df8565b96506103b461039d886023610dc2565b95506103c08787610e0f565b94506103cc8b88610e0f565b93506103d784610e21565b9250680100000000000000008502915060008311801561040157506006546103ff8482610eb3565b115b151561040c57600080fd5b600160a060020a038a1615801590610436575087600160a060020a03168a600160a060020a031614155b801561045c5750600254600160a060020a038b1660009081526003602052604090205410155b156104a257600160a060020a038a166000908152600460205260409020546104849087610eb3565b600160a060020a038b166000908152600460205260409020556104bd565b6104ac8587610eb3565b945068010000000000000000850291505b60006006541115610521576104d460065484610eb3565b60068190556801000000000000000086028115156104ee57fe5b6007805492909104909101905560065468010000000000000000860281151561051357fe5b048302820382039150610527565b60068390555b600160a060020a03881660009081526003602052604090205461054a9084610eb3565b600160a060020a03808a166000818152600360209081526040808320959095556007546005909152939020805493870286900393840190559192508b16907f8032875b28d82ddbd303a9e4e5529d047a14ecb6290f80012a81b7e6227ff1ab8d86426105b46108d5565b6040518085815260200184815260200183815260200182815260200194505050505060405180910390a350909998505050505050505050565b600160a060020a0316600090815260056020908152604080832054600390925290912054600754680100000000000000009102919091030490565b60008054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156106be5780601f10610693576101008083540402835291602001916106be565b820191906000526020600020905b8154815290600101906020018083116106a157829003601f168201915b505050505081565b60008080806106d961039d866014610dc2565b92506106e58584610e0f565b91506106f082610e21565b95945050505050565b60065490565b600080600080600654851115151561071657600080fd5b61071f85610ec2565b925061072f61039d846019610dc2565b91506106f08383610e0f565b601281565b600080600061074f6001610869565b1161075957600080fd5b3391506107666000610869565b600160a060020a0383166000818152600560209081526040808320805468010000000000000000870201905560049091528082208054929055920192509082156108fc0290839051600060405180830381858888f1935050505015156107cb57600080fd5b81600160a060020a03167fccad973dcd043c7d680389db4378bd6b9775db7124092e9e0422c9e46d7985dc8260405190815260200160405180910390a25050565b6000806000806006546000141561082a57640218711a00935061085d565b61083b670de0b6b3a7640000610ec2565b925061084b61039d846019610dc2565b91506108578383610e0f565b90508093505b50505090565b60025481565b6000338261087f5761087a816105ed565b6108a3565b600160a060020a0381166000908152600460205260409020546108a1826105ed565b015b91505b50919050565b600160a060020a0330163190565b600160a060020a031660009081526003602052604090205490565b600080600080600654600014156108f35764028fa6ae00935061085d565b610904670de0b6b3a7640000610ec2565b925061091461039d846014610dc2565b91506108578383610eb3565b60003361092c816108ba565b91505090565b60018054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156106be5780601f10610693576101008083540402835291602001916106be565b6000806000806000806109ae610920565b116109b857600080fd5b33600160a060020a0381166000908152600360205260409020549094508611156109e157600080fd5b60006109ed6001610869565b11156109fb576109fb610740565b610a0961039d87600a610dc2565b9250610a158684610e0f565b9150610a2083610ec2565b9050610a2e60065484610e0f565b600655600160a060020a038416600090815260036020526040902054610a549087610e0f565b600160a060020a038086166000908152600360205260408082209390935590891681522054610a839083610eb3565b600160a060020a0388811660008181526003602090815260408083209590955560078054948a16835260059091528482208054948c02909403909355825491815292909220805492850290920190915554600654610af79190680100000000000000008402811515610af157fe5b04610eb3565b600755600160a060020a038088169085167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405190815260200160405180910390a35060019695505050505050565b6000806000806000806000610b5b610920565b11610b6557600080fd5b33600160a060020a038116600090815260036020526040902054909650871115610b8e57600080fd5b869450610b9a85610ec2565b9350610baa61039d856019610dc2565b9250610bb68484610e0f565b9150610bc460065486610e0f565b600655600160a060020a038616600090815260036020526040902054610bea9086610e0f565b600160a060020a0387166000908152600360209081526040808320939093556007546005909152918120805492880268010000000000000000860201928390039055600654919250901115610c5b57610c57600754600654680100000000000000008602811515610af157fe5b6007555b85600160a060020a03167f8d3a0130073dbd54ab6ac632c05946df540553d3b514c9f8165b4ab7f2b1805e868442610c916108d5565b6040518085815260200184815260200183815260200182815260200194505050505060405180910390a250505050505050565b33600160a060020a03811660009081526003602052604081205490811115610cef57610cef81610b48565b610cf7610740565b5050565b60006108a63483610385565b600080600080610d176001610869565b11610d2157600080fd5b610d2b6000610869565b33600160a060020a038116600090815260056020908152604080832080546801000000000000000087020190556004909152812080549082905590920194509250610d77908490610385565b905081600160a060020a03167fbe339fc14b041c2b0e0f3dd2cd325d0c3668b78378001e53160eab3615326458848360405191825260208201526040908101905180910390a2505050565b600080831515610dd55760009150610df1565b50828202828482811515610de557fe5b0414610ded57fe5b8091505b5092915050565b6000808284811515610e0657fe5b04949350505050565b600082821115610e1b57fe5b50900390565b6006546000906b204fce5e3e25026110000000908290633b9aca00610ea0610e9a7259aedfc10d7279c5eed140164540000000000088026002850a670de0b6b3a764000002016f0f0bdc21abb48db201e86d40000000008502017704140c78940f6a24fdffc78873d4490d210000000000000001610f2c565b85610e0f565b811515610ea957fe5b0403949350505050565b600082820183811015610ded57fe5b600654600090670de0b6b3a7640000838101918101908390610f19640218711a00828504633b9aca0002018702600283670de0b6b3a763ffff1982890a8b90030104633b9aca0002811515610f1357fe5b04610e0f565b811515610f2257fe5b0495945050505050565b80600260018201045b818110156108a6578091506002818285811515610f4e57fe5b0401811515610f5957fe5b049050610f355600a165627a7a72305820ae4b88f50b406a7a09a38f04fa4be89df8d2f5bf3e029f8320e56dcf651469010029

   Swarm Source:
bzzr://ae4b88f50b406a7a09a38f04fa4be89df8d2f5bf3e029f8320e56dcf65146901

 

View All
Block Age txn Difficulty GasUsed Reward
View All
Block Age UncleNumber Difficulty GasUsed Reward
Make sure to use the "downvote" button for any spammy posts, and the "upvote" for interesting conversations.