Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
## [4.0.1] - 2023-04-26
### Fixed
- [GameObjectBrush] Set HideFlags of instantiated GameObject to HideFlags.None when painting
- [GridInformation] Fix serialization of GridInformationKey/Value
  • Loading branch information
Unity Technologies committed Apr 26, 2023
1 parent 49dd0fb commit e052ca5
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 7 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@ All notable changes to this package will be documented in this file.

The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)

## [4.0.1] - 2023-04-26
### Fixed
- [GameObjectBrush] Set HideFlags of instantiated GameObject to HideFlags.None when painting
- [GridInformation] Fix serialization of GridInformationKey/Value

## [4.0.0] - 2023-03-07
### Added
- [RuleTile] Add RotatedMirror rule which checks neighbors using both the mirror and rotation Rule in addition to the standard rotation Rule
Expand Down
4 changes: 2 additions & 2 deletions Editor/Brushes/GameObjectBrush/GameObjectBrush.cs
Original file line number Diff line number Diff line change
Expand Up @@ -592,10 +592,10 @@ private static void SetSceneCell(GridLayout grid, Transform parent, Vector3Int p
renderer.enabled = true;
}
}

instance.hideFlags = HideFlags.None;
Undo.RegisterCreatedObjectUndo(instance, "Paint GameObject");

var anchorRatio = GetAnchorRatio(grid, anchor);

instance.transform.position = grid.LocalToWorld(grid.CellToLocalInterpolated(position) + grid.CellToLocalInterpolated(anchorRatio));
instance.transform.localRotation = orientation;
instance.transform.localScale = scale;
Expand Down
2 changes: 2 additions & 0 deletions Runtime/GridInformation/GridInformation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,14 @@ internal enum GridInformationType
[AddComponentMenu("Tilemap/Grid Information")]
public class GridInformation : MonoBehaviour, ISerializationCallbackReceiver
{
[Serializable]
internal struct GridInformationValue
{
public GridInformationType type;
public object data;
}

[Serializable]
internal struct GridInformationKey : IEquatable<GridInformationKey>
{
public Vector3Int position;
Expand Down
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "com.unity.2d.tilemap.extras",
"displayName": "2D Tilemap Extras",
"version": "4.0.0",
"version": "4.0.1",
"unity": "2023.1",
"description": "2D Tilemap Extras is a package that contains extra scripts for use with 2D Tilemap features in Unity. These include custom Tiles and Brushes for the Tilemap feature.\n\nThe following are included in the package:\nBrushes: GameObject Brush, Group Brush, Line Brush, Random Brush\nTiles: Animated Tile, Rule Tile, Rule Override Tile\nOther: Grid Information, Custom Rules for Rule Tile",
"keywords": [
Expand All @@ -15,7 +15,7 @@
"com.unity.modules.jsonserialize": "1.0.0"
},
"relatedPackages": {
"com.unity.2d.tilemap.extras.tests": "4.0.0"
"com.unity.2d.tilemap.extras.tests": "4.0.1"
},
"samples": [
{
Expand All @@ -35,15 +35,15 @@
}
],
"_upm": {
"changelog": "### Added\n- [RuleTile] Add RotatedMirror rule which checks neighbors using both the mirror and rotation Rule in addition to the standard rotation Rule\n\n### Fixed\n- [GameObjectBrush] Validate size of GameObjectBrush when it changes"
"changelog": "### Fixed\n- [GameObjectBrush] Set HideFlags of instantiated GameObject to HideFlags.None when painting\n- [GridInformation] Fix serialization of GridInformationKey/Value"
},
"upmCi": {
"footprint": "9700ea727395a7b9e99c30cc1b6d3ab7f7007532"
"footprint": "e48f8942babb511d4a959a658cbe96fcbc536dfc"
},
"documentationUrl": "https://docs.unity3d.com/Packages/[email protected]/manual/index.html",
"repository": {
"url": "https://github.com/Unity-Technologies/2d-extras.git",
"type": "git",
"revision": "9961725b5671e3bdfad54e45abc175e446f2131e"
"revision": "5c1725c663304c56eb3b1612a8dae90f4a0b9fa5"
}
}

0 comments on commit e052ca5

Please sign in to comment.