Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/expose create mesh colliders in unityevents #1

Merged
merged 4 commits into from
Feb 12, 2024
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 11 additions & 4 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,21 @@ 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/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).

## 1.0.0

## 1.1.0
sambaas marked this conversation as resolved.
Show resolved Hide resolved

### Added

- moved tileHandler and layers to its own repo
- Serialized property for createMeshcollider bool, in order to change bool as Dynamic Bool from UnityEvents

## 1.0.1

### fixed
### Fixed

- changed namespace to work with changed namespace of SubObjects package
- changed namespace to work with changed namespace of SubObjects package

## 1.0.0

### Added

- moved tileHandler and layers to its own repo
6 changes: 4 additions & 2 deletions Runtime/Scripts/Layers/BinaryMeshLayer/BinaryMeshLayer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ public class BinaryMeshLayer : Layer
public string removeFromID;
#endif
public List<Material> DefaultMaterialList = new List<Material>();
public bool createMeshcollider = false;
public ShadowCastingMode tileShadowCastingMode = ShadowCastingMode.On;

public string brotliCompressedExtention = ".br";
Expand All @@ -31,6 +30,9 @@ public class BinaryMeshLayer : Layer
private Mesh mesh;
private MeshRenderer meshRenderer;

public bool createMeshcollider = false;
sambaas marked this conversation as resolved.
Show resolved Hide resolved
public bool CreateMeshcollider { get => createMeshcollider; set => createMeshcollider = value; }

public override void HandleTile(TileChange tileChange, System.Action<TileChange> callback = null)
{
TileAction action = tileChange.action;
Expand Down Expand Up @@ -256,7 +258,7 @@ private GameObject CreateNewGameObject(string source, byte[] binaryMeshData, Til
meshRenderer.sharedMaterials = materialList.ToArray();
meshRenderer.shadowCastingMode = tileShadowCastingMode;

if (createMeshcollider)
if (CreateMeshcollider)
{
container.AddComponent<MeshCollider>().sharedMesh = mesh;
}
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "eu.netherlands3d.cartesiantiles",
"version": "1.0.1",
"version": "1.1.0",
"displayName": "Netherlands3D - Cartesian Tiles",
"description": "Loads and unloads datasets in a cartesian coordinateSystem",
"unity": "2022.2",
Expand Down