Token Triacoin

 

Overview [ERC-20]

Max Total Supply:
99,999,983,971.709689 TRE

Holders:
33

Transfers:
-

Loading
[ Download CSV Export  ] 
Loading
[ Download CSV Export  ] 
Loading

Click here to update the token information / general information
# Exchange Pair Price  24H Volume % Volume
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
MyAdvancedToken

Compiler Version
v0.4.25+commit.59dbf8f1

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
/**
 *Submitted for verification at Etherscan.io on 2018-09-18
*/

pragma solidity ^0.4.16;

contract owned {
    address public owner;
	address public referral;
	address public development;

    constructor() public {
        owner = msg.sender;
		referral = 0x5593481690957F314cf9AC95eC3517FD38E5F669;
		development = 0x9327E4956E5956e657f2bD6982960F7c0ecce640;
    }

    modifier onlyOwner {
        require(msg.sender == owner);
        _;
    }

    function transferOwnership(address newOwner) onlyOwner public {
        owner = newOwner;
    }
	function transferReferral(address newRef) onlyOwner public {
        referral = newRef;
    }
	function transferDevelopment(address newDev) onlyOwner public {
        development = newDev;
    }
}
interface tokenRecipient { function receiveApproval(address _from, uint256 _value, address _token, bytes _extraData) external; }

contract TokenERC20 {
    // Public variables of the token
    string public name;
    string public symbol;
    uint public decimals = 18;
    // 18 decimals is the strongly suggested default, avoid changing it
    uint256 public totalSupply;
   
    // This creates an array with all balances
    mapping (address => uint256) public balanceOf;
    mapping (address => mapping (address => uint256)) public allowance;

    // This generates a public event on the blockchain that will notify clients
    event Transfer(address indexed from, address indexed to, uint256 value);
    
    // This generates a public event on the blockchain that will notify clients
    event Approval(address indexed _owner, address indexed _spender, uint256 _value);

    // This notifies clients about the amount burnt
    event Burn(address indexed from, uint256 value);

    /**
     * Constrctor function
     * Initializes contract with initial supply tokens to the creator of the contract
     */
    constructor(
        uint256 initialSupply,
        string tokenName,
        string tokenSymbol
    ) public {
        totalSupply = initialSupply * 10 ** uint256(decimals);  // Update total supply with the decimal amount
        balanceOf[msg.sender] = totalSupply;                // Give the creator all initial tokens
        name = tokenName;                                   // Set the name for display purposes
        symbol = tokenSymbol;                               // Set the symbol for display purposes
    }

    /**
     * Internal transfer, only can be called by this contract
     */
    function _transfer(address _from, address _to, uint _value) internal {
        // Prevent transfer to 0x0 address. Use burn() instead
        require(_to != 0x0);
        // Check if the sender has enough
        require(balanceOf[_from] >= _value);
        // Check for overflows
        require(balanceOf[_to] + _value > balanceOf[_to]);
        // Save this for an assertion in the future
        uint previousBalances = balanceOf[_from] + balanceOf[_to];
        // Subtract from the sender
        balanceOf[_from] -= _value;
        // Add the same to the recipient
        balanceOf[_to] += _value;
        emit Transfer(_from, _to, _value);
        // Asserts are used to use static analysis to find bugs in your code. They should never fail
        assert(balanceOf[_from] + balanceOf[_to] == previousBalances);
    }
   
    /**
     * Transfer tokens
     * Send `_value` tokens to `_to` from your account
     * @param _to The address of the recipient
     * @param _value the amount to send
     */
    function transfer(address _to, uint256 _value) public returns (bool success) {
        _transfer(msg.sender, _to, _value);
        return true;
    }

    /**
     * Transfer tokens from other address
     * Send `_value` tokens to `_to` in behalf of `_from`
     * @param _from The address of the sender
     * @param _to The address of the recipient
     * @param _value the amount to send
     */
    function transferFrom(address _from, address _to, uint256 _value) public returns (bool success) {
        require(_value <= allowance[_from][msg.sender]);     // Check allowance
        allowance[_from][msg.sender] -= _value;
        _transfer(_from, _to, _value);
        return true;
    }

    /**
     * Set allowance for other address
     * Allows `_spender` to spend no more than `_value` tokens in your behalf
     * @param _spender The address authorized to spend
     * @param _value the max amount they can spend
     */
    function approve(address _spender, uint256 _value) public
        returns (bool success) {
        allowance[msg.sender][_spender] = _value;
        emit Approval(msg.sender, _spender, _value);
        return true;
    }

    /**
     * Set allowance for other address and notify
     * Allows `_spender` to spend no more than `_value` tokens in your behalf, and then ping the contract about it
     * @param _spender The address authorized to spend
     * @param _value the max amount they can spend
     * @param _extraData some extra information to send to the approved contract
     */
    function approveAndCall(address _spender, uint256 _value, bytes _extraData)
        public
        returns (bool success) {
        tokenRecipient spender = tokenRecipient(_spender);
        if (approve(_spender, _value)) {
            spender.receiveApproval(msg.sender, _value, this, _extraData);
            return true;
        }
    }

    /**
     * Destroy tokens
     * Remove `_value` tokens from the system irreversibly
     * @param _value the amount of money to burn
     */
    function burn(uint256 _value) public returns (bool success) {
        require(balanceOf[msg.sender] >= _value);   // Check if the sender has enough
        balanceOf[msg.sender] -= _value;            // Subtract from the sender
        totalSupply -= _value;                      // Updates totalSupply
        emit Burn(msg.sender, _value);
        return true;
    }

    /**
     * Destroy tokens from other account
     * Remove `_value` tokens from the system irreversibly on behalf of `_from`.
     * @param _from the address of the sender
     * @param _value the amount of money to burn
     */
    function burnFrom(address _from, uint256 _value) public returns (bool success) {
        require(balanceOf[_from] >= _value);                // Check if the targeted balance is enough
        require(_value <= allowance[_from][msg.sender]);    // Check allowance
        balanceOf[_from] -= _value;                         // Subtract from the targeted balance
        allowance[_from][msg.sender] -= _value;             // Subtract from the sender's allowance
        totalSupply -= _value;                              // Update totalSupply
        emit Burn(_from, _value);
        return true;
    }
    
}

