Warning! Contract bytecode has been changed and doesn't match the verified one. Therefore, interaction with this smart contract may be risky.
- Contract name:
- LiquidityGeneratorToken
- Optimization enabled
- true
- Compiler version
- v0.8.4+commit.c7e474f2
- Optimization runs
- 200
- EVM Version
- default
- Verified at
- 2024-10-05T01:01:30.582388Z
Constructor Arguments
0x00000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000180000000000000000000000000000000000000000000000000016345785d8a0000000000000000000000000000af5e33cb31a3454c950bee39ed1c76fd65b394cf0000000000000000000000000000000000000000000000000000000000000369000000000000000000000000000000000000000000000000000000000000003200000000000000000000000000000000000000000000000000000000000000c800000000000000000000000000000000000000000000000000000000000000640000000000000000000000004b04213c2774f77e60702880654206b116d00508000000000000000000000000000000000000000000000000002386f26fc1000000000000000000000000000000000000000000000000000000000000000000064d41524b4554000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000044d41524b00000000000000000000000000000000000000000000000000000000
Arg [0] (string) : MARKET
Arg [1] (string) : MARK
Arg [2] (uint256) : 100000000000000000
Arg [3] (address) : 0xaf5e33cb31a3454c950bee39ed1c76fd65b394cf
Arg [4] (address) : 0x0000000000000000000000000000000000000369
Arg [5] (uint16) : 50
Arg [6] (uint16) : 200
Arg [7] (uint16) : 100
Arg [8] (address) : 0x4b04213c2774f77e60702880654206b116d00508
Arg [9] (uint256) : 10000000000000000
Contract source code
// Dependency file: @openzeppelin/contracts/token/ERC20/IERC20.sol
// SPDX-License-Identifier: MIT
// pragma solidity ^0.8.0;
/**
* @dev Interface of the ERC20 standard as defined in the EIP.
*/
interface IERC20 {
/**
* @dev Returns the amount of tokens in existence.
*/
function totalSupply() external view returns (uint256);
/**
* @dev Returns the amount of tokens owned by `account`.
*/
function balanceOf(address account) external view returns (uint256);
/**
* @dev Moves `amount` tokens from the caller's account to `recipient`.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* Emits a {Transfer} event.
*/
function transfer(address recipient, uint256 amount) external returns (bool);
/**
* @dev Returns the remaining number of tokens that `spender` will be
* allowed to spend on behalf of `owner` through {transferFrom}. This is
* zero by default.
*
* This value changes when {approve} or {transferFrom} are called.
*/
function allowance(address owner, address spender) external view returns (uint256);
/**
* @dev Sets `amount` as the allowance of `spender` over the caller's tokens.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* IMPORTANT: Beware that changing an allowance with this method brings the risk
* that someone may use both the old and the new allowance by unfortunate
* transaction ordering. One possible solution to mitigate this race
* condition is to first reduce the spender's allowance to 0 and set the
* desired value afterwards:
* https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
*
* Emits an {Approval} event.
*/
function approve(address spender, uint256 amount) external returns (bool);
/**
* @dev Moves `amount` tokens from `sender` to `recipient` using the
* allowance mechanism. `amount` is then deducted from the caller's
* allowance.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* Emits a {Transfer} event.
*/
function transferFrom(
address sender,
address recipient,
uint256 amount
) external returns (bool);
/**
* @dev Emitted when `value` tokens are moved from one account (`from`) to
* another (`to`).
*
* Note that `value` may be zero.
*/
event Transfer(address indexed from, address indexed to, uint256 value);
/**
* @dev Emitted when the allowance of a `spender` for an `owner` is set by
* a call to {approve}. `value` is the new allowance.
*/
event Approval(address indexed owner, address indexed spender, uint256 value);
}
// Dependency file: @openzeppelin/contracts/utils/Context.sol
// pragma solidity ^0.8.0;
/**
* @dev Provides information about the current execution context, including the
* sender of the transaction and its data. While these are generally available
* via msg.sender and msg.data, they should not be accessed in such a direct
* manner, since when dealing with meta-transactions the account sending and
* paying for execution may not be the actual sender (as far as an application
* is concerned).
*
* This contract is only required for intermediate, library-like contracts.
*/
abstract contract Context {
function _msgSender() internal view virtual returns (address) {
return msg.sender;
}
function _msgData() internal view virtual returns (bytes calldata) {
return msg.data;
}
}
// Dependency file: @openzeppelin/contracts/access/Ownable.sol
// pragma solidity ^0.8.0;
// import "@openzeppelin/contracts/utils/Context.sol";
/**
* @dev Contract module which provides a basic access control mechanism, where
* there is an account (an owner) that can be granted exclusive access to
* specific functions.
*
* By default, the owner account will be the one that deploys the contract. This
* can later be changed with {transferOwnership}.
*
* This module is used through inheritance. It will make available the modifier
* `onlyOwner`, which can be applied to your functions to restrict their use to
* the owner.
*/
abstract contract Ownable is Context {
address private _owner;
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
/**
* @dev Initializes the contract setting the deployer as the initial owner.
*/
constructor() {
_setOwner(_msgSender());
}
/**
* @dev Returns the address of the current owner.
*/
function owner() public view virtual returns (address) {
return _owner;
}
/**
* @dev Throws if called by any account other than the owner.
*/
modifier onlyOwner() {
require(owner() == _msgSender(), "Ownable: caller is not the owner");
_;
}
/**
* @dev Leaves the contract without owner. It will not be possible to call
* `onlyOwner` functions anymore. Can only be called by the current owner.
*
* NOTE: Renouncing ownership will leave the contract without an owner,
* thereby removing any functionality that is only available to the owner.
*/
function renounceOwnership() public virtual onlyOwner {
_setOwner(address(0));
}
/**
* @dev Transfers ownership of the contract to a new account (`newOwner`).
* Can only be called by the current owner.
*/
function transferOwnership(address newOwner) public virtual onlyOwner {
require(newOwner != address(0), "Ownable: new owner is the zero address");
_setOwner(newOwner);
}
function _setOwner(address newOwner) private {
address oldOwner = _owner;
_owner = newOwner;
emit OwnershipTransferred(oldOwner, newOwner);
}
}
// Dependency file: @openzeppelin/contracts/utils/math/SafeMath.sol
// pragma solidity ^0.8.0;
// CAUTION
// This version of SafeMath should only be used with Solidity 0.8 or later,
// because it relies on the compiler's built in overflow checks.
/**
* @dev Wrappers over Solidity's arithmetic operations.
*
* NOTE: `SafeMath` is no longer needed starting with Solidity 0.8. The compiler
* now has built in overflow checking.
*/
library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, with an overflow flag.
*
* _Available since v3.4._
*/
function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) {
unchecked {
uint256 c = a + b;
if (c < a) return (false, 0);
return (true, c);
}
}
/**
* @dev Returns the substraction of two unsigned integers, with an overflow flag.
*
* _Available since v3.4._
*/
function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) {
unchecked {
if (b > a) return (false, 0);
return (true, a - b);
}
}
/**
* @dev Returns the multiplication of two unsigned integers, with an overflow flag.
*
* _Available since v3.4._
*/
function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) {
unchecked {
// Gas optimization: this is cheaper than requiring 'a' not being zero, but the
// benefit is lost if 'b' is also tested.
// See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522
if (a == 0) return (true, 0);
uint256 c = a * b;
if (c / a != b) return (false, 0);
return (true, c);
}
}
/**
* @dev Returns the division of two unsigned integers, with a division by zero flag.
*
* _Available since v3.4._
*/
function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) {
unchecked {
if (b == 0) return (false, 0);
return (true, a / b);
}
}
/**
* @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag.
*
* _Available since v3.4._
*/
function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) {
unchecked {
if (b == 0) return (false, 0);
return (true, a % b);
}
}
/**
* @dev Returns the addition of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `+` operator.
*
* Requirements:
*
* - Addition cannot overflow.
*/
function add(uint256 a, uint256 b) internal pure returns (uint256) {
return a + b;
}
/**
* @dev Returns the subtraction of two unsigned integers, reverting on
* overflow (when the result is negative).
*
* Counterpart to Solidity's `-` operator.
*
* Requirements:
*
* - Subtraction cannot overflow.
*/
function sub(uint256 a, uint256 b) internal pure returns (uint256) {
return a - b;
}
/**
* @dev Returns the multiplication of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `*` operator.
*
* Requirements:
*
* - Multiplication cannot overflow.
*/
function mul(uint256 a, uint256 b) internal pure returns (uint256) {
return a * b;
}
/**
* @dev Returns the integer division of two unsigned integers, reverting on
* division by zero. The result is rounded towards zero.
*
* Counterpart to Solidity's `/` operator.
*
* Requirements:
*
* - The divisor cannot be zero.
*/
function div(uint256 a, uint256 b) internal pure returns (uint256) {
return a / b;
}
/**
* @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
* reverting when dividing by zero.
*
* Counterpart to Solidity's `%` operator. This function uses a `revert`
* opcode (which leaves remaining gas untouched) while Solidity uses an
* invalid opcode to revert (consuming all remaining gas).
*
* Requirements:
*
* - The divisor cannot be zero.
*/
function mod(uint256 a, uint256 b) internal pure returns (uint256) {
return a % b;
}
/**
* @dev Returns the subtraction of two unsigned integers, reverting with custom message on
* overflow (when the result is negative).
*
* CAUTION: This function is deprecated because it requires allocating memory for the error
* message unnecessarily. For custom revert reasons use {trySub}.
*
* Counterpart to Solidity's `-` operator.
*
* Requirements:
*
* - Subtraction cannot overflow.
*/
function sub(
uint256 a,
uint256 b,
string memory errorMessage
) internal pure returns (uint256) {
unchecked {
require(b <= a, errorMessage);
return a - b;
}
}
/**
* @dev Returns the integer division of two unsigned integers, reverting with custom message on
* division by zero. The result is rounded towards zero.
*
* Counterpart to Solidity's `/` operator. Note: this function uses a
* `revert` opcode (which leaves remaining gas untouched) while Solidity
* uses an invalid opcode to revert (consuming all remaining gas).
*
* Requirements:
*
* - The divisor cannot be zero.
*/
function div(
uint256 a,
uint256 b,
string memory errorMessage
) internal pure returns (uint256) {
unchecked {
require(b > 0, errorMessage);
return a / b;
}
}
/**
* @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
* reverting with custom message when dividing by zero.
*
* CAUTION: This function is deprecated because it requires allocating memory for the error
* message unnecessarily. For custom revert reasons use {tryMod}.
*
* Counterpart to Solidity's `%` operator. This function uses a `revert`
* opcode (which leaves remaining gas untouched) while Solidity uses an
* invalid opcode to revert (consuming all remaining gas).
*
* Requirements:
*
* - The divisor cannot be zero.
*/
function mod(
uint256 a,
uint256 b,
string memory errorMessage
) internal pure returns (uint256) {
unchecked {
require(b > 0, errorMessage);
return a % b;
}
}
}
// Dependency file: @openzeppelin/contracts/utils/Address.sol
// pragma solidity ^0.8.0;
/**
* @dev Collection of functions related to the address type
*/
library Address {
/**
* @dev Returns true if `account` is a contract.
*
* [IMPORTANT]
* ====
* It is unsafe to assume that an address for which this function returns
* false is an externally-owned account (EOA) and not a contract.
*
* Among others, `isContract` will return false for the following
* types of addresses:
*
* - an externally-owned account
* - a contract in construction
* - an address where a contract will be created
* - an address where a contract lived, but was destroyed
* ====
*/
function isContract(address account) internal view returns (bool) {
// This method relies on extcodesize, which returns 0 for contracts in
// construction, since the code is only stored at the end of the
// constructor execution.
uint256 size;
assembly {
size := extcodesize(account)
}
return size > 0;
}
/**
* @dev Replacement for Solidity's `transfer`: sends `amount` wei to
* `recipient`, forwarding all available gas and reverting on errors.
*
* https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
* of certain opcodes, possibly making contracts go over the 2300 gas limit
* imposed by `transfer`, making them unable to receive funds via
* `transfer`. {sendValue} removes this limitation.
*
* https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
*
* IMPORTANT: because control is transferred to `recipient`, care must be
* taken to not create reentrancy vulnerabilities. Consider using
* {ReentrancyGuard} or the
* https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
*/
function sendValue(address payable recipient, uint256 amount) internal {
require(address(this).balance >= amount, "Address: insufficient balance");
(bool success, ) = recipient.call{value: amount}("");
require(success, "Address: unable to send value, recipient may have reverted");
}
/**
* @dev Performs a Solidity function call using a low level `call`. A
* plain `call` is an unsafe replacement for a function call: use this
* function instead.
*
* If `target` reverts with a revert reason, it is bubbled up by this
* function (like regular Solidity function calls).
*
* Returns the raw returned data. To convert to the expected return value,
* use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
*
* Requirements:
*
* - `target` must be a contract.
* - calling `target` with `data` must not revert.
*
* _Available since v3.1._
*/
function functionCall(address target, bytes memory data) internal returns (bytes memory) {
return functionCall(target, data, "Address: low-level call failed");
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with
* `errorMessage` as a fallback revert reason when `target` reverts.
*
* _Available since v3.1._
*/
function functionCall(
address target,
bytes memory data,
string memory errorMessage
) internal returns (bytes memory) {
return functionCallWithValue(target, data, 0, errorMessage);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but also transferring `value` wei to `target`.
*
* Requirements:
*
* - the calling contract must have an ETH balance of at least `value`.
* - the called Solidity function must be `payable`.
*
* _Available since v3.1._
*/
function functionCallWithValue(
address target,
bytes memory data,
uint256 value
) internal returns (bytes memory) {
return functionCallWithValue(target, data, value, "Address: low-level call with value failed");
}
/**
* @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but
* with `errorMessage` as a fallback revert reason when `target` reverts.
*
* _Available since v3.1._
*/
function functionCallWithValue(
address target,
bytes memory data,
uint256 value,
string memory errorMessage
) internal returns (bytes memory) {
require(address(this).balance >= value, "Address: insufficient balance for call");
require(isContract(target), "Address: call to non-contract");
(bool success, bytes memory returndata) = target.call{value: value}(data);
return verifyCallResult(success, returndata, errorMessage);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but performing a static call.
*
* _Available since v3.3._
*/
function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {
return functionStaticCall(target, data, "Address: low-level static call failed");
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
* but performing a static call.
*
* _Available since v3.3._
*/
function functionStaticCall(
address target,
bytes memory data,
string memory errorMessage
) internal view returns (bytes memory) {
require(isContract(target), "Address: static call to non-contract");
(bool success, bytes memory returndata) = target.staticcall(data);
return verifyCallResult(success, returndata, errorMessage);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but performing a delegate call.
*
* _Available since v3.4._
*/
function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {
return functionDelegateCall(target, data, "Address: low-level delegate call failed");
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
* but performing a delegate call.
*
* _Available since v3.4._
*/
function functionDelegateCall(
address target,
bytes memory data,
string memory errorMessage
) internal returns (bytes memory) {
require(isContract(target), "Address: delegate call to non-contract");
(bool success, bytes memory returndata) = target.delegatecall(data);
return verifyCallResult(success, returndata, errorMessage);
}
/**
* @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the
* revert reason using the provided one.
*
* _Available since v4.3._
*/
function verifyCallResult(
bool success,
bytes memory returndata,
string memory errorMessage
) internal pure returns (bytes memory) {
if (success) {
return returndata;
} else {
// Look for revert reason and bubble it up if present
if (returndata.length > 0) {
// The easiest way to bubble the revert reason is using memory via assembly
assembly {
let returndata_size := mload(returndata)
revert(add(32, returndata), returndata_size)
}
} else {
revert(errorMessage);
}
}
}
}
// Dependency file: contracts/interfaces/IUniswapV2Router02.sol
// pragma solidity >=0.6.2;
interface IUniswapV2Router01 {
function factory() external pure returns (address);
function WETH() external pure returns (address);
function addLiquidity(
address tokenA,
address tokenB,
uint256 amountADesired,
uint256 amountBDesired,
uint256 amountAMin,
uint256 amountBMin,
address to,
uint256 deadline
)
external
returns (
uint256 amountA,
uint256 amountB,
uint256 liquidity
);
function addLiquidityETH(
address token,
uint256 amountTokenDesired,
uint256 amountTokenMin,
uint256 amountETHMin,
address to,
uint256 deadline
)
external
payable
returns (
uint256 amountToken,
uint256 amountETH,
uint256 liquidity
);
function removeLiquidity(
address tokenA,
address tokenB,
uint256 liquidity,
uint256 amountAMin,
uint256 amountBMin,
address to,
uint256 deadline
) external returns (uint256 amountA, uint256 amountB);
function removeLiquidityETH(
address token,
uint256 liquidity,
uint256 amountTokenMin,
uint256 amountETHMin,
address to,
uint256 deadline
) external returns (uint256 amountToken, uint256 amountETH);
function removeLiquidityWithPermit(
address tokenA,
address tokenB,
uint256 liquidity,
uint256 amountAMin,
uint256 amountBMin,
address to,
uint256 deadline,
bool approveMax,
uint8 v,
bytes32 r,
bytes32 s
) external returns (uint256 amountA, uint256 amountB);
function removeLiquidityETHWithPermit(
address token,
uint256 liquidity,
uint256 amountTokenMin,
uint256 amountETHMin,
address to,
uint256 deadline,
bool approveMax,
uint8 v,
bytes32 r,
bytes32 s
) external returns (uint256 amountToken, uint256 amountETH);
function swapExactTokensForTokens(
uint256 amountIn,
uint256 amountOutMin,
address[] calldata path,
address to,
uint256 deadline
) external returns (uint256[] memory amounts);
function swapTokensForExactTokens(
uint256 amountOut,
uint256 amountInMax,
address[] calldata path,
address to,
uint256 deadline
) external returns (uint256[] memory amounts);
function swapExactETHForTokens(
uint256 amountOutMin,
address[] calldata path,
address to,
uint256 deadline
) external payable returns (uint256[] memory amounts);
function swapTokensForExactETH(
uint256 amountOut,
uint256 amountInMax,
address[] calldata path,
address to,
uint256 deadline
) external returns (uint256[] memory amounts);
function swapExactTokensForETH(
uint256 amountIn,
uint256 amountOutMin,
address[] calldata path,
address to,
uint256 deadline
) external returns (uint256[] memory amounts);
function swapETHForExactTokens(
uint256 amountOut,
address[] calldata path,
address to,
uint256 deadline
) external payable returns (uint256[] memory amounts);
function quote(
uint256 amountA,
uint256 reserveA,
uint256 reserveB
) external pure returns (uint256 amountB);
function getAmountOut(
uint256 amountIn,
uint256 reserveIn,
uint256 reserveOut
) external pure returns (uint256 amountOut);
function getAmountIn(
uint256 amountOut,
uint256 reserveIn,
uint256 reserveOut
) external pure returns (uint256 amountIn);
function getAmountsOut(uint256 amountIn, address[] calldata path)
external
view
returns (uint256[] memory amounts);
function getAmountsIn(uint256 amountOut, address[] calldata path)
external
view
returns (uint256[] memory amounts);
}
interface IUniswapV2Router02 is IUniswapV2Router01 {
function removeLiquidityETHSupportingFeeOnTransferTokens(
address token,
uint256 liquidity,
uint256 amountTokenMin,
uint256 amountETHMin,
address to,
uint256 deadline
) external returns (uint256 amountETH);
function removeLiquidityETHWithPermitSupportingFeeOnTransferTokens(
address token,
uint256 liquidity,
uint256 amountTokenMin,
uint256 amountETHMin,
address to,
uint256 deadline,
bool approveMax,
uint8 v,
bytes32 r,
bytes32 s
) external returns (uint256 amountETH);
function swapExactTokensForTokensSupportingFeeOnTransferTokens(
uint256 amountIn,
uint256 amountOutMin,
address[] calldata path,
address to,
uint256 deadline
) external;
function swapExactETHForTokensSupportingFeeOnTransferTokens(
uint256 amountOutMin,
address[] calldata path,
address to,
uint256 deadline
) external payable;
function swapExactTokensForETHSupportingFeeOnTransferTokens(
uint256 amountIn,
uint256 amountOutMin,
address[] calldata path,
address to,
uint256 deadline
) external;
}
// Dependency file: contracts/interfaces/IUniswapV2Factory.sol
// pragma solidity >=0.5.0;
interface IUniswapV2Factory {
event PairCreated(
address indexed token0,
address indexed token1,
address pair,
uint256
);
function feeTo() external view returns (address);
function feeToSetter() external view returns (address);
function getPair(address tokenA, address tokenB)
external
view
returns (address pair);
function allPairs(uint256) external view returns (address pair);
function allPairsLength() external view returns (uint256);
function createPair(address tokenA, address tokenB)
external
returns (address pair);
function setFeeTo(address) external;
function setFeeToSetter(address) external;
}
// Dependency file: contracts/BaseToken.sol
// pragma solidity =0.8.4;
enum TokenType {
standard,
antiBotStandard,
liquidityGenerator,
antiBotLiquidityGenerator,
baby,
antiBotBaby,
buybackBaby,
antiBotBuybackBaby
}
abstract contract BaseToken {
event TokenCreated(
address indexed owner,
address indexed token,
TokenType tokenType,
uint256 version
);
}
// Root file: contracts/liquidity-generator/LiquidityGeneratorToken.sol
pragma solidity =0.8.4;
// import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
// import "@openzeppelin/contracts/access/Ownable.sol";
// import "@openzeppelin/contracts/utils/math/SafeMath.sol";
// import "@openzeppelin/contracts/utils/Address.sol";
// import "contracts/interfaces/IUniswapV2Router02.sol";
// import "contracts/interfaces/IUniswapV2Factory.sol";
// import "contracts/BaseToken.sol";
contract LiquidityGeneratorToken is IERC20, Ownable, BaseToken {
using SafeMath for uint256;
using Address for address;
uint256 public constant VERSION = 2;
uint256 public constant MAX_FEE = 10**4 / 4;
mapping(address => uint256) private _rOwned;
mapping(address => uint256) private _tOwned;
mapping(address => mapping(address => uint256)) private _allowances;
mapping(address => bool) private _isExcludedFromFee;
mapping(address => bool) private _isExcluded;
address[] private _excluded;
uint256 private constant MAX = ~uint256(0);
uint256 private _tTotal;
uint256 private _rTotal;
uint256 private _tFeeTotal;
string private _name;
string private _symbol;
uint8 private _decimals;
uint256 public _taxFee;
uint256 private _previousTaxFee;
uint256 public _liquidityFee;
uint256 private _previousLiquidityFee;
uint256 public _charityFee;
uint256 private _previousCharityFee;
IUniswapV2Router02 public uniswapV2Router;
address public uniswapV2Pair;
address public _charityAddress;
bool inSwapAndLiquify;
bool public swapAndLiquifyEnabled;
uint256 private numTokensSellToAddToLiquidity;
event MinTokensBeforeSwapUpdated(uint256 minTokensBeforeSwap);
event SwapAndLiquifyAmountUpdated(uint256 amount);
event SwapAndLiquify(
uint256 tokensSwapped,
uint256 ethReceived,
uint256 tokensIntoLiqudity
);
modifier lockTheSwap() {
inSwapAndLiquify = true;
_;
inSwapAndLiquify = false;
}
constructor(
string memory name_,
string memory symbol_,
uint256 totalSupply_,
address router_,
address charityAddress_,
uint16 taxFeeBps_,
uint16 liquidityFeeBps_,
uint16 charityFeeBps_,
address serviceFeeReceiver_,
uint256 serviceFee_
) payable {
if (charityAddress_ == address(0)) {
require(
charityFeeBps_ == 0,
"Cant set both charity address to address 0 and charity percent more than 0"
);
}
require(
taxFeeBps_ + liquidityFeeBps_ + charityFeeBps_ <= MAX_FEE,
"Total fee is over 25%"
);
_name = name_;
_symbol = symbol_;
_decimals = 9;
_tTotal = totalSupply_;
_rTotal = (MAX - (MAX % _tTotal));
_taxFee = taxFeeBps_;
_previousTaxFee = _taxFee;
_liquidityFee = liquidityFeeBps_;
_previousLiquidityFee = _liquidityFee;
_charityAddress = charityAddress_;
_charityFee = charityFeeBps_;
_previousCharityFee = _charityFee;
numTokensSellToAddToLiquidity = totalSupply_.div(10**3); // 0.1%
swapAndLiquifyEnabled = true;
_rOwned[owner()] = _rTotal;
IUniswapV2Router02 _uniswapV2Router = IUniswapV2Router02(router_);
// Create a uniswap pair for this new token
uniswapV2Pair = IUniswapV2Factory(_uniswapV2Router.factory())
.createPair(address(this), _uniswapV2Router.WETH());
// set the rest of the contract variables
uniswapV2Router = _uniswapV2Router;
// exclude owner and this contract from fee
_isExcludedFromFee[owner()] = true;
_isExcludedFromFee[address(this)] = true;
emit Transfer(address(0), owner(), _tTotal);
emit TokenCreated(
owner(),
address(this),
TokenType.liquidityGenerator,
VERSION
);
payable(serviceFeeReceiver_).transfer(serviceFee_);
}
function name() public view returns (string memory) {
return _name;
}
function symbol() public view returns (string memory) {
return _symbol;
}
function decimals() public view returns (uint8) {
return _decimals;
}
function totalSupply() public view override returns (uint256) {
return _tTotal;
}
function balanceOf(address account) public view override returns (uint256) {
if (_isExcluded[account]) return _tOwned[account];
return tokenFromReflection(_rOwned[account]);
}
function transfer(address recipient, uint256 amount)
public
override
returns (bool)
{
_transfer(_msgSender(), recipient, amount);
return true;
}
function allowance(address owner, address spender)
public
view
override
returns (uint256)
{
return _allowances[owner][spender];
}
function approve(address spender, uint256 amount)
public
override
returns (bool)
{
_approve(_msgSender(), spender, amount);
return true;
}
function transferFrom(
address sender,
address recipient,
uint256 amount
) public override returns (bool) {
_transfer(sender, recipient, amount);
_approve(
sender,
_msgSender(),
_allowances[sender][_msgSender()].sub(
amount,
"ERC20: transfer amount exceeds allowance"
)
);
return true;
}
function increaseAllowance(address spender, uint256 addedValue)
public
virtual
returns (bool)
{
_approve(
_msgSender(),
spender,
_allowances[_msgSender()][spender].add(addedValue)
);
return true;
}
function decreaseAllowance(address spender, uint256 subtractedValue)
public
virtual
returns (bool)
{
_approve(
_msgSender(),
spender,
_allowances[_msgSender()][spender].sub(
subtractedValue,
"ERC20: decreased allowance below zero"
)
);
return true;
}
function isExcludedFromReward(address account) public view returns (bool) {
return _isExcluded[account];
}
function totalFees() public view returns (uint256) {
return _tFeeTotal;
}
function deliver(uint256 tAmount) public {
address sender = _msgSender();
require(
!_isExcluded[sender],
"Excluded addresses cannot call this function"
);
(uint256 rAmount, , , , , , ) = _getValues(tAmount);
_rOwned[sender] = _rOwned[sender].sub(rAmount);
_rTotal = _rTotal.sub(rAmount);
_tFeeTotal = _tFeeTotal.add(tAmount);
}
function reflectionFromToken(uint256 tAmount, bool deductTransferFee)
public
view
returns (uint256)
{
require(tAmount <= _tTotal, "Amount must be less than supply");
if (!deductTransferFee) {
(uint256 rAmount, , , , , , ) = _getValues(tAmount);
return rAmount;
} else {
(, uint256 rTransferAmount, , , , , ) = _getValues(tAmount);
return rTransferAmount;
}
}
function tokenFromReflection(uint256 rAmount)
public
view
returns (uint256)
{
require(
rAmount <= _rTotal,
"Amount must be less than total reflections"
);
uint256 currentRate = _getRate();
return rAmount.div(currentRate);
}
function excludeFromReward(address account) public onlyOwner {
// require(account != 0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D, 'We can not exclude Uniswap router.');
require(!_isExcluded[account], "Account is already excluded");
if (_rOwned[account] > 0) {
_tOwned[account] = tokenFromReflection(_rOwned[account]);
}
_isExcluded[account] = true;
_excluded.push(account);
}
function includeInReward(address account) external onlyOwner {
require(_isExcluded[account], "Account is already excluded");
for (uint256 i = 0; i < _excluded.length; i++) {
if (_excluded[i] == account) {
_excluded[i] = _excluded[_excluded.length - 1];
_tOwned[account] = 0;
_isExcluded[account] = false;
_excluded.pop();
break;
}
}
}
function _transferBothExcluded(
address sender,
address recipient,
uint256 tAmount
) private {
(
uint256 rAmount,
uint256 rTransferAmount,
uint256 rFee,
uint256 tTransferAmount,
uint256 tFee,
uint256 tLiquidity,
uint256 tCharity
) = _getValues(tAmount);
_tOwned[sender] = _tOwned[sender].sub(tAmount);
_rOwned[sender] = _rOwned[sender].sub(rAmount);
_tOwned[recipient] = _tOwned[recipient].add(tTransferAmount);
_rOwned[recipient] = _rOwned[recipient].add(rTransferAmount);
_takeLiquidity(tLiquidity);
_takeCharityFee(tCharity);
_reflectFee(rFee, tFee);
emit Transfer(sender, recipient, tTransferAmount);
}
function excludeFromFee(address account) public onlyOwner {
_isExcludedFromFee[account] = true;
}
function setTaxFeePercent(uint256 taxFeeBps) external onlyOwner {
_taxFee = taxFeeBps;
require(
_taxFee + _liquidityFee + _charityFee <= MAX_FEE,
"Total fee is over 25%"
);
}
function setLiquidityFeePercent(uint256 liquidityFeeBps)
external
onlyOwner
{
_liquidityFee = liquidityFeeBps;
require(
_taxFee + _liquidityFee + _charityFee <= MAX_FEE,
"Total fee is over 25%"
);
}
function setCharityFeePercent(uint256 charityFeeBps) external onlyOwner {
_charityFee = charityFeeBps;
require(
_taxFee + _liquidityFee + _charityFee <= MAX_FEE,
"Total fee is over 25%"
);
}
function setSwapBackSettings(uint256 _amount) external onlyOwner {
require(
_amount >= totalSupply().mul(5).div(10**4),
"Swapback amount should be at least 0.05% of total supply"
);
numTokensSellToAddToLiquidity = _amount;
emit SwapAndLiquifyAmountUpdated(_amount);
}
//to recieve ETH from uniswapV2Router when swaping
receive() external payable {}
function _reflectFee(uint256 rFee, uint256 tFee) private {
_rTotal = _rTotal.sub(rFee);
_tFeeTotal = _tFeeTotal.add(tFee);
}
function _getValues(uint256 tAmount)
private
view
returns (
uint256,
uint256,
uint256,
uint256,
uint256,
uint256,
uint256
)
{
(
uint256 tTransferAmount,
uint256 tFee,
uint256 tLiquidity,
uint256 tCharity
) = _getTValues(tAmount);
(uint256 rAmount, uint256 rTransferAmount, uint256 rFee) = _getRValues(
tAmount,
tFee,
tLiquidity,
tCharity,
_getRate()
);
return (
rAmount,
rTransferAmount,
rFee,
tTransferAmount,
tFee,
tLiquidity,
tCharity
);
}
function _getTValues(uint256 tAmount)
private
view
returns (
uint256,
uint256,
uint256,
uint256
)
{
uint256 tFee = calculateTaxFee(tAmount);
uint256 tLiquidity = calculateLiquidityFee(tAmount);
uint256 tCharityFee = calculateCharityFee(tAmount);
uint256 tTransferAmount = tAmount.sub(tFee).sub(tLiquidity).sub(
tCharityFee
);
return (tTransferAmount, tFee, tLiquidity, tCharityFee);
}
function _getRValues(
uint256 tAmount,
uint256 tFee,
uint256 tLiquidity,
uint256 tCharity,
uint256 currentRate
)
private
pure
returns (
uint256,
uint256,
uint256
)
{
uint256 rAmount = tAmount.mul(currentRate);
uint256 rFee = tFee.mul(currentRate);
uint256 rLiquidity = tLiquidity.mul(currentRate);
uint256 rCharity = tCharity.mul(currentRate);
uint256 rTransferAmount = rAmount.sub(rFee).sub(rLiquidity).sub(
rCharity
);
return (rAmount, rTransferAmount, rFee);
}
function _getRate() private view returns (uint256) {
(uint256 rSupply, uint256 tSupply) = _getCurrentSupply();
return rSupply.div(tSupply);
}
function _getCurrentSupply() private view returns (uint256, uint256) {
uint256 rSupply = _rTotal;
uint256 tSupply = _tTotal;
for (uint256 i = 0; i < _excluded.length; i++) {
if (
_rOwned[_excluded[i]] > rSupply ||
_tOwned[_excluded[i]] > tSupply
) return (_rTotal, _tTotal);
rSupply = rSupply.sub(_rOwned[_excluded[i]]);
tSupply = tSupply.sub(_tOwned[_excluded[i]]);
}
if (rSupply < _rTotal.div(_tTotal)) return (_rTotal, _tTotal);
return (rSupply, tSupply);
}
function _takeLiquidity(uint256 tLiquidity) private {
uint256 currentRate = _getRate();
uint256 rLiquidity = tLiquidity.mul(currentRate);
_rOwned[address(this)] = _rOwned[address(this)].add(rLiquidity);
if (_isExcluded[address(this)])
_tOwned[address(this)] = _tOwned[address(this)].add(tLiquidity);
}
function _takeCharityFee(uint256 tCharity) private {
if (tCharity > 0) {
uint256 currentRate = _getRate();
uint256 rCharity = tCharity.mul(currentRate);
_rOwned[_charityAddress] = _rOwned[_charityAddress].add(rCharity);
if (_isExcluded[_charityAddress])
_tOwned[_charityAddress] = _tOwned[_charityAddress].add(
tCharity
);
emit Transfer(_msgSender(), _charityAddress, tCharity);
}
}
function calculateTaxFee(uint256 _amount) private view returns (uint256) {
return _amount.mul(_taxFee).div(10**4);
}
function calculateLiquidityFee(uint256 _amount)
private
view
returns (uint256)
{
return _amount.mul(_liquidityFee).div(10**4);
}
function calculateCharityFee(uint256 _amount)
private
view
returns (uint256)
{
if (_charityAddress == address(0)) return 0;
return _amount.mul(_charityFee).div(10**4);
}
function removeAllFee() private {
_previousTaxFee = _taxFee;
_previousLiquidityFee = _liquidityFee;
_previousCharityFee = _charityFee;
_taxFee = 0;
_liquidityFee = 0;
_charityFee = 0;
}
function restoreAllFee() private {
_taxFee = _previousTaxFee;
_liquidityFee = _previousLiquidityFee;
_charityFee = _previousCharityFee;
}
function isExcludedFromFee(address account) public view returns (bool) {
return _isExcludedFromFee[account];
}
function _approve(
address owner,
address spender,
uint256 amount
) private {
require(owner != address(0), "ERC20: approve from the zero address");
require(spender != address(0), "ERC20: approve to the zero address");
_allowances[owner][spender] = amount;
emit Approval(owner, spender, amount);
}
function _transfer(
address from,
address to,
uint256 amount
) private {
require(from != address(0), "ERC20: transfer from the zero address");
require(to != address(0), "ERC20: transfer to the zero address");
require(amount > 0, "Transfer amount must be greater than zero");
// is the token balance of this contract address over the min number of
// tokens that we need to initiate a swap + liquidity lock?
// also, don't get caught in a circular liquidity event.
// also, don't swap & liquify if sender is uniswap pair.
uint256 contractTokenBalance = balanceOf(address(this));
bool overMinTokenBalance = contractTokenBalance >=
numTokensSellToAddToLiquidity;
if (
overMinTokenBalance &&
!inSwapAndLiquify &&
from != uniswapV2Pair &&
swapAndLiquifyEnabled
) {
contractTokenBalance = numTokensSellToAddToLiquidity;
//add liquidity
swapAndLiquify(contractTokenBalance);
}
//indicates if fee should be deducted from transfer
bool takeFee = true;
//if any account belongs to _isExcludedFromFee account then remove the fee
if (_isExcludedFromFee[from] || _isExcludedFromFee[to]) {
takeFee = false;
}
//transfer amount, it will take tax, burn, liquidity fee
_tokenTransfer(from, to, amount, takeFee);
}
function swapAndLiquify(uint256 contractTokenBalance) private lockTheSwap {
// split the contract balance into halves
uint256 half = contractTokenBalance.div(2);
uint256 otherHalf = contractTokenBalance.sub(half);
// capture the contract's current ETH balance.
// this is so that we can capture exactly the amount of ETH that the
// swap creates, and not make the liquidity event include any ETH that
// has been manually sent to the contract
uint256 initialBalance = address(this).balance;
// swap tokens for ETH
swapTokensForEth(half); // <- this breaks the ETH -> HATE swap when swap+liquify is triggered
// how much ETH did we just swap into?
uint256 newBalance = address(this).balance.sub(initialBalance);
// add liquidity to uniswap
addLiquidity(otherHalf, newBalance);
emit SwapAndLiquify(half, newBalance, otherHalf);
}
function swapTokensForEth(uint256 tokenAmount) private {
// generate the uniswap pair path of token -> weth
address[] memory path = new address[](2);
path[0] = address(this);
path[1] = uniswapV2Router.WETH();
_approve(address(this), address(uniswapV2Router), tokenAmount);
// make the swap
uniswapV2Router.swapExactTokensForETHSupportingFeeOnTransferTokens(
tokenAmount,
0, // accept any amount of ETH
path,
address(this),
block.timestamp
);
}
function addLiquidity(uint256 tokenAmount, uint256 ethAmount) private {
// approve token transfer to cover all possible scenarios
_approve(address(this), address(uniswapV2Router), tokenAmount);
// add the liquidity
uniswapV2Router.addLiquidityETH{value: ethAmount}(
address(this),
tokenAmount,
0, // slippage is unavoidable
0, // slippage is unavoidable
address(0xdead),
block.timestamp
);
}
//this method is responsible for taking all fee, if takeFee is true
function _tokenTransfer(
address sender,
address recipient,
uint256 amount,
bool takeFee
) private {
if (!takeFee) removeAllFee();
if (_isExcluded[sender] && !_isExcluded[recipient]) {
_transferFromExcluded(sender, recipient, amount);
} else if (!_isExcluded[sender] && _isExcluded[recipient]) {
_transferToExcluded(sender, recipient, amount);
} else if (!_isExcluded[sender] && !_isExcluded[recipient]) {
_transferStandard(sender, recipient, amount);
} else if (_isExcluded[sender] && _isExcluded[recipient]) {
_transferBothExcluded(sender, recipient, amount);
} else {
_transferStandard(sender, recipient, amount);
}
if (!takeFee) restoreAllFee();
}
function _transferStandard(
address sender,
address recipient,
uint256 tAmount
) private {
(
uint256 rAmount,
uint256 rTransferAmount,
uint256 rFee,
uint256 tTransferAmount,
uint256 tFee,
uint256 tLiquidity,
uint256 tCharity
) = _getValues(tAmount);
_rOwned[sender] = _rOwned[sender].sub(rAmount);
_rOwned[recipient] = _rOwned[recipient].add(rTransferAmount);
_takeLiquidity(tLiquidity);
_takeCharityFee(tCharity);
_reflectFee(rFee, tFee);
emit Transfer(sender, recipient, tTransferAmount);
}
function _transferToExcluded(
address sender,
address recipient,
uint256 tAmount
) private {
(
uint256 rAmount,
uint256 rTransferAmount,
uint256 rFee,
uint256 tTransferAmount,
uint256 tFee,
uint256 tLiquidity,
uint256 tCharity
) = _getValues(tAmount);
_rOwned[sender] = _rOwned[sender].sub(rAmount);
_tOwned[recipient] = _tOwned[recipient].add(tTransferAmount);
_rOwned[recipient] = _rOwned[recipient].add(rTransferAmount);
_takeLiquidity(tLiquidity);
_takeCharityFee(tCharity);
_reflectFee(rFee, tFee);
emit Transfer(sender, recipient, tTransferAmount);
}
function _transferFromExcluded(
address sender,
address recipient,
uint256 tAmount
) private {
(
uint256 rAmount,
uint256 rTransferAmount,
uint256 rFee,
uint256 tTransferAmount,
uint256 tFee,
uint256 tLiquidity,
uint256 tCharity
) = _getValues(tAmount);
_tOwned[sender] = _tOwned[sender].sub(tAmount);
_rOwned[sender] = _rOwned[sender].sub(rAmount);
_rOwned[recipient] = _rOwned[recipient].add(rTransferAmount);
_takeLiquidity(tLiquidity);
_takeCharityFee(tCharity);
_reflectFee(rFee, tFee);
emit Transfer(sender, recipient, tTransferAmount);
}
}
Contract ABI
[{"type":"constructor","stateMutability":"payable","inputs":[{"type":"string","name":"name_","internalType":"string"},{"type":"string","name":"symbol_","internalType":"string"},{"type":"uint256","name":"totalSupply_","internalType":"uint256"},{"type":"address","name":"router_","internalType":"address"},{"type":"address","name":"charityAddress_","internalType":"address"},{"type":"uint16","name":"taxFeeBps_","internalType":"uint16"},{"type":"uint16","name":"liquidityFeeBps_","internalType":"uint16"},{"type":"uint16","name":"charityFeeBps_","internalType":"uint16"},{"type":"address","name":"serviceFeeReceiver_","internalType":"address"},{"type":"uint256","name":"serviceFee_","internalType":"uint256"}]},{"type":"event","name":"Approval","inputs":[{"type":"address","name":"owner","internalType":"address","indexed":true},{"type":"address","name":"spender","internalType":"address","indexed":true},{"type":"uint256","name":"value","internalType":"uint256","indexed":false}],"anonymous":false},{"type":"event","name":"MinTokensBeforeSwapUpdated","inputs":[{"type":"uint256","name":"minTokensBeforeSwap","internalType":"uint256","indexed":false}],"anonymous":false},{"type":"event","name":"OwnershipTransferred","inputs":[{"type":"address","name":"previousOwner","internalType":"address","indexed":true},{"type":"address","name":"newOwner","internalType":"address","indexed":true}],"anonymous":false},{"type":"event","name":"SwapAndLiquify","inputs":[{"type":"uint256","name":"tokensSwapped","internalType":"uint256","indexed":false},{"type":"uint256","name":"ethReceived","internalType":"uint256","indexed":false},{"type":"uint256","name":"tokensIntoLiqudity","internalType":"uint256","indexed":false}],"anonymous":false},{"type":"event","name":"SwapAndLiquifyAmountUpdated","inputs":[{"type":"uint256","name":"amount","internalType":"uint256","indexed":false}],"anonymous":false},{"type":"event","name":"TokenCreated","inputs":[{"type":"address","name":"owner","internalType":"address","indexed":true},{"type":"address","name":"token","internalType":"address","indexed":true},{"type":"uint8","name":"tokenType","internalType":"enum TokenType","indexed":false},{"type":"uint256","name":"version","internalType":"uint256","indexed":false}],"anonymous":false},{"type":"event","name":"Transfer","inputs":[{"type":"address","name":"from","internalType":"address","indexed":true},{"type":"address","name":"to","internalType":"address","indexed":true},{"type":"uint256","name":"value","internalType":"uint256","indexed":false}],"anonymous":false},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"MAX_FEE","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"VERSION","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"_charityAddress","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"_charityFee","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"_liquidityFee","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"_taxFee","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"allowance","inputs":[{"type":"address","name":"owner","internalType":"address"},{"type":"address","name":"spender","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"approve","inputs":[{"type":"address","name":"spender","internalType":"address"},{"type":"uint256","name":"amount","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"balanceOf","inputs":[{"type":"address","name":"account","internalType":"address"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint8","name":"","internalType":"uint8"}],"name":"decimals","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"decreaseAllowance","inputs":[{"type":"address","name":"spender","internalType":"address"},{"type":"uint256","name":"subtractedValue","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"deliver","inputs":[{"type":"uint256","name":"tAmount","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"excludeFromFee","inputs":[{"type":"address","name":"account","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"excludeFromReward","inputs":[{"type":"address","name":"account","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"includeInReward","inputs":[{"type":"address","name":"account","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"increaseAllowance","inputs":[{"type":"address","name":"spender","internalType":"address"},{"type":"uint256","name":"addedValue","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"isExcludedFromFee","inputs":[{"type":"address","name":"account","internalType":"address"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"isExcludedFromReward","inputs":[{"type":"address","name":"account","internalType":"address"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"string","name":"","internalType":"string"}],"name":"name","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"owner","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"reflectionFromToken","inputs":[{"type":"uint256","name":"tAmount","internalType":"uint256"},{"type":"bool","name":"deductTransferFee","internalType":"bool"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"renounceOwnership","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setCharityFeePercent","inputs":[{"type":"uint256","name":"charityFeeBps","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setLiquidityFeePercent","inputs":[{"type":"uint256","name":"liquidityFeeBps","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setSwapBackSettings","inputs":[{"type":"uint256","name":"_amount","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setTaxFeePercent","inputs":[{"type":"uint256","name":"taxFeeBps","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"swapAndLiquifyEnabled","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"string","name":"","internalType":"string"}],"name":"symbol","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"tokenFromReflection","inputs":[{"type":"uint256","name":"rAmount","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"totalFees","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"totalSupply","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"transfer","inputs":[{"type":"address","name":"recipient","internalType":"address"},{"type":"uint256","name":"amount","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"transferFrom","inputs":[{"type":"address","name":"sender","internalType":"address"},{"type":"address","name":"recipient","internalType":"address"},{"type":"uint256","name":"amount","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"transferOwnership","inputs":[{"type":"address","name":"newOwner","internalType":"address"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"uniswapV2Pair","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"contract IUniswapV2Router02"}],"name":"uniswapV2Router","inputs":[]},{"type":"receive","stateMutability":"payable"}]
Contract Creation Code
0x608060405260405162002ee138038062002ee1833981016040819052620000269162000764565b620000313362000559565b6001600160a01b038616620000d15761ffff831615620000d15760405162461bcd60e51b815260206004820152604a60248201527f43616e742073657420626f74682063686172697479206164647265737320746f60448201527f2061646472657373203020616e6420636861726974792070657263656e74206d60648201526906f7265207468616e20360b41b608482015260a4015b60405180910390fd5b6109c483620000e186886200087d565b620000ed91906200087d565b61ffff161115620001415760405162461bcd60e51b815260206004820152601560248201527f546f74616c20666565206973206f7665722032352500000000000000000000006044820152606401620000c8565b89516200015690600a9060208d0190620005be565b5088516200016c90600b9060208c0190620005be565b50600c805460ff1916600917905560078890556200018d8860001962000914565b6200019b90600019620008bd565b60085561ffff858116600d819055600e55848116600f819055601055601580546001600160a01b0319166001600160a01b03891617905583166011819055601255620001f6886103e8620005a9602090811b6200116b17901c565b6016556015805460ff60a81b1916600160a81b17905560085460016000620002266000546001600160a01b031690565b6001600160a01b03166001600160a01b03168152602001908152602001600020819055506000879050806001600160a01b031663c45a01556040518163ffffffff1660e01b815260040160206040518083038186803b1580156200028957600080fd5b505afa1580156200029e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620002c4919062000747565b6001600160a01b031663c9c6539630836001600160a01b031663ad5c46486040518163ffffffff1660e01b815260040160206040518083038186803b1580156200030d57600080fd5b505afa15801562000322573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062000348919062000747565b6040516001600160e01b031960e085901b1681526001600160a01b03928316600482015291166024820152604401602060405180830381600087803b1580156200039157600080fd5b505af1158015620003a6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620003cc919062000747565b601480546001600160a01b03199081166001600160a01b039384161790915560138054909116918316919091179055600160046000620004146000546001600160a01b031690565b6001600160a01b0316815260208082019290925260409081016000908120805494151560ff199586161790553081526004909252902080549091166001179055620004676000546001600160a01b031690565b6001600160a01b031660006001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef600754604051620004af91815260200190565b60405180910390a330620004cb6000546001600160a01b031690565b6001600160a01b03167f56358b41df5fa59f5639228f0930994cbdde383c8a8fd74e06c04e1deebe35626002806040516200050892919062000850565b60405180910390a36040516001600160a01b0384169083156108fc029084906000818181858888f1935050505015801562000547573d6000803e3d6000fd5b5050505050505050505050506200096d565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6000620005b78284620008a6565b9392505050565b828054620005cc90620008d7565b90600052602060002090601f016020900481019282620005f057600085556200063b565b82601f106200060b57805160ff19168380011785556200063b565b828001600101855582156200063b579182015b828111156200063b5782518255916020019190600101906200061e565b50620006499291506200064d565b5090565b5b808211156200064957600081556001016200064e565b80516001600160a01b03811681146200067c57600080fd5b919050565b600082601f83011262000692578081fd5b81516001600160401b0380821115620006af57620006af62000957565b604051601f8301601f19908116603f01168101908282118183101715620006da57620006da62000957565b81604052838152602092508683858801011115620006f6578485fd5b8491505b83821015620007195785820183015181830184015290820190620006fa565b838211156200072a57848385830101525b9695505050505050565b805161ffff811681146200067c57600080fd5b60006020828403121562000759578081fd5b620005b78262000664565b6000806000806000806000806000806101408b8d03121562000784578586fd5b8a516001600160401b03808211156200079b578788fd5b620007a98e838f0162000681565b9b5060208d0151915080821115620007bf578788fd5b50620007ce8d828e0162000681565b99505060408b01519750620007e660608c0162000664565b9650620007f660808c0162000664565b95506200080660a08c0162000734565b94506200081660c08c0162000734565b93506200082660e08c0162000734565b9250620008376101008c0162000664565b91506101208b015190509295989b9194979a5092959850565b60408101600884106200087357634e487b7160e01b600052602160045260246000fd5b9281526020015290565b600061ffff8083168185168083038211156200089d576200089d6200092b565b01949350505050565b600082620008b857620008b862000941565b500490565b600082821015620008d257620008d26200092b565b500390565b600181811c90821680620008ec57607f821691505b602082108114156200090e57634e487b7160e01b600052602260045260246000fd5b50919050565b60008262000926576200092662000941565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b612564806200097d6000396000f3fe6080604052600436106102135760003560e01c80634a74bb02116101185780638ee88c53116100a0578063af41063b1161006f578063af41063b14610627578063bc063e1a14610647578063dd62ed3e1461065d578063f2fde38b146106a3578063ffa1ad74146106c357600080fd5b80638ee88c53146105b257806395d89b41146105d2578063a457c2d7146105e7578063a9059cbb1461060757600080fd5b806370a08231116100e757806370a0823114610506578063715018a614610526578063796431d01461053b57806388f820201461055b5780638da5cb5b1461059457600080fd5b80634a74bb021461047657806352390c02146104975780635342acb4146104b75780636bc87c3a146104f057600080fd5b8063313ce5671161019b5780633bd5d1731161016a5780633bd5d173146103e057806340f8007a14610400578063437823ec146104165780634549b0391461043657806349bd5a5e1461045657600080fd5b8063313ce567146103685780633685d4191461038a57806339509351146103aa5780633b124fe7146103ca57600080fd5b80631694505e116101e25780631694505e146102bb57806318160ddd146102f357806319a8ac9e1461030857806323b872dd146103285780632d8381191461034857600080fd5b8063061c82d01461021f57806306fdde0314610241578063095ea7b31461026c57806313114a9d1461029c57600080fd5b3661021a57005b600080fd5b34801561022b57600080fd5b5061023f61023a36600461228d565b6106d8565b005b34801561024d57600080fd5b50610256610778565b60405161026391906122fa565b60405180910390f35b34801561027857600080fd5b5061028c610287366004612262565b61080a565b6040519015158152602001610263565b3480156102a857600080fd5b506009545b604051908152602001610263565b3480156102c757600080fd5b506013546102db906001600160a01b031681565b6040516001600160a01b039091168152602001610263565b3480156102ff57600080fd5b506007546102ad565b34801561031457600080fd5b506015546102db906001600160a01b031681565b34801561033457600080fd5b5061028c610343366004612222565b610821565b34801561035457600080fd5b506102ad61036336600461228d565b61088a565b34801561037457600080fd5b50600c5460405160ff9091168152602001610263565b34801561039657600080fd5b5061023f6103a53660046121b2565b61090e565b3480156103b657600080fd5b5061028c6103c5366004612262565b610afd565b3480156103d657600080fd5b506102ad600d5481565b3480156103ec57600080fd5b5061023f6103fb36600461228d565b610b33565b34801561040c57600080fd5b506102ad60115481565b34801561042257600080fd5b5061023f6104313660046121b2565b610c1f565b34801561044257600080fd5b506102ad6104513660046122a5565b610c6d565b34801561046257600080fd5b506014546102db906001600160a01b031681565b34801561048257600080fd5b5060155461028c90600160a81b900460ff1681565b3480156104a357600080fd5b5061023f6104b23660046121b2565b610cfc565b3480156104c357600080fd5b5061028c6104d23660046121b2565b6001600160a01b031660009081526004602052604090205460ff1690565b3480156104fc57600080fd5b506102ad600f5481565b34801561051257600080fd5b506102ad6105213660046121b2565b610e4f565b34801561053257600080fd5b5061023f610eae565b34801561054757600080fd5b5061023f61055636600461228d565b610ee4565b34801561056757600080fd5b5061028c6105763660046121b2565b6001600160a01b031660009081526005602052604090205460ff1690565b3480156105a057600080fd5b506000546001600160a01b03166102db565b3480156105be57600080fd5b5061023f6105cd36600461228d565b610fde565b3480156105de57600080fd5b50610256611023565b3480156105f357600080fd5b5061028c610602366004612262565b611032565b34801561061357600080fd5b5061028c610622366004612262565b611081565b34801561063357600080fd5b5061023f61064236600461228d565b61108e565b34801561065357600080fd5b506102ad6109c481565b34801561066957600080fd5b506102ad6106783660046121ea565b6001600160a01b03918216600090815260036020908152604080832093909416825291909152205490565b3480156106af57600080fd5b5061023f6106be3660046121b2565b6110d3565b3480156106cf57600080fd5b506102ad600281565b6000546001600160a01b0316331461070b5760405162461bcd60e51b81526004016107029061234d565b60405180910390fd5b600d819055601154600f546109c4919061072590846123f2565b61072f91906123f2565b11156107755760405162461bcd60e51b8152602060048201526015602482015274546f74616c20666565206973206f7665722032352560581b6044820152606401610702565b50565b6060600a805461078790612460565b80601f01602080910402602001604051908101604052809291908181526020018280546107b390612460565b80156108005780601f106107d557610100808354040283529160200191610800565b820191906000526020600020905b8154815290600101906020018083116107e357829003601f168201915b5050505050905090565b6000610817338484611177565b5060015b92915050565b600061082e84848461129c565b610880843361087b856040518060600160405280602881526020016124e2602891396001600160a01b038a1660009081526003602090815260408083203384529091529020549190611491565b611177565b5060019392505050565b60006008548211156108f15760405162461bcd60e51b815260206004820152602a60248201527f416d6f756e74206d757374206265206c657373207468616e20746f74616c207260448201526965666c656374696f6e7360b01b6064820152608401610702565b60006108fb6114bd565b9050610907838261116b565b9392505050565b6000546001600160a01b031633146109385760405162461bcd60e51b81526004016107029061234d565b6001600160a01b03811660009081526005602052604090205460ff166109a05760405162461bcd60e51b815260206004820152601b60248201527f4163636f756e7420697320616c7265616479206578636c7564656400000000006044820152606401610702565b60005b600654811015610af957816001600160a01b0316600682815481106109d857634e487b7160e01b600052603260045260246000fd5b6000918252602090912001546001600160a01b03161415610ae75760068054610a0390600190612449565b81548110610a2157634e487b7160e01b600052603260045260246000fd5b600091825260209091200154600680546001600160a01b039092169183908110610a5b57634e487b7160e01b600052603260045260246000fd5b600091825260208083209190910180546001600160a01b0319166001600160a01b039485161790559184168152600282526040808220829055600590925220805460ff191690556006805480610ac157634e487b7160e01b600052603160045260246000fd5b600082815260209020810160001990810180546001600160a01b03191690550190555050565b80610af18161249b565b9150506109a3565b5050565b3360008181526003602090815260408083206001600160a01b0387168452909152812054909161081791859061087b90866114e0565b3360008181526005602052604090205460ff1615610ba85760405162461bcd60e51b815260206004820152602c60248201527f4578636c75646564206164647265737365732063616e6e6f742063616c6c207460448201526b3434b990333ab731ba34b7b760a11b6064820152608401610702565b6000610bb3836114ec565b5050506001600160a01b038616600090815260016020526040902054939450610be193925084915050611547565b6001600160a01b038316600090815260016020526040902055600854610c079082611547565b600855600954610c1790846114e0565b600955505050565b6000546001600160a01b03163314610c495760405162461bcd60e51b81526004016107029061234d565b6001600160a01b03166000908152600460205260409020805460ff19166001179055565b6000600754831115610cc15760405162461bcd60e51b815260206004820152601f60248201527f416d6f756e74206d757374206265206c657373207468616e20737570706c79006044820152606401610702565b81610ce1576000610cd1846114ec565b5094965061081b95505050505050565b6000610cec846114ec565b5093965061081b95505050505050565b6000546001600160a01b03163314610d265760405162461bcd60e51b81526004016107029061234d565b6001600160a01b03811660009081526005602052604090205460ff1615610d8f5760405162461bcd60e51b815260206004820152601b60248201527f4163636f756e7420697320616c7265616479206578636c7564656400000000006044820152606401610702565b6001600160a01b03811660009081526001602052604090205415610de9576001600160a01b038116600090815260016020526040902054610dcf9061088a565b6001600160a01b0382166000908152600260205260409020555b6001600160a01b03166000818152600560205260408120805460ff191660019081179091556006805491820181559091527ff652222313e28459528d920b65115c16c04f3efc82aaedc97be59f3f377c0d3f0180546001600160a01b0319169091179055565b6001600160a01b03811660009081526005602052604081205460ff1615610e8c57506001600160a01b031660009081526002602052604090205490565b6001600160a01b03821660009081526001602052604090205461081b9061088a565b6000546001600160a01b03163314610ed85760405162461bcd60e51b81526004016107029061234d565b610ee26000611553565b565b6000546001600160a01b03163314610f0e5760405162461bcd60e51b81526004016107029061234d565b610f2e612710610f286005610f2260075490565b906115a3565b9061116b565b811015610fa35760405162461bcd60e51b815260206004820152603860248201527f537761706261636b20616d6f756e742073686f756c64206265206174206c656160448201527f737420302e303525206f6620746f74616c20737570706c7900000000000000006064820152608401610702565b60168190556040518181527ff7edd1a72d399eb95c56c07c5a26f00a9096735269c96c75caa8fc4e15bcd5d29060200160405180910390a150565b6000546001600160a01b031633146110085760405162461bcd60e51b81526004016107029061234d565b600f819055601154600d546109c491906107259084906123f2565b6060600b805461078790612460565b6000610817338461087b8560405180606001604052806025815260200161250a602591393360009081526003602090815260408083206001600160a01b038d1684529091529020549190611491565b600061081733848461129c565b6000546001600160a01b031633146110b85760405162461bcd60e51b81526004016107029061234d565b6011819055600f54600d546109c491839161072591906123f2565b6000546001600160a01b031633146110fd5760405162461bcd60e51b81526004016107029061234d565b6001600160a01b0381166111625760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610702565b61077581611553565b6000610907828461240a565b6001600160a01b0383166111d95760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b6064820152608401610702565b6001600160a01b03821661123a5760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b6064820152608401610702565b6001600160a01b0383811660008181526003602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b6001600160a01b0383166113005760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b6064820152608401610702565b6001600160a01b0382166113625760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b6064820152608401610702565b600081116113c45760405162461bcd60e51b815260206004820152602960248201527f5472616e7366657220616d6f756e74206d7573742062652067726561746572206044820152687468616e207a65726f60b81b6064820152608401610702565b60006113cf30610e4f565b601654909150811080159081906113f05750601554600160a01b900460ff16155b801561140a57506014546001600160a01b03868116911614155b801561141f5750601554600160a81b900460ff165b15611432576016549150611432826115af565b6001600160a01b03851660009081526004602052604090205460019060ff168061147457506001600160a01b03851660009081526004602052604090205460ff165b1561147d575060005b61148986868684611656565b505050505050565b600081848411156114b55760405162461bcd60e51b815260040161070291906122fa565b505050900390565b60008060006114ca6117f6565b90925090506114d9828261116b565b9250505090565b600061090782846123f2565b60008060008060008060008060008060006115068c6119b0565b935093509350935060008060006115278f8787876115226114bd565b611a05565b919f509d509b509599509397509195509350505050919395979092949650565b60006109078284612449565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6000610907828461242a565b6015805460ff60a01b1916600160a01b17905560006115cf82600261116b565b905060006115dd8383611547565b9050476115e983611a67565b60006115f54783611547565b90506116018382611be4565b60408051858152602081018390529081018490527f17bbfb9a6069321b6ded73bd96327c9e6b7212a5cd51ff219cd61370acafb5619060600160405180910390a150506015805460ff60a01b19169055505050565b8061168057611680600d8054600e55600f8054601055601180546012556000928390559082905555565b6001600160a01b03841660009081526005602052604090205460ff1680156116c157506001600160a01b03831660009081526005602052604090205460ff16155b156116d6576116d1848484611ca5565b6117d4565b6001600160a01b03841660009081526005602052604090205460ff1615801561171757506001600160a01b03831660009081526005602052604090205460ff165b15611727576116d1848484611deb565b6001600160a01b03841660009081526005602052604090205460ff1615801561176957506001600160a01b03831660009081526005602052604090205460ff16155b15611779576116d1848484611eaa565b6001600160a01b03841660009081526005602052604090205460ff1680156117b957506001600160a01b03831660009081526005602052604090205460ff165b156117c9576116d1848484611f04565b6117d4848484611eaa565b806117f0576117f0600e54600d55601054600f55601254601155565b50505050565b6008546007546000918291825b6006548110156119805782600160006006848154811061183357634e487b7160e01b600052603260045260246000fd5b60009182526020808320909101546001600160a01b0316835282019290925260400190205411806118ac575081600260006006848154811061188557634e487b7160e01b600052603260045260246000fd5b60009182526020808320909101546001600160a01b03168352820192909252604001902054115b156118c257600854600754945094505050509091565b61191660016000600684815481106118ea57634e487b7160e01b600052603260045260246000fd5b60009182526020808320909101546001600160a01b031683528201929092526040019020548490611547565b925061196c600260006006848154811061194057634e487b7160e01b600052603260045260246000fd5b60009182526020808320909101546001600160a01b031683528201929092526040019020548390611547565b9150806119788161249b565b915050611803565b506007546008546119909161116b565b8210156119a7576008546007549350935050509091565b90939092509050565b60008060008060006119c186611f8d565b905060006119ce87611faa565b905060006119db88611fc7565b905060006119f5826119ef85818d89611547565b90611547565b9993985091965094509092505050565b6000808080611a1489866115a3565b90506000611a2289876115a3565b90506000611a3089886115a3565b90506000611a3e89896115a3565b90506000611a52826119ef85818989611547565b949d949c50929a509298505050505050505050565b6040805160028082526060820183526000926020830190803683370190505090503081600081518110611aaa57634e487b7160e01b600052603260045260246000fd5b6001600160a01b03928316602091820292909201810191909152601354604080516315ab88c960e31b81529051919093169263ad5c4648926004808301939192829003018186803b158015611afe57600080fd5b505afa158015611b12573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611b3691906121ce565b81600181518110611b5757634e487b7160e01b600052603260045260246000fd5b6001600160a01b039283166020918202929092010152601354611b7d9130911684611177565b60135460405163791ac94760e01b81526001600160a01b039091169063791ac94790611bb6908590600090869030904290600401612382565b600060405180830381600087803b158015611bd057600080fd5b505af1158015611489573d6000803e3d6000fd5b601354611bfc9030906001600160a01b031684611177565b60135460405163f305d71960e01b815230600482015260248101849052600060448201819052606482015261dead60848201524260a48201526001600160a01b039091169063f305d71990839060c4016060604051808303818588803b158015611c6557600080fd5b505af1158015611c79573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190611c9e91906122cd565b5050505050565b6000806000806000806000611cb9886114ec565b9650965096509650965096509650611cff88600260008d6001600160a01b03166001600160a01b031681526020019081526020016000205461154790919063ffffffff16565b6001600160a01b038b16600090815260026020908152604080832093909355600190522054611d2e9088611547565b6001600160a01b03808c1660009081526001602052604080822093909355908b1681522054611d5d90876114e0565b6001600160a01b038a16600090815260016020526040902055611d7f82611ffd565b611d8881612086565b611d92858461218e565b886001600160a01b03168a6001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef86604051611dd791815260200190565b60405180910390a350505050505050505050565b6000806000806000806000611dff886114ec565b9650965096509650965096509650611e4587600160008d6001600160a01b03166001600160a01b031681526020019081526020016000205461154790919063ffffffff16565b6001600160a01b03808c16600090815260016020908152604080832094909455918c16815260029091522054611e7b90856114e0565b6001600160a01b038a16600090815260026020908152604080832093909355600190522054611d5d90876114e0565b6000806000806000806000611ebe886114ec565b9650965096509650965096509650611d2e87600160008d6001600160a01b03166001600160a01b031681526020019081526020016000205461154790919063ffffffff16565b6000806000806000806000611f18886114ec565b9650965096509650965096509650611f5e88600260008d6001600160a01b03166001600160a01b031681526020019081526020016000205461154790919063ffffffff16565b6001600160a01b038b16600090815260026020908152604080832093909355600190522054611e459088611547565b600061081b612710610f28600d54856115a390919063ffffffff16565b600061081b612710610f28600f54856115a390919063ffffffff16565b6015546000906001600160a01b0316611fe257506000919050565b61081b612710610f28601154856115a390919063ffffffff16565b60006120076114bd565b9050600061201583836115a3565b3060009081526001602052604090205490915061203290826114e0565b3060009081526001602090815260408083209390935560059052205460ff1615612081573060009081526002602052604090205461207090846114e0565b306000908152600260205260409020555b505050565b80156107755760006120966114bd565b905060006120a483836115a3565b6015546001600160a01b03166000908152600160205260409020549091506120cc90826114e0565b601580546001600160a01b03908116600090815260016020908152604080832095909555925490911681526005909152205460ff1615612147576015546001600160a01b031660009081526002602052604090205461212b90846114e0565b6015546001600160a01b03166000908152600260205260409020555b6015546001600160a01b0316336001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8560405161128f91815260200190565b60085461219b9083611547565b6008556009546121ab90826114e0565b6009555050565b6000602082840312156121c3578081fd5b8135610907816124cc565b6000602082840312156121df578081fd5b8151610907816124cc565b600080604083850312156121fc578081fd5b8235612207816124cc565b91506020830135612217816124cc565b809150509250929050565b600080600060608486031215612236578081fd5b8335612241816124cc565b92506020840135612251816124cc565b929592945050506040919091013590565b60008060408385031215612274578182fd5b823561227f816124cc565b946020939093013593505050565b60006020828403121561229e578081fd5b5035919050565b600080604083850312156122b7578182fd5b8235915060208301358015158114612217578182fd5b6000806000606084860312156122e1578283fd5b8351925060208401519150604084015190509250925092565b6000602080835283518082850152825b818110156123265785810183015185820160400152820161230a565b818111156123375783604083870101525b50601f01601f1916929092016040019392505050565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b600060a082018783526020878185015260a0604085015281875180845260c0860191508289019350845b818110156123d15784516001600160a01b0316835293830193918301916001016123ac565b50506001600160a01b03969096166060850152505050608001529392505050565b60008219821115612405576124056124b6565b500190565b60008261242557634e487b7160e01b81526012600452602481fd5b500490565b6000816000190483118215151615612444576124446124b6565b500290565b60008282101561245b5761245b6124b6565b500390565b600181811c9082168061247457607f821691505b6020821081141561249557634e487b7160e01b600052602260045260246000fd5b50919050565b60006000198214156124af576124af6124b6565b5060010190565b634e487b7160e01b600052601160045260246000fd5b6001600160a01b038116811461077557600080fdfe45524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa26469706673582212206b3cdcd747ccffde0f872c7b21c646b780b2fab45f8bd8c6f4b73570b4a54b6564736f6c6343000804003300000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000180000000000000000000000000000000000000000000000000016345785d8a0000000000000000000000000000af5e33cb31a3454c950bee39ed1c76fd65b394cf0000000000000000000000000000000000000000000000000000000000000369000000000000000000000000000000000000000000000000000000000000003200000000000000000000000000000000000000000000000000000000000000c800000000000000000000000000000000000000000000000000000000000000640000000000000000000000004b04213c2774f77e60702880654206b116d00508000000000000000000000000000000000000000000000000002386f26fc1000000000000000000000000000000000000000000000000000000000000000000064d41524b4554000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000044d41524b00000000000000000000000000000000000000000000000000000000
Deployed ByteCode
0x6080604052600436106102135760003560e01c80634a74bb02116101185780638ee88c53116100a0578063af41063b1161006f578063af41063b14610627578063bc063e1a14610647578063dd62ed3e1461065d578063f2fde38b146106a3578063ffa1ad74146106c357600080fd5b80638ee88c53146105b257806395d89b41146105d2578063a457c2d7146105e7578063a9059cbb1461060757600080fd5b806370a08231116100e757806370a0823114610506578063715018a614610526578063796431d01461053b57806388f820201461055b5780638da5cb5b1461059457600080fd5b80634a74bb021461047657806352390c02146104975780635342acb4146104b75780636bc87c3a146104f057600080fd5b8063313ce5671161019b5780633bd5d1731161016a5780633bd5d173146103e057806340f8007a14610400578063437823ec146104165780634549b0391461043657806349bd5a5e1461045657600080fd5b8063313ce567146103685780633685d4191461038a57806339509351146103aa5780633b124fe7146103ca57600080fd5b80631694505e116101e25780631694505e146102bb57806318160ddd146102f357806319a8ac9e1461030857806323b872dd146103285780632d8381191461034857600080fd5b8063061c82d01461021f57806306fdde0314610241578063095ea7b31461026c57806313114a9d1461029c57600080fd5b3661021a57005b600080fd5b34801561022b57600080fd5b5061023f61023a36600461228d565b6106d8565b005b34801561024d57600080fd5b50610256610778565b60405161026391906122fa565b60405180910390f35b34801561027857600080fd5b5061028c610287366004612262565b61080a565b6040519015158152602001610263565b3480156102a857600080fd5b506009545b604051908152602001610263565b3480156102c757600080fd5b506013546102db906001600160a01b031681565b6040516001600160a01b039091168152602001610263565b3480156102ff57600080fd5b506007546102ad565b34801561031457600080fd5b506015546102db906001600160a01b031681565b34801561033457600080fd5b5061028c610343366004612222565b610821565b34801561035457600080fd5b506102ad61036336600461228d565b61088a565b34801561037457600080fd5b50600c5460405160ff9091168152602001610263565b34801561039657600080fd5b5061023f6103a53660046121b2565b61090e565b3480156103b657600080fd5b5061028c6103c5366004612262565b610afd565b3480156103d657600080fd5b506102ad600d5481565b3480156103ec57600080fd5b5061023f6103fb36600461228d565b610b33565b34801561040c57600080fd5b506102ad60115481565b34801561042257600080fd5b5061023f6104313660046121b2565b610c1f565b34801561044257600080fd5b506102ad6104513660046122a5565b610c6d565b34801561046257600080fd5b506014546102db906001600160a01b031681565b34801561048257600080fd5b5060155461028c90600160a81b900460ff1681565b3480156104a357600080fd5b5061023f6104b23660046121b2565b610cfc565b3480156104c357600080fd5b5061028c6104d23660046121b2565b6001600160a01b031660009081526004602052604090205460ff1690565b3480156104fc57600080fd5b506102ad600f5481565b34801561051257600080fd5b506102ad6105213660046121b2565b610e4f565b34801561053257600080fd5b5061023f610eae565b34801561054757600080fd5b5061023f61055636600461228d565b610ee4565b34801561056757600080fd5b5061028c6105763660046121b2565b6001600160a01b031660009081526005602052604090205460ff1690565b3480156105a057600080fd5b506000546001600160a01b03166102db565b3480156105be57600080fd5b5061023f6105cd36600461228d565b610fde565b3480156105de57600080fd5b50610256611023565b3480156105f357600080fd5b5061028c610602366004612262565b611032565b34801561061357600080fd5b5061028c610622366004612262565b611081565b34801561063357600080fd5b5061023f61064236600461228d565b61108e565b34801561065357600080fd5b506102ad6109c481565b34801561066957600080fd5b506102ad6106783660046121ea565b6001600160a01b03918216600090815260036020908152604080832093909416825291909152205490565b3480156106af57600080fd5b5061023f6106be3660046121b2565b6110d3565b3480156106cf57600080fd5b506102ad600281565b6000546001600160a01b0316331461070b5760405162461bcd60e51b81526004016107029061234d565b60405180910390fd5b600d819055601154600f546109c4919061072590846123f2565b61072f91906123f2565b11156107755760405162461bcd60e51b8152602060048201526015602482015274546f74616c20666565206973206f7665722032352560581b6044820152606401610702565b50565b6060600a805461078790612460565b80601f01602080910402602001604051908101604052809291908181526020018280546107b390612460565b80156108005780601f106107d557610100808354040283529160200191610800565b820191906000526020600020905b8154815290600101906020018083116107e357829003601f168201915b5050505050905090565b6000610817338484611177565b5060015b92915050565b600061082e84848461129c565b610880843361087b856040518060600160405280602881526020016124e2602891396001600160a01b038a1660009081526003602090815260408083203384529091529020549190611491565b611177565b5060019392505050565b60006008548211156108f15760405162461bcd60e51b815260206004820152602a60248201527f416d6f756e74206d757374206265206c657373207468616e20746f74616c207260448201526965666c656374696f6e7360b01b6064820152608401610702565b60006108fb6114bd565b9050610907838261116b565b9392505050565b6000546001600160a01b031633146109385760405162461bcd60e51b81526004016107029061234d565b6001600160a01b03811660009081526005602052604090205460ff166109a05760405162461bcd60e51b815260206004820152601b60248201527f4163636f756e7420697320616c7265616479206578636c7564656400000000006044820152606401610702565b60005b600654811015610af957816001600160a01b0316600682815481106109d857634e487b7160e01b600052603260045260246000fd5b6000918252602090912001546001600160a01b03161415610ae75760068054610a0390600190612449565b81548110610a2157634e487b7160e01b600052603260045260246000fd5b600091825260209091200154600680546001600160a01b039092169183908110610a5b57634e487b7160e01b600052603260045260246000fd5b600091825260208083209190910180546001600160a01b0319166001600160a01b039485161790559184168152600282526040808220829055600590925220805460ff191690556006805480610ac157634e487b7160e01b600052603160045260246000fd5b600082815260209020810160001990810180546001600160a01b03191690550190555050565b80610af18161249b565b9150506109a3565b5050565b3360008181526003602090815260408083206001600160a01b0387168452909152812054909161081791859061087b90866114e0565b3360008181526005602052604090205460ff1615610ba85760405162461bcd60e51b815260206004820152602c60248201527f4578636c75646564206164647265737365732063616e6e6f742063616c6c207460448201526b3434b990333ab731ba34b7b760a11b6064820152608401610702565b6000610bb3836114ec565b5050506001600160a01b038616600090815260016020526040902054939450610be193925084915050611547565b6001600160a01b038316600090815260016020526040902055600854610c079082611547565b600855600954610c1790846114e0565b600955505050565b6000546001600160a01b03163314610c495760405162461bcd60e51b81526004016107029061234d565b6001600160a01b03166000908152600460205260409020805460ff19166001179055565b6000600754831115610cc15760405162461bcd60e51b815260206004820152601f60248201527f416d6f756e74206d757374206265206c657373207468616e20737570706c79006044820152606401610702565b81610ce1576000610cd1846114ec565b5094965061081b95505050505050565b6000610cec846114ec565b5093965061081b95505050505050565b6000546001600160a01b03163314610d265760405162461bcd60e51b81526004016107029061234d565b6001600160a01b03811660009081526005602052604090205460ff1615610d8f5760405162461bcd60e51b815260206004820152601b60248201527f4163636f756e7420697320616c7265616479206578636c7564656400000000006044820152606401610702565b6001600160a01b03811660009081526001602052604090205415610de9576001600160a01b038116600090815260016020526040902054610dcf9061088a565b6001600160a01b0382166000908152600260205260409020555b6001600160a01b03166000818152600560205260408120805460ff191660019081179091556006805491820181559091527ff652222313e28459528d920b65115c16c04f3efc82aaedc97be59f3f377c0d3f0180546001600160a01b0319169091179055565b6001600160a01b03811660009081526005602052604081205460ff1615610e8c57506001600160a01b031660009081526002602052604090205490565b6001600160a01b03821660009081526001602052604090205461081b9061088a565b6000546001600160a01b03163314610ed85760405162461bcd60e51b81526004016107029061234d565b610ee26000611553565b565b6000546001600160a01b03163314610f0e5760405162461bcd60e51b81526004016107029061234d565b610f2e612710610f286005610f2260075490565b906115a3565b9061116b565b811015610fa35760405162461bcd60e51b815260206004820152603860248201527f537761706261636b20616d6f756e742073686f756c64206265206174206c656160448201527f737420302e303525206f6620746f74616c20737570706c7900000000000000006064820152608401610702565b60168190556040518181527ff7edd1a72d399eb95c56c07c5a26f00a9096735269c96c75caa8fc4e15bcd5d29060200160405180910390a150565b6000546001600160a01b031633146110085760405162461bcd60e51b81526004016107029061234d565b600f819055601154600d546109c491906107259084906123f2565b6060600b805461078790612460565b6000610817338461087b8560405180606001604052806025815260200161250a602591393360009081526003602090815260408083206001600160a01b038d1684529091529020549190611491565b600061081733848461129c565b6000546001600160a01b031633146110b85760405162461bcd60e51b81526004016107029061234d565b6011819055600f54600d546109c491839161072591906123f2565b6000546001600160a01b031633146110fd5760405162461bcd60e51b81526004016107029061234d565b6001600160a01b0381166111625760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610702565b61077581611553565b6000610907828461240a565b6001600160a01b0383166111d95760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b6064820152608401610702565b6001600160a01b03821661123a5760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b6064820152608401610702565b6001600160a01b0383811660008181526003602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b6001600160a01b0383166113005760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b6064820152608401610702565b6001600160a01b0382166113625760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b6064820152608401610702565b600081116113c45760405162461bcd60e51b815260206004820152602960248201527f5472616e7366657220616d6f756e74206d7573742062652067726561746572206044820152687468616e207a65726f60b81b6064820152608401610702565b60006113cf30610e4f565b601654909150811080159081906113f05750601554600160a01b900460ff16155b801561140a57506014546001600160a01b03868116911614155b801561141f5750601554600160a81b900460ff165b15611432576016549150611432826115af565b6001600160a01b03851660009081526004602052604090205460019060ff168061147457506001600160a01b03851660009081526004602052604090205460ff165b1561147d575060005b61148986868684611656565b505050505050565b600081848411156114b55760405162461bcd60e51b815260040161070291906122fa565b505050900390565b60008060006114ca6117f6565b90925090506114d9828261116b565b9250505090565b600061090782846123f2565b60008060008060008060008060008060006115068c6119b0565b935093509350935060008060006115278f8787876115226114bd565b611a05565b919f509d509b509599509397509195509350505050919395979092949650565b60006109078284612449565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6000610907828461242a565b6015805460ff60a01b1916600160a01b17905560006115cf82600261116b565b905060006115dd8383611547565b9050476115e983611a67565b60006115f54783611547565b90506116018382611be4565b60408051858152602081018390529081018490527f17bbfb9a6069321b6ded73bd96327c9e6b7212a5cd51ff219cd61370acafb5619060600160405180910390a150506015805460ff60a01b19169055505050565b8061168057611680600d8054600e55600f8054601055601180546012556000928390559082905555565b6001600160a01b03841660009081526005602052604090205460ff1680156116c157506001600160a01b03831660009081526005602052604090205460ff16155b156116d6576116d1848484611ca5565b6117d4565b6001600160a01b03841660009081526005602052604090205460ff1615801561171757506001600160a01b03831660009081526005602052604090205460ff165b15611727576116d1848484611deb565b6001600160a01b03841660009081526005602052604090205460ff1615801561176957506001600160a01b03831660009081526005602052604090205460ff16155b15611779576116d1848484611eaa565b6001600160a01b03841660009081526005602052604090205460ff1680156117b957506001600160a01b03831660009081526005602052604090205460ff165b156117c9576116d1848484611f04565b6117d4848484611eaa565b806117f0576117f0600e54600d55601054600f55601254601155565b50505050565b6008546007546000918291825b6006548110156119805782600160006006848154811061183357634e487b7160e01b600052603260045260246000fd5b60009182526020808320909101546001600160a01b0316835282019290925260400190205411806118ac575081600260006006848154811061188557634e487b7160e01b600052603260045260246000fd5b60009182526020808320909101546001600160a01b03168352820192909252604001902054115b156118c257600854600754945094505050509091565b61191660016000600684815481106118ea57634e487b7160e01b600052603260045260246000fd5b60009182526020808320909101546001600160a01b031683528201929092526040019020548490611547565b925061196c600260006006848154811061194057634e487b7160e01b600052603260045260246000fd5b60009182526020808320909101546001600160a01b031683528201929092526040019020548390611547565b9150806119788161249b565b915050611803565b506007546008546119909161116b565b8210156119a7576008546007549350935050509091565b90939092509050565b60008060008060006119c186611f8d565b905060006119ce87611faa565b905060006119db88611fc7565b905060006119f5826119ef85818d89611547565b90611547565b9993985091965094509092505050565b6000808080611a1489866115a3565b90506000611a2289876115a3565b90506000611a3089886115a3565b90506000611a3e89896115a3565b90506000611a52826119ef85818989611547565b949d949c50929a509298505050505050505050565b6040805160028082526060820183526000926020830190803683370190505090503081600081518110611aaa57634e487b7160e01b600052603260045260246000fd5b6001600160a01b03928316602091820292909201810191909152601354604080516315ab88c960e31b81529051919093169263ad5c4648926004808301939192829003018186803b158015611afe57600080fd5b505afa158015611b12573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611b3691906121ce565b81600181518110611b5757634e487b7160e01b600052603260045260246000fd5b6001600160a01b039283166020918202929092010152601354611b7d9130911684611177565b60135460405163791ac94760e01b81526001600160a01b039091169063791ac94790611bb6908590600090869030904290600401612382565b600060405180830381600087803b158015611bd057600080fd5b505af1158015611489573d6000803e3d6000fd5b601354611bfc9030906001600160a01b031684611177565b60135460405163f305d71960e01b815230600482015260248101849052600060448201819052606482015261dead60848201524260a48201526001600160a01b039091169063f305d71990839060c4016060604051808303818588803b158015611c6557600080fd5b505af1158015611c79573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190611c9e91906122cd565b5050505050565b6000806000806000806000611cb9886114ec565b9650965096509650965096509650611cff88600260008d6001600160a01b03166001600160a01b031681526020019081526020016000205461154790919063ffffffff16565b6001600160a01b038b16600090815260026020908152604080832093909355600190522054611d2e9088611547565b6001600160a01b03808c1660009081526001602052604080822093909355908b1681522054611d5d90876114e0565b6001600160a01b038a16600090815260016020526040902055611d7f82611ffd565b611d8881612086565b611d92858461218e565b886001600160a01b03168a6001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef86604051611dd791815260200190565b60405180910390a350505050505050505050565b6000806000806000806000611dff886114ec565b9650965096509650965096509650611e4587600160008d6001600160a01b03166001600160a01b031681526020019081526020016000205461154790919063ffffffff16565b6001600160a01b03808c16600090815260016020908152604080832094909455918c16815260029091522054611e7b90856114e0565b6001600160a01b038a16600090815260026020908152604080832093909355600190522054611d5d90876114e0565b6000806000806000806000611ebe886114ec565b9650965096509650965096509650611d2e87600160008d6001600160a01b03166001600160a01b031681526020019081526020016000205461154790919063ffffffff16565b6000806000806000806000611f18886114ec565b9650965096509650965096509650611f5e88600260008d6001600160a01b03166001600160a01b031681526020019081526020016000205461154790919063ffffffff16565b6001600160a01b038b16600090815260026020908152604080832093909355600190522054611e459088611547565b600061081b612710610f28600d54856115a390919063ffffffff16565b600061081b612710610f28600f54856115a390919063ffffffff16565b6015546000906001600160a01b0316611fe257506000919050565b61081b612710610f28601154856115a390919063ffffffff16565b60006120076114bd565b9050600061201583836115a3565b3060009081526001602052604090205490915061203290826114e0565b3060009081526001602090815260408083209390935560059052205460ff1615612081573060009081526002602052604090205461207090846114e0565b306000908152600260205260409020555b505050565b80156107755760006120966114bd565b905060006120a483836115a3565b6015546001600160a01b03166000908152600160205260409020549091506120cc90826114e0565b601580546001600160a01b03908116600090815260016020908152604080832095909555925490911681526005909152205460ff1615612147576015546001600160a01b031660009081526002602052604090205461212b90846114e0565b6015546001600160a01b03166000908152600260205260409020555b6015546001600160a01b0316336001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8560405161128f91815260200190565b60085461219b9083611547565b6008556009546121ab90826114e0565b6009555050565b6000602082840312156121c3578081fd5b8135610907816124cc565b6000602082840312156121df578081fd5b8151610907816124cc565b600080604083850312156121fc578081fd5b8235612207816124cc565b91506020830135612217816124cc565b809150509250929050565b600080600060608486031215612236578081fd5b8335612241816124cc565b92506020840135612251816124cc565b929592945050506040919091013590565b60008060408385031215612274578182fd5b823561227f816124cc565b946020939093013593505050565b60006020828403121561229e578081fd5b5035919050565b600080604083850312156122b7578182fd5b8235915060208301358015158114612217578182fd5b6000806000606084860312156122e1578283fd5b8351925060208401519150604084015190509250925092565b6000602080835283518082850152825b818110156123265785810183015185820160400152820161230a565b818111156123375783604083870101525b50601f01601f1916929092016040019392505050565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b600060a082018783526020878185015260a0604085015281875180845260c0860191508289019350845b818110156123d15784516001600160a01b0316835293830193918301916001016123ac565b50506001600160a01b03969096166060850152505050608001529392505050565b60008219821115612405576124056124b6565b500190565b60008261242557634e487b7160e01b81526012600452602481fd5b500490565b6000816000190483118215151615612444576124446124b6565b500290565b60008282101561245b5761245b6124b6565b500390565b600181811c9082168061247457607f821691505b6020821081141561249557634e487b7160e01b600052602260045260246000fd5b50919050565b60006000198214156124af576124af6124b6565b5060010190565b634e487b7160e01b600052601160045260246000fd5b6001600160a01b038116811461077557600080fdfe45524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa26469706673582212206b3cdcd747ccffde0f872c7b21c646b780b2fab45f8bd8c6f4b73570b4a54b6564736f6c63430008040033