Beispiel #1
0
        public static T Instantiate <T>(int x, int y, SpawnsManager.SpawnData data = null) where T : GameObject, new()
        {
            T g = new T();

            GameObjectsManager.AddObject(g);
            g.SetPosition(x, y);
            if (data != null)
            {
                g.SetData(data);
            }

            g.Init();
            return(g);
        }
Beispiel #2
0
 private void SetData(SpawnsManager.SpawnData data)
 {
 }