Contract Overview
Balance: 1.33485763888888889 Ether
Ether Value: $269.85 (@ $202.16/ETH)
Transactions: 7 txns
 Latest 7 txns

TxHash Age From To Value [TxFee]
0xd9ef84c141698acfa9a8d880cf1847220cebacb790386518c68bed53ec77107e2 days 3 hrs ago0x85ffac7184ddf8d0dd47607acbbd81736dc89ee5  IN   0x6d9f2ad8aa8c4ceafd032c0e8abdb3c2ccf9a7c50 Ether0.000229235
0x9d630e2a2325c5b8e5b2ddef8f0c71224b137df117ed42c49c3e606c4da5e3633 days 2 hrs ago0x85ffac7184ddf8d0dd47607acbbd81736dc89ee5  IN   0x6d9f2ad8aa8c4ceafd032c0e8abdb3c2ccf9a7c50 Ether0.000229235
0x80d65cde7a0253c311d28b5229936ccd7bb32bdbb5b45e1f56097ae9bed06d9e3 days 3 hrs ago0x85ffac7184ddf8d0dd47607acbbd81736dc89ee5  IN   0x6d9f2ad8aa8c4ceafd032c0e8abdb3c2ccf9a7c51 Ether0.000764346
0x5b16633bd3a8bd5573f53c2b3ea165b1b212ce22750f76456450fed6c710520a3 days 3 hrs ago0x85ffac7184ddf8d0dd47607acbbd81736dc89ee5  IN   0x6d9f2ad8aa8c4ceafd032c0e8abdb3c2ccf9a7c50 Ether0.00021614
0x3ce441586b264f1e49817faff788e7a83ef1b744b9be9607e8aaaacc94c339bf3 days 5 hrs ago0x85ffac7184ddf8d0dd47607acbbd81736dc89ee5  IN   0x6d9f2ad8aa8c4ceafd032c0e8abdb3c2ccf9a7c51 Ether0.00049938
0x51987d3d9f5e2be59ea5cecd5e8858fd354b9b839dece949a3409878617d26ec7 days 37 mins ago0xcc1ceb36cab5ada7fd0376b55602dd0d4b429c30  IN   0x6d9f2ad8aa8c4ceafd032c0e8abdb3c2ccf9a7c50 Ether0.000040443
0xa49c9a8383ab0f2867b6f98a78f86cf8f4fea8ce108633c6ee04ed08c335b5267 days 43 mins ago0xcc1ceb36cab5ada7fd0376b55602dd0d4b429c30  IN    Contract Creation0 Ether0.0027136864
[ Download CSV Export  ] 
 Internal Transactions as a result of Contract Execution
 Latest 8 Internal Transactions

