Kitchen object creation and spawning
This commit is contained in:
parent
989648c00b
commit
1729ddf5c6
22 changed files with 462 additions and 3 deletions
|
@ -3,9 +3,18 @@ using UnityEngine;
|
|||
public class ClearCounter : MonoBehaviour
|
||||
{
|
||||
|
||||
[SerializeField] private KitchenObjectSO kitchenObjectSO;
|
||||
[SerializeField] private Transform counterTopPoint;
|
||||
|
||||
public void Interact()
|
||||
{
|
||||
Debug.Log("Interacted!");
|
||||
|
||||
Transform kitchenObjectTransform = Instantiate(kitchenObjectSO.prefab, counterTopPoint);
|
||||
|
||||
kitchenObjectTransform.localPosition = Vector3.zero;
|
||||
|
||||
Debug.Log(kitchenObjectTransform.GetComponent<KitchenObject>().GetKitchenObjectSO().objectName);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Reference in a new issue