PawsInUToken

0x8b6b401dd2833493151c1d6ea4fce64640615657

Verification
Verified
v0.8.26+commit.8a97fa7a
Type
Contract
19,002 bytes
ABI entries
83
37 read · 16 write
License
none

Contract information

Address
0x8b6b401dd2833493151c1d6ea4fce64640615657
Chain
Robinhood Chain (4663)
Compiler
v0.8.26+commit.8a97fa7a
Optimization
Enabled
Creation tx
0x5b7236afc4…50069b28a6

Token

Name
pawsinU
Symbol
inU
Decimals
18
Holders
36

Read contract (37)

BEACON_DELAY_BLOCKS()uint256
DOMAIN_SEPARATOR()bytes32
INITIAL_SUPPLY()uint256
MILESTONE_COUNT()uint8
REVEAL_BATCH_SIZE()uint256
REVEAL_BLOCKHASH_WINDOW()uint256
SLOT_COUNT()uint8
TRAIT_ENTRY_COUNT()uint8
UNIT_PER_INU()uint256
allowance(address, address)uint256
balanceOf(address)uint256
decimals()uint8
fairLimit()uint256
getInusOf(address)uint256[]
getTraitCount(uint256)uint256
getTraits(uint256)tuple[]
holdStartTimestamp(uint256)uint64
holdersCount()uint256
inuOwner(uint256)address
inusTotalCount()uint256
isStarted()bool
milestoneCommit(uint256, uint8)tuple
milestoneHoldSeconds(uint8)uint256
name()string
nonces(address)uint256
owner()address
ownerInu(address, uint256)tuple
ownerInusCount(address)uint256
ownerOwns(address, uint256)bool
ownershipHandoverExpiresAt(address)uint256
pendingCount(uint8)uint256
pool()address
slotGreatness(uint256, uint8)uint8
symbol()string
totalSupply()uint256
traitRevealEnteredBlock(uint256, uint8)uint64
traitSlotCount()uint8

Events (10)

ApprovalMilestoneCommittedOnInuBurnedOnInuMintedOnInuTransferOwnershipHandoverCanceledOwnershipHandoverRequestedOwnershipTransferredTraitRevealedTransfer

ABI