ParentTxHash Block Age From To Value
0xd9ef84c141698acfa9a8d880cf1847220cebacb790386518c68bed53ec77107e65275782 days 3 hrs ago0x6d9f2ad8aa8c4ceafd032c0e8abdb3c2ccf9a7c50x85ffac7184ddf8d0dd47607acbbd81736dc89ee50.11495 Ether
0x9d630e2a2325c5b8e5b2ddef8f0c71224b137df117ed42c49c3e606c4da5e36365217183 days 2 hrs ago0x6d9f2ad8aa8c4ceafd032c0e8abdb3c2ccf9a7c50x85ffac7184ddf8d0dd47607acbbd81736dc89ee50.005244444444444444 Ether
0x80d65cde7a0253c311d28b5229936ccd7bb32bdbb5b45e1f56097ae9bed06d9e65214653 days 3 hrs ago0x6d9f2ad8aa8c4ceafd032c0e8abdb3c2ccf9a7c50x53e10ad589f223d88aa178d7c8fd2ee3716df8630.24 Ether
0x80d65cde7a0253c311d28b5229936ccd7bb32bdbb5b45e1f56097ae9bed06d9e65214653 days 3 hrs ago0x6d9f2ad8aa8c4ceafd032c0e8abdb3c2ccf9a7c50x85ffac7184ddf8d0dd47607acbbd81736dc89ee50.000080555555555555 Ether
0x80d65cde7a0253c311d28b5229936ccd7bb32bdbb5b45e1f56097ae9bed06d9e65214653 days 3 hrs ago0x6d9f2ad8aa8c4ceafd032c0e8abdb3c2ccf9a7c50xa3592653e52125c905041ed85a787540313df8d90.03 Ether
0x5b16633bd3a8bd5573f53c2b3ea165b1b212ce22750f76456450fed6c710520a65214573 days 3 hrs ago0x6d9f2ad8aa8c4ceafd032c0e8abdb3c2ccf9a7c50x85ffac7184ddf8d0dd47607acbbd81736dc89ee50.004867361111111111 Ether
0x3ce441586b264f1e49817faff788e7a83ef1b744b9be9607e8aaaacc94c339bf65209473 days 5 hrs ago0x6d9f2ad8aa8c4ceafd032c0e8abdb3c2ccf9a7c50x53e10ad589f223d88aa178d7c8fd2ee3716df8630.24 Ether
0x3ce441586b264f1e49817faff788e7a83ef1b744b9be9607e8aaaacc94c339bf65209473 days 5 hrs ago0x6d9f2ad8aa8c4ceafd032c0e8abdb3c2ccf9a7c50xa3592653e52125c905041ed85a787540313df8d90.03 Ether
[ Download CSV Export  ] 
Contract Source Code Verified (Exact Match)
Contract Name: GreenEthereus2
Compiler Text: v0.4.25+commit.59dbf8f1
Optimization Enabled: Yes
Runs (Optimiser):  200



  Contract Source Code   Find Similiar Contracts

pragma solidity 0.4.25;


library SafeMath {


    function mul(uint256 _a, uint256 _b) internal pure returns (uint256) {
        if (_a == 0) {
            return 0;
        }

        uint256 c = _a * _b;
        require(c / _a == _b);

        return c;
    }

    function div(uint256 _a, uint256 _b) internal pure returns (uint256) {
        require(_b > 0);
        uint256 c = _a / _b;

        return c;
    }

    function sub(uint256 _a, uint256 _b) internal pure returns (uint256) {
        require(_b <= _a);
        uint256 c = _a - _b;

        return c;
    }

    function add(uint256 _a, uint256 _b) internal pure returns (uint256) {
        uint256 c = _a + _b;
        require(c >= _a);

        return c;
    }

    function mod(uint256 a, uint256 b) internal pure returns (uint256) {
        require(b != 0);
        return a % b;
    }
}

