Created Implementation Guide & TODO Tasks - Complete roadmap for integration & UI creation
This commit is contained in:
505
docs/IMPLEMENTATION_GUIDE.md
Normal file
505
docs/IMPLEMENTATION_GUIDE.md
Normal file
@@ -0,0 +1,505 @@
|
||||
# KRVAVA ŽETEV - Implementation Guide
|
||||
## System Integration & UI Creation Plan
|
||||
|
||||
**Datum:** 23.12.2025
|
||||
**Cilj:** Integrate all 46 systems into GameScene.js and create all required UIs
|
||||
|
||||
---
|
||||
|
||||
## 📊 CURRENT STATUS
|
||||
|
||||
**Systems Created:** 46
|
||||
**Lines of Code:** 22,596
|
||||
**Phases Complete:** 30/30 (100%)
|
||||
**Game Status:** Systems ready, needs integration
|
||||
|
||||
---
|
||||
|
||||
## 🎯 PHASE 1: QUICK WINS (1-2 hours)
|
||||
|
||||
### 1.1 Add Missing System Imports to index.html
|
||||
**Status:** ⏳ To Do
|
||||
**Time:** 15 minutes
|
||||
|
||||
**Missing Systems to Add:**
|
||||
- [ ] MiningSystem.js
|
||||
- [ ] CharacterCustomizationSystem.js
|
||||
- [ ] TimeSystem.js (check if different from WeatherSystem)
|
||||
- [ ] TownRestorationSystem.js
|
||||
- [ ] PortalRepairSystem.js
|
||||
- [ ] SmartZombieSystem.js
|
||||
- [ ] ToolSystem.js
|
||||
- [ ] AnaClueSystem.js
|
||||
- [ ] PyramidSystem.js
|
||||
- [ ] SlimesDogsSystem.js
|
||||
- [ ] AnimalsSeedsSystem.js
|
||||
- [ ] AutomationSystem.js
|
||||
- [ ] InventorySystemExpanded.js
|
||||
|
||||
**Action:**
|
||||
```html
|
||||
<!-- Add before GameScene.js (line 212) -->
|
||||
<script src="src/systems/MiningSystem.js"></script>
|
||||
<script src="src/systems/CharacterCustomizationSystem.js"></script>
|
||||
<script src="src/systems/TimeSystem.js"></script>
|
||||
<script src="src/systems/TownRestorationSystem.js"></script>
|
||||
<script src="src/systems/PortalRepairSystem.js"></script>
|
||||
<script src="src/systems/SmartZombieSystem.js"></script>
|
||||
<script src="src/systems/ToolSystem.js"></script>
|
||||
<script src="src/systems/AnaClueSystem.js"></script>
|
||||
<script src="src/systems/PyramidSystem.js"></script>
|
||||
<script src="src/systems/SlimesDogsSystem.js"></script>
|
||||
<script src="src/systems/AnimalsSeedsSystem.js"></script>
|
||||
<script src="src/systems/AutomationSystem.js"></script>
|
||||
<script src="src/systems/InventorySystemExpanded.js"></script>
|
||||
```
|
||||
|
||||
### 1.2 Test System Loading
|
||||
**Status:** ⏳ To Do
|
||||
**Time:** 10 minutes
|
||||
|
||||
**Action:**
|
||||
1. Hard reload browser (Ctrl+Shift+R)
|
||||
2. Check console for errors
|
||||
3. Verify all systems load without conflicts
|
||||
|
||||
### 1.3 Fix Any Export/Import Issues
|
||||
**Status:** ⏳ To Do
|
||||
**Time:** 30 minutes
|
||||
|
||||
**Known Issues:**
|
||||
- Some systems might use ES6 export (like DialogueSystem did)
|
||||
- Check all new systems for `export` keywords
|
||||
- Remove if found
|
||||
|
||||
### 1.4 Basic Smoke Tests
|
||||
**Status:** ⏳ To Do
|
||||
**Time:** 15 minutes
|
||||
|
||||
**Tests:**
|
||||
- [ ] Game launches
|
||||
- [ ] No console errors
|
||||
- [ ] Player spawns
|
||||
- [ ] Basic movement works
|
||||
|
||||
---
|
||||
|
||||
## 🔧 PHASE 2: SYSTEM INTEGRATION (4-6 hours)
|
||||
|
||||
### 2.1 Initialize All Systems in GameScene.create()
|
||||
**Status:** ⏳ To Do
|
||||
**Time:** 2 hours
|
||||
|
||||
**Current GameScene Systems:** ~40
|
||||
**New Systems to Add:** 13
|
||||
|
||||
**Integration Pattern:**
|
||||
```javascript
|
||||
// In GameScene.create(), add after line 800:
|
||||
|
||||
// ========================================================
|
||||
// 🆕 NEW SYSTEMS (P16-P30) - 23.12.2025
|
||||
// ========================================================
|
||||
console.log('🆕 Initializing New Systems (P16-P30)...');
|
||||
|
||||
// P16: Mining System
|
||||
console.log('⛏️ Initializing Mining System...');
|
||||
this.miningSystem = new MiningSystem(this);
|
||||
|
||||
// P17: Character Customization
|
||||
console.log('👤 Initializing Character Customization...');
|
||||
this.characterCustomization = new CharacterCustomizationSystem(this);
|
||||
|
||||
// P18: Time System (if different from WeatherSystem)
|
||||
console.log('🕐 Initializing Time System...');
|
||||
this.timeSystem = new TimeSystem(this);
|
||||
|
||||
// P19: Town Restoration
|
||||
console.log('🏘️ Initializing Town Restoration...');
|
||||
this.townRestoration = new TownRestorationSystem(this);
|
||||
|
||||
// P20: Portal Repair
|
||||
console.log('🌀 Initializing Portal Repair...');
|
||||
this.portalRepair = new PortalRepairSystem(this);
|
||||
|
||||
// P22: Smart Zombies
|
||||
console.log('🧠 Initializing Smart Zombies...');
|
||||
this.smartZombies = new SmartZombieSystem(this);
|
||||
|
||||
// P23: Tool System
|
||||
console.log('🔧 Initializing Tool System...');
|
||||
this.toolSystem = new ToolSystem(this);
|
||||
|
||||
// P25: Ana's Clues
|
||||
console.log('💜 Initializing Ana Clues...');
|
||||
this.anaClues = new AnaClueSystem(this);
|
||||
|
||||
// P26: Pyramids
|
||||
console.log('🏜️ Initializing Pyramid System...');
|
||||
this.pyramids = new PyramidSystem(this);
|
||||
|
||||
// P27: Slimes & Dogs
|
||||
console.log('🟢🐶 Initializing Slimes & Dogs...');
|
||||
this.slimesDogs = new SlimesDogsSystem(this);
|
||||
|
||||
// P28: Animals & Seeds
|
||||
console.log('🐄🌱 Initializing Animals & Seeds...');
|
||||
this.animalsSeeds = new AnimalsSeedsSystem(this);
|
||||
|
||||
// P29: Automation
|
||||
console.log('⚙️ Initializing Automation...');
|
||||
this.automation = new AutomationSystem(this);
|
||||
|
||||
// P30: Inventory Expanded
|
||||
console.log('🎒 Initializing Inventory Expansion...');
|
||||
this.inventoryExpanded = new InventorySystemExpanded(this, this.inventorySystem);
|
||||
```
|
||||
|
||||
### 2.2 Connect System Communications
|
||||
**Status:** ⏳ To Do
|
||||
**Time:** 1-2 hours
|
||||
|
||||
**Key Integrations:**
|
||||
|
||||
#### A. SmartZombieSystem ↔ ZombieSystem
|
||||
```javascript
|
||||
// Connect smart zombie features to base zombie system
|
||||
this.smartZombies.onZombieUpgraded = (zombieId, level) => {
|
||||
this.zombieSystem.upgradeIntelligence(zombieId, level);
|
||||
};
|
||||
```
|
||||
|
||||
#### B. ToolSystem ↔ InventorySystem
|
||||
```javascript
|
||||
// Tools affect inventory durability
|
||||
this.toolSystem.onToolBreak = (toolId) => {
|
||||
this.inventorySystem.removeItem(toolId, 1);
|
||||
};
|
||||
```
|
||||
|
||||
#### C. AutomationSystem ↔ Multiple Systems
|
||||
```javascript
|
||||
// Automation connects to farming, zombies, inventory
|
||||
this.automation.farmingSystem = this.farmingSystem;
|
||||
this.automation.zombieSystem = this.smartZombies;
|
||||
this.automation.inventorySystem = this.inventoryExpanded;
|
||||
```
|
||||
|
||||
#### D. AnaClueSystem ↔ TwinBondSystem
|
||||
```javascript
|
||||
// Clues trigger Twin Bond events
|
||||
this.anaClues.onClueFound = (clueId) => {
|
||||
this.twinBondSystem.triggerMemory(clueId);
|
||||
};
|
||||
```
|
||||
|
||||
#### E. PyramidSystem ↔ QuestSystem
|
||||
```javascript
|
||||
// Pyramid exploration triggers quests
|
||||
this.pyramids.onPyramidEntered = (pyramidId) => {
|
||||
this.questSystemExpanded.checkPyramidQuests(pyramidId);
|
||||
};
|
||||
```
|
||||
|
||||
### 2.3 Update GameScene.update()
|
||||
**Status:** ⏳ To Do
|
||||
**Time:** 1 hour
|
||||
|
||||
**Add Daily Updates:**
|
||||
```javascript
|
||||
// In GameScene.update(time, delta):
|
||||
|
||||
// Update automation daily
|
||||
if (this.automation) {
|
||||
this.automation.runDailyAutomation();
|
||||
}
|
||||
|
||||
// Update animals & breeding
|
||||
if (this.animalsSeeds) {
|
||||
this.animalsSeeds.updateLivestock();
|
||||
this.animalsSeeds.updateTrees(this.currentSeason);
|
||||
}
|
||||
|
||||
// Update smart zombies
|
||||
if (this.smartZombies) {
|
||||
this.smartZombies.updateZombies(delta);
|
||||
}
|
||||
|
||||
// Update town restoration
|
||||
if (this.townRestoration) {
|
||||
this.townRestoration.updateConstruction(delta);
|
||||
}
|
||||
|
||||
// Update portal repair
|
||||
if (this.portalRepair) {
|
||||
this.portalRepair.updateConstruction(delta);
|
||||
}
|
||||
```
|
||||
|
||||
### 2.4 Testing & Debugging
|
||||
**Status:** ⏳ To Do
|
||||
**Time:** 1 hour
|
||||
|
||||
**Test Each System:**
|
||||
- [ ] MiningSystem - Enter a mine
|
||||
- [ ] Character Customization - Create character
|
||||
- [ ] TimeSystem - Day/night cycle
|
||||
- [ ] TownRestoration - Restore a building
|
||||
- [ ] PortalRepair - Repair a portal
|
||||
- [ ] SmartZombies - Level up zombie
|
||||
- [ ] ToolSystem - Use and break tool
|
||||
- [ ] AnaClues - Find a clue
|
||||
- [ ] Pyramids - Enter pyramid
|
||||
- [ ] SlimesDogs - Spawn slime, adopt dog
|
||||
- [ ] AnimalsSeeds - Buy livestock, plant seeds
|
||||
- [ ] Automation - Build sprinkler
|
||||
- [ ] InventoryExpanded - Upgrade inventory
|
||||
|
||||
---
|
||||
|
||||
## 🎨 PHASE 3: UI CREATION (4-6 hours)
|
||||
|
||||
### 3.1 Character Creation Screen
|
||||
**Status:** ⏳ To Do
|
||||
**Time:** 1 hour
|
||||
**File:** `src/scenes/CharacterCreationScene.js`
|
||||
|
||||
**Features:**
|
||||
- Gender selection (Kai/Ana story reversal)
|
||||
- RGB hair color picker (10 presets + custom + rainbow/glowing)
|
||||
- Body customization (4 skin tones, 4 body types)
|
||||
- Starting outfit selection
|
||||
- Preview window
|
||||
- Confirm button
|
||||
|
||||
**Priority:** HIGH (game start)
|
||||
|
||||
### 3.2 Mining UI
|
||||
**Status:** ⏳ To Do
|
||||
**Time:** 30 minutes
|
||||
**File:** `src/ui/MiningUI.js`
|
||||
|
||||
**Features:**
|
||||
- Mine selection panel
|
||||
- Current depth indicator
|
||||
- Oxygen/radiation warning
|
||||
- Ore inventory
|
||||
- Elevator button
|
||||
- Boss warning
|
||||
|
||||
**Priority:** MEDIUM
|
||||
|
||||
### 3.3 Smart Zombie Command UI
|
||||
**Status:** ⏳ To Do
|
||||
**Time:** 45 minutes
|
||||
**File:** `src/ui/SmartZombieUI.js`
|
||||
|
||||
**Features:**
|
||||
- Zombie list (with intelligence levels)
|
||||
- Command buttons (Stop, Help, Attack, Home)
|
||||
- Follower management (max 10)
|
||||
- Team construction interface
|
||||
- XP display
|
||||
|
||||
**Priority:** HIGH (core gameplay)
|
||||
|
||||
### 3.4 Tool Management UI
|
||||
**Status:** ⏳ To Do
|
||||
**Time:** 30 minutes
|
||||
**File:** `src/ui/ToolUI.js`
|
||||
|
||||
**Features:**
|
||||
- Tool durability bars
|
||||
- Repair options (Ivan, Repair Kit, Blacksmith Zombie)
|
||||
- Upgrade menu (6 tiers)
|
||||
- Ultimate tools display
|
||||
|
||||
**Priority:** MEDIUM
|
||||
|
||||
### 3.5 Blueprint Gallery UI
|
||||
**Status:** ⏳ To Do
|
||||
**Time:** 45 minutes
|
||||
**File:** `src/ui/BlueprintGalleryUI.js`
|
||||
|
||||
**Features:**
|
||||
- Collection progress (X/35)
|
||||
- Category tabs (Buildings, Weapons, Bows, Vehicles, Special)
|
||||
- Discovery method indicators
|
||||
- Quest-locked visual indicators
|
||||
- Preview on hover
|
||||
|
||||
**Priority:** MEDIUM
|
||||
|
||||
### 3.6 Ana's Clue Collection UI
|
||||
**Status:** ⏳ To Do
|
||||
**Time:** 1 hour
|
||||
**File:** `src/ui/AnaClueUI.js`
|
||||
|
||||
**Features:**
|
||||
- Progress tracker (15 Messages, 12 Photos, 23 Items)
|
||||
- Gallery view with thumbnails
|
||||
- Story milestone indicators (6 milestones)
|
||||
- Clue description on click
|
||||
- Kai's reaction display
|
||||
|
||||
**Priority:** HIGH (story)
|
||||
|
||||
### 3.7 Town Restoration UI
|
||||
**Status:** ⏳ To Do
|
||||
**Time:** 45 minutes
|
||||
**File:** `src/ui/TownRestorationUI.js`
|
||||
|
||||
**Features:**
|
||||
- Town list (27 towns)
|
||||
- Building progress bars
|
||||
- NPC count (X/180)
|
||||
- Global milestone tracker
|
||||
- Zombie assignment
|
||||
|
||||
**Priority:** MEDIUM
|
||||
|
||||
### 3.8 Portal Repair UI
|
||||
**Status:** ⏳ To Do
|
||||
**Time:** 30 minutes
|
||||
**File:** `src/ui/PortalRepairUI.js`
|
||||
|
||||
**Features:**
|
||||
- Portal list (18 portals, 5 difficulty tiers)
|
||||
- Material requirements
|
||||
- Construction progress
|
||||
- Defend event warnings
|
||||
- Teleport button (when complete)
|
||||
|
||||
**Priority:** MEDIUM
|
||||
|
||||
### 3.9 Animal Shop UI
|
||||
**Status:** ⏳ To Do
|
||||
**Time:** 45 minutes
|
||||
**File:** `src/ui/AnimalShopUI.js`
|
||||
|
||||
**Features:**
|
||||
- Animal Rescue quest progress (0/8)
|
||||
- Livestock shop (16+ types)
|
||||
- Breeding interface (30-day countdown)
|
||||
- Rarity indicators (Common/Rare/Legendary/Mythic)
|
||||
|
||||
**Priority:** MEDIUM
|
||||
|
||||
### 3.10 Seed Shop UI
|
||||
**Status:** ⏳ To Do
|
||||
**Time:** 30 minutes
|
||||
**File:** `src/ui/SeedShopUI.js`
|
||||
|
||||
**Features:**
|
||||
- Season tabs (Spring, Summer, Fall, Winter)
|
||||
- 100+ seed varieties
|
||||
- Growth time display
|
||||
- Sell price preview
|
||||
- Greenhouse indicator
|
||||
|
||||
**Priority:** MEDIUM
|
||||
|
||||
### 3.11 Automation Control Panel
|
||||
**Status:** ⏳ To Do
|
||||
**Time:** 45 minutes
|
||||
**File:** `src/ui/AutomationUI.js`
|
||||
|
||||
**Features:**
|
||||
- Sprinkler management
|
||||
- Water tower status
|
||||
- Minting building controls
|
||||
- Auto-harvest worker assignment
|
||||
- Full automation status (requirements checklist)
|
||||
|
||||
**Priority:** LOW (endgame feature)
|
||||
|
||||
### 3.12 Inventory Expansion UI
|
||||
**Status:** ⏳ To Do
|
||||
**Time:** 30 minutes
|
||||
**File:** `src/ui/InventoryUpgradeUI.js`
|
||||
|
||||
**Features:**
|
||||
- Tier upgrade buttons (Jakob's shop)
|
||||
- Tool Belt unlock
|
||||
- Dog Backpack unlock
|
||||
- Quick Sort options
|
||||
- Stack All button
|
||||
- Quick Deposit button
|
||||
|
||||
**Priority:** HIGH (core gameplay)
|
||||
|
||||
---
|
||||
|
||||
## ✅ TESTING CHECKLIST
|
||||
|
||||
### System Integration Tests:
|
||||
- [ ] All 46 systems initialize without errors
|
||||
- [ ] No memory leaks
|
||||
- [ ] Systems communicate correctly
|
||||
- [ ] Save/load works with all systems
|
||||
- [ ] Performance is acceptable (60 FPS)
|
||||
|
||||
### UI Tests:
|
||||
- [ ] All UIs open/close correctly
|
||||
- [ ] Buttons are functional
|
||||
- [ ] Data displays correctly
|
||||
- [ ] Responsive to window resize
|
||||
- [ ] No visual bugs
|
||||
|
||||
### Gameplay Tests:
|
||||
- [ ] Start new game → Character Creation
|
||||
- [ ] Mine exploration
|
||||
- [ ] Zombie commands
|
||||
- [ ] Tool usage and repair
|
||||
- [ ] Blueprint discovery
|
||||
- [ ] Clue finding
|
||||
- [ ] Town restoration
|
||||
- [ ] Portal repair
|
||||
- [ ] Animal breeding
|
||||
- [ ] Seed planting
|
||||
- [ ] Automation setup
|
||||
- [ ] Inventory management
|
||||
|
||||
---
|
||||
|
||||
## 📝 ESTIMATED TIMELINE
|
||||
|
||||
**PHASE 1 (Quick Wins):** 1-2 hours
|
||||
**PHASE 2 (Integration):** 4-6 hours
|
||||
**PHASE 3 (UI Creation):** 4-6 hours
|
||||
|
||||
**TOTAL:** 9-14 hours
|
||||
|
||||
**If Starting Now (22:00):**
|
||||
- Quick Wins: 22:00-23:30
|
||||
- Integration: 23:30-05:30
|
||||
- UI Creation: 05:30-11:30
|
||||
|
||||
**Completion:** Tomorrow morning (11:30)
|
||||
|
||||
---
|
||||
|
||||
## 🎯 SUCCESS CRITERIA
|
||||
|
||||
✅ All 46 systems integrated into GameScene
|
||||
✅ All systems communicate correctly
|
||||
✅ All 12 UIs created and functional
|
||||
✅ Game is playable from start to finish
|
||||
✅ No critical bugs
|
||||
✅ Performance is stable
|
||||
|
||||
---
|
||||
|
||||
## 💡 TIPS
|
||||
|
||||
1. **Work in Batches:** Don't try to do everything at once
|
||||
2. **Test Frequently:** Test after each system integration
|
||||
3. **Use Console Logs:** Debug with extensive logging
|
||||
4. **Save Often:** Commit every major milestone
|
||||
5. **Take Breaks:** This is a marathon, not a sprint!
|
||||
|
||||
---
|
||||
|
||||
**Created:** 23.12.2025, 21:57
|
||||
**By:** Antigravity AI
|
||||
**Status:** Ready to Execute
|
||||
523
docs/TODO_TASKS.md
Normal file
523
docs/TODO_TASKS.md
Normal file
@@ -0,0 +1,523 @@
|
||||
# KRVAVA ŽETEV - TODO Task List
|
||||
## Naslednji Koraki za Integracijo
|
||||
|
||||
**Datum:** 23.12.2025
|
||||
**Status:** Systems Complete (46/46), Ready for Integration
|
||||
|
||||
---
|
||||
|
||||
## 🚀 PRIORITETA 1: QUICK WINS (1-2 uri)
|
||||
|
||||
### ✅ Task 1.1: Add Missing Systems to index.html
|
||||
**Lokacija:** `index.html` (pred line 212 - GameScene.js)
|
||||
**Čas:** 15 min
|
||||
|
||||
```html
|
||||
<!-- Dodaj pred <script src="src/scenes/GameScene.js"></script> -->
|
||||
<script src="src/systems/MiningSystem.js"></script>
|
||||
<script src="src/systems/CharacterCustomizationSystem.js"></script>
|
||||
<script src="src/systems/TownRestorationSystem.js"></script>
|
||||
<script src="src/systems/PortalRepairSystem.js"></script>
|
||||
<script src="src/systems/SmartZombieSystem.js"></script>
|
||||
<script src="src/systems/ToolSystem.js"></script>
|
||||
<script src="src/systems/AnaClueSystem.js"></script>
|
||||
<script src="src/systems/PyramidSystem.js"></script>
|
||||
<script src="src/systems/SlimesDogsSystem.js"></script>
|
||||
<script src="src/systems/AnimalsSeedsSystem.js"></script>
|
||||
<script src="src/systems/AutomationSystem.js"></script>
|
||||
<script src="src/systems/InventorySystemExpanded.js"></script>
|
||||
```
|
||||
|
||||
**Checklist:**
|
||||
- [ ] Odpri `index.html`
|
||||
- [ ] Najdi line 212 (`<script src="src/scenes/GameScene.js"></script>`)
|
||||
- [ ] Dodaj zgoraj navedene script tag-e PRED GameScene.js
|
||||
- [ ] Shrani
|
||||
- [ ] Test: Hard reload (Ctrl+Shift+R)
|
||||
- [ ] Preveri console za napake
|
||||
|
||||
---
|
||||
|
||||
### ✅ Task 1.2: Check for Export Statements
|
||||
**Lokacija:** Vsi novi sistemi
|
||||
**Čas:** 20 min
|
||||
|
||||
**Sistemi za check:**
|
||||
- [ ] MiningSystem.js
|
||||
- [ ] CharacterCustomizationSystem.js
|
||||
- [ ] TownRestorationSystem.js
|
||||
- [ ] PortalRepairSystem.js
|
||||
- [ ] SmartZombieSystem.js
|
||||
- [ ] ToolSystem.js
|
||||
- [ ] AnaClueSystem.js
|
||||
- [ ] PyramidSystem.js
|
||||
- [ ] SlimesDogsSystem.js
|
||||
- [ ] AnimalsSeedsSystem.js
|
||||
- [ ] AutomationSystem.js
|
||||
- [ ] InventorySystemExpanded.js
|
||||
|
||||
**Action:**
|
||||
1. Odpri vsak file
|
||||
2. Preveri za `export default class` ali `export class`
|
||||
3. Če najdeš, zamenjaj z samo `class`
|
||||
4. Shrani
|
||||
|
||||
---
|
||||
|
||||
### ✅ Task 1.3: Basic Smoke Test
|
||||
**Čas:** 10 min
|
||||
|
||||
**Test:**
|
||||
- [ ] Igra se zažene brez napak
|
||||
- [ ] Console nima critical errors
|
||||
- [ ] Player spawna
|
||||
- [ ] Basic movement dela (WASD)
|
||||
- [ ] Inventory dela (I key)
|
||||
|
||||
---
|
||||
|
||||
## 🔧 PRIORITETA 2: SYSTEM INTEGRATION (4-6 ur)
|
||||
|
||||
### ✅ Task 2.1: Initialize New Systems in GameScene
|
||||
**Lokacija:** `src/scenes/GameScene.js` - `create()` function
|
||||
**Čas:** 1 ura
|
||||
|
||||
**Kje dodati:** Po line ~800 (po inicializaciji DialogueSystem/TwinBondSystem)
|
||||
|
||||
```javascript
|
||||
// ========================================================
|
||||
// 🆕 NEW SYSTEMS (P16-P30) - 23.12.2025
|
||||
// ========================================================
|
||||
console.log('🆕 Initializing New Systems (P16-P30)...');
|
||||
|
||||
// P16: Mining System
|
||||
console.log('⛏️ Initializing Mining System...');
|
||||
this.miningSystem = new MiningSystem(this);
|
||||
|
||||
// P17: Character Customization
|
||||
console.log('👤 Initializing Character Customization...');
|
||||
this.characterCustomization = new CharacterCustomizationSystem(this);
|
||||
|
||||
// P19: Town Restoration
|
||||
console.log('🏘️ Initializing Town Restoration...');
|
||||
this.townRestoration = new TownRestorationSystem(this);
|
||||
|
||||
// P20: Portal Repair
|
||||
console.log('🌀 Initializing Portal Repair...');
|
||||
this.portalRepair = new PortalRepairSystem(this);
|
||||
|
||||
// P22: Smart Zombies
|
||||
console.log('🧠 Initializing Smart Zombies...');
|
||||
this.smartZombies = new SmartZombieSystem(this);
|
||||
|
||||
// P23: Tool System
|
||||
console.log('🔧 Initializing Tool System...');
|
||||
this.toolSystem = new ToolSystem(this);
|
||||
|
||||
// P25: Ana's Clues
|
||||
console.log('💜 Initializing Ana Clues...');
|
||||
this.anaClues = new AnaClueSystem(this);
|
||||
|
||||
// P26: Pyramids
|
||||
console.log('🏜️ Initializing Pyramid System...');
|
||||
this.pyramids = new PyramidSystem(this);
|
||||
|
||||
// P27: Slimes & Dogs
|
||||
console.log('🟢🐶 Initializing Slimes & Dogs...');
|
||||
this.slimesDogs = new SlimesDogsSystem(this);
|
||||
|
||||
// P28: Animals & Seeds
|
||||
console.log('🐄🌱 Initializing Animals & Seeds...');
|
||||
this.animalsSeeds = new AnimalsSeedsSystem(this);
|
||||
|
||||
// P29: Automation
|
||||
console.log('⚙️ Initializing Automation...');
|
||||
this.automation = new AutomationSystem(this);
|
||||
|
||||
// P30: Inventory Expanded
|
||||
console.log('🎒 Initializing Inventory Expansion...');
|
||||
this.inventoryExpanded = new InventorySystemExpanded(this, this.inventorySystem);
|
||||
|
||||
console.log('✅ All New Systems Initialized!');
|
||||
```
|
||||
|
||||
**Checklist:**
|
||||
- [ ] Odpri `src/scenes/GameScene.js`
|
||||
- [ ] Najdi `create()` function
|
||||
- [ ] Najdi line kjer so inicializirani DialogueSystem & TwinBondSystem
|
||||
- [ ] Dodaj zgoraj navedeno kodo PO tem
|
||||
- [ ] Shrani
|
||||
- [ ] Test reload
|
||||
|
||||
---
|
||||
|
||||
### ✅ Task 2.2: Add System Updates to update() Loop
|
||||
**Lokacija:** `src/scenes/GameScene.js` - `update()` function
|
||||
**Čas:** 30 min
|
||||
|
||||
**Najdi update() in dodaj:**
|
||||
|
||||
```javascript
|
||||
update(time, delta) {
|
||||
// ... existing update code ...
|
||||
|
||||
// NEW: Daily automation
|
||||
if (this.automation) {
|
||||
// Check if new day (runs once per day)
|
||||
const currentDay = Math.floor(time / 86400000); // ms to days
|
||||
if (currentDay !== this.lastDay) {
|
||||
this.automation.runDailyAutomation();
|
||||
this.lastDay = currentDay;
|
||||
}
|
||||
}
|
||||
|
||||
// NEW: Animal updates
|
||||
if (this.animalsSeeds) {
|
||||
this.animalsSeeds.updateLivestock();
|
||||
}
|
||||
|
||||
// NEW: Smart zombie updates
|
||||
if (this.smartZombies) {
|
||||
this.smartZombies.updateZombies(delta);
|
||||
}
|
||||
|
||||
// NEW: Town construction
|
||||
if (this.townRestoration) {
|
||||
this.townRestoration.updateConstruction(delta);
|
||||
}
|
||||
|
||||
// NEW: Portal construction
|
||||
if (this.portalRepair) {
|
||||
this.portalRepair.updateConstruction(delta);
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
**Checklist:**
|
||||
- [ ] Najdi `update(time, delta)` function
|
||||
- [ ] Dodaj zgoraj navedeno kodo
|
||||
- [ ] Shrani
|
||||
- [ ] Test: Check console za update logs
|
||||
|
||||
---
|
||||
|
||||
### ✅ Task 2.3: Connect System Communications
|
||||
**Lokacija:** `src/scenes/GameScene.js`
|
||||
**Čas:** 1 ura
|
||||
|
||||
**A. SmartZombies ↔ ZombieSystem**
|
||||
```javascript
|
||||
// V create(), po init SmartZombies:
|
||||
if (this.smartZombies && this.zombieSystem) {
|
||||
this.smartZombies.baseZombieSystem = this.zombieSystem;
|
||||
}
|
||||
```
|
||||
|
||||
**B. ToolSystem ↔ InventorySystem**
|
||||
```javascript
|
||||
// V create(), po init ToolSystem:
|
||||
if (this.toolSystem && this.inventorySystem) {
|
||||
this.toolSystem.inventorySystem = this.inventorySystem;
|
||||
}
|
||||
```
|
||||
|
||||
**C. AnaClues ↔ TwinBondSystem**
|
||||
```javascript
|
||||
// V create(), po init AnaClues:
|
||||
if (this.anaClues && this.twinBondSystem) {
|
||||
this.anaClues.onClueFound = (clueId) => {
|
||||
this.twinBondSystem.triggerMemory(clueId);
|
||||
};
|
||||
}
|
||||
```
|
||||
|
||||
**D. Automation ↔ Multiple Systems**
|
||||
```javascript
|
||||
// V create(), po init Automation:
|
||||
if (this.automation) {
|
||||
this.automation.farmingSystem = this.farmingSystem;
|
||||
this.automation.smartZombies = this.smartZombies;
|
||||
this.automation.inventoryExpanded = this.inventoryExpanded;
|
||||
}
|
||||
```
|
||||
|
||||
**Checklist:**
|
||||
- [ ] Dodaj vse zgoraj navedene povezave
|
||||
- [ ] Test: Preveri da sistemi lahko komunicirajo
|
||||
|
||||
---
|
||||
|
||||
## 🎨 PRIORITETA 3: UI CREATION (4-6 ur)
|
||||
|
||||
### ✅ Task 3.1: Character Creation Scene
|
||||
**File:** `src/scenes/CharacterCreationScene.js` (CREATE NEW)
|
||||
**Čas:** 1 ura
|
||||
**Prioriteta:** CRITICAL (game start)
|
||||
|
||||
**Potrebno:**
|
||||
- Gender selection (Kai/Ana)
|
||||
- RGB hair color picker
|
||||
- Body customization
|
||||
- Outfit selection
|
||||
- Preview window
|
||||
|
||||
---
|
||||
|
||||
### ✅ Task 3.2: Smart Zombie Command UI
|
||||
**File:** `src/ui/SmartZombieUI.js` (CREATE NEW)
|
||||
**Čas:** 45 min
|
||||
**Prioriteta:** HIGH
|
||||
|
||||
**Potrebno:**
|
||||
- Zombie list
|
||||
- Command buttons (Stop, Help, Attack, Home)
|
||||
- Follower management
|
||||
- XP display
|
||||
|
||||
---
|
||||
|
||||
### ✅ Task 3.3: Inventory Upgrade UI
|
||||
**File:** `src/ui/InventoryUpgradeUI.js` (CREATE NEW)
|
||||
**Čas:** 30 min
|
||||
**Prioriteta:** HIGH
|
||||
|
||||
**Potrebno:**
|
||||
- Tier upgrade menu
|
||||
- Tool Belt unlock button
|
||||
- Dog Backpack unlock button
|
||||
- Quick Sort/Stack/Deposit buttons
|
||||
|
||||
---
|
||||
|
||||
### ✅ Task 3.4: Ana's Clue Collection UI
|
||||
**File:** `src/ui/AnaClueUI.js` (CREATE NEW)
|
||||
**Čas:** 1 ura
|
||||
**Prioriteta:** HIGH (story)
|
||||
|
||||
**Potrebno:**
|
||||
- Progress tracker (15/12/23)
|
||||
- Gallery view
|
||||
- Story milestone indicators
|
||||
- Clue descriptions
|
||||
|
||||
---
|
||||
|
||||
### ✅ Task 3.5: Mining UI
|
||||
**File:** `src/ui/MiningUI.js` (CREATE NEW)
|
||||
**Čas:** 30 min
|
||||
**Prioriteta:** MEDIUM
|
||||
|
||||
**Potrebno:**
|
||||
- Mine selection
|
||||
- Depth indicator
|
||||
- Oxygen warning
|
||||
- Elevator button
|
||||
|
||||
---
|
||||
|
||||
### ✅ Task 3.6: Town Restoration UI
|
||||
**File:** `src/ui/TownRestorationUI.js` (CREATE NEW)
|
||||
**Čas:** 45 min
|
||||
**Prioriteta:** MEDIUM
|
||||
|
||||
**Potrebno:**
|
||||
- Town list (27)
|
||||
- Building progress
|
||||
- NPC count
|
||||
- Zombie assignment
|
||||
|
||||
---
|
||||
|
||||
### ✅ Task 3.7: Portal Repair UI
|
||||
**File:** `src/ui/PortalRepairUI.js` (CREATE NEW)
|
||||
**Čas:** 30 min
|
||||
**Prioriteta:** MEDIUM
|
||||
|
||||
**Potrebno:**
|
||||
- Portal list (18)
|
||||
- Material requirements
|
||||
- Construction progress
|
||||
- Teleport button
|
||||
|
||||
---
|
||||
|
||||
### ✅ Task 3.8: Tool Management UI
|
||||
**File:** `src/ui/ToolUI.js` (CREATE NEW)
|
||||
**Čas:** 30 min
|
||||
**Prioriteta:** MEDIUM
|
||||
|
||||
**Potrebno:**
|
||||
- Durability bars
|
||||
- Repair options
|
||||
- Upgrade menu
|
||||
|
||||
---
|
||||
|
||||
### ✅ Task 3.9: Blueprint Gallery UI
|
||||
**File:** `src/ui/BlueprintGalleryUI.js` (CREATE NEW)
|
||||
**Čas:** 45 min
|
||||
**Prioriteta:** MEDIUM
|
||||
|
||||
**Potrebno:**
|
||||
- Collection progress
|
||||
- Category tabs
|
||||
- Discovery indicators
|
||||
|
||||
---
|
||||
|
||||
### ✅ Task 3.10: Animal Shop UI
|
||||
**File:** `src/ui/AnimalShopUI.js` (CREATE NEW)
|
||||
**Čas:** 45 min
|
||||
**Prioriteta:** MEDIUM
|
||||
|
||||
**Potrebno:**
|
||||
- Animal Rescue progress
|
||||
- Livestock shop
|
||||
- Breeding interface
|
||||
|
||||
---
|
||||
|
||||
### ✅ Task 3.11: Seed Shop UI
|
||||
**File:** `src/ui/SeedShopUI.js` (CREATE NEW)
|
||||
**Čas:** 30 min
|
||||
**Prioriteta:** MEDIUM
|
||||
|
||||
**Potrebno:**
|
||||
- Season tabs
|
||||
- 100+ seeds
|
||||
- Growth time display
|
||||
|
||||
---
|
||||
|
||||
### ✅ Task 3.12: Automation Control Panel
|
||||
**File:** `src/ui/AutomationUI.js` (CREATE NEW)
|
||||
**Čas:** 45 min
|
||||
**Prioriteta:** LOW (endgame)
|
||||
|
||||
**Potrebno:**
|
||||
- Sprinkler management
|
||||
- Water tower status
|
||||
- Minting controls
|
||||
- Full automation checklist
|
||||
|
||||
---
|
||||
|
||||
## 🗺️ PRIORITETA 4: TILED MAPS (30 min)
|
||||
|
||||
### ✅ Task 4.1: Import TSX Files
|
||||
**Čas:** 10 min
|
||||
|
||||
**Action:**
|
||||
1. Odpri Tiled Map Editor
|
||||
2. Import → External Tilesets
|
||||
3. Dodaj vse 61 TSX iz `assets/tilesets/`
|
||||
|
||||
---
|
||||
|
||||
### ✅ Task 4.2: Create Starter Map
|
||||
**Čas:** 15 min
|
||||
|
||||
**Action:**
|
||||
1. New Map → 16x16
|
||||
2. Dodaj Base Ground layer
|
||||
3. Dodaj Decoration layer
|
||||
4. Paint basic starter area
|
||||
5. Save as `starter_farm_16x16.tmx`
|
||||
|
||||
---
|
||||
|
||||
### ✅ Task 4.3: Export to JSON
|
||||
**Čas:** 5 min
|
||||
|
||||
**Action:**
|
||||
1. File → Export As → JSON
|
||||
2. Save v `assets/maps/starter_farm_16x16.json`
|
||||
3. Test load v `TiledTestScene.js`
|
||||
|
||||
---
|
||||
|
||||
## ✅ TESTING CHECKLIST
|
||||
|
||||
### After Quick Wins:
|
||||
- [ ] Game launches
|
||||
- [ ] No console errors
|
||||
- [ ] All systems load
|
||||
|
||||
### After Integration:
|
||||
- [ ] All 46 systems initialize
|
||||
- [ ] Systems communicate
|
||||
- [ ] No memory leaks
|
||||
- [ ] 60 FPS maintained
|
||||
|
||||
### After UI:
|
||||
- [ ] All UIs open/close
|
||||
- [ ] Buttons work
|
||||
- [ ] Data displays correctly
|
||||
|
||||
### Full Gameplay:
|
||||
- [ ] New game → Character creation
|
||||
- [ ] Mining works
|
||||
- [ ] Zombie commands work
|
||||
- [ ] Tools break/repair
|
||||
- [ ] Clues found
|
||||
- [ ] Towns restored
|
||||
- [ ] Portals repaired
|
||||
- [ ] Animals breed
|
||||
- [ ] Seeds grow
|
||||
- [ ] Automation works
|
||||
- [ ] Inventory expands
|
||||
|
||||
---
|
||||
|
||||
## 📅 ČASOVNI PLAN (Recommended)
|
||||
|
||||
**Session 1 (1-2h):** Quick Wins
|
||||
- Add systems to HTML
|
||||
- Check exports
|
||||
- Basic testing
|
||||
|
||||
**Session 2 (2-3h):** Integration Part 1
|
||||
- Initialize systems
|
||||
- Add updates
|
||||
- Basic connections
|
||||
|
||||
**Session 3 (2-3h):** Integration Part 2
|
||||
- Full system communications
|
||||
- Testing
|
||||
- Bug fixes
|
||||
|
||||
**Session 4 (2h):** High Priority UIs
|
||||
- Character Creation
|
||||
- Smart Zombie UI
|
||||
- Inventory Upgrade UI
|
||||
- Ana Clue UI
|
||||
|
||||
**Session 5 (2-3h):** Medium Priority UIs
|
||||
- Mining, Town, Portal, Tool UIs
|
||||
- Blueprint Gallery
|
||||
- Animal/Seed Shops
|
||||
|
||||
**Session 6 (1h):** Low Priority UIs
|
||||
- Automation Panel
|
||||
- Final polish
|
||||
|
||||
**Session 7 (1h):** Tiled Maps
|
||||
- Import, create, export
|
||||
|
||||
**TOTAL:** ~12-15 hours split across multiple sessions
|
||||
|
||||
---
|
||||
|
||||
## 💡 PRIPOROČILA
|
||||
|
||||
1. **Ne delaj vsega naenkrat!** Razdeli na seje
|
||||
2. **Testiraj pogosto** po vsakem task-u
|
||||
3. **Commit pogosto** za vsak večji milestone
|
||||
4. **Odpočij med sesjami** za boljšo produktivnost
|
||||
5. **Prioritize** - začni najprej s HIGH priority task-i
|
||||
|
||||
---
|
||||
|
||||
**Created:** 23.12.2025, 22:00
|
||||
**Status:** Ready to Execute
|
||||
**Next Step:** Start with Task 1.1 (Add Systems to HTML)
|
||||
Reference in New Issue
Block a user