Added some first floor balancing to obstacle course

This commit is contained in:
Gregory Campbell
2020-02-11 21:45:18 -05:00
parent 092ce96d3a
commit eb85a88643
2 changed files with 57 additions and 45 deletions
+3 -6
View File
@@ -2964,16 +2964,13 @@ MonoBehaviour:
- {fileID: 8014827120313548368, guid: 20d028e2f45dd134fbaf292705530768, type: 3}
- {fileID: 1236683392463883085, guid: b49833699123fc74886c706b80b7cbfe, type: 3}
- {fileID: 2905477253455755942, guid: cc2991a7dd7e57d4b89e9b7cc0d29440, type: 3}
- {fileID: 2709827901078906258, guid: ff7c3b7d52b8de54e9917c40c82aecc4, type: 3}
- {fileID: 7191534383892929012, guid: 6de824c9a7c7a334284769001bca9c75, type: 3}
- {fileID: 986717874393107686, guid: da5fd426b6efd1842a8e9be671efb9a0, type: 3}
- {fileID: 98210784416435151, guid: 22057d85c3bbde94ab02b5b32393a624, type: 3}
- {fileID: 7886215492682801492, guid: 6b8db22eae7d69c41b7922d792a06409, type: 3}
- {fileID: 5799837134442839398, guid: 4b6e429c70b7144418db287eb6f6c1a7, type: 3}
- {fileID: 4589213692722742485, guid: f2127aac0c5addb4ab388991a33e8299, type: 3}
- {fileID: 2729766386463878366, guid: 258ef028e1596b043b63e318da3964f2, type: 3}
- {fileID: 3425233021637308467, guid: 9cfafec4161cf3c4f86a3824513846ac, type: 3}
- {fileID: 2988591104085892534, guid: 03140737509422d4d8bb02e8666c8d00, type: 3}
- {fileID: 98210784416435151, guid: 22057d85c3bbde94ab02b5b32393a624, type: 3}
- {fileID: 7886215492682801492, guid: 6b8db22eae7d69c41b7922d792a06409, type: 3}
- {fileID: 5799837134442839398, guid: 4b6e429c70b7144418db287eb6f6c1a7, type: 3}
--- !u!4 &1677821150
Transform:
m_ObjectHideFlags: 0
+15
View File
@@ -245,6 +245,11 @@ public class FloorLevel : MonoBehaviour
}
}
if(escalation == 1)
{
selection = Random.Range(0, easyObstacleList.Length);
Instantiate(cornerList[selection], new Vector3(100*i+50, Random.Range(-5, 0), -100*j-50), Quaternion.Euler(0, (45*Random.Range(0,8)), 0));
} else {
if(Random.Range(0, 10) != 0)
{
@@ -267,8 +272,17 @@ public class FloorLevel : MonoBehaviour
Instantiate(obstacleList[selection], new Vector3(100*i+50, Random.Range(-5, 0), -100*j-50), Quaternion.Euler(0, (45*Random.Range(0,8)), 0));
break;
}
}
}
if(escalation == 1)
{
selection = Random.Range(0, easyObstacleList.Length);
Instantiate(cornerList[selection], new Vector3(-100*i-50, Random.Range(-5, 0), 100*j+50), Quaternion.Euler(0, (45*Random.Range(0,8)), 0));
} else {
if(Random.Range(0, 10) != 0)
{
@@ -292,6 +306,7 @@ public class FloorLevel : MonoBehaviour
break;
}
}
}
if(i == escalation-1)
{