public ExploreCat addCat(Cat cat, int i, GameObject catPrefab, Vector2 offset, Vector2 pos, Vector3 rot, float scale, HealthBar hb) { GameObject catGameObject = Instantiate(catPrefab); ExploreCat exploreCat = catGameObject.AddComponent <ExploreCat>(); exploreCat.transform.position = pos; exploreCat.transform.position += new Vector3(offset.x, offset.y, 0); exploreCat.transform.eulerAngles = rot; exploreCat.transform.localScale = new Vector3(scale, scale, scale); exploreCat.init(cat, this, i, hb); return(exploreCat); }