diff --git a/DungeonShooting_Godot/resource/map/tileMaps/Test1/battle/Battle2/Preview.png b/DungeonShooting_Godot/resource/map/tileMaps/Test1/battle/Battle2/Preview.png
index 9ff5376..dda6011 100644
--- a/DungeonShooting_Godot/resource/map/tileMaps/Test1/battle/Battle2/Preview.png
+++ b/DungeonShooting_Godot/resource/map/tileMaps/Test1/battle/Battle2/Preview.png
Binary files differ
diff --git a/DungeonShooting_Godot/resource/map/tileMaps/Test1/battle/Battle2/TileInfo.json b/DungeonShooting_Godot/resource/map/tileMaps/Test1/battle/Battle2/TileInfo.json
index cb0407a..25fca17 100644
--- a/DungeonShooting_Godot/resource/map/tileMaps/Test1/battle/Battle2/TileInfo.json
+++ b/DungeonShooting_Godot/resource/map/tileMaps/Test1/battle/Battle2/TileInfo.json
@@ -1 +1 @@
-{"NavigationVertices":[{"X":250,"Y":146},{"X":-106,"Y":146},{"X":-106,"Y":-106},{"X":250,"Y":-106}],"NavigationPolygon":[[0,1,2,3]],"Floor":[-7,-7,0,3,-7,-6,0,3,-7,-5,0,3,-7,-4,0,3,-7,-3,0,3,-7,-2,0,3,-7,-1,0,3,-7,0,0,3,-7,1,0,3,-7,2,0,3,-7,3,0,3,-7,4,0,3,-7,5,0,3,-7,6,0,3,-7,7,0,3,-7,8,0,3,-6,7,0,3,-6,8,0,3,-5,7,0,3,-5,8,0,3,-4,7,0,3,-4,8,0,3,-3,7,0,3,-3,8,0,3,-2,7,0,3,-2,8,0,3,-1,7,0,3,-1,8,0,3,0,7,0,3,0,8,0,3,1,7,0,3,1,8,0,3,2,7,0,3,2,8,0,3,3,7,0,3,3,8,0,3,4,7,0,3,4,8,0,3,5,7,0,3,5,8,0,3,6,7,0,3,6,8,0,3,7,7,0,3,7,8,0,3,8,7,0,3,8,8,0,3,9,7,0,3,9,8,0,3,10,7,0,3,10,8,0,3,11,7,0,3,11,8,0,3,12,7,0,3,12,8,0,3,13,7,0,3,13,8,0,3,14,7,0,3,14,8,0,3,15,-7,0,3,15,-6,0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1,12,-8,2,2,13,-9,63,1,13,-8,2,2,14,-9,63,1,14,-8,2,2,15,-9,63,1,15,-8,2,2],"Top":[-9,-10,511,1,-9,-9,511,1,-9,-8,511,1,-9,-7,511,1,-9,-6,511,1,-9,-5,511,1,-9,-4,511,1,-9,-3,511,1,-9,-2,511,1,-9,-1,511,1,-9,0,511,1,-9,1,511,1,-9,2,511,1,-9,3,511,1,-9,4,511,1,-9,5,511,1,-9,6,511,1,-9,7,511,1,-9,8,511,1,-9,9,511,1,-9,10,511,1,-8,-10,511,1,-8,-9,255,1,-8,-8,219,1,-8,-7,219,1,-8,-6,219,1,-8,-5,219,1,-8,-4,219,1,-8,-3,219,1,-8,-2,219,1,-8,-1,219,1,-8,0,219,1,-8,1,219,1,-8,2,219,1,-8,3,219,1,-8,4,219,1,-8,5,219,1,-8,6,219,1,-8,7,219,1,-8,8,219,1,-8,9,507,1,-8,10,511,1,-7,-10,511,1,-7,9,504,1,-7,10,511,1,-6,-10,511,1,-6,9,504,1,-6,10,511,1,-5,-10,511,1,-5,9,504,1,-5,10,511,1,-4,-10,511,1,-4,9,504,1,-4,10,511,1,-3,-10,511,1,-3,9,504,1,-3,10,511,1,-2,-10,511,1,-2,9,504,1,-2,10,511,1,-1,-10,511,1,-1,9,504,1,-1,10,511,1,0,-10,511,1,0,9,504,1,0,10,511,1,1,-10,511,1,1,9,504,1,1,10,511,1,2,-10,511,1,2,9,504,1,2,10,511,1,3,-10,511,1,3,9,504,1,3,10,511,1,4,-10,511,1,4,9,504,1,4,10,511,1,5,-10,511,1,5,9,504,1,5,10,511,1,6,-10,511,1,6,9,504,1,6,10,511,1,7,-10,511,1,7,9,504,1,7,10,511,1,8,-10,511,1,8,9,504,1,8,10,511,1,9,-10,511,1,9,9,504,1,9,10,511,1,10,-10,511,1,10,9,504,1,10,10,511,1,11,-10,511,1,11,9,504,1,11,10,511,1,12,-10,511,1,12,9,504,1,12,10,511,1,13,-10,511,1,13,9,504,1,13,10,511,1,14,-10,511,1,14,9,504,1,14,10,511,1,15,-10,511,1,15,9,504,1,15,10,511,1,16,-10,511,1,16,-9,447,1,16,-8,438,1,16,-7,438,1,16,-6,438,1,16,-5,438,1,16,-4,438,1,16,-3,438,1,16,-2,438,1,16,-1,438,1,16,0,438,1,16,1,438,1,16,2,438,1,16,3,438,1,16,4,438,1,16,5,438,1,16,6,438,1,16,7,438,1,16,8,438,1,16,9,510,1,16,10,511,1,17,-10,511,1,17,-9,511,1,17,-8,511,1,17,-7,511,1,17,-6,511,1,17,-5,511,1,17,-4,511,1,17,-3,511,1,17,-2,511,1,17,-1,511,1,17,0,511,1,17,1,511,1,17,2,511,1,17,3,511,1,17,4,511,1,17,5,511,1,17,6,511,1,17,7,511,1,17,8,511,1,17,9,511,1,17,10,511,1],"CustomFloor1":[1,-4,2,2,6,1,-3,2,2,8,0,-3,2,1,8,0,-4,2,1,6,2,-4,2,2,6,2,-3,2,2,8,3,-4,2,2,6,3,-3,2,2,8,4,-4,2,2,6,4,-3,2,2,8,5,-4,2,2,6,5,-3,2,2,8,6,-4,2,2,6,6,-3,2,2,8,7,-4,2,2,6,7,-3,2,5,8,8,-4,2,3,6,8,-3,2,4,9,8,-2,2,5,8,7,-2,2,1,8,9,-3,2,3,6,9,-2,2,3,7,9,-1,2,4,9,8,-1,2,1,7,9,0,2,2,7,8,0,2,1,7,10,-1,2,3,6,10,0,2,3,7,10,1,2,3,7,9,1,2,2,7,10,2,2,3,7,9,2,2,2,7,8,2,2,5,9,8,1,2,1,7,9,3,2,2,7,8,3,2,2,7,7,3,2,2,7,7,2,2,2,6,6,3,2,5,9,6,2,2,1,6,6,4,2,2,7,5,4,2,2,7,5,3,2,2,6,4,4,2,2,7,4,3,2,4,9,3,4,2,2,7,3,3,2,2,7,2,4,2,2,7,2,3,2,2,7,1,4,2,2,7,1,3,2,2,7,0,4,2,2,7,0,3,2,2,7,1,5,2,2,8,0,5,2,2,8,-1,5,2,2,8,-1,4,2,2,7,-2,5,2,2,8,-2,4,2,5,9,-3,5,2,2,8,-3,4,2,2,6,-4,5,2,2,8,-4,4,2,2,6,-5,5,2,1,8,-5,4,2,1,6,3,5,2,2,8,2,5,2,2,8,4,5,2,2,8,5,5,2,2,8,6,5,2,2,8,7,4,2,4,8,7,5,2,3,8,8,4,2,2,8,9,4,2,5,8,10,3,2,3,7,10,4,2,4,9,10,5,2,2,8,9,5,2,1,8,11,4,2,2,6,11,5,2,2,8,12,4,2,3,6,12,5,2,3,8,1,2,2,2,6,0,2,2,2,6,-1,3,2,2,7,-1,2,2,4,9,-2,3,2,1,7,-2,2,2,5,8,-1,1,2,3,6,-2,1,2,2,6,-3,2,2,2,8,-3,1,2,4,9,-4,2,2,1,8,-4,1,2,1,7,-3,0,2,3,7,-4,0,2,1,7,-3,-1,2,3,6,-4,-1,2,1,6,2,2,2,5,9,3,1,2,2,6,3,2,2,2,7,2,1,2,1,6,4,1,2,3,6,4,2,2,3,7],"CustomFloor2":[],"CustomFloor3":[],"CustomMiddle1":[],"CustomMiddle2":[],"CustomTop":[]}
\ No newline at end of file
+{"NavigationVertices":[{"X":250,"Y":146},{"X":-106,"Y":146},{"X":-106,"Y":-106},{"X":250,"Y":-106}],"NavigationPolygon":[[0,1,2,3]],"Floor":[-7,-7,0,3,-7,-6,0,3,-7,-5,0,3,-7,-4,0,3,-7,-3,0,3,-7,-2,0,3,-7,-1,0,3,-7,0,0,3,-7,1,0,3,-7,2,0,3,-7,3,0,3,-7,4,0,3,-7,5,0,3,-7,6,0,3,-7,7,0,3,-7,8,0,3,-6,7,0,3,-6,8,0,3,-5,7,0,3,-5,8,0,3,-4,7,0,3,-4,8,0,3,-3,7,0,3,-3,8,0,3,-2,7,0,3,-2,8,0,3,-1,7,0,3,-1,8,0,3,0,7,0,3,0,8,0,3,1,7,0,3,1,8,0,3,2,7,0,3,2,8,0,3,3,7,0,3,3,8,0,3,4,7,0,3,4,8,0,3,5,7,0,3,5,8,0,3,6,7,0,3,6,8,0,3,7,7,0,3,7,8,0,3,8,7,0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-8,2,2,6,-9,63,1,6,-8,2,2,7,-9,63,1,7,-8,2,2,8,-9,63,1,8,-8,2,2,9,-9,63,1,9,-8,2,2,10,-9,63,1,10,-8,2,2,11,-9,63,1,11,-8,2,2,12,-9,63,1,12,-8,2,2,13,-9,63,1,13,-8,2,2,14,-9,63,1,14,-8,2,2,15,-9,63,1,15,-8,2,2],"Top":[-9,-10,511,1,-9,-9,511,1,-9,-8,511,1,-9,-7,511,1,-9,-6,511,1,-9,-5,511,1,-9,-4,511,1,-9,-3,511,1,-9,-2,511,1,-9,-1,511,1,-9,0,511,1,-9,1,511,1,-9,2,511,1,-9,3,511,1,-9,4,511,1,-9,5,511,1,-9,6,511,1,-9,7,511,1,-9,8,511,1,-9,9,511,1,-9,10,511,1,-8,-10,511,1,-8,-9,255,1,-8,-8,219,1,-8,-7,219,1,-8,-6,219,1,-8,-5,219,1,-8,-4,219,1,-8,-3,219,1,-8,-2,219,1,-8,-1,219,1,-8,0,219,1,-8,1,219,1,-8,2,219,1,-8,3,219,1,-8,4,219,1,-8,5,219,1,-8,6,219,1,-8,7,219,1,-8,8,219,1,-8,9,507,1,-8,10,511,1,-7,-10,511,1,-7,9,504,1,-7,10,511,1,-6,-10,511,1,-6,9,504,1,-6,10,511,1,-5,-10,511,1,-5,9,504,1,-5,10,511,1,-4,-10,511,1,-4,9,504,1,-4,10,511,1,-3,-10,511,1,-3,9,504,1,-3,10,511,1,-2,-10,511,1,-2,9,504,1,-2,10,511,1,-1,-10,511,1,-1,9,504,1,-1,10,511,1,0,-10,511,1,0,9,504,1,0,10,511,1,1,-10,511,1,1,9,504,1,1,10,511,1,2,-10,511,1,2,9,504,1,2,10,511,1,3,-10,511,1,3,9,504,1,3,10,511,1,4,-10,511,1,4,9,504,1,4,10,511,1,5,-10,511,1,5,9,504,1,5,10,511,1,6,-10,511,1,6,9,504,1,6,10,511,1,7,-10,511,1,7,9,504,1,7,10,511,1,8,-10,511,1,8,9,504,1,8,10,511,1,9,-10,511,1,9,9,504,1,9,10,511,1,10,-10,511,1,10,9,504,1,10,10,511,1,11,-10,511,1,11,9,504,1,11,10,511,1,12,-10,511,1,12,9,504,1,12,10,511,1,13,-10,511,1,13,9,504,1,13,10,511,1,14,-10,511,1,14,9,504,1,14,10,511,1,15,-10,511,1,15,9,504,1,15,10,511,1,16,-10,511,1,16,-9,447,1,16,-8,438,1,16,-7,438,1,16,-6,438,1,16,-5,438,1,16,-4,438,1,16,-3,438,1,16,-2,438,1,16,-1,438,1,16,0,438,1,16,1,438,1,16,2,438,1,16,3,438,1,16,4,438,1,16,5,438,1,16,6,438,1,16,7,438,1,16,8,438,1,16,9,510,1,16,10,511,1,17,-10,511,1,17,-9,511,1,17,-8,511,1,17,-7,511,1,17,-6,511,1,17,-5,511,1,17,-4,511,1,17,-3,511,1,17,-2,511,1,17,-1,511,1,17,0,511,1,17,1,511,1,17,2,511,1,17,3,511,1,17,4,511,1,17,5,511,1,17,6,511,1,17,7,511,1,17,8,511,1,17,9,511,1,17,10,511,1],"CustomFloor1":[3,3,2,2,7,2,3,2,2,7,3,4,2,2,7,2,4,2,2,7,3,5,2,2,7,2,5,2,2,7,1,5,2,2,7,1,4,2,2,7,2,6,2,2,7,1,6,2,2,7,3,6,2,2,7,4,5,2,2,7,4,6,2,2,7,5,5,2,2,7,5,6,2,2,7,10,4,2,2,7,9,4,2,2,7,11,4,2,2,7,11,3,2,2,7,10,3,2,2,7,11,2,2,2,7,10,2,2,2,7,10,1,2,2,7,10,0,2,2,7,10,-1,2,2,7,8,4,2,2,7,5,4,2,2,7,4,4,2,2,7,4,3,2,2,7,5,3,2,2,7,8,2,2,2,7,8,3,2,2,7,9,2,2,2,7,9,3,2,2,7,9,1,2,2,7,5,-1,2,2,7,6,-1,2,2,7,8,-1,2,2,7,9,-1,2,2,7,9,0,2,2,7,-1,2,2,2,7,-2,2,2,2,7,-1,3,2,2,7,-2,3,2,2,7,-1,4,2,2,7,-2,4,2,2,7,-1,5,2,2,7,-2,5,2,2,7,0,4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,8,0,7,2,2,7,-1,7,2,2,7,-2,7,2,2,7,-3,7,2,2,7,-4,7,2,2,7,-4,6,2,2,7,-5,7,2,2,7,-5,6,2,2,7,-6,7,2,2,7,-6,6,2,2,7,-5,8,2,2,8,-6,8,2,2,8,-4,8,2,2,8,-3,8,2,2,8,-2,8,2,2,8,-1,8,2,2,8,-7,8,2,1,8,-7,7,2,1,7,-7,6,2,1,7,-7,5,2,1,7,-7,4,2,1,7,-7,3,2,1,7,-7,2,2,1,7,-7,1,2,1,7,-7,0,2,1,7,-7,-1,2,1,7,-7,-2,2,1,7,-7,-3,2,1,7,-7,-4,2,1,7,-7,-5,2,1,7,-5,-7,2,2,6,-6,-7,2,2,6,-7,-6,2,1,7,-7,-7,2,1,6],"CustomFloor2":[],"CustomFloor3":[],"CustomMiddle1":[],"CustomMiddle2":[],"CustomTop":[]}
\ No newline at end of file
diff --git a/DungeonShooting_Godot/resource/map/tileSet/TileSet1/Test3.png b/DungeonShooting_Godot/resource/map/tileSet/TileSet1/Test3.png
new file mode 100644
index 0000000..c3cbdb1
--- /dev/null
+++ b/DungeonShooting_Godot/resource/map/tileSet/TileSet1/Test3.png
Binary files differ
diff --git a/DungeonShooting_Godot/resource/map/tileSet/TileSet1/Test3.png.import b/DungeonShooting_Godot/resource/map/tileSet/TileSet1/Test3.png.import
new file mode 100644
index 0000000..09c92c1
--- /dev/null
+++ b/DungeonShooting_Godot/resource/map/tileSet/TileSet1/Test3.png.import
@@ -0,0 +1,34 @@
+[remap]
+
+importer="texture"
+type="CompressedTexture2D"
+uid="uid://c8dljk1dbo45l"
+path="res://.godot/imported/Test3.png-c2f29114ce951ed85e4d92b58dbb0d74.ctex"
+metadata={
+"vram_texture": false
+}
+
+[deps]
+
+source_file="res://resource/map/tileSet/TileSet1/Test3.png"
+dest_files=["res://.godot/imported/Test3.png-c2f29114ce951ed85e4d92b58dbb0d74.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/map/tileSet/TileSet1/TileSet.json b/DungeonShooting_Godot/resource/map/tileSet/TileSet1/TileSet.json
index 8bec9fb..31e1b00 100644
--- a/DungeonShooting_Godot/resource/map/tileSet/TileSet1/TileSet.json
+++ b/DungeonShooting_Godot/resource/map/tileSet/TileSet1/TileSet.json
@@ -859,6 +859,210 @@
]
}
]
+ },
+ {
+ "Name": "Test3",
+ "SourcePath": "resource/map/tileSet/TileSet1/Test3.png",
+ "Terrain": [
+ {
+ "Name": "T1",
+ "F": {},
+ "M": {},
+ "T": {
+ "144": [
+ 0,
+ 0
+ ],
+ "146": [
+ 0,
+ 16
+ ],
+ "18": [
+ 0,
+ 32
+ ],
+ "176": [
+ 16,
+ 0
+ ],
+ "184": [
+ 32,
+ 0
+ ],
+ "152": [
+ 48,
+ 0
+ ],
+ "178": [
+ 16,
+ 16
+ ],
+ "186": [
+ 32,
+ 16
+ ],
+ "154": [
+ 48,
+ 16
+ ],
+ "50": [
+ 16,
+ 32
+ ],
+ "58": [
+ 32,
+ 32
+ ],
+ "26": [
+ 48,
+ 32
+ ],
+ "16": [
+ 0,
+ 48
+ ],
+ "48": [
+ 16,
+ 48
+ ],
+ "56": [
+ 32,
+ 48
+ ],
+ "24": [
+ 48,
+ 48
+ ],
+ "187": [
+ 64,
+ 0
+ ],
+ "434": [
+ 64,
+ 16
+ ],
+ "182": [
+ 64,
+ 32
+ ],
+ "250": [
+ 64,
+ 48
+ ],
+ "440": [
+ 80,
+ 0
+ ],
+ "510": [
+ 80,
+ 16
+ ],
+ "447": [
+ 80,
+ 32
+ ],
+ "62": [
+ 80,
+ 48
+ ],
+ "248": [
+ 96,
+ 0
+ ],
+ "190": [
+ 112,
+ 0
+ ],
+ "507": [
+ 96,
+ 16
+ ],
+ "218": [
+ 112,
+ 16
+ ],
+ "255": [
+ 96,
+ 32
+ ],
+ "155": [
+ 112,
+ 32
+ ],
+ "59": [
+ 96,
+ 48
+ ],
+ "442": [
+ 112,
+ 48
+ ],
+ "432": [
+ 128,
+ 0
+ ],
+ "506": [
+ 144,
+ 0
+ ],
+ "504": [
+ 160,
+ 0
+ ],
+ "216": [
+ 176,
+ 0
+ ],
+ "438": [
+ 128,
+ 16
+ ],
+ "443": [
+ 144,
+ 16
+ ],
+ "254": [
+ 160,
+ 32
+ ],
+ "511": [
+ 144,
+ 32
+ ],
+ "446": [
+ 128,
+ 32
+ ],
+ "54": [
+ 128,
+ 48
+ ],
+ "63": [
+ 144,
+ 48
+ ],
+ "191": [
+ 160,
+ 48
+ ],
+ "27": [
+ 176,
+ 48
+ ],
+ "219": [
+ 176,
+ 32
+ ],
+ "251": [
+ 176,
+ 16
+ ]
+ },
+ "TerrainType": 0,
+ "Ready": true
+ }
+ ],
+ "Combination": []
}
]
}
\ No newline at end of file
diff --git a/DungeonShooting_Godot/src/framework/map/serialize/tileSet/TileSetTerrainInfo.cs b/DungeonShooting_Godot/src/framework/map/serialize/tileSet/TileSetTerrainInfo.cs
index 1c067f5..85597b4 100644
--- a/DungeonShooting_Godot/src/framework/map/serialize/tileSet/TileSetTerrainInfo.cs
+++ b/DungeonShooting_Godot/src/framework/map/serialize/tileSet/TileSetTerrainInfo.cs
@@ -80,17 +80,17 @@
///
/// 刷新这个TileSet地形是否可以正常使用了
///
- public void RefreshReady(int terrainIndex)
+ public void RefreshReady(int sourceIndex, int terrainIndex)
{
if (TerrainType == 0)
{
- if (terrainIndex == 0)
+ if (sourceIndex == 0 && terrainIndex == 0)
{
Ready = T != null && T.Count == 47 && M != null && M.Count == 4 && F != null && F.Count == 1;
}
else
{
- Ready = M != null && M.Count == 4 && F != null && F.Count == 1;
+ Ready = T != null && T.Count == 47;
}
}
else
diff --git a/DungeonShooting_Godot/src/game/ui/mapEditor/tileView/EditorTileMap.cs b/DungeonShooting_Godot/src/game/ui/mapEditor/tileView/EditorTileMap.cs
index 76b502c..128a7b4 100644
--- a/DungeonShooting_Godot/src/game/ui/mapEditor/tileView/EditorTileMap.cs
+++ b/DungeonShooting_Godot/src/game/ui/mapEditor/tileView/EditorTileMap.cs
@@ -235,6 +235,11 @@
var newDelta = (float)delta;
_drawFullRect = false;
var position = GetLocalMousePosition();
+ //绘制2x2地形
+ if (CurrBrushType == TileMapDrawMode.Terrain && CurrTerrain != null && CurrTerrain.TerrainInfo.TerrainType == 1 && !_isRightPressed)
+ {
+ position -= new Vector2(GameConfig.TileCellSize / 2f, GameConfig.TileCellSize / 2f);
+ }
_mouseCellPosition = LocalToMap(position);
_mousePosition = new Vector2(
_mouseCellPosition.X * GameConfig.TileCellSize,
@@ -389,7 +394,7 @@
}
else if (CurrBrushType == TileMapDrawMode.Terrain) //绘制地形
{
- if (CurrTerrain == null)
+ if (CurrTerrain == null) //未选择地形
{
DrawCellOutline(canvasItem);
}
@@ -400,9 +405,12 @@
else //2x2
{
DrawCellOutline(canvasItem);
- DrawCellOutline(canvasItem, new Vector2I(GameConfig.TileCellSize, 0));
- DrawCellOutline(canvasItem, new Vector2I(0, GameConfig.TileCellSize));
- DrawCellOutline(canvasItem, new Vector2I(GameConfig.TileCellSize, GameConfig.TileCellSize));
+ if (!_isRightPressed) //没按下左键擦除
+ {
+ DrawCellOutline(canvasItem, new Vector2I(GameConfig.TileCellSize, 0));
+ DrawCellOutline(canvasItem, new Vector2I(0, GameConfig.TileCellSize));
+ DrawCellOutline(canvasItem, new Vector2I(GameConfig.TileCellSize, GameConfig.TileCellSize));
+ }
}
}
}
@@ -876,7 +884,11 @@
}
else if (CurrBrushType == TileMapDrawMode.Terrain) //绘制地形
{
- if (!CurrTerrain.TerrainInfo.Ready) //存在错误就不绘制了
+ if (CurrTerrain == null) //未选择地形
+ {
+ return;
+ }
+ else if (!CurrTerrain.TerrainInfo.Ready) //存在错误就不绘制了
{
return;
}
@@ -888,7 +900,6 @@
}
else if (CurrTerrain.TerrainInfo.TerrainType == 1) //2x2地形
{
-
var arr = new Array()
{
position,
@@ -896,25 +907,8 @@
position + new Vector2I(1, 1),
position + new Vector2I(1, 0),
};
- //这里需要判断周围8格是否是同terrainSet
- // if (EqualsTerrainSet(position + new Vector2I(-1, -1)))
- // arr.Add(position + new Vector2I(-1, -1));
- // if (EqualsTerrainSet(position + new Vector2I(0, -1)))
- // arr.Add(position + new Vector2I(0, -1));
- // if (EqualsTerrainSet(position + new Vector2I(1, -1)))
- // arr.Add(position + new Vector2I(1, -1));
- // if (EqualsTerrainSet(position + new Vector2I(-1, 0)))
- // arr.Add(position + new Vector2I(-1, 0));
- // if (EqualsTerrainSet(position + new Vector2I(1, 0)))
- // arr.Add(position + new Vector2I(1, 0));
- // if (EqualsTerrainSet(position + new Vector2I(-1, 1)))
- // arr.Add(position + new Vector2I(-1, 1));
- // if (EqualsTerrainSet(position + new Vector2I(0, 1)))
- // arr.Add(position + new Vector2I(0, 1));
- // if (EqualsTerrainSet(position + new Vector2I(1, 1)))
- // arr.Add(position + new Vector2I(1, 1));
//绘制自动图块
- SetCellsTerrainConnect(CurrLayer.Layer, arr, CurrTerrain.TerrainSetIndex, 0);
+ SetCellsTerrainConnect(CurrLayer.Layer, arr, CurrTerrain.TerrainSetIndex, 0, false);
dirty = true;
}
}
@@ -972,7 +966,73 @@
}
else //自定义层
{
- EraseCell(CurrLayer.Layer, position);
+ if (CurrBrushType == TileMapDrawMode.Free || CurrBrushType == TileMapDrawMode.Combination) //自由绘制 或者 组合
+ {
+ EraseCell(CurrLayer.Layer, position);
+ }
+ else //绘制地形
+ {
+ if (CurrTerrain == null) //未选择地形
+ {
+ EraseCell(CurrLayer.Layer, position);
+ }
+ else if (CurrTerrain.TerrainInfo.TerrainType == 0 || CurrTerrain.TerrainInfo.TerrainType == 1) //2x2地形 / 3x3地形
+ {
+ EraseCell(CurrLayer.Layer, position);
+
+ var arr2 = new Array();
+ //这里需要判断周围8格是否是同terrainSet
+ if (EqualsTerrainSet(position + new Vector2I(-1, -1)))
+ {
+ EraseCell(CurrLayer.Layer, position + new Vector2I(-1, -1));
+ arr2.Add(position + new Vector2I(-1, -1));
+ }
+
+ if (EqualsTerrainSet(position + new Vector2I(0, -1)))
+ {
+ EraseCell(CurrLayer.Layer, position + new Vector2I(0, -1));
+ arr2.Add(position + new Vector2I(0, -1));
+ }
+
+ if (EqualsTerrainSet(position + new Vector2I(1, -1)))
+ {
+ EraseCell(CurrLayer.Layer, position + new Vector2I(1, -1));
+ arr2.Add(position + new Vector2I(1, -1));
+ }
+
+ if (EqualsTerrainSet(position + new Vector2I(-1, 0)))
+ {
+ EraseCell(CurrLayer.Layer, position + new Vector2I(-1, 0));
+ arr2.Add(position + new Vector2I(-1, 0));
+ }
+
+ if (EqualsTerrainSet(position + new Vector2I(1, 0)))
+ {
+ EraseCell(CurrLayer.Layer, position + new Vector2I(1, 0));
+ arr2.Add(position + new Vector2I(1, 0));
+ }
+
+ if (EqualsTerrainSet(position + new Vector2I(-1, 1)))
+ {
+ EraseCell(CurrLayer.Layer, position + new Vector2I(-1, 1));
+ arr2.Add(position + new Vector2I(-1, 1));
+ }
+
+ if (EqualsTerrainSet(position + new Vector2I(0, 1)))
+ {
+ EraseCell(CurrLayer.Layer, position + new Vector2I(0, 1));
+ arr2.Add(position + new Vector2I(0, 1));
+ }
+
+ if (EqualsTerrainSet(position + new Vector2I(1, 1)))
+ {
+ EraseCell(CurrLayer.Layer, position + new Vector2I(1, 1));
+ arr2.Add(position + new Vector2I(1, 1));
+ }
+
+ SetCellsTerrainConnect(CurrLayer.Layer, arr2, CurrTerrain.TerrainSetIndex, 0, false);
+ }
+ }
//标记有修改数据
EventManager.EmitEvent(EventEnum.OnTileMapDirty);
}
diff --git a/DungeonShooting_Godot/src/game/ui/tileSetEditorTerrain/up/TerrainCell.cs b/DungeonShooting_Godot/src/game/ui/tileSetEditorTerrain/up/TerrainCell.cs
index 7ff2535..c0ba71e 100644
--- a/DungeonShooting_Godot/src/game/ui/tileSetEditorTerrain/up/TerrainCell.cs
+++ b/DungeonShooting_Godot/src/game/ui/tileSetEditorTerrain/up/TerrainCell.cs
@@ -120,12 +120,12 @@
if (cellData == null)
{
_panel.CurrTerrain?.RemoveTerrainCell(Index, Data);
- _panel.CurrTerrain?.RefreshReady(_panel.CurrTerrainIndex);
+ _panel.CurrTerrain?.RefreshReady(_panel.EditorPanel.TileSetSourceIndex, _panel.CurrTerrainIndex);
}
else
{
_panel.CurrTerrain?.SetTerrainCell(Index, Data, cellData);
- _panel.CurrTerrain?.RefreshReady(_panel.CurrTerrainIndex);
+ _panel.CurrTerrain?.RefreshReady(_panel.EditorPanel.TileSetSourceIndex, _panel.CurrTerrainIndex);
}
EventManager.EmitEvent(EventEnum.OnTileSetDirty);