Green Background Removal + TSX Generation + Bug Fixes
Removed green backgrounds from 30 tileset PNGs (16.4M pixels!) Created mass TSX generation script for 3877 individual objects Fixed TiledTestScene cursor crash bug Added micro_farm_8x8 JSON loading support Documentation: GREEN_BACKGROUND_FIX.md, MASS_TSX_GENERATION.md Scripts: - scripts/remove_green_background.py (batch transparency fix) - scripts/generate_mass_tsx.py (3877 .tsx files generator) Backups: assets/tilesets/backup_green_bg/
This commit is contained in:
@@ -34,6 +34,7 @@ class PreloadScene extends Phaser.Scene {
|
||||
// 🗺️ TILED MAP (JSON export from Tiled Editor)
|
||||
this.load.tilemapTiledJSON('farm_map', 'assets/maps/farm_map.json');
|
||||
this.load.tilemapTiledJSON('micro_farm_128x128', 'assets/maps/micro_farm_128x128.json'); // 🌾 Testna farma
|
||||
this.load.tilemapTiledJSON('micro_farm_8x8', 'assets/maps/micro_farm_8x8.json'); // 🏕️ Manjša test mapa
|
||||
this.load.image('grass_tileset_img', 'assets/tilesets/grass.png');
|
||||
this.load.image('water_tileset_img', 'assets/tilesets/water.png');
|
||||
this.load.image('decorations_tileset_img', 'assets/tilesets/decorations.png');
|
||||
|
||||
@@ -202,6 +202,9 @@ class TiledTestScene extends Phaser.Scene {
|
||||
}
|
||||
|
||||
update(time, delta) {
|
||||
// Safety check - only run if cursors are initialized
|
||||
if (!this.cursors) return;
|
||||
|
||||
// Camera movement with arrow keys
|
||||
const speed = 10 / this.cameras.main.zoom; // Adjust speed based on zoom
|
||||
|
||||
|
||||
Reference in New Issue
Block a user