Contrat

Contrat Token WRC-721
0x78d64baa7e…3038e60b0f

Solde WTG

0 WTG

0,00 FCFA (@ 23,31 FCFA/WTG)

Avoirs en tokens

0 token

≈ 0,00 FCFA

Plus d'infos

Transactions envoyées1
Dernière activitéil y a 33 s
Première activitéil y a 1 j
Financé par

Code du contrat

✓ Vérifié

TestNFT · Solidity v0.8.35 · optimiseur activé (200 runs) · licence MIT

// SPDX-License-Identifier: MIT
pragma solidity ^0.8.20;

contract WCFA {
    string public name = "WINTG CFA";
    string public symbol = "WCFA";
    uint8 public decimals = 18;
    uint256 public totalSupply;
    address public owner;
    mapping(address => uint256) public balanceOf;
    mapping(address => mapping(address => uint256)) public allowance;
    event Transfer(address indexed from, address indexed to, uint256 value);
    event Approval(address indexed owner, address indexed spender, uint256 value);

    constructor() { owner = msg.sender; }

    function mint(address to, uint256 amt) external {
        require(msg.sender == owner, "!owner");
        totalSupply += amt;
        balanceOf[to] += amt;
        emit Transfer(address(0), to, amt);
    }
    function transfer(address to, uint256 amt) external returns (bool) { _t(msg.sender, to, amt); return true; }
    function approve(address s, uint256 amt) external returns (bool) {
        allowance[msg.sender][s] = amt; emit Approval(msg.sender, s, amt); return true;
    }
    function transferFrom(address f, address to, uint256 amt) external returns (bool) {
        uint256 a = allowance[f][msg.sender];
        require(a >= amt, "allow");
        if (a != type(uint256).max) allowance[f][msg.sender] = a - amt;
        _t(f, to, amt); return true;
    }
    function _t(address f, address to, uint256 amt) internal {
        require(balanceOf[f] >= amt, "bal");
        balanceOf[f] -= amt; balanceOf[to] += amt; emit Transfer(f, to, amt);
    }
}

contract TestToken {
    string public name;
    string public symbol;
    uint8 public decimals = 18;
    uint256 public totalSupply;
    address public owner;
    mapping(address => uint256) public balanceOf;
    mapping(address => mapping(address => uint256)) public allowance;
    event Transfer(address indexed from, address indexed to, uint256 value);
    event Approval(address indexed owner, address indexed spender, uint256 value);

    constructor(string memory n, string memory s, uint256 supply) {
        name = n; symbol = s; owner = msg.sender;
        totalSupply = supply; balanceOf[msg.sender] = supply;
        emit Transfer(address(0), msg.sender, supply);
    }
    function mint(address to, uint256 amt) external {
        require(msg.sender == owner, "!owner");
        totalSupply += amt; balanceOf[to] += amt; emit Transfer(address(0), to, amt);
    }
    function transfer(address to, uint256 amt) external returns (bool) { _t(msg.sender, to, amt); return true; }
    function approve(address sp, uint256 amt) external returns (bool) {
        allowance[msg.sender][sp] = amt; emit Approval(msg.sender, sp, amt); return true;
    }
    function transferFrom(address f, address to, uint256 amt) external returns (bool) {
        uint256 a = allowance[f][msg.sender]; require(a >= amt, "allow");
        if (a != type(uint256).max) allowance[f][msg.sender] = a - amt;
        _t(f, to, amt); return true;
    }
    function _t(address f, address to, uint256 amt) internal {
        require(balanceOf[f] >= amt, "bal");
        balanceOf[f] -= amt; balanceOf[to] += amt; emit Transfer(f, to, amt);
    }
}

contract TestNFT {
    string public name;
    string public symbol;
    uint256 public totalSupply;
    address public owner;
    mapping(uint256 => address) public ownerOf;
    mapping(address => uint256) public balanceOf;
    mapping(uint256 => address) public getApproved;
    event Transfer(address indexed from, address indexed to, uint256 indexed id);
    event Approval(address indexed owner, address indexed approved, uint256 indexed id);

    constructor(string memory n, string memory s) { name = n; symbol = s; owner = msg.sender; }
    function mint(address to) external returns (uint256 id) {
        id = ++totalSupply; ownerOf[id] = to; balanceOf[to]++; emit Transfer(address(0), to, id);
    }
    function transferFrom(address from, address to, uint256 id) external {
        require(ownerOf[id] == from, "own");
        require(msg.sender == from || getApproved[id] == msg.sender, "auth");
        ownerOf[id] = to; balanceOf[from]--; balanceOf[to]++; delete getApproved[id];
        emit Transfer(from, to, id);
    }
    function approve(address a, uint256 id) external {
        require(ownerOf[id] == msg.sender, "own"); getApproved[id] = a; emit Approval(msg.sender, a, id);
    }
}

