More Info
Private Name Tags
Latest 25 internal transactions (View All)
Advanced mode:
Parent Transaction Hash | Block |
From
|
To
|
|||
---|---|---|---|---|---|---|
14827466 | 992 days ago | 0.00136868 ETH | ||||
14827466 | 992 days ago | 0.00136868 ETH | ||||
14827466 | 992 days ago | 0.00273736 ETH | ||||
14806716 | 995 days ago | 0.14868552 ETH | ||||
14806716 | 995 days ago | 0.14868552 ETH | ||||
14806716 | 995 days ago | 0.29737104 ETH | ||||
14791866 | 998 days ago | 0.03539071 ETH | ||||
14791866 | 998 days ago | 0.03539071 ETH | ||||
14791866 | 998 days ago | 0.07078143 ETH | ||||
14789892 | 998 days ago | 0.03307171 ETH | ||||
14789892 | 998 days ago | 0.03307171 ETH | ||||
14789892 | 998 days ago | 0.06614342 ETH | ||||
14787328 | 998 days ago | 0.03562392 ETH | ||||
14787328 | 998 days ago | 0.03562392 ETH | ||||
14787328 | 998 days ago | 0.07124785 ETH | ||||
14787057 | 998 days ago | 0.03562392 ETH | ||||
14787057 | 998 days ago | 0.03562392 ETH | ||||
14787057 | 998 days ago | 0.07124785 ETH | ||||
14786178 | 999 days ago | 0.09377202 ETH | ||||
14786178 | 999 days ago | 0.09377202 ETH | ||||
14786178 | 999 days ago | 0.18754404 ETH | ||||
14785164 | 999 days ago | 0.03821055 ETH | ||||
14785164 | 999 days ago | 0.03821055 ETH | ||||
14785164 | 999 days ago | 0.0764211 ETH | ||||
14782473 | 999 days ago | 0.03031641 ETH |
Loading...
Loading
Contract Source Code Verified (Exact Match)
Contract Name:
CamelConverterProcessor
Compiler Version
v0.8.13+commit.abaa5c0e
Optimization Enabled:
Yes with 100 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: UNLICENSED pragma solidity ^0.8.2; import "@openzeppelin/contracts/access/Ownable.sol"; import "@uniswap/v2-periphery/contracts/interfaces/IUniswapV2Router02.sol"; import "@uniswap/v2-core/contracts/interfaces/IUniswapV2Factory.sol"; import "./CamelCoin.sol"; /// @title Camel Coin Converter /// @notice Collects and converts Camel Coins to ETH, sends them to team & marketing wallets. /// @author metacrypt.org contract CamelConverterProcessor is Ownable { CamelCoin public immutable camelCoin; IUniswapV2Router02 public immutable uniswapRouter; uint256 private minTokensToSwap; address payable public teamWallet; address payable public marketingWallet; uint256 public splitTeam = 1; uint256 public splitMarketing = 1; constructor( address _uniswapRouterAddress, address _camelCoinAddress, address payable _teamWallet, address payable _marketingWallet ) { uniswapRouter = IUniswapV2Router02(_uniswapRouterAddress); camelCoin = CamelCoin(_camelCoinAddress); setMinTokensToSwap(100 * (10**camelCoin.decimals())); setDistributors(_teamWallet, _marketingWallet); } function setMinTokensToSwap(uint256 _minTokensToSwap) public onlyOwner { minTokensToSwap = _minTokensToSwap; } function setDistributors(address payable _teamWallet, address payable _marketingWallet) public onlyOwner { teamWallet = _teamWallet; marketingWallet = _marketingWallet; } function setSplits(uint256 _splitTeam, uint256 _splitMarketing) public onlyOwner { splitTeam = _splitTeam; splitMarketing = _splitMarketing; } function autoSwap() internal returns (bool) { uint256 balanceToSwap = camelCoin.balanceOf(address(this)); if (balanceToSwap < minTokensToSwap) { return false; } // Let's approve the exact swap amount. camelCoin.approve(address(uniswapRouter), balanceToSwap); // Router Path Token -> WETH address[] memory path = new address[](2); path[0] = address(camelCoin); path[1] = uniswapRouter.WETH(); uniswapRouter.swapExactTokensForETHSupportingFeeOnTransferTokens( balanceToSwap, 0, // slippage is unavoidable path, address(this), block.timestamp + 1 ); return true; } function processFunds() external { autoSwap(); if (teamWallet != address(0) && marketingWallet != address(0) && address(this).balance > 0) { (bool sent1, ) = teamWallet.call{value: (address(this).balance * splitTeam) / (splitTeam + splitMarketing)}(""); (bool sent2, ) = marketingWallet.call{value: address(this).balance}(""); require(sent1 && sent2, "CamelConverterProcessor: Transfer Failed"); } } receive() external payable {} }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (access/Ownable.sol) pragma solidity ^0.8.0; import "../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() { _transferOwnership(_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 { _transferOwnership(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"); _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
pragma solidity >=0.6.2; import './IUniswapV2Router01.sol'; interface IUniswapV2Router02 is IUniswapV2Router01 { function removeLiquidityETHSupportingFeeOnTransferTokens( address token, uint liquidity, uint amountTokenMin, uint amountETHMin, address to, uint deadline ) external returns (uint amountETH); function removeLiquidityETHWithPermitSupportingFeeOnTransferTokens( address token, uint liquidity, uint amountTokenMin, uint amountETHMin, address to, uint deadline, bool approveMax, uint8 v, bytes32 r, bytes32 s ) external returns (uint amountETH); function swapExactTokensForTokensSupportingFeeOnTransferTokens( uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline ) external; function swapExactETHForTokensSupportingFeeOnTransferTokens( uint amountOutMin, address[] calldata path, address to, uint deadline ) external payable; function swapExactTokensForETHSupportingFeeOnTransferTokens( uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline ) external; }
pragma solidity >=0.5.0; interface IUniswapV2Factory { event PairCreated(address indexed token0, address indexed token1, address pair, uint); 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(uint) external view returns (address pair); function allPairsLength() external view returns (uint); function createPair(address tokenA, address tokenB) external returns (address pair); function setFeeTo(address) external; function setFeeToSetter(address) external; }
// SPDX-License-Identifier: UNLICENSED pragma solidity ^0.8.2; import "@openzeppelin/contracts/token/ERC20/extensions/ERC20Burnable.sol"; import "@openzeppelin/contracts/access/AccessControl.sol"; import "@openzeppelin/contracts/security/Pausable.sol"; import "./CamelLiquidityProcessor.sol"; import "./CamelSandstormCollector.sol"; import "./CamelConverterProcessor.sol"; /// @title Camel Coin ERC20 Token /// @author metacrypt.org contract CamelCoin is ERC20Burnable, Pausable, AccessControl { mapping(address => bool) public _isExcludedFee; mapping(address => bool) public _isExcludedWallet; CamelLiquidityProcessor public liquidityProcessor; CamelSandstormCollector public sandstormProcessor; CamelConverterProcessor public converterProcessor; uint256 private constant FEE_DENOMINATOR = 100_000; uint256 public feeLiquidity; // % div FEE_DENOMINATOR uint256 public feeSandstorm; // % div FEE_DENOMINATOR uint256 public feeConverter; // % div FEE_DENOMINATOR uint256 private walletLimit; // % div FEE_DENOMINATOR bool public isTradingEnabled = true; bool private inSwapAndLiquify = false; constructor() ERC20("Camel Coin", "CAMEL") { _grantRole(DEFAULT_ADMIN_ROLE, msg.sender); setFeeExclusion(msg.sender, true); setWalletExclusion(msg.sender, true); _mint(_msgSender(), 5_000_000 * (10**decimals())); setFees(4_000, 1_000, 4_000); // Initial fees } function setFeeProcessors( address payable _liquidityProcessor, address payable _sandstormProcessor, address payable _converterProcessor ) external onlyRole(DEFAULT_ADMIN_ROLE) { require(_liquidityProcessor != address(0), "Invalid liquidityProcessor"); require(_sandstormProcessor != address(0), "Invalid sandstormProcessor"); require(_converterProcessor != address(0), "Invalid converterProcessor"); liquidityProcessor = CamelLiquidityProcessor(_liquidityProcessor); sandstormProcessor = CamelSandstormCollector(_sandstormProcessor); converterProcessor = CamelConverterProcessor(_converterProcessor); setFeeExclusion(_liquidityProcessor, true); setFeeExclusion(_sandstormProcessor, true); setFeeExclusion(_converterProcessor, true); setWalletExclusion(_liquidityProcessor, true); setWalletExclusion(_sandstormProcessor, true); setWalletExclusion(_converterProcessor, true); setWalletExclusion(liquidityProcessor.uniswapPair(), true); } function setWalletLimit(uint256 _walletLimit) public onlyRole(DEFAULT_ADMIN_ROLE) { require(_walletLimit <= 25_000 && _walletLimit >= 0, "Wallet limit must be less than 25%"); walletLimit = _walletLimit; } function setFeeExclusion(address _wallet, bool _exclude) public onlyRole(DEFAULT_ADMIN_ROLE) { require(_wallet != address(0), "Invalid Wallet"); _isExcludedFee[_wallet] = _exclude; } function setFeeExclusion(address[] calldata _wallet, bool _exclude) public onlyRole(DEFAULT_ADMIN_ROLE) { for (uint256 i = 0; i < _wallet.length; i++) { setFeeExclusion(_wallet[i], _exclude); } } function setWalletExclusion(address _wallet, bool _exclude) public onlyRole(DEFAULT_ADMIN_ROLE) { require(_wallet != address(0), "Invalid Wallet"); _isExcludedWallet[_wallet] = _exclude; } function setWalletExclusion(address[] calldata _wallet, bool _exclude) public onlyRole(DEFAULT_ADMIN_ROLE) { for (uint256 i = 0; i < _wallet.length; i++) { setWalletExclusion(_wallet[i], _exclude); } } function setTradingEnabled(bool _enabled) external onlyRole(DEFAULT_ADMIN_ROLE) { isTradingEnabled = _enabled; } function setTransactionsPaused(bool _p) external onlyRole(DEFAULT_ADMIN_ROLE) { if (_p) { _pause(); } else { _unpause(); } } function setFees( uint256 _feeConverter, uint256 _feeLiquidity, uint256 _feeSandstorm ) public onlyRole(DEFAULT_ADMIN_ROLE) { require(_feeLiquidity <= 10_000 && _feeLiquidity >= 0, "feeLiquidity must be less than 10%"); require(_feeSandstorm <= 10_000 && _feeSandstorm >= 0, "feeSandstorm must be less than 10%"); require(_feeConverter <= 10_000 && _feeConverter >= 0, "feeConverter must be less than 10%"); feeLiquidity = _feeLiquidity; feeSandstorm = _feeSandstorm; feeConverter = _feeConverter; } function _transfer( address sender, address recipient, uint256 amount ) internal override { // Call processors if it's a sell tx if (recipient == liquidityProcessor.uniswapPair() && !inSwapAndLiquify) { inSwapAndLiquify = true; liquidityProcessor.processFunds(); sandstormProcessor.processFunds(); converterProcessor.processFunds(); inSwapAndLiquify = false; } if (_isExcludedFee[sender] || _isExcludedFee[recipient]) { ERC20._transfer(sender, recipient, amount); } else { uint256 splitLiquidity = (amount * feeLiquidity) / FEE_DENOMINATOR; uint256 splitSandstorm = (amount * feeSandstorm) / FEE_DENOMINATOR; uint256 splitConverter = (amount * feeConverter) / FEE_DENOMINATOR; ERC20._transfer(sender, address(liquidityProcessor), splitLiquidity); ERC20._transfer(sender, address(sandstormProcessor), splitSandstorm); ERC20._transfer(sender, address(converterProcessor), splitConverter); ERC20._transfer(sender, recipient, amount - splitLiquidity - splitSandstorm - splitConverter); } } function _beforeTokenTransfer( address from, address to, uint256 amount ) internal virtual override whenNotPaused { super._beforeTokenTransfer(from, to, amount); if (!isTradingEnabled) { require(to != liquidityProcessor.uniswapPair() && from != liquidityProcessor.uniswapPair(), "Trading is disabled"); } } function _afterTokenTransfer( address from, address to, uint256 amount ) internal virtual override { super._afterTokenTransfer(from, to, amount); if (walletLimit != 0) { if (!_isExcludedWallet[from]) { require(balanceOf(from) <= (totalSupply() * walletLimit) / FEE_DENOMINATOR, "Sender wallet limit reached"); } if (!_isExcludedWallet[to]) { require(balanceOf(to) <= (totalSupply() * walletLimit) / FEE_DENOMINATOR, "Receiver wallet limit reached"); } } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (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; } }
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, uint amountADesired, uint amountBDesired, uint amountAMin, uint amountBMin, address to, uint deadline ) external returns (uint amountA, uint amountB, uint liquidity); function addLiquidityETH( address token, uint amountTokenDesired, uint amountTokenMin, uint amountETHMin, address to, uint deadline ) external payable returns (uint amountToken, uint amountETH, uint liquidity); function removeLiquidity( address tokenA, address tokenB, uint liquidity, uint amountAMin, uint amountBMin, address to, uint deadline ) external returns (uint amountA, uint amountB); function removeLiquidityETH( address token, uint liquidity, uint amountTokenMin, uint amountETHMin, address to, uint deadline ) external returns (uint amountToken, uint amountETH); function removeLiquidityWithPermit( address tokenA, address tokenB, uint liquidity, uint amountAMin, uint amountBMin, address to, uint deadline, bool approveMax, uint8 v, bytes32 r, bytes32 s ) external returns (uint amountA, uint amountB); function removeLiquidityETHWithPermit( address token, uint liquidity, uint amountTokenMin, uint amountETHMin, address to, uint deadline, bool approveMax, uint8 v, bytes32 r, bytes32 s ) external returns (uint amountToken, uint amountETH); function swapExactTokensForTokens( uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline ) external returns (uint[] memory amounts); function swapTokensForExactTokens( uint amountOut, uint amountInMax, address[] calldata path, address to, uint deadline ) external returns (uint[] memory amounts); function swapExactETHForTokens(uint amountOutMin, address[] calldata path, address to, uint deadline) external payable returns (uint[] memory amounts); function swapTokensForExactETH(uint amountOut, uint amountInMax, address[] calldata path, address to, uint deadline) external returns (uint[] memory amounts); function swapExactTokensForETH(uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline) external returns (uint[] memory amounts); function swapETHForExactTokens(uint amountOut, address[] calldata path, address to, uint deadline) external payable returns (uint[] memory amounts); function quote(uint amountA, uint reserveA, uint reserveB) external pure returns (uint amountB); function getAmountOut(uint amountIn, uint reserveIn, uint reserveOut) external pure returns (uint amountOut); function getAmountIn(uint amountOut, uint reserveIn, uint reserveOut) external pure returns (uint amountIn); function getAmountsOut(uint amountIn, address[] calldata path) external view returns (uint[] memory amounts); function getAmountsIn(uint amountOut, address[] calldata path) external view returns (uint[] memory amounts); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/ERC20Burnable.sol) pragma solidity ^0.8.0; import "../ERC20.sol"; import "../../../utils/Context.sol"; /** * @dev Extension of {ERC20} that allows token holders to destroy both their own * tokens and those that they have an allowance for, in a way that can be * recognized off-chain (via event analysis). */ abstract contract ERC20Burnable is Context, ERC20 { /** * @dev Destroys `amount` tokens from the caller. * * See {ERC20-_burn}. */ function burn(uint256 amount) public virtual { _burn(_msgSender(), amount); } /** * @dev Destroys `amount` tokens from `account`, deducting from the caller's * allowance. * * See {ERC20-_burn} and {ERC20-allowance}. * * Requirements: * * - the caller must have allowance for ``accounts``'s tokens of at least * `amount`. */ function burnFrom(address account, uint256 amount) public virtual { uint256 currentAllowance = allowance(account, _msgSender()); require(currentAllowance >= amount, "ERC20: burn amount exceeds allowance"); unchecked { _approve(account, _msgSender(), currentAllowance - amount); } _burn(account, amount); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (access/AccessControl.sol) pragma solidity ^0.8.0; import "./IAccessControl.sol"; import "../utils/Context.sol"; import "../utils/Strings.sol"; import "../utils/introspection/ERC165.sol"; /** * @dev Contract module that allows children to implement role-based access * control mechanisms. This is a lightweight version that doesn't allow enumerating role * members except through off-chain means by accessing the contract event logs. Some * applications may benefit from on-chain enumerability, for those cases see * {AccessControlEnumerable}. * * Roles are referred to by their `bytes32` identifier. These should be exposed * in the external API and be unique. The best way to achieve this is by * using `public constant` hash digests: * * ``` * bytes32 public constant MY_ROLE = keccak256("MY_ROLE"); * ``` * * Roles can be used to represent a set of permissions. To restrict access to a * function call, use {hasRole}: * * ``` * function foo() public { * require(hasRole(MY_ROLE, msg.sender)); * ... * } * ``` * * Roles can be granted and revoked dynamically via the {grantRole} and * {revokeRole} functions. Each role has an associated admin role, and only * accounts that have a role's admin role can call {grantRole} and {revokeRole}. * * By default, the admin role for all roles is `DEFAULT_ADMIN_ROLE`, which means * that only accounts with this role will be able to grant or revoke other * roles. More complex role relationships can be created by using * {_setRoleAdmin}. * * WARNING: The `DEFAULT_ADMIN_ROLE` is also its own admin: it has permission to * grant and revoke this role. Extra precautions should be taken to secure * accounts that have been granted it. */ abstract contract AccessControl is Context, IAccessControl, ERC165 { struct RoleData { mapping(address => bool) members; bytes32 adminRole; } mapping(bytes32 => RoleData) private _roles; bytes32 public constant DEFAULT_ADMIN_ROLE = 0x00; /** * @dev Modifier that checks that an account has a specific role. Reverts * with a standardized message including the required role. * * The format of the revert reason is given by the following regular expression: * * /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/ * * _Available since v4.1._ */ modifier onlyRole(bytes32 role) { _checkRole(role, _msgSender()); _; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IAccessControl).interfaceId || super.supportsInterface(interfaceId); } /** * @dev Returns `true` if `account` has been granted `role`. */ function hasRole(bytes32 role, address account) public view override returns (bool) { return _roles[role].members[account]; } /** * @dev Revert with a standard message if `account` is missing `role`. * * The format of the revert reason is given by the following regular expression: * * /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/ */ function _checkRole(bytes32 role, address account) internal view { if (!hasRole(role, account)) { revert( string( abi.encodePacked( "AccessControl: account ", Strings.toHexString(uint160(account), 20), " is missing role ", Strings.toHexString(uint256(role), 32) ) ) ); } } /** * @dev Returns the admin role that controls `role`. See {grantRole} and * {revokeRole}. * * To change a role's admin, use {_setRoleAdmin}. */ function getRoleAdmin(bytes32 role) public view override returns (bytes32) { return _roles[role].adminRole; } /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function grantRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) { _grantRole(role, account); } /** * @dev Revokes `role` from `account`. * * If `account` had been granted `role`, emits a {RoleRevoked} event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function revokeRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) { _revokeRole(role, account); } /** * @dev Revokes `role` from the calling account. * * Roles are often managed via {grantRole} and {revokeRole}: this function's * purpose is to provide a mechanism for accounts to lose their privileges * if they are compromised (such as when a trusted device is misplaced). * * If the calling account had been revoked `role`, emits a {RoleRevoked} * event. * * Requirements: * * - the caller must be `account`. */ function renounceRole(bytes32 role, address account) public virtual override { require(account == _msgSender(), "AccessControl: can only renounce roles for self"); _revokeRole(role, account); } /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. Note that unlike {grantRole}, this function doesn't perform any * checks on the calling account. * * [WARNING] * ==== * This function should only be called from the constructor when setting * up the initial roles for the system. * * Using this function in any other way is effectively circumventing the admin * system imposed by {AccessControl}. * ==== * * NOTE: This function is deprecated in favor of {_grantRole}. */ function _setupRole(bytes32 role, address account) internal virtual { _grantRole(role, account); } /** * @dev Sets `adminRole` as ``role``'s admin role. * * Emits a {RoleAdminChanged} event. */ function _setRoleAdmin(bytes32 role, bytes32 adminRole) internal virtual { bytes32 previousAdminRole = getRoleAdmin(role); _roles[role].adminRole = adminRole; emit RoleAdminChanged(role, previousAdminRole, adminRole); } /** * @dev Grants `role` to `account`. * * Internal function without access restriction. */ function _grantRole(bytes32 role, address account) internal virtual { if (!hasRole(role, account)) { _roles[role].members[account] = true; emit RoleGranted(role, account, _msgSender()); } } /** * @dev Revokes `role` from `account`. * * Internal function without access restriction. */ function _revokeRole(bytes32 role, address account) internal virtual { if (hasRole(role, account)) { _roles[role].members[account] = false; emit RoleRevoked(role, account, _msgSender()); } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (security/Pausable.sol) pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which allows children to implement an emergency stop * mechanism that can be triggered by an authorized account. * * This module is used through inheritance. It will make available the * modifiers `whenNotPaused` and `whenPaused`, which can be applied to * the functions of your contract. Note that they will not be pausable by * simply including this module, only once the modifiers are put in place. */ abstract contract Pausable is Context { /** * @dev Emitted when the pause is triggered by `account`. */ event Paused(address account); /** * @dev Emitted when the pause is lifted by `account`. */ event Unpaused(address account); bool private _paused; /** * @dev Initializes the contract in unpaused state. */ constructor() { _paused = false; } /** * @dev Returns true if the contract is paused, and false otherwise. */ function paused() public view virtual returns (bool) { return _paused; } /** * @dev Modifier to make a function callable only when the contract is not paused. * * Requirements: * * - The contract must not be paused. */ modifier whenNotPaused() { require(!paused(), "Pausable: paused"); _; } /** * @dev Modifier to make a function callable only when the contract is paused. * * Requirements: * * - The contract must be paused. */ modifier whenPaused() { require(paused(), "Pausable: not paused"); _; } /** * @dev Triggers stopped state. * * Requirements: * * - The contract must not be paused. */ function _pause() internal virtual whenNotPaused { _paused = true; emit Paused(_msgSender()); } /** * @dev Returns to normal state. * * Requirements: * * - The contract must be paused. */ function _unpause() internal virtual whenPaused { _paused = false; emit Unpaused(_msgSender()); } }
// SPDX-License-Identifier: UNLICENSED pragma solidity ^0.8.2; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@uniswap/v2-periphery/contracts/interfaces/IUniswapV2Router02.sol"; import "@uniswap/v2-core/contracts/interfaces/IUniswapV2Factory.sol"; import "./CamelCoin.sol"; /// @title Camel Coin Liquidity Manager /// @author metacrypt.org contract CamelLiquidityProcessor is Ownable { CamelCoin public immutable camelCoin; IUniswapV2Router02 public immutable uniswapRouter; address public immutable uniswapPair; uint256 public minTokensToSwap; constructor(address _uniswapRouterAddress, address _camelCoinAddress) { require(_uniswapRouterAddress != address(0), "Uniswap Router can not be address(0)"); require(_camelCoinAddress != address(0), "Camel Coin can not be address(0)"); uniswapRouter = IUniswapV2Router02(_uniswapRouterAddress); camelCoin = CamelCoin(_camelCoinAddress); uniswapPair = IUniswapV2Factory(uniswapRouter.factory()).createPair(_camelCoinAddress, uniswapRouter.WETH()); setMinTokensToAdd(100 * (10**camelCoin.decimals())); } function setMinTokensToAdd(uint256 _minTokensToSwap) public onlyOwner { minTokensToSwap = _minTokensToSwap; } function addLiquidity() public { uint256 balanceToAdd = camelCoin.balanceOf(address(this)); camelCoin.approve(address(uniswapRouter), balanceToAdd); uniswapRouter.addLiquidityETH{value: address(this).balance}( address(camelCoin), balanceToAdd, 0, // slippage is unavoidable 0, // slippage is unavoidable address(this), block.timestamp + 1 ); } function autoSwap() internal returns (bool) { uint256 balanceToSwap = (camelCoin.balanceOf(address(this)) * 2) / 5; if (balanceToSwap < minTokensToSwap) { return false; } // Let's approve the exact swap amount. camelCoin.approve(address(uniswapRouter), balanceToSwap); // Router Path Token -> WETH address[] memory path = new address[](2); path[0] = address(camelCoin); path[1] = uniswapRouter.WETH(); uniswapRouter.swapExactTokensForETHSupportingFeeOnTransferTokens( balanceToSwap, 0, // slippage is unavoidable path, address(this), block.timestamp + 1 ); return true; } function processFunds() external { if (autoSwap()) { addLiquidity(); } } function recoverToken(address tokenAddress, uint256 tokenAmount) external onlyOwner { require(tokenAddress != address(camelCoin), "Can not recover Camel Coin"); IERC20(tokenAddress).transfer(owner(), tokenAmount == 0 ? IERC20(tokenAddress).balanceOf(address(this)) : tokenAmount); } receive() external payable {} }
// SPDX-License-Identifier: UNLICENSED pragma solidity ^0.8.2; import "@openzeppelin/contracts/access/Ownable.sol"; import "@uniswap/v2-periphery/contracts/interfaces/IUniswapV2Router02.sol"; import "@uniswap/v2-core/contracts/interfaces/IUniswapV2Factory.sol"; import "./CamelCoin.sol"; /// @title Camel Coin Sandstorm Collector /// @notice Collects and converts Camel Coins to ETH, holds until Camel Distributor is available. /// @author metacrypt.org contract CamelSandstormCollector is Ownable { CamelCoin public immutable camelCoin; IUniswapV2Router02 public immutable uniswapRouter; uint256 private minTokensToSwap; address payable camelDistributor; constructor(address _uniswapRouterAddress, address _camelCoinAddress) { uniswapRouter = IUniswapV2Router02(_uniswapRouterAddress); camelCoin = CamelCoin(_camelCoinAddress); setMinTokensToSwap(100 * (10**camelCoin.decimals())); } function setMinTokensToSwap(uint256 _minTokensToSwap) public onlyOwner { minTokensToSwap = _minTokensToSwap; } // The distributor can be set to address(0) to disable forwards. function setCamelDistributor(address payable _distributor) external onlyOwner { camelDistributor = _distributor; } function autoSwap() internal returns (bool) { uint256 balanceToSwap = camelCoin.balanceOf(address(this)); if (balanceToSwap < minTokensToSwap) { return false; } // Let's approve the exact swap amount. camelCoin.approve(address(uniswapRouter), balanceToSwap); // Router Path Token -> WETH address[] memory path = new address[](2); path[0] = address(camelCoin); path[1] = uniswapRouter.WETH(); uniswapRouter.swapExactTokensForETHSupportingFeeOnTransferTokens( balanceToSwap, 0, // slippage is unavoidable path, address(this), block.timestamp + 1 ); return true; } function processFunds() external { autoSwap(); if (camelDistributor != address(0)) { (bool sent, ) = camelDistributor.call{value: address(this).balance}(""); require(sent, "CamelSandstormCollector: Transfer Failed"); } } receive() external payable {} }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC20/ERC20.sol) pragma solidity ^0.8.0; import "./IERC20.sol"; import "./extensions/IERC20Metadata.sol"; import "../../utils/Context.sol"; /** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our guide * https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226[How * to implement supply mechanisms]. * * We have followed general OpenZeppelin Contracts guidelines: functions revert * instead returning `false` on failure. This behavior is nonetheless * conventional and does not conflict with the expectations of ERC20 * applications. * * Additionally, an {Approval} event is emitted on calls to {transferFrom}. * This allows applications to reconstruct the allowance for all accounts just * by listening to said events. Other implementations of the EIP may not emit * these events, as it isn't required by the specification. * * Finally, the non-standard {decreaseAllowance} and {increaseAllowance} * functions have been added to mitigate the well-known issues around setting * allowances. See {IERC20-approve}. */ contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; uint256 private _totalSupply; string private _name; string private _symbol; /** * @dev Sets the values for {name} and {symbol}. * * The default value of {decimals} is 18. To select a different value for * {decimals} you should overload it. * * All two of these values are immutable: they can only be set once during * construction. */ constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; } /** * @dev Returns the name of the token. */ function name() public view virtual override returns (string memory) { return _name; } /** * @dev Returns the symbol of the token, usually a shorter version of the * name. */ function symbol() public view virtual override returns (string memory) { return _symbol; } /** * @dev Returns the number of decimals used to get its user representation. * For example, if `decimals` equals `2`, a balance of `505` tokens should * be displayed to a user as `5.05` (`505 / 10 ** 2`). * * Tokens usually opt for a value of 18, imitating the relationship between * Ether and Wei. This is the value {ERC20} uses, unless this function is * overridden; * * NOTE: This information is only used for _display_ purposes: it in * no way affects any of the arithmetic of the contract, including * {IERC20-balanceOf} and {IERC20-transfer}. */ function decimals() public view virtual override returns (uint8) { return 18; } /** * @dev See {IERC20-totalSupply}. */ function totalSupply() public view virtual override returns (uint256) { return _totalSupply; } /** * @dev See {IERC20-balanceOf}. */ function balanceOf(address account) public view virtual override returns (uint256) { return _balances[account]; } /** * @dev See {IERC20-transfer}. * * Requirements: * * - `recipient` cannot be the zero address. * - the caller must have a balance of at least `amount`. */ function transfer(address recipient, uint256 amount) public virtual override returns (bool) { _transfer(_msgSender(), recipient, amount); return true; } /** * @dev See {IERC20-allowance}. */ function allowance(address owner, address spender) public view virtual override returns (uint256) { return _allowances[owner][spender]; } /** * @dev See {IERC20-approve}. * * Requirements: * * - `spender` cannot be the zero address. */ function approve(address spender, uint256 amount) public virtual override returns (bool) { _approve(_msgSender(), spender, amount); return true; } /** * @dev See {IERC20-transferFrom}. * * Emits an {Approval} event indicating the updated allowance. This is not * required by the EIP. See the note at the beginning of {ERC20}. * * Requirements: * * - `sender` and `recipient` cannot be the zero address. * - `sender` must have a balance of at least `amount`. * - the caller must have allowance for ``sender``'s tokens of at least * `amount`. */ function transferFrom( address sender, address recipient, uint256 amount ) public virtual override returns (bool) { _transfer(sender, recipient, amount); uint256 currentAllowance = _allowances[sender][_msgSender()]; require(currentAllowance >= amount, "ERC20: transfer amount exceeds allowance"); unchecked { _approve(sender, _msgSender(), currentAllowance - amount); } return true; } /** * @dev Atomically increases the allowance granted to `spender` by the caller. * * This is an alternative to {approve} that can be used as a mitigation for * problems described in {IERC20-approve}. * * Emits an {Approval} event indicating the updated allowance. * * Requirements: * * - `spender` cannot be the zero address. */ function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) { _approve(_msgSender(), spender, _allowances[_msgSender()][spender] + addedValue); return true; } /** * @dev Atomically decreases the allowance granted to `spender` by the caller. * * This is an alternative to {approve} that can be used as a mitigation for * problems described in {IERC20-approve}. * * Emits an {Approval} event indicating the updated allowance. * * Requirements: * * - `spender` cannot be the zero address. * - `spender` must have allowance for the caller of at least * `subtractedValue`. */ function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) { uint256 currentAllowance = _allowances[_msgSender()][spender]; require(currentAllowance >= subtractedValue, "ERC20: decreased allowance below zero"); unchecked { _approve(_msgSender(), spender, currentAllowance - subtractedValue); } return true; } /** * @dev Moves `amount` of tokens from `sender` to `recipient`. * * This internal function is equivalent to {transfer}, and can be used to * e.g. implement automatic token fees, slashing mechanisms, etc. * * Emits a {Transfer} event. * * Requirements: * * - `sender` cannot be the zero address. * - `recipient` cannot be the zero address. * - `sender` must have a balance of at least `amount`. */ function _transfer( address sender, address recipient, uint256 amount ) internal virtual { require(sender != address(0), "ERC20: transfer from the zero address"); require(recipient != address(0), "ERC20: transfer to the zero address"); _beforeTokenTransfer(sender, recipient, amount); uint256 senderBalance = _balances[sender]; require(senderBalance >= amount, "ERC20: transfer amount exceeds balance"); unchecked { _balances[sender] = senderBalance - amount; } _balances[recipient] += amount; emit Transfer(sender, recipient, amount); _afterTokenTransfer(sender, recipient, amount); } /** @dev Creates `amount` tokens and assigns them to `account`, increasing * the total supply. * * Emits a {Transfer} event with `from` set to the zero address. * * Requirements: * * - `account` cannot be the zero address. */ function _mint(address account, uint256 amount) internal virtual { require(account != address(0), "ERC20: mint to the zero address"); _beforeTokenTransfer(address(0), account, amount); _totalSupply += amount; _balances[account] += amount; emit Transfer(address(0), account, amount); _afterTokenTransfer(address(0), account, amount); } /** * @dev Destroys `amount` tokens from `account`, reducing the * total supply. * * Emits a {Transfer} event with `to` set to the zero address. * * Requirements: * * - `account` cannot be the zero address. * - `account` must have at least `amount` tokens. */ function _burn(address account, uint256 amount) internal virtual { require(account != address(0), "ERC20: burn from the zero address"); _beforeTokenTransfer(account, address(0), amount); uint256 accountBalance = _balances[account]; require(accountBalance >= amount, "ERC20: burn amount exceeds balance"); unchecked { _balances[account] = accountBalance - amount; } _totalSupply -= amount; emit Transfer(account, address(0), amount); _afterTokenTransfer(account, address(0), amount); } /** * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens. * * This internal function is equivalent to `approve`, and can be used to * e.g. set automatic allowances for certain subsystems, etc. * * Emits an {Approval} event. * * Requirements: * * - `owner` cannot be the zero address. * - `spender` cannot be the zero address. */ function _approve( address owner, address spender, uint256 amount ) internal virtual { 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); } /** * @dev Hook that is called before any transfer of tokens. This includes * minting and burning. * * Calling conditions: * * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens * will be transferred to `to`. * - when `from` is zero, `amount` tokens will be minted for `to`. * - when `to` is zero, `amount` of ``from``'s tokens will be burned. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer( address from, address to, uint256 amount ) internal virtual {} /** * @dev Hook that is called after any transfer of tokens. This includes * minting and burning. * * Calling conditions: * * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens * has been transferred to `to`. * - when `from` is zero, `amount` tokens have been minted for `to`. * - when `to` is zero, `amount` of ``from``'s tokens have been burned. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _afterTokenTransfer( address from, address to, uint256 amount ) internal virtual {} }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC20/IERC20.sol) 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); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/IERC20Metadata.sol) pragma solidity ^0.8.0; import "../IERC20.sol"; /** * @dev Interface for the optional metadata functions from the ERC20 standard. * * _Available since v4.1._ */ interface IERC20Metadata is IERC20 { /** * @dev Returns the name of the token. */ function name() external view returns (string memory); /** * @dev Returns the symbol of the token. */ function symbol() external view returns (string memory); /** * @dev Returns the decimals places of the token. */ function decimals() external view returns (uint8); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (access/IAccessControl.sol) pragma solidity ^0.8.0; /** * @dev External interface of AccessControl declared to support ERC165 detection. */ interface IAccessControl { /** * @dev Emitted when `newAdminRole` is set as ``role``'s admin role, replacing `previousAdminRole` * * `DEFAULT_ADMIN_ROLE` is the starting admin for all roles, despite * {RoleAdminChanged} not being emitted signaling this. * * _Available since v3.1._ */ event RoleAdminChanged(bytes32 indexed role, bytes32 indexed previousAdminRole, bytes32 indexed newAdminRole); /** * @dev Emitted when `account` is granted `role`. * * `sender` is the account that originated the contract call, an admin role * bearer except when using {AccessControl-_setupRole}. */ event RoleGranted(bytes32 indexed role, address indexed account, address indexed sender); /** * @dev Emitted when `account` is revoked `role`. * * `sender` is the account that originated the contract call: * - if using `revokeRole`, it is the admin role bearer * - if using `renounceRole`, it is the role bearer (i.e. `account`) */ event RoleRevoked(bytes32 indexed role, address indexed account, address indexed sender); /** * @dev Returns `true` if `account` has been granted `role`. */ function hasRole(bytes32 role, address account) external view returns (bool); /** * @dev Returns the admin role that controls `role`. See {grantRole} and * {revokeRole}. * * To change a role's admin, use {AccessControl-_setRoleAdmin}. */ function getRoleAdmin(bytes32 role) external view returns (bytes32); /** * @dev Grants `role` to `account`. * * If `account` had not been already granted `role`, emits a {RoleGranted} * event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function grantRole(bytes32 role, address account) external; /** * @dev Revokes `role` from `account`. * * If `account` had been granted `role`, emits a {RoleRevoked} event. * * Requirements: * * - the caller must have ``role``'s admin role. */ function revokeRole(bytes32 role, address account) external; /** * @dev Revokes `role` from the calling account. * * Roles are often managed via {grantRole} and {revokeRole}: this function's * purpose is to provide a mechanism for accounts to lose their privileges * if they are compromised (such as when a trusted device is misplaced). * * If the calling account had been granted `role`, emits a {RoleRevoked} * event. * * Requirements: * * - the caller must be `account`. */ function renounceRole(bytes32 role, address account) external; }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Strings.sol) pragma solidity ^0.8.0; /** * @dev String operations. */ library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT licence // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol if (value == 0) { return "0"; } uint256 temp = value; uint256 digits; while (temp != 0) { digits++; temp /= 10; } bytes memory buffer = new bytes(digits); while (value != 0) { digits -= 1; buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); value /= 10; } return string(buffer); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol) pragma solidity ^0.8.0; import "./IERC165.sol"; /** * @dev Implementation of the {IERC165} interface. * * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check * for the additional interface id that will be supported. For example: * * ```solidity * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { * return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId); * } * ``` * * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation. */ abstract contract ERC165 is IERC165 { /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IERC165).interfaceId; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC165 standard, as defined in the * https://eips.ethereum.org/EIPS/eip-165[EIP]. * * Implementers can declare support of contract interfaces, which can then be * queried by others ({ERC165Checker}). * * For an implementation, see {ERC165}. */ interface IERC165 { /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] * to learn more about how these ids are created. * * This function call must use less than 30 000 gas. */ function supportsInterface(bytes4 interfaceId) external view returns (bool); }
{ "optimizer": { "enabled": true, "runs": 100 }, "metadata": { "bytecodeHash": "none" }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"address","name":"_uniswapRouterAddress","type":"address"},{"internalType":"address","name":"_camelCoinAddress","type":"address"},{"internalType":"address payable","name":"_teamWallet","type":"address"},{"internalType":"address payable","name":"_marketingWallet","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"inputs":[],"name":"camelCoin","outputs":[{"internalType":"contract CamelCoin","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"marketingWallet","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"processFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address payable","name":"_teamWallet","type":"address"},{"internalType":"address payable","name":"_marketingWallet","type":"address"}],"name":"setDistributors","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_minTokensToSwap","type":"uint256"}],"name":"setMinTokensToSwap","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_splitTeam","type":"uint256"},{"internalType":"uint256","name":"_splitMarketing","type":"uint256"}],"name":"setSplits","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"splitMarketing","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"splitTeam","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"teamWallet","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"uniswapRouter","outputs":[{"internalType":"contract IUniswapV2Router02","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"stateMutability":"payable","type":"receive"}]
Contract Creation Code
60c0604052600160045560016005553480156200001b57600080fd5b5060405162000fcc38038062000fcc8339810160408190526200003e9162000231565b6200004933620000fb565b6001600160a01b0380851660a052831660808190526040805163313ce56760e01b81529051620000e5929163313ce5679160048083019260209291908290030181865afa1580156200009f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620000c5919062000299565b620000d290600a620003da565b620000df906064620003eb565b6200014b565b620000f182826200019f565b505050506200040d565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6000546001600160a01b031633146200019a5760405162461bcd60e51b8152602060048201819052602482015260008051602062000fac83398151915260448201526064015b60405180910390fd5b600155565b6000546001600160a01b03163314620001ea5760405162461bcd60e51b8152602060048201819052602482015260008051602062000fac833981519152604482015260640162000191565b600280546001600160a01b039384166001600160a01b03199182161790915560038054929093169116179055565b6001600160a01b03811681146200022e57600080fd5b50565b600080600080608085870312156200024857600080fd5b8451620002558162000218565b6020860151909450620002688162000218565b60408601519093506200027b8162000218565b60608601519092506200028e8162000218565b939692955090935050565b600060208284031215620002ac57600080fd5b815160ff81168114620002be57600080fd5b9392505050565b634e487b7160e01b600052601160045260246000fd5b600181815b808511156200031c578160001904821115620003005762000300620002c5565b808516156200030e57918102915b93841c9390800290620002e0565b509250929050565b6000826200033557506001620003d4565b816200034457506000620003d4565b81600181146200035d5760028114620003685762000388565b6001915050620003d4565b60ff8411156200037c576200037c620002c5565b50506001821b620003d4565b5060208310610133831016604e8410600b8410161715620003ad575081810a620003d4565b620003b98383620002db565b8060001904821115620003d057620003d0620002c5565b0290505b92915050565b6000620002be60ff84168362000324565b6000816000190483118215151615620004085762000408620002c5565b500290565b60805160a051610b4f6200045d600039600081816101c001528181610673015281816107870152610832015260008181610229015281816105dd015281816106a201526107330152610b4f6000f3fe6080604052600436106100b55760003560e01c8063715018a61161006f578063715018a614610199578063735de9f7146101ae57806375f0a874146101e25780638da5cb5b14610202578063aa33842914610217578063ea9af4321461024b578063f2fde38b1461026157600080fd5b80629e4404146100c1578063110430bb146100e3578063157208ca1461010357806320aa655914610118578063336aea9714610138578063599270441461016157600080fd5b366100bc57005b600080fd5b3480156100cd57600080fd5b506100e16100dc366004610912565b610281565b005b3480156100ef57600080fd5b506100e16100fe366004610934565b6102c4565b34801561010f57600080fd5b506100e16102f8565b34801561012457600080fd5b506100e1610133366004610962565b610476565b34801561014457600080fd5b5061014e60045481565b6040519081526020015b60405180910390f35b34801561016d57600080fd5b50600254610181906001600160a01b031681565b6040516001600160a01b039091168152602001610158565b3480156101a557600080fd5b506100e16104d3565b3480156101ba57600080fd5b506101817f000000000000000000000000000000000000000000000000000000000000000081565b3480156101ee57600080fd5b50600354610181906001600160a01b031681565b34801561020e57600080fd5b5061018161050c565b34801561022357600080fd5b506101817f000000000000000000000000000000000000000000000000000000000000000081565b34801561025757600080fd5b5061014e60055481565b34801561026d57600080fd5b506100e161027c36600461099b565b61051b565b3361028a61050c565b6001600160a01b0316146102b95760405162461bcd60e51b81526004016102b0906109bf565b60405180910390fd5b600491909155600555565b336102cd61050c565b6001600160a01b0316146102f35760405162461bcd60e51b81526004016102b0906109bf565b600155565b6103006105bb565b506002546001600160a01b03161580159061032557506003546001600160a01b031615155b80156103315750600047115b15610474576002546005546004546000926001600160a01b03169161035591610a0a565b6004546103629047610a22565b61036c9190610a41565b604051600081818185875af1925050503d80600081146103a8576040519150601f19603f3d011682016040523d82523d6000602084013e6103ad565b606091505b50506003546040519192506000916001600160a01b039091169047908381818185875af1925050503d8060008114610401576040519150601f19603f3d011682016040523d82523d6000602084013e610406565b606091505b505090508180156104145750805b6104715760405162461bcd60e51b815260206004820152602860248201527f43616d656c436f6e76657274657250726f636573736f723a205472616e7366656044820152671c8811985a5b195960c21b60648201526084016102b0565b50505b565b3361047f61050c565b6001600160a01b0316146104a55760405162461bcd60e51b81526004016102b0906109bf565b600280546001600160a01b039384166001600160a01b03199182161790915560038054929093169116179055565b336104dc61050c565b6001600160a01b0316146105025760405162461bcd60e51b81526004016102b0906109bf565b61047460006108c2565b6000546001600160a01b031690565b3361052461050c565b6001600160a01b03161461054a5760405162461bcd60e51b81526004016102b0906109bf565b6001600160a01b0381166105af5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016102b0565b6105b8816108c2565b50565b6040516370a0823160e01b815230600482015260009081906001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016906370a0823190602401602060405180830381865afa158015610624573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106489190610a63565b905060015481101561065c57600091505090565b60405163095ea7b360e01b81526001600160a01b037f000000000000000000000000000000000000000000000000000000000000000081166004830152602482018390527f0000000000000000000000000000000000000000000000000000000000000000169063095ea7b3906044016020604051808303816000875af11580156106eb573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061070f9190610a7c565b506040805160028082526060820183526000926020830190803683370190505090507f00000000000000000000000000000000000000000000000000000000000000008160008151811061076557610765610a9e565b60200260200101906001600160a01b031690816001600160a01b0316815250507f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031663ad5c46486040518163ffffffff1660e01b8152600401602060405180830381865afa1580156107e3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108079190610ab4565b8160018151811061081a5761081a610a9e565b6001600160a01b0392831660209182029290920101527f00000000000000000000000000000000000000000000000000000000000000001663791ac9478360008430610867426001610a0a565b6040518663ffffffff1660e01b8152600401610887959493929190610ad1565b600060405180830381600087803b1580156108a157600080fd5b505af11580156108b5573d6000803e3d6000fd5b5050505060019250505090565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6000806040838503121561092557600080fd5b50508035926020909101359150565b60006020828403121561094657600080fd5b5035919050565b6001600160a01b03811681146105b857600080fd5b6000806040838503121561097557600080fd5b82356109808161094d565b915060208301356109908161094d565b809150509250929050565b6000602082840312156109ad57600080fd5b81356109b88161094d565b9392505050565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b634e487b7160e01b600052601160045260246000fd5b60008219821115610a1d57610a1d6109f4565b500190565b6000816000190483118215151615610a3c57610a3c6109f4565b500290565b600082610a5e57634e487b7160e01b600052601260045260246000fd5b500490565b600060208284031215610a7557600080fd5b5051919050565b600060208284031215610a8e57600080fd5b815180151581146109b857600080fd5b634e487b7160e01b600052603260045260246000fd5b600060208284031215610ac657600080fd5b81516109b88161094d565b600060a082018783526020878185015260a0604085015281875180845260c086019150828901935060005b81811015610b215784516001600160a01b031683529383019391830191600101610afc565b50506001600160a01b0396909616606085015250505060800152939250505056fea164736f6c634300080d000a4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65720000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d0000000000000000000000002b6a25ede8b6b3e870c03f0e5e25893097499cf00000000000000000000000002e1ff581023cd3bf52e7914ab5682c656e842405000000000000000000000000f89cd8c8366cb0e505f33108ff2ba15c2a06a4c4
Deployed Bytecode
0x6080604052600436106100b55760003560e01c8063715018a61161006f578063715018a614610199578063735de9f7146101ae57806375f0a874146101e25780638da5cb5b14610202578063aa33842914610217578063ea9af4321461024b578063f2fde38b1461026157600080fd5b80629e4404146100c1578063110430bb146100e3578063157208ca1461010357806320aa655914610118578063336aea9714610138578063599270441461016157600080fd5b366100bc57005b600080fd5b3480156100cd57600080fd5b506100e16100dc366004610912565b610281565b005b3480156100ef57600080fd5b506100e16100fe366004610934565b6102c4565b34801561010f57600080fd5b506100e16102f8565b34801561012457600080fd5b506100e1610133366004610962565b610476565b34801561014457600080fd5b5061014e60045481565b6040519081526020015b60405180910390f35b34801561016d57600080fd5b50600254610181906001600160a01b031681565b6040516001600160a01b039091168152602001610158565b3480156101a557600080fd5b506100e16104d3565b3480156101ba57600080fd5b506101817f0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d81565b3480156101ee57600080fd5b50600354610181906001600160a01b031681565b34801561020e57600080fd5b5061018161050c565b34801561022357600080fd5b506101817f0000000000000000000000002b6a25ede8b6b3e870c03f0e5e25893097499cf081565b34801561025757600080fd5b5061014e60055481565b34801561026d57600080fd5b506100e161027c36600461099b565b61051b565b3361028a61050c565b6001600160a01b0316146102b95760405162461bcd60e51b81526004016102b0906109bf565b60405180910390fd5b600491909155600555565b336102cd61050c565b6001600160a01b0316146102f35760405162461bcd60e51b81526004016102b0906109bf565b600155565b6103006105bb565b506002546001600160a01b03161580159061032557506003546001600160a01b031615155b80156103315750600047115b15610474576002546005546004546000926001600160a01b03169161035591610a0a565b6004546103629047610a22565b61036c9190610a41565b604051600081818185875af1925050503d80600081146103a8576040519150601f19603f3d011682016040523d82523d6000602084013e6103ad565b606091505b50506003546040519192506000916001600160a01b039091169047908381818185875af1925050503d8060008114610401576040519150601f19603f3d011682016040523d82523d6000602084013e610406565b606091505b505090508180156104145750805b6104715760405162461bcd60e51b815260206004820152602860248201527f43616d656c436f6e76657274657250726f636573736f723a205472616e7366656044820152671c8811985a5b195960c21b60648201526084016102b0565b50505b565b3361047f61050c565b6001600160a01b0316146104a55760405162461bcd60e51b81526004016102b0906109bf565b600280546001600160a01b039384166001600160a01b03199182161790915560038054929093169116179055565b336104dc61050c565b6001600160a01b0316146105025760405162461bcd60e51b81526004016102b0906109bf565b61047460006108c2565b6000546001600160a01b031690565b3361052461050c565b6001600160a01b03161461054a5760405162461bcd60e51b81526004016102b0906109bf565b6001600160a01b0381166105af5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016102b0565b6105b8816108c2565b50565b6040516370a0823160e01b815230600482015260009081906001600160a01b037f0000000000000000000000002b6a25ede8b6b3e870c03f0e5e25893097499cf016906370a0823190602401602060405180830381865afa158015610624573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106489190610a63565b905060015481101561065c57600091505090565b60405163095ea7b360e01b81526001600160a01b037f0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d81166004830152602482018390527f0000000000000000000000002b6a25ede8b6b3e870c03f0e5e25893097499cf0169063095ea7b3906044016020604051808303816000875af11580156106eb573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061070f9190610a7c565b506040805160028082526060820183526000926020830190803683370190505090507f0000000000000000000000002b6a25ede8b6b3e870c03f0e5e25893097499cf08160008151811061076557610765610a9e565b60200260200101906001600160a01b031690816001600160a01b0316815250507f0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d6001600160a01b031663ad5c46486040518163ffffffff1660e01b8152600401602060405180830381865afa1580156107e3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108079190610ab4565b8160018151811061081a5761081a610a9e565b6001600160a01b0392831660209182029290920101527f0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d1663791ac9478360008430610867426001610a0a565b6040518663ffffffff1660e01b8152600401610887959493929190610ad1565b600060405180830381600087803b1580156108a157600080fd5b505af11580156108b5573d6000803e3d6000fd5b5050505060019250505090565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6000806040838503121561092557600080fd5b50508035926020909101359150565b60006020828403121561094657600080fd5b5035919050565b6001600160a01b03811681146105b857600080fd5b6000806040838503121561097557600080fd5b82356109808161094d565b915060208301356109908161094d565b809150509250929050565b6000602082840312156109ad57600080fd5b81356109b88161094d565b9392505050565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b634e487b7160e01b600052601160045260246000fd5b60008219821115610a1d57610a1d6109f4565b500190565b6000816000190483118215151615610a3c57610a3c6109f4565b500290565b600082610a5e57634e487b7160e01b600052601260045260246000fd5b500490565b600060208284031215610a7557600080fd5b5051919050565b600060208284031215610a8e57600080fd5b815180151581146109b857600080fd5b634e487b7160e01b600052603260045260246000fd5b600060208284031215610ac657600080fd5b81516109b88161094d565b600060a082018783526020878185015260a0604085015281875180845260c086019150828901935060005b81811015610b215784516001600160a01b031683529383019391830191600101610afc565b50506001600160a01b0396909616606085015250505060800152939250505056fea164736f6c634300080d000a
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d0000000000000000000000002b6a25ede8b6b3e870c03f0e5e25893097499cf00000000000000000000000002e1ff581023cd3bf52e7914ab5682c656e842405000000000000000000000000f89cd8c8366cb0e505f33108ff2ba15c2a06a4c4
-----Decoded View---------------
Arg [0] : _uniswapRouterAddress (address): 0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D
Arg [1] : _camelCoinAddress (address): 0x2b6A25EDe8b6B3E870C03f0e5e25893097499Cf0
Arg [2] : _teamWallet (address): 0x2e1FF581023CD3bF52e7914ab5682c656e842405
Arg [3] : _marketingWallet (address): 0xf89cD8c8366cB0e505F33108FF2ba15C2a06A4c4
-----Encoded View---------------
4 Constructor Arguments found :
Arg [0] : 0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d
Arg [1] : 0000000000000000000000002b6a25ede8b6b3e870c03f0e5e25893097499cf0
Arg [2] : 0000000000000000000000002e1ff581023cd3bf52e7914ab5682c656e842405
Arg [3] : 000000000000000000000000f89cd8c8366cb0e505f33108ff2ba15c2a06a4c4
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
[ Download: CSV Export ]
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.