Skip to content

Instantly share code, notes, and snippets.

View xtremetom's full-sized avatar

xtremetom

View GitHub Profile
@xtremetom
xtremetom / claimReserve.sol
Created September 6, 2021 10:43
claim and reserve test
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
import '@openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol';
import '@openzeppelin/contracts/access/Ownable.sol';
contract Reserve is ERC721Enumerable, Ownable {
string _baseTokenURI;
uint256 private _price = 0.04 ether;
@xtremetom
xtremetom / sigTest.sol
Last active October 22, 2021 12:32
SigTestContract
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
import "@openzeppelin/contracts/utils/cryptography/ECDSA.sol";
contract SigTest {
using ECDSA for bytes32;
address private systemAddress;
@xtremetom
xtremetom / sigTest.ts
Created October 19, 2021 12:01
sigTest Testing
import {ethers} from "hardhat";
import chai from "chai";
import {solidity} from "ethereum-waffle";
import {SigTest} from "../typechain/SigTest";
chai.use(solidity);
describe("SigTest", () => {
let sigTest: SigTest;
@xtremetom
xtremetom / twitterGameOne.sol
Last active October 30, 2021 11:44
twitterGame-1
pragma solidity ^0.8.0;
contract A {
address systemAddress;
function setSystemAddress(address systemAddress_) public {
systemAddress = systemAddress_;
}
@xtremetom
xtremetom / randomTokenSelector.sol
Last active February 27, 2023 22:56
randomTokenSelector Untested
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
/*
This code is untested, feel free to use it, but do so at your own risk
*/
contract Random {
uint256[] tokens = new uint256[](100);