diff --git a/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Room1/Room1_preinstall.json b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Room1/Room1_preinstall.json index 119a4eb..6b7b9ae 100644 --- a/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Room1/Room1_preinstall.json +++ b/DungeonShooting_Godot/resource/map/tileMaps/TestGroup1/battle/Room1/Room1_preinstall.json @@ -1 +1 @@ -[{"Name":"test1","Weight":100,"Remark":"","WaveList":[[{"Position":{"X":20,"Y":-32},"Size":{"X":92,"Y":134},"DelayTime":0,"MarkList":[{"Id":"weapon0006","Weight":100,"Attr":{"CurrAmmon":"20","ResidueAmmo":"300"}}]}],[{"Position":{"X":61,"Y":34},"Size":{"X":86,"Y":72},"DelayTime":0,"MarkList":[{"Id":"weapon0007","Weight":100,"Attr":{"CurrAmmon":"60","ResidueAmmo":"300"}}]}]]},{"Name":"test2","Weight":100,"Remark":"","WaveList":[[]]}] \ No newline at end of file +[{"Name":"test1","Weight":100,"Remark":"","WaveList":[[{"Position":{"X":20,"Y":-32},"Size":{"X":92,"Y":134},"DelayTime":0,"MarkList":[{"Id":"weapon0006","Weight":100,"Attr":{"CurrAmmon":"20","ResidueAmmo":"300"}}]}],[{"Position":{"X":61,"Y":34},"Size":{"X":86,"Y":72},"DelayTime":0,"MarkList":[{"Id":"weapon0007","Weight":100,"Attr":{"CurrAmmon":"60","ResidueAmmo":"300"}}]}]]},{"Name":"test2","Weight":150,"Remark":"","WaveList":[[{"Position":{"X":65,"Y":32},"Size":{"X":75,"Y":37},"DelayTime":0,"MarkList":[{"Id":"weapon0002","Weight":100,"Attr":{"CurrAmmon":"7","ResidueAmmo":"70"}}]}]]}] \ No newline at end of file diff --git a/DungeonShooting_Godot/resource/sprite/role/enemy0001/Enemy0001.png.import b/DungeonShooting_Godot/resource/sprite/role/enemy0001/Enemy0001.png.import new file mode 100644 index 0000000..7e5d2de --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/role/enemy0001/Enemy0001.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://ddhkhfaos2w1g" +path="res://.godot/imported/Enemy0001.png-148a38dfa95953b26d890356e8875de4.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://resource/sprite/role/enemy0001/Enemy0001.png" +dest_files=["res://.godot/imported/Enemy0001.png-148a38dfa95953b26d890356e8875de4.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/resource/sprite/role/enemy0001/Enemy0001_Debris.png.import b/DungeonShooting_Godot/resource/sprite/role/enemy0001/Enemy0001_Debris.png.import new file mode 100644 index 0000000..aa89659 --- /dev/null +++ b/DungeonShooting_Godot/resource/sprite/role/enemy0001/Enemy0001_Debris.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://cn64eauvwx1uj" +path="res://.godot/imported/Enemy0001_Debris.png-ac416dc79cd3c1217b27e1ef1fbe0d0b.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"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/DungeonShooting_Godot/src/game/ui/mapEditorMapMark/EditorWaveCell.cs b/DungeonShooting_Godot/src/game/ui/mapEditorMapMark/EditorWaveCell.cs index 2b43d60..739eefd 100644 --- a/DungeonShooting_Godot/src/game/ui/mapEditorMapMark/EditorWaveCell.cs +++ b/DungeonShooting_Godot/src/game/ui/mapEditorMapMark/EditorWaveCell.cs @@ -71,6 +71,8 @@ MarkGrid.Click(MarkGrid.Count - 1); //执行排序操作 MarkGrid.Sort(); + //派发数据修改事件 + EventManager.EmitEvent(EventEnum.OnEditorDirty); } /// diff --git a/DungeonShooting_Godot/src/game/ui/mapEditorMapMark/MapEditorMapMarkPanel.cs b/DungeonShooting_Godot/src/game/ui/mapEditorMapMark/MapEditorMapMarkPanel.cs index dbbafaf..b1b444c 100644 --- a/DungeonShooting_Godot/src/game/ui/mapEditorMapMark/MapEditorMapMarkPanel.cs +++ b/DungeonShooting_Godot/src/game/ui/mapEditorMapMark/MapEditorMapMarkPanel.cs @@ -267,6 +267,8 @@ //创建逻辑 roomSplitPreinstall.Add(preinstall); RefreshPreinstallSelect(roomSplitPreinstall.Count - 1); + //派发数据修改事件 + EventManager.EmitEvent(EventEnum.OnEditorDirty); }); } @@ -284,6 +286,8 @@ //修改下拉菜单数据 var optionButton = S_PreinstallOption.Instance; optionButton.SetItemText(optionButton.Selected, $"{preinstall.Name} ({preinstall.Weight})"); + //派发数据修改事件 + EventManager.EmitEvent(EventEnum.OnEditorDirty); }); } @@ -308,6 +312,8 @@ EditorTileMap.RoomSplit.Preinstall.RemoveAt(index); //刷新选项 RefreshPreinstallSelect(EditorTileMap.RoomSplit.Preinstall.Count - 1); + //派发数据修改事件 + EventManager.EmitEvent(EventEnum.OnEditorDirty); } }); } @@ -334,6 +340,8 @@ var wave = new List(); item.WaveList.Add(wave); _grid.Add(wave); + //派发数据修改事件 + EventManager.EmitEvent(EventEnum.OnEditorDirty); } //工具节点编辑按钮点击 @@ -393,6 +401,8 @@ selectPreinstall.WaveList.RemoveAt(index); _grid.RemoveByIndex(index); EditorTileMap.SelectWaveIndex = -1; + //派发数据修改事件 + EventManager.EmitEvent(EventEnum.OnEditorDirty); } }); } @@ -415,6 +425,8 @@ //执行排序 markCell.Grid.Sort(); EventManager.EmitEvent(EventEnum.OnEditMark, dataMarkInfo); + //派发数据修改事件 + EventManager.EmitEvent(EventEnum.OnEditorDirty); }); } } @@ -452,6 +464,8 @@ EventManager.EmitEvent(EventEnum.OnDeleteMark, markInfo); waveCell.MarkGrid.RemoveByIndex(markCellIndex); waveCell.Data.RemoveAt(markCellIndex); + //派发数据修改事件 + EventManager.EmitEvent(EventEnum.OnEditorDirty); } }); }