﻿using App.SpaceInvaders.Components;
using CodeCafeEngine;

namespace App.SpaceInvaders.GameObjects
{
    class InvaderObject
    {
        /// <summary>
        /// Get the invader game object.
        /// </summary>
        /// <returns></returns>
        public static GameObject GetGameObject(Vec2 position, int invaderType)
        {
            GameObject gameObject = new GameObject("Invader_" + invaderType);
            gameObject.AddComponent(new InvaderController { StartPosition = position, InvaderType = invaderType });
            return gameObject;
        }
    }
}