interface IERC20 {
    function transfer(address to, uint256 amount) external returns (bool);
    function transferFrom(address from, address to, uint256 amount) external returns (bool);
    function balanceOf(address) external view returns (uint256);
}

contract GasBurner {
    uint256 public acc;
    function churn(uint256 rounds) external {
        uint256 a = acc;

        assembly {
            for { let i := 0 } lt(i, rounds) { i := add(i, 1) } {
                mstore(0x00, a)
                mstore(0x20, i)
                a := keccak256(0x00, 0x40)
            }
        }
        acc = a;
    }
}

contract WtgPool {
    IERC20 public quote;
    address public owner;
    event Swap(address indexed who, bool wtgIn, uint256 amountIn, uint256 amountOut);

    constructor(address _quote) { quote = IERC20(_quote); owner = msg.sender; }

    function getReserves() external view returns (uint256 wtgReserve, uint256 quoteReserve) {
        return (address(this).balance, quote.balanceOf(address(this)));
    }

    function addLiquidity(uint256 quoteAmount) external payable {
        require(quote.transferFrom(msg.sender, address(this), quoteAmount), "quote in");
    }

    function _out(uint256 amountIn, uint256 rIn, uint256 rOut) internal pure returns (uint256) {
        uint256 inWithFee = amountIn * 997;
        return (inWithFee * rOut) / (rIn * 1000 + inWithFee);
    }

    function swapWtgForQuote(uint256 minOut) external payable returns (uint256 out) {
        uint256 rWtg = address(this).balance - msg.value;
        uint256 rQuote = quote.balanceOf(address(this));
        out = _out(msg.value, rWtg, rQuote);
        require(out >= minOut && out < rQuote, "slip");
        require(quote.transfer(msg.sender, out), "quote out");
        emit Swap(msg.sender, true, msg.value, out);
    }

    function swapQuoteForWtg(uint256 amountIn, uint256 minOut) external returns (uint256 out) {
        require(quote.transferFrom(msg.sender, address(this), amountIn), "quote in");
        uint256 rQuote = quote.balanceOf(address(this)) - amountIn;
        uint256 rWtg = address(this).balance;
        out = _out(amountIn, rQuote, rWtg);
        require(out >= minOut && out < rWtg, "slip");
        (bool ok, ) = msg.sender.call{value: out}("");
        require(ok, "wtg out");
        emit Swap(msg.sender, false, amountIn, out);
    }

    receive() external payable {}
}
[
    {
        "inputs": [
            {
                "internalType": "string",
                "name": "n",
                "type": "string"
            },
            {
                "internalType": "string",
                "name": "s",
                "type": "string"
            }
        ],
        "stateMutability": "nonpayable",
        "type": "constructor"
    },
    {
        "anonymous": false,
        "inputs": [
            {
                "indexed": true,
                "internalType": "address",
                "name": "owner",
                "type": "address"
            },
            {
                "indexed": true,
                "internalType": "address",
                "name": "approved",
                "type": "address"
            },
            {
                "indexed": true,
                "internalType": "uint256",
                "name": "id",
                "type": "uint256"
            }
        ],
        "name": "Approval",
        "type": "event"
    },
    {
        "anonymous": false,
        "inputs": [
            {
                "indexed": true,
                "internalType": "address",
                "name": "from",
                "type": "address"
            },
            {
                "indexed": true,
                "internalType": "address",
                "name": "to",
                "type": "address"
            },
            {
                "indexed": true,
                "internalType": "uint256",
                "name": "id",
                "type": "uint256"
            }
        ],
        "name": "Transfer",
        "type": "event"
    },
    {
        "inputs": [
            {
                "internalType": "address",
                "name": "a",
                "type": "address"
            },
            {
                "internalType": "uint256",
                "name": "id",
                "type": "uint256"
            }
        ],
        "name": "approve",
        "outputs": [],
        "stateMutability": "nonpayable",
        "type": "function"
    },
    {
        "inputs": [
            {
                "internalType": "address",
                "name": "",
                "type": "address"
            }
        ],
        "name": "balanceOf",
        "outputs": [
            {
                "internalType": "uint256",
                "name": "",
                "type": "uint256"
            }
        ],
        "stateMutability": "view",
        "type": "function"
    },
    {
        "inputs": [
            {
                "internalType": "uint256",
                "name": "",
                "type": "uint256"
            }
        ],
        "name": "getApproved",
        "outputs": [
            {
                "internalType": "address",
                "name": "",
                "type": "address"
            }
        ],
        "stateMutability": "view",
        "type": "function"
    },
    {
        "inputs": [
            {
                "internalType": "address",
                "name": "to",
                "type": "address"
            }
        ],
        "name": "mint",
        "outputs": [
            {
                "internalType": "uint256",
                "name": "id",
                "type": "uint256"
            }
        ],
        "stateMutability": "nonpayable",
        "type": "function"
    },
    {
        "inputs": [],
        "name": "name",
        "outputs": [
            {
                "internalType": "string",
                "name": "",
                "type": "string"
            }
        ],
        "stateMutability": "view",
        "type": "function"
    },
    {
        "inputs": [],
        "name": "owner",
        "outputs": [
            {
                "internalType": "address",
                "name": "",
                "type": "address"
            }
        ],
        "stateMutability": "view",
        "type": "function"
    },
    {
        "inputs": [
            {
                "internalType": "uint256",
                "name": "",
                "type": "uint256"
            }
        ],
        "name": "ownerOf",
        "outputs": [
            {
                "internalType": "address",
                "name": "",
                "type": "address"
            }
        ],
        "stateMutability": "view",
        "type": "function"
    },
    {
        "inputs": [],
        "name": "symbol",
        "outputs": [
            {
                "internalType": "string",
                "name": "",
                "type": "string"
            }
        ],
        "stateMutability": "view",
        "type": "function"
    },
    {
        "inputs": [],
        "name": "totalSupply",
        "outputs": [
            {
                "internalType": "uint256",
                "name": "",
                "type": "uint256"
            }
        ],
        "stateMutability": "view",
        "type": "function"
    },
    {
        "inputs": [
            {
                "internalType": "address",
                "name": "from",
                "type": "address"
            },
            {
                "internalType": "address",
                "name": "to",
                "type": "address"
            },
            {
                "internalType": "uint256",
                "name": "id",
                "type": "uint256"
            }
        ],
        "name": "transferFrom",
        "outputs": [],
        "stateMutability": "nonpayable",
        "type": "function"
    }
]
0x608060405234801561001057600080fd5b506004361061009e5760003560e01c80636352211e116100665780636352211e146101415780636a6278421461016a57806370a082311461017d5780638da5cb5b1461019d57806395d89b41146101b057600080fd5b806306fdde03146100a3578063081812fc146100c1578063095ea7b31461010257806318160ddd1461011757806323b872dd1461012e575b600080fd5b6100ab6101b8565b6040516100b89190610517565b60405180910390f35b6100ea6100cf366004610565565b6006602052600090815260409020546001600160a01b031681565b6040516001600160a01b0390911681526020016100b8565b61011561011036600461059a565b610246565b005b61012060025481565b6040519081526020016100b8565b61011561013c3660046105c4565b6102f0565b6100ea61014f366004610565565b6004602052600090815260409020546001600160a01b031681565b610120610178366004610601565b61046d565b61012061018b366004610601565b60056020526000908152604090205481565b6003546100ea906001600160a01b031681565b6100ab61050a565b600080546101c590610623565b80601f01602080910402602001604051908101604052809291908181526020018280546101f190610623565b801561023e5780601f106102135761010080835404028352916020019161023e565b820191906000526020600020905b81548152906001019060200180831161022157829003601f168201915b505050505081565b6000818152600460205260409020546001600160a01b031633146102975760405162461bcd60e51b815260206004820152600360248201526237bbb760e91b60448201526064015b60405180910390fd5b60008181526006602052604080822080546001600160a01b0319166001600160a01b0386169081179091559051839233917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259190a45050565b6000818152600460205260409020546001600160a01b0384811691161461033f5760405162461bcd60e51b815260206004820152600360248201526237bbb760e91b604482015260640161028e565b336001600160a01b038416148061036c57506000818152600660205260409020546001600160a01b031633145b6103a15760405162461bcd60e51b815260040161028e906020808252600490820152630c2eae8d60e31b604082015260600190565b600081815260046020908152604080832080546001600160a01b0319166001600160a01b038781169190911790915586168352600590915281208054916103e783610673565b90915550506001600160a01b03821660009081526005602052604081208054916104108361068a565b909155505060008181526006602052604080822080546001600160a01b03191690555182916001600160a01b0385811692908716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b600060026000815461047e9061068a565b9182905550600081815260046020908152604080832080546001600160a01b0319166001600160a01b0388169081179091558352600590915281208054929350906104c88361068a565b909155505060405181906001600160a01b038416906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a4919050565b600180546101c590610623565b602081526000825180602084015260005b818110156105455760208186018101516040868401015201610528565b506000604082850101526040601f19601f83011684010191505092915050565b60006020828403121561057757600080fd5b5035919050565b80356001600160a01b038116811461059557600080fd5b919050565b600080604083850312156105ad57600080fd5b6105b68361057e565b946020939093013593505050565b6000806000606084860312156105d957600080fd5b6105e28461057e565b92506105f06020850161057e565b929592945050506040919091013590565b60006020828403121561061357600080fd5b61061c8261057e565b9392505050565b600181811c9082168061063757607f821691505b60208210810361065757634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b6000816106825761068261065d565b506000190190565b60006001820161069c5761069c61065d565b506001019056fea2646970667358221220be38d7e57ed0713c526440af93f181d1a9bf8ac9781c9826fb66ff25003fa12864736f6c63430008230033
HashMéthodeBlocÂgeDeÀMontantFrais
0x52ce94914e… Mint NFT 5 133 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #131 0.00044077 WTG
0xb198abb139… Mint NFT 5 111 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #130 0.00046496 WTG
0x7f523ca1e0… Mint NFT 5 078 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #129 0.0005512 WTG
0x4b2b78f74b… Mint NFT 5 056 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #128 0.00039656 WTG
0x19b8940c25… Mint NFT 5 033 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #127 0.00062963 WTG
0x7fe9b5637a… Mint NFT 4 979 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #126 0.00051251 WTG
0xe56bbe3497… Mint NFT 4 855 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #125 0.00072271 WTG
0x447db4a0c3… Mint NFT 4 732 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #124 0.00038436 WTG
0x1c8079d848… Mint NFT 4 682 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #123 0.00043009 WTG
0x32d3e63c0a… Mint NFT 4 638 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #122 0.00058417 WTG
0x72c1236f8e… Mint NFT 4 563 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #121 0.00070813 WTG
0xf088676d60… Mint NFT 4 538 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #120 0.00067008 WTG
0xf1e774fb80… Mint NFT 4 504 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #119 0.0004405 WTG
0xd601b190ca… Mint NFT 4 501 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #118 0.00042234 WTG
0x86f6314c62… Mint NFT 4 455 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #117 0.00046778 WTG
0xe01031c3e3… Mint NFT 4 452 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #116 0.00044895 WTG
0x89c8f8a369… Mint NFT 4 423 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #115 0.00053665 WTG
0x6a624ad1d0… Mint NFT 4 389 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #114 0.00092276 WTG
0x9dde2cf608… Mint NFT 4 376 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #113 0.00062844 WTG
0x10b87de707… Mint NFT 4 362 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #112 0.0004691 WTG
0x56d67642c1… Mint NFT 4 337 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #111 0.00168711 WTG
0x5aadf4b854… Mint NFT 4 323 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #110 0.00060337 WTG
0x5f04aa5f0f… Mint NFT 4 294 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #109 0.00052748 WTG
0x89aac4054b… Mint NFT 4 278 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #108 0.000478 WTG
0x0ed9a987a2… Mint NFT 4 163 il y a 1 j 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #107 0.0004113 WTG
Aucun transfert de token.
Tx parenteTypeDeÀValeur
Aucune transaction interne pour cette adresse.