protected Buildable(BuildablePrototype b) { this.name = b.name; this.sprite = Sprite_Manager.instance.GetSprite(b.sprite); this.animatorController = Sprite_Manager.instance.GetAnimator(b.animatorController); this.buildableType = b.buildableType; this.stats = new Stat[b.stats.Length]; for (int i = 0; i < this.stats.Length; i++) { this.stats[i] = new Stat(b.stats[i].statType, b.stats[i].minValue, b.stats[i].maxValue); } }
public static Buildable CreateInstance(BuildablePrototype prototype) { return(new Buildable(prototype)); }