added new models
This commit is contained in:
@@ -4,15 +4,15 @@ using UnityEngine;
|
||||
public class ColaFreezer : BaseInteractableObject
|
||||
{
|
||||
[SerializeField]
|
||||
private FoodObjectSO _foodObjectSO;
|
||||
private SellableItemSO _sellableItemSO;
|
||||
|
||||
public override void Interact(Player player)
|
||||
{
|
||||
if (!player.HasFoodObject())
|
||||
{
|
||||
player.BuyObject(_foodObjectSO);
|
||||
//player.BuyObject(_sellableItemSO);
|
||||
// Spawn new object and set to player
|
||||
var transform = Instantiate(_foodObjectSO.prefab, _playerArrivePoint);
|
||||
var transform = Instantiate(_sellableItemSO.prefab, _playerArrivePoint);
|
||||
var foodObject = transform.GetComponent<FoodObject>();
|
||||
player.SetFoodObject(foodObject);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user