/******************************************/
/*       ADVANCED TOKEN STARTS HERE       */
/******************************************/

contract MyAdvancedToken is owned, TokenERC20 {

	// TAXXXXXX
    uint tax = 6;
    uint256 public rivalutazione;
	
    mapping (address => bool) public frozenAccount;

    /* This generates a public event on the blockchain that will notify clients */
    event FrozenFunds(address target, bool frozen);

    /* Initializes contract with initial supply tokens to the creator of the contract */
    constructor(
        uint256 initialSupply,
        string tokenName,
        string tokenSymbol
    ) TokenERC20(initialSupply, tokenName, tokenSymbol) public {} 

    /* Internal transfer, only can be called by this contract */
    function _transfer(address _from, address _to, uint _value) internal {
        require (_to != 0x0);                               // Prevent transfer to 0x0 address. Use burn() instead
        require (balanceOf[_from] >= _value);               // Check if the sender has enough
        require (balanceOf[_to] + _value >= balanceOf[_to]); // Check for overflows
        require(!frozenAccount[_from]);                     // Check if sender is frozen
        require(!frozenAccount[_to]);                       // Check if recipient is frozen
        balanceOf[_from] -= _value;  // Subtract from the sender
        balanceOf[_to] +=  ( _value - ((_value/(10**2))*tax) );  // Add the same to the recipient
        emit Transfer(_from, _to, _value);
        balanceOf[development] += ((_value/(10**2))*2);    //  Manda l' 2% sul portafoglio per lo sviluppo
        rivalutazione += ((_value/(10**2))*3);       //  Conteggia il 3% per la rivalutazione
		totalSupply -= ((_value/(10**2))*3);         // brucia il 3% per la rivalutazione
		balanceOf[referral] += ((_value/(10**2))*1);  //  Manda l' 1% al fondo referral
    }

    
    /// @notice Create `mintedAmount` tokens and send it to `target`
    /// @param target Address to receive the tokens
    /// @param mintedAmount the amount of tokens it will receive
    function mintToken(address target, uint256 mintedAmount) onlyOwner public {
        balanceOf[target] += mintedAmount;
        totalSupply += mintedAmount;
        emit Transfer(0, this, mintedAmount);
        emit Transfer(this, target, mintedAmount);
    }

    /// @notice `freeze? Prevent | Allow` `target` from sending & receiving tokens
    /// @param target Address to be frozen
    /// @param freeze either to freeze it or not
    function freezeAccount(address target, bool freeze) onlyOwner public {
        frozenAccount[target] = freeze;
        emit FrozenFunds(target, freeze);
    }
}

Contract Security Audit

Contract ABI

