Initial commit: CunaFinanceBsc smart contract

- Add upgradeable smart contract with vesting and staking functionality
- Include comprehensive deployment script for proxy deployments and upgrades
- Configure Hardhat with BSC testnet and verification support
- Successfully deployed to BSC testnet at 0x12d705781764b7750d5622727EdA2392b512Ca3d

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
2025-09-10 02:15:20 +02:00
commit 8a802718d3
49 changed files with 7667 additions and 0 deletions

View File

@@ -0,0 +1,18 @@
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.20;
import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
contract MockERC20 is ERC20 {
constructor(
string memory name,
string memory symbol,
uint256 initialSupply
) ERC20(name, symbol) {
_mint(msg.sender, initialSupply);
}
function mint(address to, uint256 amount) external {
_mint(to, amount);
}
}

View File

@@ -0,0 +1,20 @@
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.20;
contract MockPriceOracle {
mapping(address => uint256) public prices;
uint256 private defaultPrice = 1e18; // $1.00 default price
function setPrice(address token, uint256 price) external {
prices[token] = price;
}
function getLatestPrice(address token) external view returns (uint256) {
uint256 price = prices[token];
return price == 0 ? defaultPrice : price;
}
function setDefaultPrice(uint256 price) external {
defaultPrice = price;
}
}