InstantiateCommand.cs 315 B

123456789101112131415
  1. using Blue;
  2. using UnityEngine;
  3. public class InstantiateCommand : ICommand
  4. {
  5. private GameObject prefab;
  6. public InstantiateCommand(GameObject prefab)
  7. {
  8. this.prefab = prefab;
  9. }
  10. public void OnExcute()
  11. {
  12. InstantiateSystem.Instance.InstantiatePrefab(prefab);
  13. }
  14. }