Skip to content

Instantly share code, notes, and snippets.

View PatrickAlphaC's full-sized avatar
💭
Enabling web3 developers at scale

Patrick Collins PatrickAlphaC

💭
Enabling web3 developers at scale
View GitHub Profile
@PatrickAlphaC
PatrickAlphaC / VRFD20.sol
Last active June 23, 2021 12:25 — forked from alexroan/VRFD20.sol
Game of Thrones 20 Sided Dice
// SPDX-License-Identifier: MIT
pragma solidity 0.6.6;
import "@chainlink/contracts/src/v0.6/VRFConsumerBase.sol";
import "@chainlink/contracts/src/v0.6/Owned.sol";
/**
* @notice A Chainlink VRF consumer which uses randomness to mimic the rolling
* of a 20 sided die
* @dev This is only an example implementation and not necessarily suitable for mainnet.
@PatrickAlphaC
PatrickAlphaC / APIConsumer.sol
Created June 23, 2021 12:10 — forked from alexroan/APIConsumer.sol
APIConsumer.sol
// This example code is designed to quickly deploy an example contract using Remix.
pragma solidity ^0.6.0;
import "https://raw.githubusercontent.com/smartcontractkit/chainlink/master/evm-contracts/src/v0.6/ChainlinkClient.sol";
contract APIConsumer is ChainlinkClient {
uint256 public volume;
@PatrickAlphaC
PatrickAlphaC / RandomNumberConsumer.sol
Last active June 23, 2021 12:12 — forked from alexroan/RandomNumberConsumer.sol
Random Number Generator. Use this gist as a way to generate a random number in solidity or your EVM compatible smart contracts. If you'd like to deploy it to remix, try this: url: https://remix.ethereum.org/#version=soljson-v0.6.6+commit.6c089d02.js&optimize=false&evmVersion=null&gist=f47e4eae5f2ffa7868ef4ecd5bda9044
/** This example code is designed to quickly deploy an example contract using Remix.
* If you have never used Remix, try our example walkthrough: https://docs.chain.link/docs/example-walkthrough
* You will need testnet ETH and LINK.
* - Kovan ETH faucet: https://faucet.kovan.network/
* - Kovan LINK faucet: https://kovan.chain.link/
*/
pragma solidity 0.6.6;
import "@chainlink/contracts/src/v0.6/VRFConsumerBase.sol";