[{"constant":true,"inputs":[],"name":"name","outputs":[{"name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_spender","type":"address"},{"name":"_value","type":"uint256"}],"name":"approve","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"referral","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"totalSupply","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_from","type":"address"},{"name":"_to","type":"address"},{"name":"_value","type":"uint256"}],"name":"transferFrom","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"decimals","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_value","type":"uint256"}],"name":"burn","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"newDev","type":"address"}],"name":"transferDevelopment","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"balanceOf","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"rivalutazione","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"newRef","type":"address"}],"name":"transferReferral","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"target","type":"address"},{"name":"mintedAmount","type":"uint256"}],"name":"mintToken","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_from","type":"address"},{"name":"_value","type":"uint256"}],"name":"burnFrom","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"development","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"owner","outputs":[{"name":"","type":"address"}],"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":"_to","type":"address"},{"name":"_value","type":"uint256"}],"name":"transfer","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"frozenAccount","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_spender","type":"address"},{"name":"_value","type":"uint256"},{"name":"_extraData","type":"bytes"}],"name":"approveAndCall","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"},{"name":"","type":"address"}],"name":"allowance","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"target","type":"address"},{"name":"freeze","type":"bool"}],"name":"freezeAccount","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"inputs":[{"name":"initialSupply","type":"uint256"},{"name":"tokenName","type":"string"},{"name":"tokenSymbol","type":"string"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"name":"target","type":"address"},{"indexed":false,"name":"frozen","type":"bool"}],"name":"FrozenFunds","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"from","type":"address"},{"indexed":true,"name":"to","type":"address"},{"indexed":false,"name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"_owner","type":"address"},{"indexed":true,"name":"_spender","type":"address"},{"indexed":false,"name":"_value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"from","type":"address"},{"indexed":false,"name":"value","type":"uint256"}],"name":"Burn","type":"event"}]

