public void RebuildArea(RectInt area, float tileSize, bool paintEmptyTileColorsBlack) { paintEmptyTilesBlack = paintEmptyTileColorsBlack; PrepareTopFaces(area.ExpandRect(1), tileSize); SmoothNormals(area); }
//public bool RedoChange(out RectInt affectedRegion) //{ // var success = ChangeTracker.Redo(out var cells, out affectedRegion); // if(success) // { // container.CellData = cells; // EditorUtility.SetDirty(this); // } // return success; //} private void UpdateWalkCellData(RectInt area) { area = area.ExpandRect(1); area.ClampToBounds(Rect); for (var x = area.xMin; x < area.xMax; x++) { for (var y = area.yMin; y < area.yMax; y++) { var wc = WalkCellData.Cells[x + y * Width]; var cell = Cell(x, y); wc.Heights = cell.Heights; wc.Type = RagnarokWalkData.ColorToCellMask(cell.Top.Texture); WalkCellData.Cells[x + y * Width] = wc; } } EditorUtility.SetDirty(WalkCellData); }