// SPDX-License-Identifier: MIT pragma solidity 0.8.30; import {NysaGameEscrow} from "./NysaGameEscrow.sol"; import {NysaScorekeeperEngine} from "./NysaScorekeeperEngine.sol"; /// @notice Creates and binds both contracts in one wallet transaction. contract NysaEscrowDeployment { NysaGameEscrow public immutable escrow; NysaScorekeeperEngine public immutable engine; constructor(address token, address scorekeeper) { require(msg.sender == scorekeeper, "scorekeeper deploys"); engine = new NysaScorekeeperEngine(scorekeeper); escrow = new NysaGameEscrow(token, address(engine)); engine.bind(address(escrow)); } }