Compare commits
No commits in common. "debe9b21841220a822800180fdf377265325a746" and "221015e57515a81b0678e721884b3dc288a974e6" have entirely different histories.
debe9b2184
...
221015e575
File diff suppressed because it is too large
Load Diff
|
@ -1,31 +0,0 @@
|
||||||
using System.Collections;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using UnityEngine;
|
|
||||||
|
|
||||||
public class SlotPathDeleter : MonoBehaviour
|
|
||||||
{
|
|
||||||
[SerializeField] private GridManager TargetCarveGrid;
|
|
||||||
|
|
||||||
private void Start()
|
|
||||||
{
|
|
||||||
Invoke(nameof(LateStart), 0.1f);
|
|
||||||
}
|
|
||||||
|
|
||||||
private void LateStart()
|
|
||||||
{
|
|
||||||
MeshCollider[] targets = TargetCarveGrid.SpawnedSlots.Select(x=>x.GetComponentInChildren<MeshCollider>()).ToArray();
|
|
||||||
|
|
||||||
BoxCollider[] colliders = GetComponentsInChildren<BoxCollider>();
|
|
||||||
for (int i = 0; i < colliders.Length; i++)
|
|
||||||
{
|
|
||||||
for (int j = 0; j < targets.Length; j++)
|
|
||||||
{
|
|
||||||
if (colliders[i].bounds.Intersects(targets[j].bounds))
|
|
||||||
{
|
|
||||||
Destroy(targets[j].gameObject);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -1,11 +0,0 @@
|
||||||
fileFormatVersion: 2
|
|
||||||
guid: 37a80941383726449a76228f163f0a26
|
|
||||||
MonoImporter:
|
|
||||||
externalObjects: {}
|
|
||||||
serializedVersion: 2
|
|
||||||
defaultReferences: []
|
|
||||||
executionOrder: 0
|
|
||||||
icon: {instanceID: 0}
|
|
||||||
userData:
|
|
||||||
assetBundleName:
|
|
||||||
assetBundleVariant:
|
|
Loading…
Reference in New Issue