contract GreenEthereus2 {
    using SafeMath for uint;

    address public owner;
    address marketing;
    address admin;

    mapping (address => uint) index;
    mapping (address => mapping (uint => uint)) deposit;
    mapping (address => mapping (uint => uint)) finish;
    mapping (address => uint) checkpoint;

    mapping (address => address) referrers;
    mapping (address => uint) refBonus;

    event LogInvestment(address _addr, uint _value);
    event LogPayment(address _addr, uint _value);
    event LogNewReferrer(address _referral, address _referrer);
    event LogReferralInvestment(address _referral, uint _value);

    constructor(address _marketing, address _admin) public {
        owner = msg.sender;
        marketing = _marketing;
        admin = _admin;
    }

    function renounceOwnership() external {
        require(msg.sender == owner);
        owner = 0x0;
    }

    function bytesToAddress(bytes _source) internal pure returns(address parsedreferrer) {
        assembly {
            parsedreferrer := mload(add(_source,0x14))
        }
        return parsedreferrer;
    }

    function setRef(uint _value) internal {
        address _referrer = bytesToAddress(bytes(msg.data));
        if (_referrer != msg.sender) {
            referrers[msg.sender] = _referrer;
            refBonus[msg.sender] += _value * 3 / 100;
            refBonus[_referrer] += _value / 10;

            emit LogNewReferrer(msg.sender, _referrer);
            emit LogReferralInvestment(msg.sender, msg.value);
        }
    }

    function() external payable {
        if (msg.value == 0) {
            withdraw();
        } else {
            invest();
        }
    }

    function invest() public payable {

        require(msg.value >= 50000000000000000);
        admin.transfer(msg.value * 3 / 100);

        if (deposit[msg.sender][0] > 0 || refBonus[msg.sender] > 0) {
            withdraw();
            if (deposit[msg.sender][0] > 0) {
                index[msg.sender] += 1;
            }
        }

        checkpoint[msg.sender] = block.timestamp;
        finish[msg.sender][index[msg.sender]] = block.timestamp + (25 * 1 days);
        deposit[msg.sender][index[msg.sender]] = msg.value;

        if (referrers[msg.sender] != 0x0) {
            marketing.transfer(msg.value * 7 / 50);
            refBonus[referrers[msg.sender]] += msg.value / 10;
            emit LogReferralInvestment(msg.sender, msg.value);
        } else if (msg.data.length == 20) {
            marketing.transfer(msg.value * 7 / 50);
            setRef(msg.value);
        } else {
            marketing.transfer(msg.value * 6 / 25);
        }

        emit LogInvestment(msg.sender, msg.value);
    }

    function withdraw() public {

        uint _payout = refBonus[msg.sender];
        refBonus[msg.sender] = 0;

        for (uint i = 0; i <= index[msg.sender]; i++) {
            if (checkpoint[msg.sender] < finish[msg.sender][i]) {
                if (block.timestamp > finish[msg.sender][i]) {
                    _payout = _payout.add((deposit[msg.sender][i].mul(6).div(100)).mul(finish[msg.sender][i].sub(checkpoint[msg.sender])).div(1 days));
                } else {
                    _payout = _payout.add((deposit[msg.sender][i].mul(6).div(100)).mul(block.timestamp.sub(checkpoint[msg.sender])).div(1 days));
                }
            }
        }

        if (_payout > 0) {
            checkpoint[msg.sender] = block.timestamp;
            msg.sender.transfer(_payout);

            emit LogPayment(msg.sender, _payout);
        }
    }

    function getInfo1(address _address) public view returns(uint Invested) {
        uint _sum;
        for (uint i = 0; i <= index[_address]; i++) {
            if (block.timestamp < finish[_address][i]) {
                _sum += deposit[_address][i];
            }
        }
        Invested = _sum;
    }

    function getInfo2(address _address, uint _number) public view returns(uint Deposit_N) {
        if (block.timestamp < finish[_address][_number - 1]) {
            Deposit_N = deposit[_address][_number - 1];
        } else {
            Deposit_N = 0;
        }
    }

    function getInfo3(address _address) public view returns(uint Dividends, uint Bonuses) {
        uint _payout;
        for (uint i = 0; i <= index[_address]; i++) {
            if (checkpoint[_address] < finish[_address][i]) {
                if (block.timestamp > finish[_address][i]) {
                    _payout = _payout.add((deposit[_address][i].mul(6).div(100)).mul(finish[_address][i].sub(checkpoint[_address])).div(1 days));
                } else {
                    _payout = _payout.add((deposit[_address][i].mul(6).div(100)).mul(block.timestamp.sub(checkpoint[_address])).div(1 days));
                }
            }
        }
        Dividends = _payout;
        Bonuses = refBonus[_address];
    }
}

    Contract ABI  
