-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathRandomNumberRetailerInterface.sol
More file actions
39 lines (32 loc) · 1.15 KB
/
RandomNumberRetailerInterface.sol
File metadata and controls
39 lines (32 loc) · 1.15 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
pragma solidity ^0.8.7;
// SPDX-License-Identifier: MIT
interface RandomNumberRetailerInterface {
struct Proof {
uint256[2] pk;
uint256[2] gamma;
uint256 c;
uint256 s;
uint256 seed;
address uWitness;
uint256[2] cGammaWitness;
uint256[2] sHashWitness;
uint256 zInv;
}
struct RequestCommitment {
uint64 blockNum;
uint256 subId;
uint32 callbackGasLimit;
uint32 numWords;
address sender;
bytes extraArgs;
}
event RandomWordsReturnedSync(address indexed requestor, uint256 weiPaid, uint256 amountOfRandomNumbersReturned);
function priceOfARandomNumberInWei() external view returns (uint256 priceOfARandomNumberInWei);
function randomNumbersAvailable() external view returns (uint256 amountOfRandomNumbersAvailable);
function requestRandomNumbersSynchronousUsingVRFv2Seed(
uint256 amountOfRandomNumbersToRequest,
Proof memory proof,
RequestCommitment memory rc,
bool payWithRando
) external payable returns (uint256[] memory randomNumbersToReturn);
}