Contrat

Contrat Token WRC-721
0x78d64baa7e…3038e60b0f

Solde WTG

0 WTG

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

Avoirs en tokens

0 token

≈ 0,00 FCFA

Plus d'infos

Transactions envoyées0
Dernière activitéil y a 1 sem.
Première activitéil y a 3 sem.
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"
    }
]
HashMéthodeBlocÂgeDeÀMontantFrais
0x0e190a4dc4… Mint NFT 410 279 il y a 1 sem. 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #20384 0.00011245 WTG
0xe17bcb8930… Approbation 410 264 il y a 1 sem. 0xc67907…6e33ab ENTR. 0x78d64b…e60b0f 0.00009659 WTG
0x39bbd298f8… Mint NFT 410 259 il y a 1 sem. 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #20383 0.00011245 WTG
0x62420b675b… Approbation 410 247 il y a 1 sem. 0x6a85c7…8c4e4a ENTR. 0x78d64b…e60b0f 0.00009659 WTG
0xecd5e25fba… Approbation 410 241 il y a 1 sem. 0x5fe027…0ad9b5 ENTR. 0x78d64b…e60b0f 0.00009659 WTG
0x37e7a7dead… Approbation 410 224 il y a 1 sem. 0x85a88b…9e0192 ENTR. 0x78d64b…e60b0f 0.00009659 WTG
0x5480eef1d2… Mint NFT 410 223 il y a 1 sem. 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #20382 0.00011245 WTG
0xe77e21566b… Mint NFT 410 212 il y a 1 sem. 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #20381 0.00011245 WTG
0x4e53ac947f… Approbation 410 199 il y a 1 sem. 0x735444…af9da9 ENTR. 0x78d64b…e60b0f 0.00009659 WTG
0xcc78b73dcd… Mint NFT 410 197 il y a 1 sem. 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #20380 0.00011245 WTG
0x48a29eecc4… Approbation 410 161 il y a 1 sem. 0x30d6cd…760717 ENTR. 0x78d64b…e60b0f 0.00009659 WTG
0xf8393f4990… Mint NFT 410 159 il y a 1 sem. 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #20379 0.00011245 WTG
0xa0af007bf6… Mint NFT 410 157 il y a 1 sem. 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #20378 0.00011245 WTG
0xad74fe2ec9… Approbation 410 151 il y a 1 sem. 0xa000c8…6f2db0 ENTR. 0x78d64b…e60b0f 0.00009659 WTG
0x5ac659e858… Mint NFT 410 150 il y a 1 sem. 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #20377 0.00011242 WTG
0x3f314c08eb… Approbation 410 143 il y a 1 sem. 0x9f6ef0…2a2ca1 ENTR. 0x78d64b…e60b0f 0.00009659 WTG
0x52dd8ca558… Mint NFT 410 142 il y a 1 sem. 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #20376 0.00011245 WTG
0x10834ced7d… Approbation 410 132 il y a 1 sem. 0x06ffa8…78b6fe ENTR. 0x78d64b…e60b0f 0.00005679 WTG
0xb09b4cf390… Mint NFT 410 113 il y a 1 sem. 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #20375 0.00011245 WTG
0xb7f05c6b30… Approbation 410 105 il y a 1 sem. 0xcd020d…bb70cc ENTR. 0x78d64b…e60b0f 0.00009659 WTG
0x561669805a… Approbation 410 092 il y a 1 sem. 0x34f3dd…f3852a ENTR. 0x78d64b…e60b0f 0.00009659 WTG
0x419be0ed09… Mint NFT 410 091 il y a 1 sem. 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #20374 0.00011245 WTG
0x4a45a66d96… Mint NFT 410 071 il y a 1 sem. 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #20373 0.00011245 WTG
0x4928893650… Mint NFT 410 064 il y a 1 sem. 0x835164…ee75cc ENTR. 0x78d64b…e60b0f NFT #20372 0.00011245 WTG
0x05866a0586… Approbation 410 064 il y a 1 sem. 0xb2fa5a…bdf678 ENTR. 0x78d64b…e60b0f 0.00009659 WTG
Aucun transfert de token.
Tx parenteTypeDeÀValeur
Aucune transaction interne pour cette adresse.