[{"constant":true,"inputs":[{"name":"_address","type":"address"},{"name":"_number","type":"uint256"}],"name":"getInfo2","outputs":[{"name":"Deposit_N","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"withdraw","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"renounceOwnership","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"owner","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"_address","type":"address"}],"name":"getInfo1","outputs":[{"name":"Invested","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"_address","type":"address"}],"name":"getInfo3","outputs":[{"name":"Dividends","type":"uint256"},{"name":"Bonuses","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"invest","outputs":[],"payable":true,"stateMutability":"payable","type":"function"},{"inputs":[{"name":"_marketing","type":"address"},{"name":"_admin","type":"address"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"payable":true,"stateMutability":"payable","type":"fallback"},{"anonymous":false,"inputs":[{"indexed":false,"name":"_addr","type":"address"},{"indexed":false,"name":"_value","type":"uint256"}],"name":"LogInvestment","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"_addr","type":"address"},{"indexed":false,"name":"_value","type":"uint256"}],"name":"LogPayment","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"_referral","type":"address"},{"indexed":false,"name":"_referrer","type":"address"}],"name":"LogNewReferrer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"_referral","type":"address"},{"indexed":false,"name":"_value","type":"uint256"}],"name":"LogReferralInvestment","type":"event"}]

  Contract Creation Code Switch To Opcodes View
608060405234801561001057600080fd5b50604051604080610b1a83398101604052805160209091015160008054600160a060020a0319908116331790915560018054600160a060020a0394851690831617905560028054939092169216919091179055610aa8806100726000396000f3006080604052600436106100825763ffffffff7c0100000000000000000000000000000000000000000000000000000000600035041663144f9cc681146100a05780633ccfd60b146100d6578063715018a6146100eb5780638da5cb5b14610100578063abc8cddb14610131578063cf70e27b14610152578063e8b5e51f14610096575b3415156100965761009161018c565b61009e565b61009e61036c565b005b3480156100ac57600080fd5b506100c4600160a060020a0360043516602435610621565b60408051918252519081900360200190f35b3480156100e257600080fd5b5061009e61018c565b3480156100f757600080fd5b5061009e610688565b34801561010c57600080fd5b506101156106be565b60408051600160a060020a039092168252519081900360200190f35b34801561013d57600080fd5b506100c4600160a060020a03600435166106cd565b34801561015e57600080fd5b50610173600160a060020a0360043516610755565b6040805192835260208301919091528051918290030190f35b336000908152600860205260408120805490829055905b3360009081526003602052604090205481116102e757336000818152600560209081526040808320858452825280832054938352600690915290205410156102df573360009081526005602090815260408083208484529091529020544211156102aa573360009081526006602090815260408083205460058352818420858552909252909120546102a39161029691620151809161027e9161024b9163ffffffff6108d216565b33600090815260046020908152604080832089845290915290205461028a9060649061027e90600663ffffffff6108e916565b9063ffffffff61091e16565b9063ffffffff6108e916565b839063ffffffff61094116565b91506102df565b336000908152600660205260409020546102dc9061029690620151809061027e9061024b90429063ffffffff6108d216565b91505b6001016101a3565b600082111561036857336000818152600660205260408082204290555184156108fc0291859190818181858888f1935050505015801561032b573d6000803e3d6000fd5b50604080513381526020810184905281517f27a391d95d67e3626574fb5fbe3532bb7366e9254957b1f0e840953c248b2aa8929181900390910190a15b5050565b66b1a2bc2ec5000034101561038057600080fd5b600254604051600160a060020a03909116906064346003020480156108fc02916000818181858888f193505050501580156103bf573d6000803e3d6000fd5b5033600090815260046020908152604080832083805290915281205411806103f4575033600090815260086020526040812054115b156104395761040161018c565b336000908152600460209081526040808320838052909152812054111561043957336000908152600360205260409020805460010190555b33600081815260066020908152604080832042908190556005835281842060038452828520805486529084528285206220f58090920190915584845260048352818420905484528252808320349055928252600790522054600160a060020a03161561054d57600154604051600160a060020a03909116906032346007020480156108fc02916000818181858888f193505050501580156104de573d6000803e3d6000fd5b5033600081815260076020908152604080832054600160a060020a0316835260088252918290208054600a3490810490910190915582519384529083015280517f68ddd38115213632e2bb11139da8c4a26b4d2c9198679867ae030a657c0545259281900390910190a16105e5565b60143614156105a457600154604051600160a060020a03909116906032346007020480156108fc02916000818181858888f19350505050158015610595573d6000803e3d6000fd5b5061059f34610953565b6105e5565b600154604051600160a060020a03909116906019346006020480156108fc02916000818181858888f193505050501580156105e3573d6000803e3d6000fd5b505b6040805133815234602082015281517fc74590e3281392e897f5c0f45530951cfe0db0e86c76d65af861e80b925871a4929181900390910190a1565b600160a060020a03821660009081526005602090815260408083206000198501845290915281205442101561067e5750600160a060020a038216600090815260046020908152604080832060001985018452909152902054610682565b5060005b92915050565b600054600160a060020a0316331461069f57600080fd5b6000805473ffffffffffffffffffffffffffffffffffffffff19169055565b600054600160a060020a031681565b600080805b600160a060020a038416600090815260036020526040902054811161074e57600160a060020a038416600090815260056020908152604080832084845290915290205442101561074657600160a060020a038416600090815260046020908152604080832084845290915290205491909101905b6001016106d2565b5092915050565b60008080805b600160a060020a03851660009081526003602052604090205481116108b057600160a060020a0385166000818152600560209081526040808320858452825280832054938352600690915290205410156108a857600160a060020a038516600090815260056020908152604080832084845290915290205442111561086a57600160a060020a03851660009081526006602090815260408083205460058352818420858552909252909120546108639161029691620151809161027e916108279163ffffffff6108d216565b600160a060020a038a16600090815260046020908152604080832089845290915290205461028a9060649061027e90600663ffffffff6108e916565b91506108a8565b600160a060020a0385166000908152600660205260409020546108a59061029690620151809061027e9061082790429063ffffffff6108d216565b91505b60010161075b565b50600160a060020a039093166000908152600860205260409020549293915050565b600080838311156108e257600080fd5b5050900390565b6000808315156108fc576000915061074e565b5082820282848281151561090c57fe5b041461091757600080fd5b9392505050565b60008080831161092d57600080fd5b828481151561093857fe5b04949350505050565b60008282018381101561091757600080fd5b600061098f6000368080601f01602080910402602001604051908101604052809392919081815260200183838082843750610a75945050505050565b9050600160a060020a038116331461036857336000818152600760209081526040808320805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a038716908117909155600883528184208054606460038a0204019055808452928190208054600a880401905580519384529083019190915280517f2f6461653c890e2b6b3b8724242670308661a0c148c14d47f130e87b2c93e1a79281900390910190a16040805133815234602082015281517f68ddd38115213632e2bb11139da8c4a26b4d2c9198679867ae030a657c054525929181900390910190a15050565b60140151905600a165627a7a723058205ec2762f1cd8567db907232953a46c9e77c03bd0c10e31099fd03cf60ee96ff3002900000000000000000000000053e10ad589f223d88aa178d7c8fd2ee3716df863000000000000000000000000a3592653e52125c905041ed85a787540313df8d9

    Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
00000000000000000000000053e10ad589f223d88aa178d7c8fd2ee3716df863000000000000000000000000a3592653e52125c905041ed85a787540313df8d9

-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 00000000000000000000000053e10ad589f223d88aa178d7c8fd2ee3716df863
Arg [1] : 000000000000000000000000a3592653e52125c905041ed85a787540313df8d9


   Swarm Source:
bzzr://5ec2762f1cd8567db907232953a46c9e77c03bd0c10e31099fd03cf60ee96ff3

 

View All
Block Age transaction Difficulty GasUsed Reward
View All
Block Age UncleNumber Difficulty GasUsed Reward
Make sure to use the "Vote Down" button for any spammy posts, and the "Vote Up" for interesting conversations.