25 lines
452 B
C#
25 lines
452 B
C#
using UnityEngine;
|
|
|
|
public class ScrewsManager : MonoBehaviour
|
|
{
|
|
public Module module;
|
|
|
|
public void CheckAllScrews()
|
|
{
|
|
bool allDropped = true;
|
|
foreach (Transform screw in transform)
|
|
{
|
|
if (screw.gameObject.activeSelf)
|
|
{
|
|
allDropped = false;
|
|
break;
|
|
}
|
|
}
|
|
|
|
if (allDropped)
|
|
{
|
|
module.EnableDragging();
|
|
}
|
|
}
|
|
}
|