Beispiel #1
0
        public void ShowExpBar(Entity entity, float fromHPRatio, float toHPRatio)
        {
            if (entity == null)
            {
                Log.Warning("Entity is invalid.");
                return;
            }

            ExpBarItem expBarItem = GetActiveExpBarItem(entity);

            if (expBarItem == null)
            {
                expBarItem = CreateExpBarItem(entity);
                m_ActiveExpBarItems.Add(expBarItem);
            }

            expBarItem.Init(entity, m_CachedCanvas, fromHPRatio, toHPRatio);
        }