Merge branch 'main' of https://git.steelants.cz/GJP/GGJ2022
This commit is contained in:
commit
bf49ea332b
179
Assets/Prefabs/Platforms/chunk_loop Variant.prefab
Normal file
179
Assets/Prefabs/Platforms/chunk_loop Variant.prefab
Normal file
@ -0,0 +1,179 @@
|
||||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!1001 &5655692384574475916
|
||||
PrefabInstance:
|
||||
m_ObjectHideFlags: 0
|
||||
serializedVersion: 2
|
||||
m_Modification:
|
||||
m_TransformParent: {fileID: 0}
|
||||
m_Modifications:
|
||||
- target: {fileID: 227903404414380179, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_Name
|
||||
value: chunk_loop
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 717028255710887108, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_Materials.Array.data[0]
|
||||
value:
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 1581099807273813101, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: color.a
|
||||
value: 0.8663576
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 1581099807273813101, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: emissionUp
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 2319157629489888751, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: color.a
|
||||
value: 0.8663576
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 2319157629489888751, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: emissionUp
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3438793468450317897, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: color.a
|
||||
value: 0.8663576
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3438793468450317897, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: emissionUp
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3441825231734693490, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_RootOrder
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3441825231734693490, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_LocalPosition.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3441825231734693490, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_LocalPosition.y
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3441825231734693490, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_LocalPosition.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3441825231734693490, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_LocalRotation.w
|
||||
value: 1
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3441825231734693490, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_LocalRotation.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3441825231734693490, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_LocalRotation.y
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3441825231734693490, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_LocalRotation.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3441825231734693490, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_LocalEulerAnglesHint.x
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3441825231734693490, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_LocalEulerAnglesHint.y
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 3441825231734693490, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_LocalEulerAnglesHint.z
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 4046279780535153479, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: color.a
|
||||
value: 0.8663576
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 4046279780535153479, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: emissionUp
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 5191330650780006077, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_Materials.Array.data[0]
|
||||
value:
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 5246183545790649614, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: color.a
|
||||
value: 0.8663576
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 5246183545790649614, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: emissionUp
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 5560813059931370072, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_Materials.Array.data[0]
|
||||
value:
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 5583649251154797518, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: color.a
|
||||
value: 0.8663576
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 5583649251154797518, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: emissionUp
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 6276350747539873226, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_Materials.Array.data[0]
|
||||
value:
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 6933565818185019858, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_Materials.Array.data[0]
|
||||
value:
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7025949950676294748, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_Materials.Array.data[0]
|
||||
value:
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7184203947689591411, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_Materials.Array.data[0]
|
||||
value:
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7901524657762734192, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: color.a
|
||||
value: 0.8663576
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 7901524657762734192, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: emissionUp
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 8557637333134395230, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: color.a
|
||||
value: 0.8663576
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 8557637333134395230, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: emissionUp
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 8792983175967883553, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_Materials.Array.data[0]
|
||||
value:
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 8861260383688057481, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: color.a
|
||||
value: 0.8663576
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 8861260383688057481, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: emissionUp
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 9032494463022098444, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_Materials.Array.data[0]
|
||||
value:
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 9039345283432774328, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: color.a
|
||||
value: 0.8663576
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 9039345283432774328, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: emissionUp
|
||||
value: 0
|
||||
objectReference: {fileID: 0}
|
||||
- target: {fileID: 9177498565491931535, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
||||
propertyPath: m_Materials.Array.data[0]
|
||||
value:
|
||||
objectReference: {fileID: 0}
|
||||
m_RemovedComponents: []
|
||||
m_SourcePrefab: {fileID: 100100000, guid: fe24996af0c9aa44cb6ea0408cbfb1c5, type: 3}
|
7
Assets/Prefabs/Platforms/chunk_loop Variant.prefab.meta
Normal file
7
Assets/Prefabs/Platforms/chunk_loop Variant.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 0b012cacc00335a42b77f11e349d334e
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -58,6 +58,7 @@ public class ProceduralGeneration : MonoBehaviour
|
||||
}
|
||||
GameObject drawPlatform(GameObject lastObject, GameObject objToSpawn, GameObject parentLevelObject)
|
||||
{
|
||||
|
||||
Bounds bounds = this.getPrefabBounds(lastObject);
|
||||
Bounds b = this.getPrefabBounds(objToSpawn);
|
||||
Vector3 nextBlockLocation = new Vector3(lastObject.transform.position.x, lastObject.transform.position.y, lastObject.transform.position.z + bounds.extents.z + b.extents.z);
|
||||
@ -177,6 +178,11 @@ public class ProceduralGeneration : MonoBehaviour
|
||||
|
||||
if (blockToSpawn > -1 && (blockToSpawn < levelBlocks.Count))
|
||||
{
|
||||
if (this.spawnedLevelBlocks.Count == 3)
|
||||
{
|
||||
blockToSpawn = 10;
|
||||
}
|
||||
|
||||
blockObjToSpawn = levelBlocks[blockToSpawn];
|
||||
instantiatedGameObject = this.drawPlatform(this.lastBlock, this.levelBlocks[blockToSpawn], this.levelParrent);
|
||||
this.spawnedLevelBlocks.Add(instantiatedGameObject);
|
||||
|
Loading…
Reference in New Issue
Block a user