Пример #1
0
    // Token: 0x06000E01 RID: 3585 RVA: 0x00060730 File Offset: 0x0005E930
    protected void DrawPrice(Rect rect, ItemPrice points, ItemPrice credits)
    {
        float num = 0f;

        if (points != null)
        {
            string text = string.Format("{0}", (points.Price != 0) ? points.Price.ToString("N0") : "FREE");
            GUI.DrawTexture(new Rect(rect.x, rect.y, 16f, 16f), ShopUtils.CurrencyIcon(points.Currency));
            GUI.Label(new Rect(rect.x + 20f, rect.y + 3f, rect.width - 20f, 16f), text, BlueStonez.label_interparkmed_11pt_left);
            num += 40f + BlueStonez.label_interparkmed_11pt_left.CalcSize(new GUIContent(text)).x;
        }
        if (credits != null)
        {
            string text2 = string.Format("{0}", (credits.Price != 0) ? credits.Price.ToString("N0") : "FREE");
            if (num > 0f)
            {
                GUI.Label(new Rect(rect.x + num - 10f, rect.y + 3f, 10f, 16f), "/", BlueStonez.label_interparkmed_11pt_left);
            }
            GUI.DrawTexture(new Rect(rect.x + num, rect.y, 16f, 16f), ShopUtils.CurrencyIcon(credits.Currency));
            GUI.Label(new Rect(rect.x + num + 20f, rect.y + 3f, rect.width - 20f, 16f), text2, BlueStonez.label_interparkmed_11pt_left);
        }
    }