easy

easy

CLIPS專案解析:如何無風險用0.035eth 十小時輕鬆賺取78000U

Earn 78000U easily in ten hours with zero risk using 0.035eth.

The popular project today is Clips, which is similar to Xen, so the gameplay should be similar to Xen. However, some people have taken a different approach and are earning transaction fees through batch minting, which is a profitable business without any losses. This article mainly aims to understand the basic logic of batch minting.

Profit Calculation#

The price of CLIPS used to calculate the earnings in this article is shown in the image below:

image

The GAS spent by the contract author: 0.0352ETH
Address: Ethereum Transaction Hash (Txhash) Details | Etherscan

image

Profit calculation process: The contract charges a 6% transaction fee, but batch minting helps users save some gas. So users still profit, a win-win situation. You can see the details in the Twitter image below.

image

From the contract information, it is known that the beneficiary address of the contract author is the deployment address:

image

Check the CLIPS balance of this address: 1374900000. At the time of writing this article, the price of this token was 0.000057, but I haven't delved into the liquidity of the pool specifically.

Profit calculation: 1374900000 * 0.000057 = 78369.3U

Contract Interpretation#

This contract consists of only 43 lines of code, so 43 lines of code earned 78000U in ten hours.

/**
 *Submitted for verification at Etherscan.io on 2023-05-04
*/

pragma solidity ^0.8.0;

interface Clip {
    function mintClips() external;
    function transfer(address to, uint256 amount) external returns (bool);
    function balanceOf(address account) external view returns (uint256);
}

contract claimer {
    constructor (address receiver) {
        Clip clip = Clip(0xeCbEE2fAE67709F718426DDC3bF770B26B95eD20);
        clip.mintClips();
        clip.transfer(receiver, clip.balanceOf(address(this)));
    }
}

contract BatchMintClips {
    address public owner;
    modifier onlyOwner() {
        require(msg.sender == owner, "Not owner.");
        _;
    }
    constructor() {
        owner = msg.sender;
    }

    function batchMint(uint count) external {
        for (uint i = 0; i < count;) {
            new claimer(address(this));
            unchecked {
                i++;
            }
        }

        Clip clip = Clip(0xeCbEE2fAE67709F718426DDC3bF770B26B95eD20);
        clip.transfer(msg.sender, clip.balanceOf(address(this)) * 94 / 100);
        clip.transfer(owner, clip.balanceOf(address(this)));
    }
}

This is an Ethereum smart contract written in Solidity. The contract consists of three parts: the Clip interface, the claimer contract, and the BatchMintClips contract. Here is an explanation of these parts:

  1. Clip interface:
    This interface defines the basic functions of the Clip contract, including mintClips(), transfer(), and balanceOf(). These functions are used to create new Clip tokens, transfer tokens from one address to another, and query the token balance of an address, respectively.

  2. claimer contract:
    This is a simple contract that takes an address as a parameter in its constructor. In the constructor, it first gets an instance of the Clip contract and then calls the mintClips() function to create new Clip tokens. Finally, it transfers the newly created tokens to the receiver address passed in.

  3. BatchMintClips contract:
    This contract is used to batch mint Clip tokens. It has a public owner variable and an onlyOwner modifier to ensure that only the contract creator can execute certain functions.

    • Constructor: When creating the BatchMintClips contract, the address of the contract creator is set as the owner.
    • batchMint() function: This function takes a parameter count indicating how many claimer contracts to create. For each claimer contract to be created, it instantiates a new claimer contract with the address of the BatchMintClips contract as the receiver. This way, when new Clip tokens are created, they will be sent to the address of the BatchMintClips contract. After the batch creation is complete, 94% of the tokens are transferred to the caller's address, and the remaining 6% of the tokens are transferred to the owner address.

In summary, this contract allows users to batch mint Clip tokens. The caller can execute this operation by calling the batchMint() function and providing the desired quantity to create. After the batch creation is complete, the caller will receive 94% of the tokens, while the contract creator will receive the remaining 6%.

Conclusion#

The contract author combines the experience of Xen and demonstrates a flexible use of Solidity. The idea can be very well borrowed.

The above contract is very simple, and I believe that anyone who has studied the WTF-Solidity Basics can write it. The implementation of the code is not difficult, but the difficulty lies in the implementation of the idea. Looking forward to the arrival of the bull market, everyone will reap what they sow.

載入中......
此文章數據所有權由區塊鏈加密技術和智能合約保障僅歸創作者所有。