コーンマネージャ追加
This commit is contained in:
parent
3868a71d79
commit
8c1b82287a
|
|
@ -0,0 +1,20 @@
|
|||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
namespace MyGame.Scenes.Main
|
||||
{
|
||||
public class CornManager : MonoBehaviour
|
||||
{
|
||||
[SerializeField] private Transform cornSpawnTarget;
|
||||
[SerializeField] private Corn cornPrefab;
|
||||
[SerializeField] private int cornSpawnCount = 20;
|
||||
|
||||
private void Start()
|
||||
{
|
||||
for (int i = 0; i < cornSpawnCount; i++)
|
||||
{
|
||||
Instantiate(cornPrefab, cornSpawnTarget);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
fileFormatVersion: 2
|
||||
guid: f16b861cdcc84ae9a3bf105ff59a1f49
|
||||
timeCreated: 1625130512
|
||||
Loading…
Reference in New Issue