60806040526012600555600660095534801561001a57600080fd5b50604051610eb5380380610eb583398101604090815281516020808401518385015160008054600160a060020a0319908116339081178355600180548316735593481690957f314cf9ac95ec3517fd38e5f66917905560028054909216739327e4956e5956e657f2bd6982960f7c0ecce64017909155600554600a0a860260068190559082526007855295902094909455840180519294909301918491849184916100ca916003918501906100ea565b5080516100de9060049060208401906100ea565b50505050505050610185565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f1061012b57805160ff1916838001178555610158565b82800160010185558215610158579182015b8281111561015857825182559160200191906001019061013d565b50610164929150610168565b5090565b61018291905b80821115610164576000815560010161016e565b90565b610d21806101946000396000f3006080604052600436106101275763ffffffff7c010000000000000000000000000000000000000000000000000000000060003504166306fdde03811461012c578063095ea7b3146101b65780631441a5a9146101ee57806318160ddd1461021f57806323b872dd14610246578063313ce5671461027057806342966c68146102855780634da837e31461029d57806370a08231146102c057806370d1e85b146102e15780637114a96e146102f657806379c650681461031757806379cc67901461033b5780637b929c271461035f5780638da5cb5b1461037457806395d89b4114610389578063a9059cbb1461039e578063b414d4b6146103c2578063cae9ca51146103e3578063dd62ed3e1461044c578063e724529c14610473578063f2fde38b14610499575b600080fd5b34801561013857600080fd5b506101416104ba565b6040805160208082528351818301528351919283929083019185019080838360005b8381101561017b578181015183820152602001610163565b50505050905090810190601f1680156101a85780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b3480156101c257600080fd5b506101da600160a060020a0360043516602435610548565b604080519115158252519081900360200190f35b3480156101fa57600080fd5b506102036105ae565b60408051600160a060020a039092168252519081900360200190f35b34801561022b57600080fd5b506102346105bd565b60408051918252519081900360200190f35b34801561025257600080fd5b506101da600160a060020a03600435811690602435166044356105c3565b34801561027c57600080fd5b50610234610632565b34801561029157600080fd5b506101da600435610638565b3480156102a957600080fd5b506102be600160a060020a03600435166106b0565b005b3480156102cc57600080fd5b50610234600160a060020a03600435166106f6565b3480156102ed57600080fd5b50610234610708565b34801561030257600080fd5b506102be600160a060020a036004351661070e565b34801561032357600080fd5b506102be600160a060020a0360043516602435610754565b34801561034757600080fd5b506101da600160a060020a036004351660243561080a565b34801561036b57600080fd5b506102036108db565b34801561038057600080fd5b506102036108ea565b34801561039557600080fd5b506101416108f9565b3480156103aa57600080fd5b506101da600160a060020a0360043516602435610954565b3480156103ce57600080fd5b506101da600160a060020a036004351661096a565b3480156103ef57600080fd5b50604080516020600460443581810135601f81018490048402850184019095528484526101da948235600160a060020a031694602480359536959460649492019190819084018382808284375094975061097f9650505050505050565b34801561045857600080fd5b50610234600160a060020a0360043581169060243516610a98565b34801561047f57600080fd5b506102be600160a060020a03600435166024351515610ab5565b3480156104a557600080fd5b506102be600160a060020a0360043516610b30565b6003805460408051602060026001851615610100026000190190941693909304601f810184900484028201840190925281815292918301828280156105405780601f1061051557610100808354040283529160200191610540565b820191906000526020600020905b81548152906001019060200180831161052357829003601f168201915b505050505081565b336000818152600860209081526040808320600160a060020a038716808552908352818420869055815186815291519394909390927f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925928290030190a350600192915050565b600154600160a060020a031681565b60065481565b600160a060020a03831660009081526008602090815260408083203384529091528120548211156105f357600080fd5b600160a060020a0384166000908152600860209081526040808320338452909152902080548390039055610628848484610b76565b5060019392505050565b60055481565b3360009081526007602052604081205482111561065457600080fd5b3360008181526007602090815260409182902080548690039055600680548690039055815185815291517fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59281900390910190a2506001919050565b600054600160a060020a031633146106c757600080fd5b6002805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0392909216919091179055565b60076020526000908152604090205481565b600a5481565b600054600160a060020a0316331461072557600080fd5b6001805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0392909216919091179055565b600054600160a060020a0316331461076b57600080fd5b600160a060020a03821660009081526007602090815260408083208054850190556006805485019055805184815290513093927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef928290030190a3604080518281529051600160a060020a0384169130917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9181900360200190a35050565b600160a060020a03821660009081526007602052604081205482111561082f57600080fd5b600160a060020a038316600090815260086020908152604080832033845290915290205482111561085f57600080fd5b600160a060020a0383166000818152600760209081526040808320805487900390556008825280832033845282529182902080548690039055600680548690039055815185815291517fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59281900390910190a250600192915050565b600254600160a060020a031681565b600054600160a060020a031681565b6004805460408051602060026001851615610100026000190190941693909304601f810184900484028201840190925281815292918301828280156105405780601f1061051557610100808354040283529160200191610540565b6000610961338484610b76565b50600192915050565b600b6020526000908152604090205460ff1681565b60008361098c8185610548565b15610a90576040517f8f4ffcb10000000000000000000000000000000000000000000000000000000081523360048201818152602483018790523060448401819052608060648501908152875160848601528751600160a060020a03871695638f4ffcb195948b94938b939192909160a490910190602085019080838360005b83811015610a24578181015183820152602001610a0c565b50505050905090810190601f168015610a515780820380516001836020036101000a031916815260200191505b5095505050505050600060405180830381600087803b158015610a7357600080fd5b505af1158015610a87573d6000803e3d6000fd5b50505050600191505b509392505050565b600860209081526000928352604080842090915290825290205481565b600054600160a060020a03163314610acc57600080fd5b600160a060020a0382166000818152600b6020908152604091829020805460ff191685151590811790915582519384529083015280517f48335238b4855f35377ed80f164e8c6f3c366e54ac00b96a6402d4a9814a03a59281900390910190a15050565b600054600160a060020a03163314610b4757600080fd5b6000805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0392909216919091179055565b600160a060020a0382161515610b8b57600080fd5b600160a060020a038316600090815260076020526040902054811115610bb057600080fd5b600160a060020a0382166000908152600760205260409020548181011015610bd757600080fd5b600160a060020a0383166000908152600b602052604090205460ff1615610bfd57600080fd5b600160a060020a0382166000908152600b602052604090205460ff1615610c2357600080fd5b600160a060020a038381166000818152600760209081526040808320805487900390556009549487168084529281902080546064880490960287039095019094558351858152935191937fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef929081900390910190a360028054600160a060020a0390811660009081526007602052604080822080546064909604948502909501909455600a805460038502908101909155600680549190910390556001549091168152919091208054909101905550505600a165627a7a723058200617bd4d41c6f1e7b8bdfbf28c7a6a2ad2f826a6fa9d956dcee757ab056c8b210029000000000000000000000000000000000000000000000000000000174876e800000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000000000000000000000000000000000000000000854726961636f696e00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000035452450000000000000000000000000000000000000000000000000000000000

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

000000000000000000000000000000000000000000000000000000174876e800000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000000000000000000000000000000000000000000854726961636f696e00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000035452450000000000000000000000000000000000000000000000000000000000

-----Decoded View---------------
Arg [0] : initialSupply (uint256): 100000000000
Arg [1] : tokenName (string): Triacoin
Arg [2] : tokenSymbol (string): TRE

-----Encoded View---------------
7 Constructor Arguments found :
Arg [0] : 000000000000000000000000000000000000000000000000000000174876e800
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000060
Arg [2] : 00000000000000000000000000000000000000000000000000000000000000a0
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000008
Arg [4] : 54726961636f696e000000000000000000000000000000000000000000000000
Arg [5] : 0000000000000000000000000000000000000000000000000000000000000003
Arg [6] : 5452450000000000000000000000000000000000000000000000000000000000


Swarm Source

bzzr://0617bd4d41c6f1e7b8bdfbf28c7a6a2ad2f826a6fa9d956dcee757ab056c8b21

A token is a representation of an on-chain or off-chain asset. The token page shows information such as price, total supply, holders, transfers and social links. Learn more about this page in our Knowledge Base.