Ejemplo n.º 1
0
    public void Init(int shipsCount)
    {
        Discriptions.text = GetRandomDiscriptions();
        _types            = FindObjectOfType <WarshipTypes>();
        _infoUI           = FindObjectOfType <MissionInfoRender>(true);
        Button b = GetComponent <Button>();

        b.onClick.AddListener(() => { _infoUI.Show(() => { StartMission(); }, _metalResourses, _yellowGemResourses, _blueGemResourses, _greenGemResourses, _yellowType, _blueType, _greenType); });
        RandomiseEnemySquad(shipsCount);
        RandomiseMissionResourse(shipsCount);
    }
Ejemplo n.º 2
0
 private void Start()
 {
     _types = GameObject.FindGameObjectWithTag("WarshipTypes").GetComponent <WarshipTypes>();
     RenderShip(null, 0);
 }