A complete BEP20 token system with automated airdrop and tokenomics-based vesting functionality for the MetaSoilVerseProtocol (MSVP) token. This system implements a sophisticated vesting schedule with 6-month cliff periods and 1.2% unlocks every 4-6 months alternating over 10+ years.
- BEP20 Standard: Full ERC20 compatibility on Binance Smart Chain
- Tokenomics-Based Vesting: Sophisticated vesting schedule with 6-month cliff and 1.2% unlocks
- Transfer Taxes: Configurable 5% transfer tax with distribution to:
- LP Contribution (2%)
- Development Fee (1.5%)
- Marketing (1%)
- Burn (0.5%)
- Max Transaction Limits: Prevents large dumps
- Admin Controls: Pause/unpause, tax rate adjustments, wallet updates
- Security: Reentrancy protection, ownership controls
- Automatic Unlocking: Tokens unlock automatically without claiming mechanism
- 6-Month Cliff Period: No tokens unlocked before 6 months from TGE
- 1.2% Unlock Pattern: Each unlock releases exactly 1.2% of total allocation
- Alternating Intervals: 4 months, then 6 months, then 4 months, etc.
- Long-Term Vesting: Support for 30+ unlock phases over 10+ years
- Large-Scale Support: Handles 50B token airdrop distribution
- Additional Purchases: Immediately transferable
- Early Release: Admin can release specific amounts
- High Precision: 1e18 precision for accurate calculations
- Gas Optimization: Individual user updates for efficiency
- Inconsistency Detection: Audit trail for edge cases
- Modern UI: Beautiful, responsive interface with Bootstrap 5.3
- CSV Upload: Drag & drop functionality for bulk operations
- Real-time Stats: Live vesting statistics with tax breakdown
- Participant Management: Search and modify individual schedules
- Wallet Integration: MetaMask and WalletConnect support
- Enhanced Balance Display: Multiple balance types (base, transferable, locked, vested)
- Export Functionality: Download participant data as CSV
- Gas Optimization: Individual user updates with warnings for bulk operations
| Field | Value |
|---|---|
| Token Name | MetaSoilVerse |
| Token Symbol | MSV |
| Total Supply | 100,000,000,000 (100 Billion) |
| Decimals | 18 |
| Mintable | No |
| Burnable | Yes |
| Initial Transfer Tax | 5% |
| Max Transfer Tax | 10% |
| Vesting Type | Tokenomics-Based |
| Cliff Period | 6 Months from TGE |
| Unlock Pattern | 1.2% every 4-6 months alternating |
| Unlock Intervals | 4 months, 6 months, 4 months, 6 months, etc. |
| Total Unlock Phases | 30+ phases over 10+ years |
| Airdrop Supply | 50B tokens (50% of total supply) |
| Locked Tokens | Visible in balance, non-transferable |
| Automatic Unlocking | No claiming required - tokens unlock automatically |
| Additional Purchases | Immediately transferable |
| Precision | 1e18 (18 decimal places) |
- Node.js (v16 or higher)
- npm or yarn
- MetaMask wallet
- BSC testnet/mainnet access
git clone <repository-url>
cd TokenAirdrop
npm installcp env.example .envEdit .env file:
PRIVATE_KEY=your_private_key_here
BSCSCAN_API_KEY=your_bscscan_api_key_here
LP_WALLET=your_lp_wallet_address
MARKETING_WALLET=your_marketing_wallet_address
DEVELOPMENT_WALLET=your_development_wallet_address
REPORT_GAS=truenpm run compilenpm test# Deploy Integrated Token (Recommended)
npm run deploy:integrated
# Deploy to BSC testnet
npm run deploy:testnet:integrated
# Deploy to BSC mainnet
npm run deploy:mainnet:integrated- Contract Address:
0x90D29a452e52982c9cEcD04B2ed788215Aa97ce3 - Network: BSC Testnet (Chain ID: 97)
- Deployer:
0xcd6f9715eAD50841929C5cda9ad78605AF71F1f2 - Status: Successfully deployed and tested
- BSCScan: https://testnet.bscscan.com/address/0x90D29a452e52982c9cEcD04B2ed788215Aa97ce3
- Total Tests: 63/63 passing (100% success rate)
- Coverage: All edge cases, tokenomics, and functionality tested
- Tokenomics Tests: 11/11 passing (100% coverage)
- Gas Optimization: Individual user updates ~46,792 gas, bulk updates ~165,154 gas
- Security: All access controls and validations verified
- Vesting Precision: High precision calculations with 1e18 accuracy
-
Start the server:
cd admin-dashboard python3 -m http.server 8081 -
Access dashboard: Open
http://localhost:8081in your browser -
Connect wallet: Use MetaMask or WalletConnect (ensure you're on BSC Testnet)
-
Start managing: All functions are available once connected
- Real-time Statistics: Live updates every 30 seconds
- Tax Management: Configure all tax components (0-10% max)
- Vesting Management: Create, modify, and monitor vesting schedules
- Participant Lookup: Detailed balance information for each user
- Emergency Controls: Pause/unpause, emergency unlock all, and burn admin rights
- Export Data: Download participant information as CSV
- Base Balance: Actual tokens held by user
- Transferable Balance: Tokens that can be transferred
- Locked Amount: Tokens still in vesting
- Vested Amount: Calculated vested amount
- Total Balance: Display balance including locked tokens
- 6-Month Cliff: No tokens unlocked before 6 months
- 1.2% Unlocks: Each phase releases exactly 1.2% of total allocation
- Alternating Intervals: 4 months, then 6 months, then 4 months, etc.
- Long-Term: Designed for 30+ unlock phases over 10+ years
- Large-Scale: Supports 50B token airdrop distribution
- Purpose: Allows admin to unlock a portion of locked tokens early
- Example: User has 1000 tokens locked -> Admin can unlock 500 tokens early -> Only 500 tokens remain for vesting period
- Function:
earlyRelease(address user, uint256 amount) - Restrictions: Cannot release more than remaining locked tokens
- Purpose: CRITICAL - Instantly unlocks ALL remaining tokens for a user
- Example: User has 1000 tokens locked -> Admin emergency unlocks ALL -> All 1000 tokens become immediately transferable
- Function:
emergencyUnlockAll(address user) - Restrictions: Only admin can call, requires active vesting schedule, cannot be undone
- Use Cases: Medical emergencies, legal requirements, contract bugs, or other critical situations
- Purpose: Allows admin to increase or decrease total allocation for a user
- Example: User has 1000 tokens locked -> Admin adds 1000 more tokens -> User now has 2000 tokens total for vesting
- Function:
modifyVestingSchedule(address user, uint256 newAmount) - Restrictions: New amount cannot be less than already unlocked tokens
- Purpose: Temporarily pause a vesting schedule without removing it
- Example: User has ongoing vesting -> Admin deactivates -> Vesting stops, but can be reactivated later
- Function:
deactivateVestingSchedule(address user) - Use Cases: Temporary suspension, investigations, or contract maintenance
- Purpose: Resume a previously deactivated vesting schedule
- Example: Previously paused vesting -> Admin reactivates -> Vesting continues from where it left off
- Function:
reactivateVestingSchedule(address user) - Restrictions: Can only reactivate deactivated schedules
- Purpose: Completely remove a vesting schedule and reclaim locked tokens
- Example: User has 1000 tokens locked -> Admin cancels -> 1000 tokens returned to contract allocation
- Function:
cancelVestingSchedule(address user) - Effects: Reduces total allocated tokens, permanently stops vesting
- Use Cases: Fraud detection, contract violations, emergency situations
- Purpose: Change the classification of a vesting schedule between airdrop and non-airdrop
- Function:
toggleAirdropStatus(address user) - Use Cases: Correcting misclassified vesting schedules, reporting purposes
- Purpose: Programmatically check if a vesting schedule is complete
- Function:
isVestingComplete(address user) -> bool - Returns:
trueif all tokens have been unlocked,falseotherwise
- Purpose: Automatically deactivate vesting schedules when 100% complete
- Trigger: Called when
updateUnlockedAmountsForUser()detects completion - Event: Emits
VestingScheduleCompleted(user, totalAmount, timestamp) - Benefits: Gas optimization, clean state management, clear completion tracking
// Deploy Integrated MSVP Token with Vesting
const MSVP = await ethers.getContractFactory("MSVP");
const msvpToken = await MSVP.deploy(lpWallet, marketingWallet, developmentWallet);Create a CSV file with the following format:
address,amount
0x1234567890123456789012345678901234567890,10000
0x2345678901234567890123456789012345678901,15000- Open
admin-dashboard/index.htmlin a web browser - Connect MetaMask wallet
- Upload CSV file
- Create vesting schedules (automatic start)
- Monitor and manage participants
// Check unlocked amount
const unlocked = await msvpToken.getUnlockedAmount(userAddress);
// Check locked amount
const locked = await msvpToken.getLockedAmount(userAddress);
// Check transferable balance (includes unlocked tokens)
const transferable = await msvpToken.transferableBalance(userAddress);
// Manual update of unlocked amounts (optional)
await msvpToken.updateUnlockedAmountsForUser(userAddress); // Gas efficient
await msvpToken.updateUnlockedAmounts(); // All participants (high gas)// Update transfer tax rate (0-100, max 10%)
await msvpToken.updateTransferTaxRate(50); // 5%
// Update individual tax components
await msvpToken.updateLPContributionRate(20);
await msvpToken.updateDevelopmentRate(15);
await msvpToken.updateMarketingRate(10);
await msvpToken.updateBurnRate(5);
// Exclude address from tax
await msvpToken.setTaxExclusion(address, true);// Create individual vesting schedule (automatic start)
// ✔ FIXED: Now transfers tokens to user + creates vesting schedule
await msvpToken.createVestingSchedule(userAddress, amount);
// Create batch vesting schedules from CSV
// ✔ FIXED: Now transfers tokens to all users + creates vesting schedules
await msvpToken.createVestingSchedules(addresses, amounts);
// Check vesting requirements before bulk operations (view function)
const requirements = await msvpToken.checkVestingRequirements(addresses, amounts);
console.log(`Total tokens needed: ${requirements.totalTokensNeeded}`);
console.log(`Admin balance: ${requirements.adminBalance}`);
console.log(`Can proceed: ${requirements.canProceed}`);
console.log(`Valid entries: ${requirements.validEntries}`);
// Early release for specific user
await msvpToken.earlyRelease(userAddress, amount);
// Emergency unlock ALL remaining tokens for a user
await msvpToken.emergencyUnlockAll(userAddress);
// Modify vesting schedule (can increase or decrease total allocation)
await msvpToken.modifyVestingSchedule(userAddress, newAmount);
// Vesting Schedule Management
await msvpToken.deactivateVestingSchedule(userAddress); // Pause vesting
await msvpToken.reactivateVestingSchedule(userAddress); // Resume vesting
await msvpToken.cancelVestingSchedule(userAddress); // Cancel completely (emergency)
await msvpToken.toggleAirdropStatus(userAddress); // Toggle airdrop classification
// Check vesting status
const isComplete = await msvpToken.isVestingComplete(userAddress);
// Update unlocked amounts (auto-deactivates when complete)
await msvpToken.updateUnlockedAmountsForUser(userAddress); // Single user
await msvpToken.updateUnlockedAmounts(); // All participants
// Check balances
const baseBalance = await msvpToken.balanceOf(userAddress);
const transferableBalance = await msvpToken.transferableBalance(userAddress);
const lockedAmount = await msvpToken.getLockedAmount(userAddress);Problem: The original createVestingSchedules function only created vesting schedule records without actually transferring tokens to users. This caused:
- Users to have 0 actual token balance
- Vesting logic to fail completely
balanceOf()to show locked amounts but no real tokens
Solution: Updated both createVestingSchedule and createVestingSchedules functions to:
- Transfer tokens first from admin to users
- Create vesting schedules with the transferred tokens
- Ensure users have actual token balance to start vesting
- Add balance validation before operations
- Emit events for token transfers
New Features Added:
checkVestingRequirements()- View function to check bulk operation feasibilityTokensTransferredForVestingevent - Track token transfers during vesting creation- Balance validation - Prevents operations when admin has insufficient tokens
Result: Users now receive actual tokens and can participate in vesting immediately!
npm test# Integrated Token Tests
npx hardhat test test/MSVP.test.jsnpm run coverage# Run only tokenomics tests
npm test -- --grep "Tokenomics-Specific Vesting Tests"
# Test coverage includes:
# - 6-Month Cliff Period (2 tests)
# - 1.2% Unlock Pattern (2 tests)
# - Large-Scale Airdrop Testing (2 tests)
# - Cumulative Unlock Tracking (2 tests)
# - Transfer Restrictions (1 test)
# - Early Release with Constraints (1 test)
# - Gas Optimization (1 test)REPORT_GAS=true npm testTokenAirdrop/
├── contracts/
│ └── MSVP.sol # MetaSoilVerseProtocol token with vesting (RECOMMENDED)
├── scripts/
│ ├── deploy-integrated.js # Integrated token deployment
│ ├── deploy-bsc-testnet.js # BSC testnet deployment
│ └── check-balance.js # Balance checking utility
├── test/
│ └── MSVP.test.js # Integrated token tests
├── admin-dashboard/
│ ├── index.html # Dashboard UI
│ ├── dashboard.js # Dashboard logic
│ ├── deployment-info.json # Deployment details
│ └── README.md # Dashboard documentation
├── sample-airdrop.csv # Sample CSV file
├── hardhat.config.js # Hardhat configuration
├── package.json # Dependencies
├── env.example # Environment variables template
├── DEPLOYMENT_GUIDE.md # Deployment instructions
├── BSCSCAN_INSTRUCTIONS.md # BSCScan interaction guide
└── README.md # This file
- Reentrancy Protection: Prevents reentrancy attacks
- Ownership Controls: Admin-only functions
- Pausable: Emergency pause functionality
- Max Transaction Limits: Prevents large dumps
- Tax Exclusions: Configurable tax exemptions
- High Precision: 1e18 precision to prevent rounding errors
- Overflow Protection: Comprehensive validation
- Non-reentrant Updates: Safe update functions
- Admin Controls: Restricted admin functions
- Emergency Controls: Pause/unpause and admin rights burning
- Immutable Parameters: Core vesting parameters cannot be changed
- Transparency: All schedules publicly viewable
- Inconsistency Detection: Audit trail for edge cases
- Network ID: 97
- RPC URL:
https://data-seed-prebsc-1-s1.binance.org:8545/ - Explorer:
https://testnet.bscscan.com/
- Network ID: 56
- RPC URL:
https://bsc-dataseed.binance.org/ - Explorer:
https://bscscan.com/
The MSVP contract implements a sophisticated balance management system with three different balance types to handle vested tokens:
function balanceOf(address account) public view override returns (uint256) {
uint256 baseBalance = super.balanceOf(account);
uint256 lockedAmount = getLockedAmount(account);
return baseBalance + lockedAmount;
}What users see:
- Total tokens = Regular tokens + Locked (vested) tokens
- Purpose: Shows complete token ownership for display in wallets
- Example: If user has 1,000 regular tokens + 10,000 locked tokens = 11,000 tokens displayed
What this represents:
- Actual ERC20 tokens held in the wallet
- Freely transferable without restrictions
- Not subject to vesting rules
function transferableBalance(address account) public view returns (uint256) {
uint256 baseBalance = super.balanceOf(account);
uint256 unlockedAmount = getUnlockedAmount(account);
return baseBalance + unlockedAmount;
}What users can actually use:
- Base tokens + Unlocked vested tokens
- Maximum amount available for transfers
- Real spendable balance
Each user has a VestingSchedule that tracks:
totalAmount: Total tokens allocated (e.g., 1M tokens)unlockedAmount: Tokens unlocked so far (updated over time)startTime: When vesting began (TGE - Token Generation Event)isActive: Whether vesting is currently active
The contract implements the exact vesting schedule:
| Phase | Month | Unlock % | Notes | Tokens Released | Cumulative % | Cumulative Tokens |
|---|---|---|---|---|---|---|
| Cliff M0 | 0 | 0 | Cliff period | 0 | 0 | 0 |
| Cliff M6 | 6 | 0 | Cliff period | 0 | 0 | 0 |
| Q1 | 7 | 1.2 | First year release | 600,000,000 | 1.2 | 600,000,000 |
| Q2 | 10 | 1.2 | First year release | 600,000,000 | 2.4 | 1,200,000,000 |
| Q3 | 13 | 1.2 | First year release | 600,000,000 | 3.6 | 1,800,000,000 |
| Q4 | 16 | 1.2 | First year release | 600,000,000 | 4.8 | 2,400,000,000 |
| Q5 | 19 | 1.2 | Extended release | 600,000,000 | 6 | 3,000,000,000 |
| Q6 | 22 | 7 | Post-Q5 unlock | 3,500,000,000 | 13 | 6,500,000,000 |
| Q7 | 25 | 7 | Post-Q5 unlock | 3,500,000,000 | 20 | 10,000,000,000 |
| Q8 | 28 | 7 | Post-Q5 unlock | 3,500,000,000 | 27 | 13,500,000,000 |
| Q9 | 31 | 7 | Post-Q5 unlock | 3,500,000,000 | 34 | 17,000,000,000 |
| Q10 | 34 | 7 | Post-Q5 unlock | 3,500,000,000 | 41 | 20,500,000,000 |
| Q11 | 37 | 7 | Post-Q5 unlock | 3,500,000,000 | 48 | 24,000,000,000 |
| Q12 | 40 | 7 | Post-Q5 unlock | 3,500,000,000 | 55 | 27,500,000,000 |
| Q13 | 43 | 7 | Post-Q5 unlock | 3,500,000,000 | 62 | 31,000,000,000 |
| Q14 | 46 | 7 | Post-Q5 unlock | 3,500,000,000 | 69 | 34,500,000,000 |
| Q15 | 49 | 7 | Post-Q5 unlock | 3,500,000,000 | 76 | 38,000,000,000 |
| Q16 | 52 | 6 | Final period | 3,000,000,000 | 82 | 41,000,000,000 |
| Q17 | 55 | 6 | Final period | 3,000,000,000 | 88 | 44,000,000,000 |
| Q18 | 58 | 6 | Final period | 3,000,000,000 | 94 | 47,000,000,000 |
| Q19 | 61 | 6 | Final unlock | 3,000,000,000 | 100 | 50,000,000,000 |
The contract automatically updates unlocked amounts during:
-
Token Transfers:
// In _transfer function if (isParticipant[from]) { updateUnlockedAmountsForUser(from); }
-
Manual Updates: Admin or users can call
updateUnlockedAmountsForUser() -
Bulk Updates: Admin can update all participants with
updateUnlockedAmounts()
-
Transferable Balance Check:
uint256 transferable = transferableBalance(from); require(transferable >= amount, "Insufficient transferable balance");
- Users cannot transfer locked tokens
- Only base balance + unlocked vested tokens are transferable
-
💸 Transaction Limits:
require(amount <= maxTxAmount, "Transfer amount exceeds max transaction limit");
- Default: 1% of total supply per transaction
- Can be modified by admin
- Certain addresses can be excluded
-
Transfer Tax (5% default):
- 2% to LP wallet
- 1.5% to development
- 1% to marketing
- 0.5% burned
Let's say Alice has an airdrop allocation:
Alice's Address: 0x123...
├── Display Balance (balanceOf): 10,000,000 tokens
├── Transferable Balance: 0 tokens
├── Locked Amount: 10,000,000 tokens
└── Unlocked Amount: 0 tokens (cliff period)
Alice's Address: 0x123...
├── Display Balance: 10,000,000 tokens (unchanged)
├── Base Balance: 0 tokens
├── Transferable Balance: 120,000 tokens ✔
├── Locked Amount: 9,880,000 tokens
└── Unlocked Amount: 120,000 tokens (1.2% unlocked)
Alice's Address: 0x123...
├── Display Balance: 10,001,000 tokens
├── Base Balance: 1,000 tokens
├── Transferable Balance: 121,000 tokens ✔
├── Locked Amount: 9,880,000 tokens
└── Unlocked Amount: 120,000 tokens
- Check Display Balance:
balanceOf(address)- Shows total ownership - Check Transferable:
transferableBalance(address)- Shows spendable amount - Transfer Tokens: Regular
transfer()with automatic vesting updates - Update Vesting: Call
updateUnlockedAmountsForUser()to refresh unlocked amounts
// Get complete user balance information
const displayBalance = await contract.balanceOf(userAddress);
const transferableBalance = await contract.transferableBalance(userAddress);
const lockedAmount = await contract.getLockedAmount(userAddress);
const unlockedAmount = await contract.getUnlockedAmount(userAddress);
// Display to user
console.log({
total: displayBalance, // What user "owns"
available: transferableBalance, // What user can "spend"
locked: lockedAmount, // What's still vesting
unlocked: unlockedAmount // What's been unlocked from vesting
});- Individual Updates:
updateUnlockedAmountsForUser()- Gas efficient - Automatic Updates: During transfers - No extra gas needed
- Bulk Updates:
updateUnlockedAmounts()- Admin only, gas expensive - View Functions: All balance queries are gas-free
- Immutable Vesting Logic: Once schedule is set, unlock timing cannot be changed
- Admin Controls: Early release and schedule modifications (with restrictions)
- Pause Functionality: Emergency stop for all transfers
- Overflow Protection: SafeMath and modern Solidity version
- Reentrancy Protection:
ReentrancyGuardimplementation
This design ensures that users can see their complete token ownership while only being able to spend what's actually available, providing transparency and security in the vesting process.
-
Creation (
isActive = true)- Schedule created with
createVestingSchedule() - Tokens allocated but locked during cliff period
- User appears in participant list
- Schedule created with
-
Active Vesting (
isActive = true)- Tokens unlock according to tokenomics schedule
updateUnlockedAmountsForUser()updates available amounts- Transfers automatically update vesting progress
-
Completion & Auto-Deactivation (
isActive = false)- Automatic: When 100% of tokens are unlocked
- Event:
VestingScheduleCompletedemitted - Benefits: Gas optimization, clean state management
// Pause vesting temporarily
await msvpToken.deactivateVestingSchedule(userAddress);
// Resume paused vesting
await msvpToken.reactivateVestingSchedule(userAddress);
// Emergency cancellation (permanent)
await msvpToken.cancelVestingSchedule(userAddress);
// Check completion status
const isComplete = await msvpToken.isVestingComplete(userAddress);Created → Active Vesting → Auto-Deactivated (Complete)
↓ ↓ ↑
↓ Manual Pause → Manual Resume
↓
→ Emergency Cancel (Permanent)
The contract implements a sophisticated tokenomics-based vesting system:
- 6-Month Cliff Period: No tokens are unlocked before 6 months from TGE
- 1.2% Unlock Pattern: Each unlock phase releases exactly 1.2% of the total allocation
- Alternating Intervals:
- Phase 1: 6 months (first unlock)
- Phase 2: 4 months later (10 months total)
- Phase 3: 6 months later (16 months total)
- Phase 4: 4 months later (20 months total)
- And so on...
- Long-Term Support: Designed for 30+ unlock phases over 10+ years
- Large-Scale: Handles 50B token airdrop distribution efficiently
- Unlock Amount:
(totalAllocation * 12) / 1000(1.2% = 12/1000) - Time Calculation: Precise timestamp-based calculations
- Cumulative Tracking: Accurate progression through unlock phases
- High Precision: 1e18 precision to prevent rounding errors
The system includes comprehensive tests covering:
- ✔ 6-Month cliff period enforcement
- ✔ 1.2% unlock pattern accuracy
- ✔ Alternating 4-6 month intervals
- ✔ Large-scale 50B token distribution
- ✔ 30+ unlock phases over 10 years
- ✔ Cumulative unlock tracking
- ✔ Transfer restrictions during vesting
- ✔ Early release with tokenomics constraints
- ✔ Gas optimization for large operations
- Use
updateUnlockedAmountsForUser()for individual participants (low gas) - Use
updateUnlockedAmounts()sparingly for all participants (high gas) - Automatic updates occur during transfers
- Monitor gas usage for large operations
- Maximum tax rate: 10% (100/1000)
- Individual components cannot exceed total tax rate
- Zero tax rate is supported
- All tax components are configurable
- Tokenomics-Based: 6-month cliff with 1.2% unlocks every 4-6 months alternating
- Automatic unlocking: No manual claiming required
- High precision calculations: 1e18 precision for accurate calculations
- Inconsistency detection: Audit trail for edge cases
- Long-term support: 30+ unlock phases over 10+ years
- Large-scale: Handles 50B token airdrop distribution
- Early release: Admin can release specific amounts within constraints
- Transfer restrictions: Locked tokens visible but non-transferable
- Always test on testnet before mainnet deployment
- Verify all functions work as expected
- Check gas usage for large operations
- Test edge cases and error conditions
- Ensure you're on BSC Testnet (chainId: 97)
- Check if MetaMask is installed and unlocked
- Verify you're the contract owner
- Clear browser cache and localStorage if needed
- Check gas limits and fees
- Ensure sufficient BNB for gas
- Verify input parameters are valid
- Check if contract is paused
- Refresh the page if statistics don't update
- Check browser console for errors
- Ensure JavaScript is enabled
- Clear browser cache
For support and questions:
- Create an issue in the repository
- Check the test files for usage examples
- Review the contract comments for detailed explanations
- Check the browser console for error messages
- Verify contract address and network settings
- v3.0.0: Tokenomics-Based Vesting - Implemented sophisticated vesting schedule with 6-month cliff, 1.2% unlocks every 4-6 months alternating, 30+ unlock phases over 10+ years, 50B airdrop support, comprehensive test coverage (63/63 tests passing)
- v2.0.0: Enhanced balance management, gas optimization, automatic vesting, high precision calculations, inconsistency detection
- v1.0.0: Initial release with basic token and vesting system
-
Emergency Unlock ALL Function
emergencyUnlockAll(address user)- Instantly unlock all remaining tokens- Complete emergency override for critical situations
- Comprehensive test coverage and admin dashboard integration
-
Complete Vesting Schedule Management
deactivateVestingSchedule(address user)- Pause vesting temporarilyreactivateVestingSchedule(address user)- Resume paused vestingcancelVestingSchedule(address user)- Permanently cancel vesting (emergency)toggleAirdropStatus(address user)- Toggle airdrop classificationisVestingComplete(address user)- Check completion status
-
🔄 Automatic Lifecycle Management
- Auto-deactivation when vesting reaches 100% completion
- Gas optimization by deactivating completed schedules
- VestingScheduleCompleted event emission for tracking
- Clean state management with clear active/inactive distinction
-
Removed
releaseIntervalParameter (Breaking Change)- Before:
createVestingSchedule(user, amount, releaseInterval) - After:
createVestingSchedule(user, amount) - Reason: Parameter was unused due to hardcoded tokenomics schedule
- Migration: Remove the third parameter from all function calls
- Before:
-
Updated Event Signatures
- Before:
VestingScheduleCreated(user, amount, startTime, endTime, releaseInterval) - After:
VestingScheduleCreated(user, amount, startTime, endTime)
- Before:
-
Enhanced
isVestingComplete()Function- Now works correctly for both active and deactivated schedules
- Returns
truefor completed schedules even after auto-deactivation
-
Improved Admin Dashboard
- Added emergency unlock ALL button with confirmation dialogs
- Removed unused interval selection inputs
- Updated CSV format documentation (now:
address,amount)
- 32 comprehensive tests including new management functions
- 6 new tests specifically for vesting schedule management
- 100% test coverage for all new functionality
- Backward compatibility verified for existing features
- Tokenomics-based vesting with precise 61-month schedule
- Early release and schedule modification functions
- Comprehensive admin dashboard
- Transfer tax system with multiple recipient wallets
This project is licensed under the MIT License.
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests for new functionality
- Ensure all tests pass
- Submit a pull request