InheritancePlay

Description:

Smart contract deployed on Ethereum with Factory features.

Blockchain: Ethereum

Source Code: View Code On The Blockchain

Solidity Source Code:

{{
  "language": "Solidity",
  "sources": {
    "contracts/InheritancePlay.sol": {
      "content": "// SPDX-License-Identifier: MIT
pragma solidity ^0.8.30;
import "./utils/UiProjectStamp.sol";
contract InheritancePlay is UiProjectStamp {
    event BoardOpened(address indexed by);
    event MessagePosted(address indexed by, string body);
    bool public boardOpen;
    constructor(bytes32 u) UiProjectStamp(u) {}
    function openBoard() external { boardOpen=true; emit BoardOpened(msg.sender); }
    function postMessage(string calldata body) external { require(boardOpen,"closed"); emit MessagePosted(msg.sender, body); }
}
"
    },
    "contracts/utils/UiProjectStamp.sol": {
      "content": "// SPDX-License-Identifier: MIT
pragma solidity ^0.8.30;

abstract contract UiProjectStamp {
    bytes32 private immutable _BUILD_HASH;
    uint48  private immutable _BUILT_AT;
    uint16  private immutable _VARIANT;

    constructor(bytes32 uiLabelHash_) {
        bytes32 w = keccak256(abi.encode(block.chainid, msg.sender, uiLabelHash_));
        _BUILD_HASH = keccak256(abi.encode(w, address(this)));
        _BUILT_AT   = uint48(block.timestamp);
        _VARIANT    = uint16(uint256(_BUILD_HASH));
    }
    function project() public view returns (bytes32 buildHash, uint48 builtAt, uint16 variant) {
        return (_BUILD_HASH, _BUILT_AT, _VARIANT);
    }
}
"
    }
  },
  "settings": {
    "optimizer": {
      "enabled": true,
      "runs": 200
    },
    "evmVersion": "cancun",
    "outputSelection": {
      "*": {
        "*": [
          "evm.bytecode",
          "evm.deployedBytecode",
          "devdoc",
          "userdoc",
          "metadata",
          "abi"
        ]
      }
    }
  }
}}

Tags:
Factory|addr:0x89ff81dc9aad8e7b9125bff22c5bd8276f2cedf7|verified:true|block:23471209|tx:0xed7d46d63cadbac418fd0a1ce3d9c2721fc5eca1cbc4de28fd9e63fe26956838|first_check:1759219872

Submitted on: 2025-09-30 10:11:13

Comments

Log in to comment.

No comments yet.