idk L
This commit is contained in:
@@ -12,25 +12,22 @@ public class Cooking : MonoBehaviour
|
||||
void GetIngredients()
|
||||
{
|
||||
|
||||
// foreach (GameObject ingredient in currentCollisions) {
|
||||
// Debug.Log(ingredient.name);
|
||||
// }
|
||||
|
||||
return currentCollisions
|
||||
|
||||
return currentCollisions;
|
||||
}
|
||||
|
||||
void CheckDishes()
|
||||
{
|
||||
if (System.Array.IndexOf(ingrediens, "Egg")!=-1){
|
||||
print("Egg");
|
||||
}
|
||||
foreach (GameObject ingredient in currentCollisions) {
|
||||
|
||||
Debug.Log(ingredient.name);
|
||||
}
|
||||
|
||||
void Update()
|
||||
{
|
||||
GetIngredients();
|
||||
}
|
||||
|
||||
|
||||
|
||||
// Keep track of ingredients going on and off the cooker.
|
||||
List <GameObject> currentCollisions = new List <GameObject> ();
|
||||
private void OnTriggerEnter2D(Collider2D other) {
|
||||
@@ -41,4 +38,11 @@ public class Cooking : MonoBehaviour
|
||||
currentCollisions.Remove (other.gameObject);
|
||||
}
|
||||
|
||||
|
||||
void Update()
|
||||
{
|
||||
GetIngredients();
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user