[
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "owner_",
        "type": "address"
      }
    ],
    "stateMutability": "nonpayable",
    "type": "constructor"
  },
  {
    "inputs": [],
    "name": "AddressCanNotReceiveInu",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "AllowanceOverflow",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "AllowanceUnderflow",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "AlreadyInitialized",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "InsufficientAllowance",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "InsufficientBalance",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "InuIndexOutOfRange",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "InvalidInuId",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "InvalidMilestoneIndex",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "InvalidPermit",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "InvalidTraitSlot",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "MilestoneNotReady",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "NewOwnerIsZeroAddress",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "NoHandoverRequest",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "NotInuOwner",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Permit2AllowanceIsFixedAtInfinity",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "PermitExpired",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "TotalSupplyOverflow",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Unauthorized",
    "type": "error"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "owner",
        "type": "address"
      },
      {
        "indexed": true,
        "internalType": "address",
        "name": "spender",
        "type": "address"
      },
      {
        "indexed": false,
        "internalType": "uint256",
        "name": "amount",
        "type": "uint256"
      }
    ],
    "name": "Approval",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "uint256",
        "name": "inuId",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "uint8",
        "name": "milestoneIndex",
        "type": "uint8"
      },
      {
        "indexed": false,
        "internalType": "uint64",
        "name": "enteredBlock",
        "type": "uint64"
      },
      {
        "indexed": false,
        "internalType": "address",
        "name": "holder",
        "type": "address"
      }
    ],
    "name": "MilestoneCommitted",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "owner",
        "type": "address"
      },
      {
        "indexed": false,
        "internalType": "uint256",
        "name": "inuId",
        "type": "uint256"
      }
    ],
    "name": "OnInuBurned",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "owner",
        "type": "address"
      },
      {
        "indexed": false,
        "internalType": "uint256",
        "name": "inuId",
        "type": "uint256"
      }
    ],
    "name": "OnInuMinted",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "from",
        "type": "address"
      },
      {
        "indexed": true,
        "internalType": "address",
        "name": "to",
        "type": "address"
      },
      {
        "indexed": false,
        "internalType": "uint256",
        "name": "inuId",
        "type": "uint256"
      }
    ],
    "name": "OnInuTransfer",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "pendingOwner",
        "type": "address"
      }
    ],
    "name": "OwnershipHandoverCanceled",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "pendingOwner",
        "type": "address"
      }
    ],
    "name": "OwnershipHandoverRequested",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "oldOwner",
        "type": "address"
      },
      {
        "indexed": true,
        "internalType": "address",
        "name": "newOwner",
        "type": "address"
      }
    ],
    "name": "OwnershipTransferred",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "uint256",
        "name": "inuId",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "uint8",
        "name": "milestoneIndex",
        "type": "uint8"
      },
      {
        "indexed": false,
        "internalType": "string",
        "name": "key",
        "type": "string"
      },
      {
        "indexed": false,
        "internalType": "string",
        "name": "value",
        "type": "string"
      }
    ],
    "name": "TraitRevealed",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "from",
        "type": "address"
      },
      {
        "indexed": true,
        "internalType": "address",
        "name": "to",
        "type": "address"
      },
      {
        "indexed": false,
        "internalType": "uint256",
        "name": "amount",
        "type": "uint256"
      }
    ],
    "name": "Transfer",
    "type": "event"
  },
  {
    "inputs": [],
    "name": "BEACON_DELAY_BLOCKS",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "DOMAIN_SEPARATOR",
    "outputs": [
      {
        "internalType": "bytes32",
        "name": "result",
        "type": "bytes32"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "INITIAL_SUPPLY",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "MILESTONE_COUNT",
    "outputs": [
      {
        "internalType": "uint8",
        "name": "",
        "type": "uint8"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "REVEAL_BATCH_SIZE",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "REVEAL_BLOCKHASH_WINDOW",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "SLOT_COUNT",
    "outputs": [
      {
        "internalType": "uint8",
        "name": "",
        "type": "uint8"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "TRAIT_ENTRY_COUNT",
    "outputs": [
      {
        "internalType": "uint8",
        "name": "",
        "type": "uint8"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "UNIT_PER_INU",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "owner",
        "type": "address"
      },
      {
        "internalType": "address",
        "name": "spender",
        "type": "address"
      }
    ],
    "name": "allowance",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "result",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "spender",
        "type": "address"
      },
      {
        "internalType": "uint256",
        "name": "amount",
        "type": "uint256"
      }
    ],
    "name": "approve",
    "outputs": [
      {
        "internalType": "bool",
        "name": "",
        "type": "bool"
      }
    ],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "owner",
        "type": "address"
      }
    ],
    "name": "balanceOf",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "result",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "cancelOwnershipHandover",
    "outputs": [],
    "stateMutability": "payable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "pendingOwner",
        "type": "address"
      }
    ],
    "name": "completeOwnershipHandover",
    "outputs": [],
    "stateMutability": "payable",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "decimals",
    "outputs": [
      {
        "internalType": "uint8",
        "name": "",
        "type": "uint8"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "fairLimit",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "owner",
        "type": "address"
      }
    ],
    "name": "getInusOf",
    "outputs": [
      {
        "internalType": "uint256[]",
        "name": "ids",
        "type": "uint256[]"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "uint256",
        "name": "inuId",
        "type": "uint256"
      }
    ],
    "name": "getTraitCount",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "uint256",
        "name": "inuId",
        "type": "uint256"
      }
    ],
    "name": "getTraits",
    "outputs": [
      {
        "components": [
          {
            "internalType": "string",
            "name": "key",
            "type": "string"
          },
          {
            "internalType": "string",
            "name": "value",
            "type": "string"
          },
          {
            "internalType": "enum TraitStatus",
            "name": "status",
            "type": "uint8"
          },
          {
            "internalType": "uint8",
            "name": "greatness",
            "type": "uint8"
          }
        ],
        "internalType": "struct TraitEntry[]",
        "name": "entries",
        "type": "tuple[]"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "uint256",
        "name": "inuId",
        "type": "uint256"
      }
    ],
    "name": "holdStartTimestamp",
    "outputs": [
      {
        "internalType": "uint64",
        "name": "",
        "type": "uint64"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "holdersCount",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "uint256",
        "name": "inuId",
        "type": "uint256"
      }
    ],
    "name": "inuOwner",
    "outputs": [
      {
        "internalType": "address",
        "name": "",
        "type": "address"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "inusTotalCount",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "isStarted",
    "outputs": [
      {
        "internalType": "bool",
        "name": "",
        "type": "bool"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "uint256",
        "name": "inuId",
        "type": "uint256"
      },
      {
        "internalType": "uint8",
        "name": "slotIndex",
        "type": "uint8"
      }
    ],
    "name": "milestoneCommit",
    "outputs": [
      {
        "components": [
          {
            "internalType": "uint64",
            "name": "enteredBlock",
            "type": "uint64"
          },
          {
            "internalType": "address",
            "name": "holderSnapshot",
            "type": "address"
          },
          {
            "internalType": "bool",
            "name": "committed",
            "type": "bool"
          }
        ],
        "internalType": "struct MilestoneCommit",
        "name": "",
        "type": "tuple"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "uint8",
        "name": "slotIndex",
        "type": "uint8"
      }
    ],
    "name": "milestoneHoldSeconds",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "name",
    "outputs": [
      {
        "internalType": "string",
        "name": "",
        "type": "string"
      }
    ],
    "stateMutability": "pure",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "owner",
        "type": "address"
      }
    ],
    "name": "nonces",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "result",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "owner",
    "outputs": [
      {
        "internalType": "address",
        "name": "result",
        "type": "address"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "owner",
        "type": "address"
      },
      {
        "internalType": "uint256",
        "name": "index",
        "type": "uint256"
      }
    ],
    "name": "ownerInu",
    "outputs": [
      {
        "components": [
          {
            "internalType": "uint256",
            "name": "id",
            "type": "uint256"
          }
        ],
        "internalType": "struct InuIdData",
        "name": "",
        "type": "tuple"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "owner",
        "type": "address"
      }
    ],
    "name": "ownerInusCount",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "owner",
        "type": "address"
      },
      {
        "internalType": "uint256",
        "name": "inuId",
        "type": "uint256"
      }
    ],
    "name": "ownerOwns",
    "outputs": [
      {
        "internalType": "bool",
        "name": "",
        "type": "bool"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "pendingOwner",
        "type": "address"
      }
    ],
    "name": "ownershipHandoverExpiresAt",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "result",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "uint8",
        "name": "slotIndex",
        "type": "uint8"
      }
    ],
    "name": "pendingCount",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "owner",
        "type": "address"
      },
      {
        "internalType": "address",
        "name": "spender",
        "type": "address"
      },
      {
        "internalType": "uint256",
        "name": "value",
        "type": "uint256"
      },
      {
        "internalType": "uint256",
        "name": "deadline",
        "type": "uint256"
      },
      {
        "internalType": "uint8",
        "name": "v",
        "type": "uint8"
      },
      {
        "internalType": "bytes32",
        "name": "r",
        "type": "bytes32"
      },
      {
        "internalType": "bytes32",
        "name": "s",
        "type": "bytes32"
      }
    ],
    "name": "permit",
    "outputs": [],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "pool",
    "outputs": [
      {
        "internalType": "address",
        "name": "",
        "type": "address"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "renounceOwnership",
    "outputs": [],
    "stateMutability": "payable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "uint256",
        "name": "inuId",
        "type": "uint256"
      },
      {
        "internalType": "uint256",
        "name": "newIndex",
        "type": "uint256"
      }
    ],
    "name": "reorderInu",
    "outputs": [],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "uint256",
        "name": "inuId",
        "type": "uint256"
      },
      {
        "internalType": "uint256",
        "name": "newIndex",
        "type": "uint256"
      }
    ],
    "name": "reorderInuPair",
    "outputs": [],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "requestOwnershipHandover",
    "outputs": [],
    "stateMutability": "payable",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "reveal",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "revealed",
        "type": "uint256"
      }
    ],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "uint256[]",
        "name": "inuIds",
        "type": "uint256[]"
      }
    ],
    "name": "revealInus",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "revealed",
        "type": "uint256"
      }
    ],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "uint256",
        "name": "inuId",
        "type": "uint256"
      },
      {
        "internalType": "uint8",
        "name": "slotIndex",
        "type": "uint8"
      }
    ],
    "name": "slotGreatness",
    "outputs": [
      {
        "internalType": "uint8",
        "name": "",
        "type": "uint8"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "newPool",
        "type": "address"
      }
    ],
    "name": "start",
    "outputs": [],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "symbol",
    "outputs": [
      {
        "internalType": "string",
        "name": "",
        "type": "string"
      }
    ],
    "stateMutability": "pure",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "totalSupply",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "result",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "uint256",
        "name": "inuId",
        "type": "uint256"
      },
      {
        "internalType": "uint8",
        "name": "slotIndex",
        "type": "uint8"
      }
    ],
    "name": "traitRevealEnteredBlock",
    "outputs": [
      {
        "internalType": "uint64",
        "name": "",
        "type": "uint64"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "traitSlotCount",
    "outputs": [
      {
        "internalType": "uint8",
        "name": "",
        "type": "uint8"
      }
    ],
    "stateMutability": "pure",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "to",
        "type": "address"
      },
      {
        "internalType": "uint256",
        "name": "amount",
        "type": "uint256"
      }
    ],
    "name": "transfer",
    "outputs": [
      {
        "internalType": "bool",
        "name": "",
        "type": "bool"
      }
    ],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "from",
        "type": "address"
      },
      {
        "internalType": "address",
        "name": "to",
        "type": "address"
      },
      {
        "internalType": "uint256",
        "name": "amount",
        "type": "uint256"
      }
    ],
    "name": "transferFrom",
    "outputs": [
      {
        "internalType": "bool",
        "name": "",
        "type": "bool"
      }
    ],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "to",
        "type": "address"
      },
      {
        "internalType": "uint256",
        "name": "inuId",
        "type": "uint256"
      }
    ],
    "name": "transferInu",
    "outputs": [],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "to",
        "type": "address"
      },
      {
        "internalType": "uint256[]",
        "name": "inuIds",
        "type": "uint256[]"
      }
    ],
    "name": "transferInusList",
    "outputs": [],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "newOwner",
        "type": "address"
      }
    ],
    "name": "transferOwnership",
    "outputs": [],
    "stateMutability": "payable",
    "type": "function"
  }
]

