physics wip

This commit is contained in:
2015-05-28 01:11:03 +06:00
parent b638117c89
commit 16825a6512
6 changed files with 755 additions and 219 deletions

View File

@@ -87,6 +87,130 @@ NavMeshSettings:
cellSize: .166666672 cellSize: .166666672
manualCellSize: 0 manualCellSize: 0
m_NavMeshData: {fileID: 0} m_NavMeshData: {fileID: 0}
--- !u!1001 &77928946
Prefab:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
m_TransformParent: {fileID: 0}
m_Modifications:
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.y
value: 216.398239
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.z
value: 23.0769234
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.w
value: 1
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_RootOrder
value: 2
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.x
value: 1
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.y
value: 1
objectReference: {fileID: 0}
- target: {fileID: 11422542, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: IsKinematic
value: 0
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.z
value: 12.5248899
objectReference: {fileID: 0}
- target: {fileID: 117528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_Name
value: Cube_1x1x10
objectReference: {fileID: 0}
m_RemovedComponents: []
m_ParentPrefab: {fileID: 100100000, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
m_IsPrefabParent: 0
--- !u!1001 &255120380
Prefab:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
m_TransformParent: {fileID: 0}
m_Modifications:
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.y
value: 286.0672
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.w
value: 1
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_RootOrder
value: 0
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.x
value: 1
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.y
value: 1
objectReference: {fileID: 0}
- target: {fileID: 11422542, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: IsKinematic
value: 0
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.z
value: 16.8792
objectReference: {fileID: 0}
- target: {fileID: 117528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_Name
value: Cube_1x1x12
objectReference: {fileID: 0}
m_RemovedComponents: []
m_ParentPrefab: {fileID: 100100000, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
m_IsPrefabParent: 0
--- !u!1 &318480492 --- !u!1 &318480492
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@@ -171,7 +295,7 @@ Transform:
m_LocalScale: {x: 1, y: 1, z: 1} m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: [] m_Children: []
m_Father: {fileID: 0} m_Father: {fileID: 0}
m_RootOrder: 5 m_RootOrder: 13
--- !u!114 &318480498 --- !u!114 &318480498
MonoBehaviour: MonoBehaviour:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@@ -184,6 +308,70 @@ MonoBehaviour:
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
_tileSize: 16 _tileSize: 16
_minDepth: 0
_maxDepth: 100
--- !u!1001 &436310376
Prefab:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
m_TransformParent: {fileID: 0}
m_Modifications:
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.y
value: 115.413193
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.z
value: 53.8461533
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.w
value: 1
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_RootOrder
value: 5
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.x
value: 1
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.y
value: 1
objectReference: {fileID: 0}
- target: {fileID: 11422542, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: IsKinematic
value: 0
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.z
value: 6.21332455
objectReference: {fileID: 0}
- target: {fileID: 117528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_Name
value: Cube_1x1x7
objectReference: {fileID: 0}
m_RemovedComponents: []
m_ParentPrefab: {fileID: 100100000, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
m_IsPrefabParent: 0
--- !u!1001 &485514980 --- !u!1001 &485514980
Prefab: Prefab:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@@ -193,15 +381,15 @@ Prefab:
m_Modifications: m_Modifications:
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.x propertyPath: m_LocalPosition.x
value: -48 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.y propertyPath: m_LocalPosition.y
value: 72 value: 40
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.z propertyPath: m_LocalPosition.z
value: 0 value: 76.9230728
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.x propertyPath: m_LocalRotation.x
@@ -221,256 +409,570 @@ Prefab:
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_RootOrder propertyPath: m_RootOrder
value: 4 value: 11
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2} - target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.x propertyPath: _position.x
value: 3 value: 1
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2} - target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.y propertyPath: _position.y
value: 6 value: 1
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 11422542, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2} - target: {fileID: 11422542, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: IsKinematic propertyPath: IsKinematic
value: 1 value: 0
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.z
value: 1.5
objectReference: {fileID: 0} objectReference: {fileID: 0}
m_RemovedComponents: [] m_RemovedComponents: []
m_ParentPrefab: {fileID: 100100000, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2} m_ParentPrefab: {fileID: 100100000, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
m_IsPrefabParent: 0 m_IsPrefabParent: 0
--- !u!1001 &645158917 --- !u!1001 &564579619
Prefab: Prefab:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
serializedVersion: 2 serializedVersion: 2
m_Modification: m_Modification:
m_TransformParent: {fileID: 0} m_TransformParent: {fileID: 0}
m_Modifications: m_Modifications:
- target: {fileID: 453620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 453404, guid: d10e5320df9f84d4186bda0ba98db9ff, type: 2}
propertyPath: m_LocalPosition.x propertyPath: m_LocalPosition.x
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 453620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 453404, guid: d10e5320df9f84d4186bda0ba98db9ff, type: 2}
propertyPath: m_LocalPosition.y propertyPath: m_LocalPosition.y
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 453620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 453404, guid: d10e5320df9f84d4186bda0ba98db9ff, type: 2}
propertyPath: m_LocalPosition.z propertyPath: m_LocalPosition.z
value: 0 value: 92.3076859
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 453620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 453404, guid: d10e5320df9f84d4186bda0ba98db9ff, type: 2}
propertyPath: m_LocalRotation.x propertyPath: m_LocalRotation.x
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 453620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 453404, guid: d10e5320df9f84d4186bda0ba98db9ff, type: 2}
propertyPath: m_LocalRotation.y propertyPath: m_LocalRotation.y
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 453620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 453404, guid: d10e5320df9f84d4186bda0ba98db9ff, type: 2}
propertyPath: m_LocalRotation.z propertyPath: m_LocalRotation.z
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 453620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 453404, guid: d10e5320df9f84d4186bda0ba98db9ff, type: 2}
propertyPath: m_LocalRotation.w propertyPath: m_LocalRotation.w
value: 1 value: 1
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 453620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 453404, guid: d10e5320df9f84d4186bda0ba98db9ff, type: 2}
propertyPath: m_RootOrder propertyPath: m_RootOrder
value: 0 value: 12
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 11453620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 11453404, guid: d10e5320df9f84d4186bda0ba98db9ff, type: 2}
propertyPath: _position.x propertyPath: _position.x
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 11453620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 11453404, guid: d10e5320df9f84d4186bda0ba98db9ff, type: 2}
propertyPath: _position.y propertyPath: _position.y
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 11416990, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2}
propertyPath: IsKinematic
value: 1
objectReference: {fileID: 0}
- target: {fileID: 153620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2}
propertyPath: m_Name
value: Cube_1x3x2
objectReference: {fileID: 0}
- target: {fileID: 21253620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2}
propertyPath: m_SortingOrder
value: -2
objectReference: {fileID: 0}
m_RemovedComponents: [] m_RemovedComponents: []
m_ParentPrefab: {fileID: 100100000, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} m_ParentPrefab: {fileID: 100100000, guid: d10e5320df9f84d4186bda0ba98db9ff, type: 2}
m_IsPrefabParent: 0 m_IsPrefabParent: 0
--- !u!1001 &1506134427 --- !u!1001 &572075320
Prefab: Prefab:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
serializedVersion: 2 serializedVersion: 2
m_Modification: m_Modification:
m_TransformParent: {fileID: 0} m_TransformParent: {fileID: 0}
m_Modifications: m_Modifications:
- target: {fileID: 462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.x propertyPath: m_LocalPosition.x
value: .841789246
objectReference: {fileID: 0}
- target: {fileID: 462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2}
propertyPath: m_LocalPosition.y
value: -10.5253239
objectReference: {fileID: 0}
- target: {fileID: 462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2}
propertyPath: m_LocalPosition.z
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.y
value: 262.06723
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.z
value: 7.69230747
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.x propertyPath: m_LocalRotation.x
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.y propertyPath: m_LocalRotation.y
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.z propertyPath: m_LocalRotation.z
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.w propertyPath: m_LocalRotation.w
value: 1 value: 1
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_RootOrder propertyPath: m_RootOrder
value: 1 value: 1
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 11462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} - target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.x propertyPath: _position.x
value: -.605221629 value: 1
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 11462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} - target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.y propertyPath: _position.y
value: -.657833457 value: 1
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 11462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} - target: {fileID: 11422542, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: IsKinematic
value: 0
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.z propertyPath: _position.z
value: -.0263051987 value: 15.3792019
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 162204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} - target: {fileID: 117528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_Name propertyPath: m_Name
value: Cube_3x1x3 value: Cube_1x1x11
objectReference: {fileID: 0}
- target: {fileID: 21262204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2}
propertyPath: m_SortingOrder
value: 2
objectReference: {fileID: 0} objectReference: {fileID: 0}
m_RemovedComponents: [] m_RemovedComponents: []
m_ParentPrefab: {fileID: 100100000, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} m_ParentPrefab: {fileID: 100100000, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
m_IsPrefabParent: 0 m_IsPrefabParent: 0
--- !u!1001 &1517863249 --- !u!1001 &675176528
Prefab: Prefab:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
serializedVersion: 2 serializedVersion: 2
m_Modification: m_Modification:
m_TransformParent: {fileID: 0} m_TransformParent: {fileID: 0}
m_Modifications: m_Modifications:
- target: {fileID: 453620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.x propertyPath: m_LocalPosition.x
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 453620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.y propertyPath: m_LocalPosition.y
value: 64 value: 85.6689911
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 453620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.z propertyPath: m_LocalPosition.z
value: 0 value: 61.5384598
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 453620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.x propertyPath: m_LocalRotation.x
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 453620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.y propertyPath: m_LocalRotation.y
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 453620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.z propertyPath: m_LocalRotation.z
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 453620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.w propertyPath: m_LocalRotation.w
value: 1 value: 1
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 453620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_RootOrder propertyPath: m_RootOrder
value: 7 value: 8
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 11453620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.x propertyPath: _position.x
value: 4 value: 1
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 11453620, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.y propertyPath: _position.y
value: 4 value: 1
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 11416990, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} - target: {fileID: 11422542, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: IsKinematic propertyPath: IsKinematic
value: 1 value: 0
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.z
value: 4.35431194
objectReference: {fileID: 0}
- target: {fileID: 117528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_Name
value: Cube_1x1x4
objectReference: {fileID: 0} objectReference: {fileID: 0}
m_RemovedComponents: [] m_RemovedComponents: []
m_ParentPrefab: {fileID: 100100000, guid: dbd21aa1b9a2cdf4a944f50e64d145a1, type: 2} m_ParentPrefab: {fileID: 100100000, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
m_IsPrefabParent: 0 m_IsPrefabParent: 0
--- !u!1001 &1919115803 --- !u!1001 &855841511
Prefab: Prefab:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
serializedVersion: 2 serializedVersion: 2
m_Modification: m_Modification:
m_TransformParent: {fileID: 0} m_TransformParent: {fileID: 0}
m_Modifications: m_Modifications:
- target: {fileID: 462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.x propertyPath: m_LocalPosition.x
value: -80
objectReference: {fileID: 0}
- target: {fileID: 462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2}
propertyPath: m_LocalPosition.y
value: 72
objectReference: {fileID: 0}
- target: {fileID: 462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2}
propertyPath: m_LocalPosition.z
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.y
value: 139.413193
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.z
value: 46.1538467
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.x propertyPath: m_LocalRotation.x
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.y propertyPath: m_LocalRotation.y
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.z propertyPath: m_LocalRotation.z
value: 0 value: 0
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.w propertyPath: m_LocalRotation.w
value: 1 value: 1
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} - target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_RootOrder propertyPath: m_RootOrder
value: 4 value: 4
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 11462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} - target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.x propertyPath: _position.x
value: 2 value: 1
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 11462204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} - target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.y propertyPath: _position.y
value: 7 value: 1
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 162204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} - target: {fileID: 11422542, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: IsKinematic
value: 0
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.z
value: 7.71332455
objectReference: {fileID: 0}
- target: {fileID: 117528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_Name propertyPath: m_Name
value: Cube_3x1x2 value: Cube_1x1x8
objectReference: {fileID: 0}
- target: {fileID: 21262204, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2}
propertyPath: m_SortingOrder
value: -2
objectReference: {fileID: 0} objectReference: {fileID: 0}
m_RemovedComponents: [] m_RemovedComponents: []
m_ParentPrefab: {fileID: 100100000, guid: fb3806e9ed7ada045b1b57419ac1ee53, type: 2} m_ParentPrefab: {fileID: 100100000, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
m_IsPrefabParent: 0
--- !u!1001 &1069409129
Prefab:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
m_TransformParent: {fileID: 0}
m_Modifications:
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.y
value: 161.082184
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.z
value: 38.4615402
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.w
value: 1
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_RootOrder
value: 6
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.x
value: 1
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.y
value: 1
objectReference: {fileID: 0}
- target: {fileID: 11422542, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: IsKinematic
value: 0
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.z
value: 9.06763649
objectReference: {fileID: 0}
- target: {fileID: 117528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_Name
value: Cube_1x1x6
objectReference: {fileID: 0}
m_RemovedComponents: []
m_ParentPrefab: {fileID: 100100000, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
m_IsPrefabParent: 0
--- !u!1001 &1418469066
Prefab:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
m_TransformParent: {fileID: 0}
m_Modifications:
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.y
value: 16
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.z
value: 84.6153793
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.w
value: 1
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_RootOrder
value: 10
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.x
value: 1
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.y
value: 1
objectReference: {fileID: 0}
- target: {fileID: 11422542, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: IsKinematic
value: 0
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 117528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_Name
value: Cube_1x1x2
objectReference: {fileID: 0}
m_RemovedComponents: []
m_ParentPrefab: {fileID: 100100000, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
m_IsPrefabParent: 0
--- !u!1001 &1423117994
Prefab:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
m_TransformParent: {fileID: 0}
m_Modifications:
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.y
value: 240.398239
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.z
value: 15.3846149
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.w
value: 1
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_RootOrder
value: 3
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.x
value: 1
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.y
value: 1
objectReference: {fileID: 0}
- target: {fileID: 11422542, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: IsKinematic
value: 0
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.z
value: 14.0248899
objectReference: {fileID: 0}
- target: {fileID: 117528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_Name
value: Cube_1x1x9
objectReference: {fileID: 0}
m_RemovedComponents: []
m_ParentPrefab: {fileID: 100100000, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
m_IsPrefabParent: 0
--- !u!1001 &1689211580
Prefab:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
m_TransformParent: {fileID: 0}
m_Modifications:
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.y
value: 185.082184
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.z
value: 30.7692318
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.w
value: 1
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_RootOrder
value: 7
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.x
value: 1
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.y
value: 1
objectReference: {fileID: 0}
- target: {fileID: 11422542, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: IsKinematic
value: 0
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.z
value: 10.5676365
objectReference: {fileID: 0}
- target: {fileID: 117528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_Name
value: Cube_1x1x5
objectReference: {fileID: 0}
m_RemovedComponents: []
m_ParentPrefab: {fileID: 100100000, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
m_IsPrefabParent: 0
--- !u!1001 &2146034803
Prefab:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
m_TransformParent: {fileID: 0}
m_Modifications:
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.y
value: 61.6689911
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalPosition.z
value: 69.2307663
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_LocalRotation.w
value: 1
objectReference: {fileID: 0}
- target: {fileID: 417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_RootOrder
value: 9
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.x
value: 1
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.y
value: 1
objectReference: {fileID: 0}
- target: {fileID: 11422542, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: IsKinematic
value: 0
objectReference: {fileID: 0}
- target: {fileID: 11417528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: _position.z
value: 2.85431194
objectReference: {fileID: 0}
- target: {fileID: 117528, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
propertyPath: m_Name
value: Cube_1x1x3
objectReference: {fileID: 0}
m_RemovedComponents: []
m_ParentPrefab: {fileID: 100100000, guid: c1b9b2ad3a021c549aa9190df3101248, type: 2}
m_IsPrefabParent: 0 m_IsPrefabParent: 0

View File

@@ -6,18 +6,74 @@ using UnityEditor;
namespace IsoTools { namespace IsoTools {
[ExecuteInEditMode] [ExecuteInEditMode]
[RequireComponent(typeof(SpriteRenderer))]
public class IsoObject : MonoBehaviour { public class IsoObject : MonoBehaviour {
#if UNITY_EDITOR #if UNITY_EDITOR
Vector2 _lastTransform = Vector2.zero;
Vector3 _lastPosition = Vector3.zero;
Vector3 _lastSize = Vector3.zero; Vector3 _lastSize = Vector3.zero;
Vector3 _lastPosition = Vector3.zero;
Vector2 _lastTransform = Vector2.zero;
#endif #endif
// ------------------------------------------------------------------------
//
// Size
//
// ------------------------------------------------------------------------
[SerializeField]
Vector3 _size = Vector3.one;
/// <summary>Isometric object size.</summary>
public Vector3 Size {
get { return _size; }
set {
_size = IsoUtils.Vec3Max(value, Vector3.zero);
FixTransform();
}
}
/// <summary>Isometric object size X.</summary>
public float SizeX {
get { return Size.x; }
set { Size = IsoUtils.Vec3ChangeX(Size, value); }
}
/// <summary>Isometric object size Y.</summary>
public float SizeY {
get { return Size.y; }
set { Size = IsoUtils.Vec3ChangeY(Size, value); }
}
/// <summary>Isometric object size Z.</summary>
public float SizeZ {
get { return Size.z; }
set { Size = IsoUtils.Vec3ChangeZ(Size, value); }
}
/// <summary>Isometric object size XY.</summary>
public Vector2 SizeXY {
get { return new Vector2(SizeX, SizeY); }
}
/// <summary>Isometric object size YZ.</summary>
public Vector2 SizeYZ {
get { return new Vector2(SizeY, SizeZ); }
}
/// <summary>Isometric object size XZ.</summary>
public Vector2 SizeXZ {
get { return new Vector2(SizeX, SizeZ); }
}
// ------------------------------------------------------------------------
//
// Position
//
// ------------------------------------------------------------------------
[SerializeField] [SerializeField]
Vector3 _position = Vector3.zero; Vector3 _position = Vector3.zero;
/// <summary>Isometric object position.</summary> /// <summary>Isometric object position.</summary>
public Vector3 Position { public Vector3 Position {
get { return _position; } get { return _position; }
@@ -26,7 +82,7 @@ namespace IsoTools {
FixTransform(); FixTransform();
} }
} }
/// <summary>Isometric object position X.</summary> /// <summary>Isometric object position X.</summary>
public float PositionX { public float PositionX {
get { return Position.x; } get { return Position.x; }
@@ -44,66 +100,27 @@ namespace IsoTools {
get { return Position.z; } get { return Position.z; }
set { Position = IsoUtils.Vec3ChangeZ(Position, value); } set { Position = IsoUtils.Vec3ChangeZ(Position, value); }
} }
/// <summary>Isometric object position XY.</summary> /// <summary>Isometric object position XY.</summary>
public Vector2 PositionXY { public Vector2 PositionXY {
get { return new Vector2(PositionX, PositionY); } get { return new Vector2(PositionX, PositionY); }
} }
/// <summary>Isometric object position YZ.</summary> /// <summary>Isometric object position YZ.</summary>
public Vector2 PositionYZ { public Vector2 PositionYZ {
get { return new Vector2(PositionY, PositionZ); } get { return new Vector2(PositionY, PositionZ); }
} }
/// <summary>Isometric object position XZ.</summary> /// <summary>Isometric object position XZ.</summary>
public Vector2 PositionXZ { public Vector2 PositionXZ {
get { return new Vector2(PositionX, PositionZ); } get { return new Vector2(PositionX, PositionZ); }
} }
[SerializeField] // ------------------------------------------------------------------------
Vector3 _size = Vector3.one; //
// TilePosition
/// <summary>Isometric object size.</summary> //
public Vector3 Size { // ------------------------------------------------------------------------
get { return _size; }
set {
_size = IsoUtils.Vec3Max(value, Vector3.zero);
FixTransform();
}
}
/// <summary>Isometric object size X.</summary>
public float SizeX {
get { return Size.x; }
set { Size = IsoUtils.Vec3ChangeX(Size, value); }
}
/// <summary>Isometric object size Y.</summary>
public float SizeY {
get { return Size.y; }
set { Size = IsoUtils.Vec3ChangeY(Size, value); }
}
/// <summary>Isometric object size Z.</summary>
public float SizeZ {
get { return Size.z; }
set { Size = IsoUtils.Vec3ChangeZ(Size, value); }
}
/// <summary>Isometric object size XY.</summary>
public Vector2 SizeXY {
get { return new Vector2(SizeX, SizeY); }
}
/// <summary>Isometric object size YZ.</summary>
public Vector2 SizeYZ {
get { return new Vector2(SizeY, SizeZ); }
}
/// <summary>Isometric object size XZ.</summary>
public Vector2 SizeXZ {
get { return new Vector2(SizeX, SizeZ); }
}
/// <summary>Isometric object tile position.</summary> /// <summary>Isometric object tile position.</summary>
public Vector3 TilePosition { public Vector3 TilePosition {
@@ -144,6 +161,12 @@ namespace IsoTools {
get { return new Vector2(TilePositionX, TilePositionZ); } get { return new Vector2(TilePositionX, TilePositionZ); }
} }
// ------------------------------------------------------------------------
//
// Functions
//
// ------------------------------------------------------------------------
IsoWorld _iso_world = null; IsoWorld _iso_world = null;
public IsoWorld IsoWorld { public IsoWorld IsoWorld {
get { get {
@@ -178,9 +201,9 @@ namespace IsoTools {
void FixLastProperties() { void FixLastProperties() {
#if UNITY_EDITOR #if UNITY_EDITOR
_lastTransform = transform.position;
_lastPosition = Position;
_lastSize = Size; _lastSize = Size;
_lastPosition = Position;
_lastTransform = transform.position;
#endif #endif
} }

View File

@@ -41,6 +41,8 @@ namespace IsoTools {
bool _dirty = true; bool _dirty = true;
float _lastTileSize = 0.0f; float _lastTileSize = 0.0f;
float _lastMinDepth = 0.0f;
float _lastMaxDepth = 0.0f;
List<SectorInfo> _sectors = new List<SectorInfo>(); List<SectorInfo> _sectors = new List<SectorInfo>();
List<ObjectInfo> _objects = new List<ObjectInfo>(); List<ObjectInfo> _objects = new List<ObjectInfo>();
@@ -60,6 +62,28 @@ namespace IsoTools {
ChangeSortingProperty(); ChangeSortingProperty();
} }
} }
[SerializeField]
public float _minDepth = 0.0f;
/// <summary>Min sorting depth value.</summary>
public float MinDepth {
get { return _minDepth; }
set {
_minDepth = value;
ChangeSortingProperty();
}
}
[SerializeField]
public float _maxDepth = 100.0f;
/// <summary>Max sorting depth value.</summary>
public float MaxDepth {
get { return _maxDepth; }
set {
_maxDepth = value;
ChangeSortingProperty();
}
}
// ------------------------------------------------------------------------ // ------------------------------------------------------------------------
/// <summary> /// <summary>
@@ -75,14 +99,11 @@ namespace IsoTools {
/// <summary> /// <summary>
/// Marks world for resorting. /// Marks world for resorting.
/// </summary> /// </summary>
/// <param name="obj">Isometric object for resorting.</param> /// <param name="iso_object">Isometric object for resorting.</param>
// ------------------------------------------------------------------------ // ------------------------------------------------------------------------
public void MarkDirty(IsoObject obj) { public void MarkDirty(IsoObject iso_object) {
if ( obj ) { if ( iso_object && IsIsoObjectVisible(iso_object) ) {
var renderer = obj.GetComponent<SpriteRenderer>(); MarkDirty();
if ( renderer && renderer.isVisible ) {
MarkDirty();
}
} }
} }
@@ -127,6 +148,21 @@ namespace IsoTools {
iso_z); iso_z);
} }
// ------------------------------------------------------------------------
//
// Private
//
// ------------------------------------------------------------------------
bool IsIsoObjectVisible(IsoObject iso_object) {
var renderer = iso_object.GetComponent<Renderer>();
if ( renderer && renderer.isVisible ) {
return true;
}
var renderers = iso_object.GetComponentsInChildren<Renderer>();
return renderers.Any(r => r.isVisible);
}
void MarkEditorWorldDirty() { void MarkEditorWorldDirty() {
#if UNITY_EDITOR #if UNITY_EDITOR
if ( Application.isEditor ) { if ( Application.isEditor ) {
@@ -150,6 +186,8 @@ namespace IsoTools {
MarkDirty(); MarkDirty();
FixAllTransforms(); FixAllTransforms();
_lastTileSize = TileSize; _lastTileSize = TileSize;
_lastMinDepth = MinDepth;
_lastMaxDepth = MaxDepth;
} }
int SectorIndex(Vector3 num_pos) { int SectorIndex(Vector3 num_pos) {
@@ -211,32 +249,16 @@ namespace IsoTools {
var a_yesno = a_max.x > b_min.x && a_max.y > b_min.y && b_max.z > a_min.z; var a_yesno = a_max.x > b_min.x && a_max.y > b_min.y && b_max.z > a_min.z;
var b_yesno = b_max.x > a_min.x && b_max.y > a_min.y && a_max.z > b_min.z; var b_yesno = b_max.x > a_min.x && b_max.y > a_min.y && a_max.z > b_min.z;
if ( a_yesno && b_yesno ) { if ( a_yesno && b_yesno ) {
var da_p = new Vector3(a_max.x - b_min.x, a_max.y - b_min.y, a_max.z - b_min.z); var da_p = new Vector3(a_max.x - b_min.x, a_max.y - b_min.y, b_max.z - a_min.z);
var db_p = new Vector3(b_max.x - a_min.x, b_max.y - a_min.y, b_max.z - a_min.z); var db_p = new Vector3(b_max.x - a_min.x, b_max.y - a_min.y, a_max.z - b_min.z);
var dd_p = IsoUtils.Vec3Abs(da_p - db_p); var dp_p = a_size + b_size - IsoUtils.Vec3Abs(da_p - db_p);
if ( dp_p.x <= dp_p.y && dp_p.x <= dp_p.z ) {
Debug.LogFormat("CoefDB: {0}:::{1}:::{2}", dd_p.x, dd_p.y, dd_p.z);
Debug.LogFormat("----------------------------");
if ( dd_p.z > dd_p.x || dd_p.z > dd_p.y ) {
Debug.Log("by z");
return da_p.z < db_p.z;
} else if ( dd_p.x > dd_p.y && dd_p.x > dd_p.z ) {
Debug.Log("by x");
return da_p.x > db_p.x; return da_p.x > db_p.x;
} else if ( dd_p.y > dd_p.x && dd_p.y > dd_p.z) { } else if ( dp_p.y <= dp_p.x && dp_p.y <= dp_p.z ) {
Debug.Log("by y");
return da_p.y > db_p.y;
}
/*
if ( dd_p.x < dd_p.y ) {
Debug.Log("by y");
return da_p.y > db_p.y; return da_p.y > db_p.y;
} else { } else {
Debug.Log("by x"); return da_p.z > db_p.z;
return da_p.x > db_p.x; }
}*/
} }
return a_yesno; return a_yesno;
} }
@@ -245,8 +267,7 @@ namespace IsoTools {
_objsSectorSize = 0.0f; _objsSectorSize = 0.0f;
var objsSum = 0; var objsSum = 0;
foreach ( var obj in iso_objects ) { foreach ( var obj in iso_objects ) {
var renderer = obj.GetComponent<SpriteRenderer>(); if ( IsIsoObjectVisible(obj) ) {
if ( renderer && renderer.isVisible ) {
++objsSum; ++objsSum;
_objsSectorSize += Mathf.Max(obj.Size.x, obj.Size.y, obj.Size.z); _objsSectorSize += Mathf.Max(obj.Size.x, obj.Size.y, obj.Size.z);
} }
@@ -259,8 +280,7 @@ namespace IsoTools {
_objsMinNumPos = Vector3.zero; _objsMinNumPos = Vector3.zero;
_objsMaxNumPos = Vector3.one; _objsMaxNumPos = Vector3.one;
foreach ( var obj in iso_objects ) { foreach ( var obj in iso_objects ) {
var renderer = obj.GetComponent<SpriteRenderer>(); if ( IsIsoObjectVisible(obj) ) {
if ( renderer && renderer.isVisible ) {
var max_size = IsoUtils.Vec3Max(Vector3.one, obj.Size); var max_size = IsoUtils.Vec3Max(Vector3.one, obj.Size);
var min_npos = IsoUtils.Vec3DivFloor(obj.Position, _objsSectorSize); var min_npos = IsoUtils.Vec3DivFloor(obj.Position, _objsSectorSize);
var max_npos = IsoUtils.Vec3DivCeil(obj.Position + max_size, _objsSectorSize); var max_npos = IsoUtils.Vec3DivCeil(obj.Position + max_size, _objsSectorSize);
@@ -310,7 +330,7 @@ namespace IsoTools {
} }
void PlaceAllObjects() { void PlaceAllObjects() {
var depth = 0; var depth = MinDepth;
foreach ( var info in _objects ) { foreach ( var info in _objects ) {
depth = PlaceObject(info, depth); depth = PlaceObject(info, depth);
} }
@@ -319,16 +339,12 @@ namespace IsoTools {
_depends.Clear(); _depends.Clear();
} }
void PlaceObject(IsoObject obj, int depth) { void PlaceObject(IsoObject obj, float depth) {
//var trans = obj.gameObject.transform; var trans = obj.gameObject.transform;
//trans.position = new Vector3(trans.position.x, trans.position.y, depth); trans.position = IsoUtils.Vec3ChangeZ(trans.position, depth);
var renderer = obj.GetComponent<SpriteRenderer>();
if ( renderer ) {
renderer.sortingOrder = depth;
}
} }
int PlaceObject(ObjectInfo info, int depth) { float PlaceObject(ObjectInfo info, float depth) {
if ( info.Visited ) { if ( info.Visited ) {
return depth; return depth;
} }
@@ -339,7 +355,7 @@ namespace IsoTools {
depth = PlaceObject(obj, depth); depth = PlaceObject(obj, depth);
} }
PlaceObject(info.IsoObject, depth); PlaceObject(info.IsoObject, depth);
return depth - 1; return depth + (MaxDepth - MinDepth) / _objects.Count;
} }
void StepSort() { void StepSort() {
@@ -362,6 +378,8 @@ namespace IsoTools {
void LateUpdate() { void LateUpdate() {
if ( Application.isEditor ) { if ( Application.isEditor ) {
if ( !Mathf.Approximately(_lastTileSize, _tileSize) ) TileSize = _tileSize; if ( !Mathf.Approximately(_lastTileSize, _tileSize) ) TileSize = _tileSize;
if ( !Mathf.Approximately(_lastMinDepth, _minDepth) ) MinDepth = _minDepth;
if ( !Mathf.Approximately(_lastMaxDepth, _maxDepth) ) MaxDepth = _maxDepth;
} }
StepSort(); StepSort();
} }

View File

@@ -23,7 +23,7 @@ Global
GlobalSection(SolutionProperties) = preSolution GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE HideSolutionNode = FALSE
EndGlobalSection EndGlobalSection
GlobalSection(MonoDevelopProperties) = preSolution GlobalSection(MonoDevelopProperties) = preSolution
StartupItem = Assembly-CSharp.csproj StartupItem = Assembly-CSharp.csproj
Policies = $0 Policies = $0
$0.TextStylePolicy = $1 $0.TextStylePolicy = $1

View File

@@ -23,7 +23,7 @@ Global
GlobalSection(SolutionProperties) = preSolution GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE HideSolutionNode = FALSE
EndGlobalSection EndGlobalSection
GlobalSection(MonoDevelopProperties) = preSolution GlobalSection(MonoDevelopProperties) = preSolution
StartupItem = Assembly-CSharp.csproj StartupItem = Assembly-CSharp.csproj
Policies = $0 Policies = $0
$0.TextStylePolicy = $1 $0.TextStylePolicy = $1

View File

@@ -1,17 +1,10 @@
<Properties> <Properties>
<MonoDevelop.Ide.Workspace ActiveConfiguration="Debug" PreferredExecutionTarget="MonoDevelop.Default" /> <MonoDevelop.Ide.Workspace />
<MonoDevelop.Ide.Workbench ActiveDocument="../OtherIso4/Assets/Ultimate Isometric Toolkit/Code/IsometricTools/Other/GameSetup.cs"> <MonoDevelop.Ide.Workbench ActiveDocument="Assets/IsoTools/Scripts/IsoWorld.cs">
<Files> <Files>
<File FileName="../OtherIso4/Assets/Ultimate Isometric Toolkit/Code/IsometricTools/IsoController/SimpleIsoObjectController.cs" Line="1" Column="1" /> <File FileName="Assets/IsoTools/Scripts/IsoObject.cs" Line="242" Column="56" />
<File FileName="../OtherIso4/Assets/Ultimate Isometric Toolkit/Code/IsometricTools/Iso/Isometric.cs" Line="1" Column="1" /> <File FileName="Assets/IsoTools/Scripts/IsoWorld.cs" Line="266" Column="24" />
<File FileName="../OtherIso4/Assets/Ultimate Isometric Toolkit/Code/IsometricTools/Iso/IsoObject.cs" Line="1" Column="1" /> <File FileName="Assets/IsoTools/Editor/IsoObjectEditor.cs" Line="1" Column="1" />
<File FileName="../OtherIso4/Assets/Ultimate Isometric Toolkit/SetupAndConstraints.txt" Line="1" Column="1" />
<File FileName="../OtherIso4/Assets/Ultimate Isometric Toolkit/Code/IsometricTools/Iso/GridMap.cs" Line="1" Column="1" />
<File FileName="../OtherIso4/Assets/Ultimate Isometric Toolkit/Code/IsometricTools/Iso/IsoDirection.cs" Line="1" Column="1" />
<File FileName="../OtherIso4/Assets/Ultimate Isometric Toolkit/Code/IsometricTools/Iso/Tile.cs" Line="1" Column="1" />
<File FileName="../OtherIso4/Assets/Ultimate Isometric Toolkit/Code/IsometricTools/Other/MethodExtensionForMonoBehaviourTransform.cs" Line="1" Column="1" />
<File FileName="../OtherIso4/Assets/Ultimate Isometric Toolkit/Code/IsometricTools/Other/LevelLoader.cs" Line="1" Column="1" />
<File FileName="../OtherIso4/Assets/Ultimate Isometric Toolkit/Code/IsometricTools/Other/GameSetup.cs" Line="17" Column="42" />
</Files> </Files>
</MonoDevelop.Ide.Workbench> </MonoDevelop.Ide.Workbench>
<MonoDevelop.Ide.DebuggingService.Breakpoints> <MonoDevelop.Ide.DebuggingService.Breakpoints>