I created a Deflationary token mainly forked from safemoon. txFee & liqudityFee both 5%.

I suppose every time someone transfers tokens, 5% of it will be burned and 5% go to my token contract. Once the token amount reachs the numTokensSellToAddToLiquidity value. Then swapAndLiquidity will be triggered. This is my understanding and the code is exactly the same as safemoon.

However, I found out no matter how many tokens I transfer by my different addresses. It turns that the token balance in my token contract keeps 0. Shouldn't 5% of the transaction amount be deposited in the token contract for future adding liquidity? Why? Here is my token address in BSC testnet https://testnet.bscscan.com/address/0x172ed1f636084523588bb2d13ffddf62c06b8e6f, You could have a look at the transactions if possible. I believe only the contract owner is excluded from the reward. Others are all included in Fee and reward.

I supposed that the _takeLiquidity(tLiquidity) is not taking effect in the _transferStandard() function:

function _transferStandard(address sender, address recipient, uint256 tAmount) private {
    (uint256 rAmount, uint256 rTransferAmount, uint256 rFee, uint256 tTransferAmount, uint256 tFee, uint256 tLiquidity) = _getValues(tAmount);
    _rOwned[sender] = _rOwned[sender].sub(rAmount);
    _rOwned[recipient] = _rOwned[recipient].add(rTransferAmount);
    _reflectFee(rFee, tFee);
    emit Transfer(sender, recipient, tTransferAmount);

But how could it happen? Could anyone tell me do I miss anything?

1 Answer 1


contract unverified. If you can verify the code on testnet, that would be helpful! It's hard to assume on other code.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.