Source code

// https://x.com/pawsinU_
// https://pawsinu.app/


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

import { ERC20 } from "solady/src/tokens/ERC20.sol";
import { Ownable } from "solady/src/auth/Ownable.sol";
import "../inu/InuHoldReveal.sol";
import "./IStartableToken.sol";

/// @title pawsinU
/// @notice ERC20 with inU minted on pool purchases; traits reveal via hold milestones.
contract PawsInUToken is InuHoldReveal, ERC20, Ownable, IStartableToken {
    error AddressCanNotReceiveInu();

    uint256 public constant UNIT_PER_INU = 1e18;
    uint256 public constant INITIAL_SUPPLY = 10_000e18;

    uint256 private constant FAIR_LIMIT_PRECISION = 100_000;
    uint256 private constant _startFairLimitCount = (INITIAL_SUPPLY * 250) / FAIR_LIMIT_PRECISION;
    uint256 private constant _addFairLimitPercentPerSec = 3;

    address private immutable _notMintableAccount;
    uint256 private _startTime;
    address public pool;

    constructor(address owner_) {
        _initializeOwner(owner_);
        _mint(owner_, INITIAL_SUPPLY);
        _notMintableAccount = owner_;
    }

    function name() public pure override returns (string memory) {
        return "pawsinU";
    }

    function symbol() public pure override returns (string memory) {
        return "inU";
    }

    function start(address newPool) external onlyOwner {
        require(pool == address(0), "already started");
        require(newPool != address(0), "zero pool");
        pool = newPool;
        _startTime = block.timestamp;
    }

    function isStarted() public view returns (bool) {
        return pool != address(0);
    }

    function fairLimit() public view returns (uint256) {
        if (!isStarted()) return 0;
        uint256 count = _startFairLimitCount
            + (INITIAL_SUPPLY * (block.timestamp - _startTime) * _addFairLimitPercentPerSec) / FAIR_LIMIT_PRECISION;
        if (count > INITIAL_SUPPLY) count = INITIAL_SUPPLY;
        return count;
    }

    function _afterTokenTransfer(address from, address to, uint256 amount) internal override {
        if (pool == address(0)) return;
        _onTokenTransfer(from, to, amount);
        _revealBatch(REVEAL_BATCH_SIZE);
    }

    function _onTokenTransfer(address from, address to, uint256 amount) internal {
        if (from == pool && to != address(0)) {
            if (_notMintableAccount == to) return;
            require(isStarted(), "not started");
            require(amount <= fairLimit(), "fair limit");
            uint256 qty = amount / UNIT_PER_INU;
            for (uint256 i = 0; i < qty; i++) {
                _mintInu(to);
            }
            return;
        }

        uint256 fromMaxAllowed = balanceOf(from) / UNIT_PER_INU;
        uint256 fromCount = _counts[from];
        uint256 fromRemoveCount = fromCount > fromMaxAllowed ? fromCount - fromMaxAllowed : 0;
        if (fromRemoveCount == 0) return;

        uint256 toMaxAllowed = balanceOf(to) / UNIT_PER_INU;
        uint256 toCount = _counts[to];
        uint256 toReceiveAllowed = toCount < toMaxAllowed ? toMaxAllowed - toCount : 0;

        if (!_canReceiveInus(to)) {
            toReceiveAllowed = 0;
        }

        uint256 moveQty = fromRemoveCount < toReceiveAllowed ? fromRemoveCount : toReceiveAllowed;
        if (moveQty > 0) _moveInus(from, to, moveQty);
        _burnInus(from, fromRemoveCount - moveQty);
    }

    function _mintInus(address user, uint256 qty) internal {
        for (uint256 i = 0; i < qty; i++) {
            _mintInu(user);
        }
    }

    function _burnInus(address user, uint256 qty) internal {
        for (uint256 i = 0; i < qty; i++) {
            uint256 count = _counts[user];
            if (count == 0) break;
            uint256 lastIdx = count - 1;
            uint256 inuId = _ownedInus[user][lastIdx];
            _burnInu(user, inuId);
        }
    }

    function _moveInus(address from, address to, uint256 qty) internal {
        if (!_canReceiveInus(to)) revert AddressCanNotReceiveInu();
        for (uint256 i = 0; i < qty; i++) {
            uint256 count = _counts[from];
            if (count == 0) break;
            uint256 lastIdx = count - 1;
            uint256 inuId = _ownedInus[from][lastIdx];
            _transferInu(from, to, inuId);
        }
    }

    function _canReceiveInus(address addr) internal view returns (bool) {
        return addr != pool && addr != address(0);
    }

    function _afterInuTransferred(address from, address to, uint256) internal override {
        _transfer(from, to, UNIT_PER_INU);
    }

    function _afterInusListTransferred(address from, address to, uint256[] calldata inuIds) internal override {
        _transfer(from, to, UNIT_PER_INU * inuIds.length);
    }
}
Chain explorer3232msChain node113ms