diff --git a/DungeonShooting_Godot/resource/sprite/role/enemy0001/enemy0001.png.import b/DungeonShooting_Godot/resource/sprite/role/enemy0001/enemy0001.png.import index c36be94..b20c9a6 100644 --- a/DungeonShooting_Godot/resource/sprite/role/enemy0001/enemy0001.png.import +++ b/DungeonShooting_Godot/resource/sprite/role/enemy0001/enemy0001.png.import @@ -3,15 +3,15 @@ importer="texture" type="CompressedTexture2D" uid="uid://chd2vtesap5cf" -path="res://.godot/imported/Enemy0001.png-148a38dfa95953b26d890356e8875de4.ctex" +path="res://.godot/imported/enemy0001.png-1247a3ddf8a1a163d812cad12c4340fd.ctex" metadata={ "vram_texture": false } [deps] -source_file="res://resource/sprite/role/enemy0001/Enemy0001.png" -dest_files=["res://.godot/imported/Enemy0001.png-148a38dfa95953b26d890356e8875de4.ctex"] +source_file="res://resource/sprite/role/enemy0001/enemy0001.png" +dest_files=["res://.godot/imported/enemy0001.png-1247a3ddf8a1a163d812cad12c4340fd.ctex"] [params] diff --git a/DungeonShooting_Godot/resource/sprite/role/enemy0001/enemy0001_Debris.png.import b/DungeonShooting_Godot/resource/sprite/role/enemy0001/enemy0001_Debris.png.import index d563acf..56388a2 100644 --- a/DungeonShooting_Godot/resource/sprite/role/enemy0001/enemy0001_Debris.png.import +++ b/DungeonShooting_Godot/resource/sprite/role/enemy0001/enemy0001_Debris.png.import @@ -3,15 +3,15 @@ importer="texture" type="CompressedTexture2D" uid="uid://d2f55lu60x64i" -path="res://.godot/imported/Enemy0001_Debris.png-ac416dc79cd3c1217b27e1ef1fbe0d0b.ctex" +path="res://.godot/imported/enemy0001_Debris.png-297a2fb6680cb862a9a085cf58f8268c.ctex" metadata={ "vram_texture": false } [deps] -source_file="res://resource/sprite/role/enemy0001/Enemy0001_Debris.png" -dest_files=["res://.godot/imported/Enemy0001_Debris.png-ac416dc79cd3c1217b27e1ef1fbe0d0b.ctex"] +source_file="res://resource/sprite/role/enemy0001/enemy0001_Debris.png" +dest_files=["res://.godot/imported/enemy0001_Debris.png-297a2fb6680cb862a9a085cf58f8268c.ctex"] [params] diff --git a/DungeonShooting_Godot/scene/EditorDemo.tscn b/DungeonShooting_Godot/scene/EditorDemo.tscn deleted file mode 100644 index 50a1927..0000000 --- a/DungeonShooting_Godot/scene/EditorDemo.tscn +++ /dev/null @@ -1,9 +0,0 @@ -[gd_scene load_steps=2 format=2] - -[ext_resource path="res://editor/prefabs/Editor.tscn" type="PackedScene" id=1] - -[node name="EditorDemo" type="Node2D"] - -[node name="CanvasLayer" type="CanvasLayer" parent="."] - -[node name="Editor" parent="CanvasLayer" instance=ExtResource( 1 )] diff --git a/DungeonShooting_Godot/src/game/manager/ResourcePath.cs b/DungeonShooting_Godot/src/game/manager/ResourcePath.cs index 13f88aa..475d109 100644 --- a/DungeonShooting_Godot/src/game/manager/ResourcePath.cs +++ b/DungeonShooting_Godot/src/game/manager/ResourcePath.cs @@ -159,8 +159,8 @@ public const string resource_sprite_role_role7_png = "res://resource/sprite/role/role7.png"; public const string resource_sprite_role_role8_png = "res://resource/sprite/role/role8.png"; public const string resource_sprite_role_role9_png = "res://resource/sprite/role/role9.png"; - public const string resource_sprite_role_enemy0001_Enemy0001_png = "res://resource/sprite/role/enemy0001/Enemy0001.png"; - public const string resource_sprite_role_enemy0001_Enemy0001_Debris_png = "res://resource/sprite/role/enemy0001/Enemy0001_Debris.png"; + public const string resource_sprite_role_enemy0001_enemy0001_png = "res://resource/sprite/role/enemy0001/enemy0001.png"; + public const string resource_sprite_role_enemy0001_enemy0001_Debris_png = "res://resource/sprite/role/enemy0001/enemy0001_Debris.png"; public const string resource_sprite_shell_Shell0001_png = "res://resource/sprite/shell/Shell0001.png"; public const string resource_sprite_shell_Shell0002_png = "res://resource/sprite/shell/Shell0002.png"; public const string resource_sprite_shell_Shell0003_png = "res://resource/sprite/shell/Shell0003.png"; @@ -169,6 +169,7 @@ public const string resource_sprite_ui_font_bg_png = "res://resource/sprite/ui/font_bg.png"; public const string resource_sprite_ui_GUI_png = "res://resource/sprite/ui/GUI.png"; public const string resource_sprite_ui_keyboard_e_png = "res://resource/sprite/ui/keyboard/e.png"; + public const string resource_sprite_ui_mapEditor_ErrorCell_png = "res://resource/sprite/ui/mapEditor/ErrorCell.png"; public const string resource_sprite_ui_roomUI_ChargeProgress_png = "res://resource/sprite/ui/roomUI/ChargeProgress.png"; public const string resource_sprite_ui_roomUI_ChargeProgressBar_png = "res://resource/sprite/ui/roomUI/ChargeProgressBar.png"; public const string resource_sprite_ui_roomUI_Cooldown_png = "res://resource/sprite/ui/roomUI/Cooldown.png"; @@ -234,7 +235,6 @@ public const string resource_spriteFrames_weapon_Weapon0007_tres = "res://resource/spriteFrames/weapon/Weapon0007.tres"; public const string resource_theme_mainTheme_tres = "res://resource/theme/mainTheme.tres"; public const string resource_theme_theme1_tres = "res://resource/theme/theme1.tres"; - public const string scene_EditorDemo_tscn = "res://scene/EditorDemo.tscn"; public const string scene_Main_tscn = "res://scene/Main.tscn"; public const string scene_World_tscn = "res://scene/World.tscn"; public const string scene_test_TestCommpont_tscn = "res://scene/test/TestCommpont.tscn"; diff --git a/DungeonShooting_Godot/src/game/ui/mapEditor/TileView/EditorTileMap.cs b/DungeonShooting_Godot/src/game/ui/mapEditor/TileView/EditorTileMap.cs index dc167f3..fecff92 100644 --- a/DungeonShooting_Godot/src/game/ui/mapEditor/TileView/EditorTileMap.cs +++ b/DungeonShooting_Godot/src/game/ui/mapEditor/TileView/EditorTileMap.cs @@ -334,19 +334,6 @@ _generateNavigationTimer = 3; EraseCell(GetFloorLayer(), position); _autoCellLayerGrid.Remove(position.X, position.Y); - - //执行刷墙逻辑 - - // //先检测对角是否有地板 - // var left = _autoCellLayerGrid.Get(position.X - 1, position.Y); - // var right = _autoCellLayerGrid.Get(position.X + 1, position.Y); - // var top = _autoCellLayerGrid.Get(position.X, position.Y + 1); - // var down = _autoCellLayerGrid.Get(position.X, position.Y - 1); - // - // if ((left && right) || (top && down)) - // { - // GD.Print("错误的地图块..."); - // } } //擦除一个区域内的自动贴图 @@ -379,6 +366,28 @@ _autoCellLayerGrid.RemoveRect(start, new Vector2I(width, height)); } + private bool CheckTerrain() + { + var usedRect = GetUsedRect(); + var x = usedRect.Position.X; + var y = usedRect.Position.Y; + var w = usedRect.Size.X; + var h = usedRect.Size.Y; + //执行刷墙逻辑 + + // //先检测对角是否有地板 + // var left = _autoCellLayerGrid.Get(position.X - 1, position.Y); + // var right = _autoCellLayerGrid.Get(position.X + 1, position.Y); + // var top = _autoCellLayerGrid.Get(position.X, position.Y + 1); + // var down = _autoCellLayerGrid.Get(position.X, position.Y - 1); + // + // if ((left && right) || (top && down)) + // { + // GD.Print("错误的地图块..."); + // } + return true; + } + //生成自动图块 (地形) private void GenerateTerrain() {