Get your MiniSudoku game running in 5 minutes!
- Node.js 18+ installed
- A wallet with Base Sepolia ETH (for testnet deployment)
- MetaMask or similar Web3 wallet
# Navigate to project
cd C:\Users\HomePC\nft-drop-signal
# Create environment file
copy .env.local.example .env.local
# Edit .env.local and add your private key
# PRIVATE_KEY=your_private_key_hereDependencies are already installed. If you need to reinstall:
npm installnpm run devOpen http://localhost:3000 in your browser.
You'll see:
- 🎮 MiniSudoku title with metallic gold text
- Leaf green themed interface
- "Connect Wallet" button
- Beautiful gradient backgrounds
Click "Connect Wallet" to get a simulated wallet and start playing!
- Connect Wallet: Click button to get a mock wallet address
- Select Difficulty: Choose Easy, Medium, or Hard
- Pay & Play: Click to simulate payment ($0.30 USDC)
- Play Sudoku:
- Click a cell to select it
- Use number pad to fill in numbers
- Invalid numbers show in red
- Complete the puzzle to win!
- View Stats: Check Pool Stats and Leaderboard on the right
# Compile contract
npm run compile
# Deploy to Base Sepolia
npm run deployCopy the contract address and add to .env.local:
NEXT_PUBLIC_MINISUDOKU_CONTRACT=0xYourContractAddress
Then restart dev server:
npm run dev- Local dev server runs without errors
- UI shows leaf green theme with metallic text
- Can connect wallet (mock)
- Can select difficulty level
- Sudoku board renders correctly
- Can select cells and input numbers
- Invalid placements show in red
- Pool stats display (mock data)
- Leaderboard displays (mock data)
- Responsive on mobile view
When you're ready to go live:
# Install Vercel CLI
npm i -g vercel
# Deploy
vercel
# Follow promptsThen set environment variables in Vercel dashboard.
# Kill process on port 3000
npx kill-port 3000
# Or use different port
npm run dev -- -p 3001# Clear cache and reinstall
rm -rf node_modules package-lock.json
npm install# Check for type errors
npm run lint- Ensure you have Base Sepolia ETH
- Check your private key in
.env.local - Verify RPC URL is correct
-
Colors (
src/app/globals.css):- Adjust green shades
- Modify metallic text gradient
-
Entry Fee (
contracts/MiniSudoku.sol):- Change
ENTRY_FEE,POOL_AMOUNT,CREATOR_AMOUNT - Must redeploy contract after changes
- Change
-
Difficulty (
src/lib/sudoku.ts):- Adjust cells removed in
cellsToRemoveobject
- Adjust cells removed in
-
UI Text (
src/app/page.tsx):- Customize titles, descriptions, button labels
src/
├── app/
│ ├── page.tsx ← Main game page (START HERE)
│ ├── globals.css ← Theme colors
│ └── api/ ← Backend routes
├── components/
│ ├── SudokuBoard.tsx ← Game board
│ ├── PoolStats.tsx ← Prize pool display
│ └── Leaderboard.tsx ← Rankings
└── lib/
├── sudoku.ts ← Game logic
├── contract.ts ← Blockchain
└── x402.ts ← Payments
contracts/
└── MiniSudoku.sol ← Smart contract
✅ Full Sudoku game with validation ✅ Beautiful leaf green UI with metallic text ✅ Difficulty selection (Easy/Medium/Hard) ✅ Mock wallet connection ✅ Mock leaderboard and pool stats ✅ Puzzle generation and solving ✅ Responsive design
⏳ Real wallet connection (WalletConnect/MetaMask) ⏳ Actual USDC payments via x402 ⏳ On-chain win tracking ⏳ Real-time leaderboard from blockchain ⏳ Prize pool distribution ⏳ Farcaster Frame integration
Your MiniSudoku game is ready for local testing. Enjoy the sleek leaf green interface and competitive gameplay!
Questions? Check PROJECT_SUMMARY.md for full details or DEPLOYMENT_GUIDE.md for production deployment.