Skip to content
Verified contractPartial

EtherModifierPandee

Address0x7de3b00431cd621c1de560c4e85cd93a28f689cb
Balance

0.000008 ETH

 

Transactions

160

 

Compiler

solc 0.2.1

 

Same code

Only this contract

 

Details

Compiler
solc 0.2.1+commit.91a6b35
Language
solidity
Optimization
Yes, 200 runs
License
Not stated
Match
Partialcreation code: yes, runtime code: yes
Verified on Sourcify
Created in block
5,974,723
Creation transaction
0xb78d5bfc69…43f1f8c805

EtherModifierPandee.sol

contract EtherModifierPandee
{
    struct Person 
    {
        address etherAddress;
        uint amount;
    }

    Person[] public persons;

    uint public payoutIdx = 0;
    uint public collectedFees;
    uint public balance = 0;
    uint amount;
    uint maximum = (1 ether)/10;
    uint minimum = (1 ether)/40+(1 ether)/1000;
    uint exchangemod = 120; 
    
    address public owner;
    address public developer=0xC99B66E5Cb46A05Ea997B0847a1ec50Df7fe8976;

    modifier _onlyowner
    {
        if (msg.sender == owner) 
        _
    }
    function EtherModifierPandee() 
    {
        owner = msg.sender;
    }

    function() 
    {
        enter();
    }
  
    function enter()
    {
        if (msg.value >= minimum && msg.value <= maximum) //if value is between 0.01 and 0.025
        {
	        //if value is correct
            collectedFees += ((msg.value/100) * 8) ;
	        owner.send(collectedFees/2);
	        developer.send(collectedFees/2);
	        collectedFees = 0;
	        amount = msg.value;
	        canSort();
        }
	    else
	    {
            //if value isnt correct
		    collectedFees += ((msg.value/100) * 8); //add fee to fee counter
	        owner.send(collectedFees/2);    //send halved fee to owner
	        developer.send(collectedFees/2);//send halved fee to developer
	        collectedFees = 0;
	        msg.sender.send(msg.value - ((msg.value/100) * 8)); //return icome - fee to sender
	    }
    }
    function canSort()
    {
        uint idx = persons.length;
        persons.length += 1;
        persons[idx].etherAddress = msg.sender;
        persons[idx].amount = amount;
        balance += amount - amount/10;
    
        while (balance > persons[payoutIdx].amount / 100 * exchangemod ) 
        {
            uint transactionAmount = persons[payoutIdx].amount / 100 * exchangemod;
            persons[payoutIdx].etherAddress.send(transactionAmount);
    
            balance -= transactionAmount;
            payoutIdx += 1;
        }
    }
    function setOwner(address _owner) _onlyowner 
    {
        owner = _owner;
    }
}
Compiler settingsShow
{
  "libraries": {},
  "optimizer": {
    "runs": 200,
    "enabled": true
  }
}

Source code and metadata: Sourcify.

The source code belongs to the authors of the contract.