udomacenje zombija in uboj\

This commit is contained in:
2025-12-07 12:47:47 +01:00
parent 8e401a9d6f
commit 2404d44ef7
10 changed files with 1086 additions and 532 deletions

View File

@@ -6,6 +6,13 @@ class GameScene extends Phaser.Scene {
this.terrainContainer = null;
this.player = null;
this.npcs = []; // Array za NPCje
// Settings
this.settings = {
viewDistance: 'HIGH', // LOW, MEDIUM, HIGH
particles: 'HIGH', // NONE, LOW, HIGH
shadows: true
};
}
create() {
@@ -108,6 +115,9 @@ class GameScene extends Phaser.Scene {
console.log('🌄 Initializing Parallax System...');
this.parallaxSystem = new ParallaxSystem(this);
// Generate Item Sprites for UI
TextureGenerator.createItemSprites(this);
// Launch UI Scene
console.log('🖥️ Launching UI Scene...');
this.scene.launch('UIScene');
@@ -115,10 +125,10 @@ class GameScene extends Phaser.Scene {
// Initialize Save System
this.saveSystem = new SaveSystem(this);
// Auto-load if available (optional, for now manual)
// this.saveSystem.loadGame();
// Auto-load if available
this.saveSystem.loadGame();
console.log('✅ GameScene ready - FAZA 17!');
console.log('✅ GameScene ready - FAZA 18 (Crafting & AI)!');
}
setupCamera() {
@@ -277,4 +287,12 @@ class GameScene extends Phaser.Scene {
this.clouds.push({ sprite: cloud, speed: Phaser.Math.FloatBetween(10, 30) });
}
}
saveGame() {
if (this.saveSystem) this.saveSystem.saveGame();
}
loadGame() {
if (this.saveSystem) this.saveSystem.loadGame();
}
}