-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
fa89157
commit f95f542
Showing
22 changed files
with
555 additions
and
1,094 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,11 @@ | ||
LOCALCHAIN_DEPLOYER_PK=0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80 | ||
WETH_ADDRESS=0x24fe7807089e321395172633aA9c4bBa4Ac4a357 | ||
WSTETH_ADDRESS=0xeAc0CE2994032302f72c078b678c09CcA515AD49 | ||
UNIV2ROUTER_ADDRESS=0x6682375ebc1df04676c0c5050934272368e6e883 | ||
export LOCALCHAIN_DEPLOYER_PK= | ||
export WETH_ADDRESS=0x4200000000000000000000000000000000000006 | ||
export WSTETH_ADDRESS=0xc1CBa3fCea344f92D9239c08C0568f6F2F0ee452 | ||
export UNIROUTER_ADDRESS= | ||
RPC_URL= | ||
DEPLOYER_PRIVATE_KEY= | ||
CONTRACT_OWNER_ADDRESS= | ||
export DEPLOYER_PRIVATE_KEY= | ||
export CONTRACT_OWNER_ADDRESS=0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266 | ||
ETHERSCAN_API_KEY= | ||
PROTOCOL_REWARD_BASIS_POINTS= | ||
ARBITERS_REWARD_BASIS_POINTS= | ||
export PROTOCOL_REWARD_BASIS_POINTS=100 | ||
export ARBITERS_REWARD_BASIS_POINTS=300 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Submodule forge-std
updated
3 files
+2 −0 | src/StdChains.sol | |
+1 −5 | src/mocks/MockERC721.sol | |
+2 −0 | test/StdChains.t.sol |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
// SPDX-License-Identifier: UNLICENSED | ||
pragma solidity ^0.8.13; | ||
|
||
import {Script, console2} from "forge-std/Script.sol"; | ||
|
||
import {Slaughterhouse} from "../src/Slaughterhouse.sol"; | ||
import {Beef} from "../src/Beef.sol"; | ||
|
||
contract Deploy is Script { | ||
function setUp() public {} | ||
|
||
function run() public { | ||
address WETH = vm.envAddress("WETH_ADDRESS"); | ||
address WSTETH = vm.envAddress("WSTETH_ADDRESS"); | ||
address uniswapRouter = vm.envAddress("UNIROUTER_ADDRESS"); | ||
address initialOwner = vm.envAddress("CONTRACT_OWNER_ADDRESS"); | ||
uint256 protocolRewardBasisPoints = vm.envUint("PROTOCOL_REWARD_BASIS_POINTS"); | ||
uint256 arbitersRewardBasisPoints = vm.envUint("ARBITERS_REWARD_BASIS_POINTS"); | ||
vm.broadcast(); | ||
|
||
address[] memory arbitersArray = new address[](3); | ||
arbitersArray[0] = address(0x70997970C51812dc3A010C7d01b50e0d17dc79C8); | ||
arbitersArray[1] = address(0x15d34AAf54267DB7D7c367839AAf71A00a2C6A65); | ||
arbitersArray[2] = address(0x9965507D1a55bcC2695C58ba16FB37d819B0A4dc); | ||
Beef.ConstructorParams memory params = Beef.ConstructorParams({ | ||
owner: address(0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266), | ||
wager: 1 ether, | ||
challenger: address(0x90F79bf6EB2c4f870365E785982E1f101E93b906), | ||
settleStart: block.timestamp + 1 hours, | ||
joinDeadline: block.timestamp + 1 days, | ||
staking: true, | ||
title: "test", | ||
description: "test2", | ||
arbiters: arbitersArray | ||
}); | ||
address payable slaughterhouse = payable(0x457cCf29090fe5A24c19c1bc95F492168C0EaFdb); | ||
Slaughterhouse(slaughterhouse).packageBeef{value: 1 ether}(params, 0.1 ether); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
// SPDX-License-Identifier: UNLICENSED | ||
pragma solidity ^0.8.13; | ||
|
||
import {Script, console2} from "forge-std/Script.sol"; | ||
|
||
import '@uniswap/v3-periphery/contracts/interfaces/IQuoterV2.sol'; | ||
|
||
contract TestQuote is Script { | ||
function setUp() public {} | ||
|
||
function run() public { | ||
address WETH = vm.envAddress("WETH_ADDRESS"); | ||
address WSTETH = vm.envAddress("WSTETH_ADDRESS"); | ||
vm.broadcast(); | ||
|
||
address qa = address(0x3d4e44Eb1374240CE5F1B871ab261CD16335B76a); | ||
IQuoterV2.QuoteExactInputSingleParams memory params = IQuoterV2.QuoteExactInputSingleParams({ | ||
tokenIn: WETH, | ||
tokenOut: WSTETH, | ||
fee: 100, | ||
amountIn: 1 ether, | ||
sqrtPriceLimitX96: 0 | ||
}); | ||
uint amountOut; | ||
(amountOut,,,) = IQuoterV2(qa).quoteExactInputSingle(params); | ||
|
||
console2.log("Quote: ", amountOut); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.