Beispiel #1
0
    void UpdatePrice()
    {
        m_currentPrice = Mathf.RoundToInt(m_price * (1 + ObjectsList.GetItemCount() * (m_priceObjectMultiplier - 1)));

        var price     = m_tooltip.transform.Find("popup sprite_01/Price");
        var priceBack = m_tooltip.transform.Find("popup sprite_01/PriceBack");

        price.GetComponent <TextMesh>().text     = m_currentPrice.ToString();
        priceBack.GetComponent <TextMesh>().text = m_currentPrice.ToString();
    }