Esempio n. 1
0
    // Use this for initialization
    public void BuildBody(UnitData unitData)
    {
        GameObject go = (GameObject)Instantiate(bodyPrefab, transform);

        GetComponent <CharacterMovement>().SetBody(go);
        BuildUnit.Build(go, unitData);
        Destroy(this);
    }
Esempio n. 2
0
 //This is a temoprary class for building sprites, the build should be called from the units main script
 void Awake()
 {
     BuildUnit.Build(this.gameObject, uD);
 }