Esempio n. 1
0
        static StackObject *GetMaxTurnStr_0(ILIntepreter __intp, StackObject *__esp, IList <object> __mStack, CLRMethod __method, bool isNewObj)
        {
            ILRuntime.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
            StackObject *ptr_of_this_method;
            StackObject *__ret = ILIntepreter.Minus(__esp, 1);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
            Hotfix_LT.Combat.CombatCharacterSyncData.BuffData instance_of_this_method = (Hotfix_LT.Combat.CombatCharacterSyncData.BuffData) typeof(Hotfix_LT.Combat.CombatCharacterSyncData.BuffData).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
            __intp.Free(ptr_of_this_method);

            var result_of_this_method = instance_of_this_method.GetMaxTurnStr();

            return(ILIntepreter.PushObject(__ret, __mStack, result_of_this_method));
        }
Esempio n. 2
0
        private void UpdateBuffIcon()
        {
            int IconPerPage        = BuffIconItems.Length;
            int buffStartDataIndex = mBuffAlternate ? IconPerPage : 0;

            //for (int i = 0; i < 4; ++i)
            for (var i = 0; i < BuffIconItems.Length; i++)
            {
                BuffIconItems[i].RootNode.CustomSetActive(false);
            }
            int index     = 0;
            int buffcount = 0;

            foreach (var data in mBuffDatas)
            {
                Hotfix_LT.Combat.CombatCharacterSyncData.BuffData buffData = data;
                Hotfix_LT.Data.BuffTemplate templateData = Hotfix_LT.Data.BuffTemplateManager.Instance.GetTemplate(buffData.Id);
                if (!templateData.Invisible)
                {
                    index++;
                }

                if (!templateData.Invisible && index > buffStartDataIndex)
                {
                    string buffIcon = templateData.Buff;
                    if (string.IsNullOrEmpty(templateData.Buff))
                    {
                        EB.Debug.LogError("buff icon is null for buffid:{0}", templateData.ID);
                    }

                    BuffIconItems[buffcount].RootNode.gameObject.name = buffData.Id.ToString();
                    BuffIconItems[buffcount].IconSprite.spriteName    = buffIcon;
                    BuffIconItems[buffcount].LeftTurnLabel.text       = buffData.GetMaxTurnStr();
                    BuffIconItems[buffcount].OverlyingLabel.text      = buffData.GetOverlying(templateData.StackNum);
                    BuffIconItems[buffcount].RootNode.CustomSetActive(true);
                    buffcount++;

                    if (buffcount >= BuffIconItems.Length)
                    {
                        return;
                    }
                }
            }
        }