private static int GetHeroCombatEft(PoolObjHandle <ActorRoot> actor) { if (actor == 0) { return(0); } int num = 0; IGameActorDataProvider actorDataProvider = Singleton <ActorDataCenter> .instance.GetActorDataProvider(GameActorDataProviderType.ServerDataProvider); ActorServerData actorData = new ActorServerData(); if (actorDataProvider.GetActorServerData(ref actor.handle.TheActorMeta, ref actorData)) { num += CHeroInfo.GetCombatEftByStarLevel((int)actorData.Level, (int)actorData.Star); num += CSkinInfo.GetCombatEft((uint)actorData.TheActorMeta.ConfigId, actorData.SkinId); ActorServerRuneData runeData = new ActorServerRuneData(); for (int i = 0; i < 30; i++) { if (actorDataProvider.GetActorServerRuneData(ref actor.handle.TheActorMeta, (ActorRunelSlot)i, ref runeData)) { ResSymbolInfo dataByKey = GameDataMgr.symbolInfoDatabin.GetDataByKey(runeData.RuneId); if (dataByKey != null) { num += dataByKey.iCombatEft; } } } } return(num); }
public void AddSymbolPageAttToProp(ref ActorMeta meta, bool bPVPLevel) { for (int i = 0; i < 37; i++) { PropertyHelper.s_symbolPropValAddArr[i] = 0; } IGameActorDataProvider actorDataProvider = Singleton <ActorDataCenter> .GetInstance().GetActorDataProvider(GameActorDataProviderType.ServerDataProvider); ActorServerRuneData actorServerRuneData = default(ActorServerRuneData); for (int j = 0; j < 30; j++) { if (actorDataProvider.GetActorServerRuneData(ref meta, (ActorRunelSlot)j, ref actorServerRuneData)) { ResSymbolInfo dataByKey = GameDataMgr.symbolInfoDatabin.GetDataByKey(actorServerRuneData.RuneId); if (dataByKey != null) { if (bPVPLevel) { for (int k = 0; k < dataByKey.astFuncEftList.Length; k++) { int wType = (int)dataByKey.astFuncEftList[k].wType; int bValType = (int)dataByKey.astFuncEftList[k].bValType; int iValue = dataByKey.astFuncEftList[k].iValue; if (wType != 0 && wType < 37 && iValue != 0) { if (bValType == 0) { PropertyHelper.s_symbolPropValAddArr[wType] += iValue; } else if (bValType == 1) { this.ChangeFuncEft(wType, bValType, iValue, true); } } } } else { for (int l = 0; l < dataByKey.astPveEftList.Length; l++) { int wType = (int)dataByKey.astPveEftList[l].wType; int bValType = (int)dataByKey.astPveEftList[l].bValType; int iValue = dataByKey.astPveEftList[l].iValue; if (wType != 0 && wType < 37 && iValue != 0) { if (bValType == 0) { PropertyHelper.s_symbolPropValAddArr[wType] += iValue; } else if (bValType == 1) { this.ChangeFuncEft(wType, bValType, iValue, true); } } } } } } } for (int m = 0; m < 37; m++) { int num = PropertyHelper.s_symbolPropValAddArr[m] / 100; if (num > 0) { this.ChangeFuncEft(m, 0, num, true); } } }
public void AddSymbolPageAttToProp(ref ActorMeta meta, bool bPVPLevel) { for (int i = 0; i < 0x24; i++) { s_symbolPropValAddArr[i] = 0; } IGameActorDataProvider actorDataProvider = Singleton <ActorDataCenter> .GetInstance().GetActorDataProvider(GameActorDataProviderType.ServerDataProvider); ActorServerRuneData runeData = new ActorServerRuneData(); int index = 0; int bValType = 0; int val = 0; for (int j = 0; j < 30; j++) { if (actorDataProvider.GetActorServerRuneData(ref meta, (ActorRunelSlot)j, ref runeData)) { ResSymbolInfo dataByKey = GameDataMgr.symbolInfoDatabin.GetDataByKey(runeData.RuneId); if (dataByKey != null) { if (bPVPLevel) { for (int m = 0; m < dataByKey.astFuncEftList.Length; m++) { index = dataByKey.astFuncEftList[m].wType; bValType = dataByKey.astFuncEftList[m].bValType; val = dataByKey.astFuncEftList[m].iValue; if (((index != 0) && (index < 0x24)) && (val != 0)) { switch (bValType) { case 0: s_symbolPropValAddArr[index] += val; break; case 1: this.ChangeFuncEft((RES_FUNCEFT_TYPE)index, (RES_VALUE_TYPE)bValType, val, true); break; } } } } else { for (int n = 0; n < dataByKey.astPveEftList.Length; n++) { index = dataByKey.astPveEftList[n].wType; bValType = dataByKey.astPveEftList[n].bValType; val = dataByKey.astPveEftList[n].iValue; if (((index != 0) && (index < 0x24)) && (val != 0)) { switch (bValType) { case 0: s_symbolPropValAddArr[index] += val; break; case 1: this.ChangeFuncEft((RES_FUNCEFT_TYPE)index, (RES_VALUE_TYPE)bValType, val, true); break; } } } } } } } for (int k = 0; k < 0x24; k++) { int num9 = s_symbolPropValAddArr[k] / 100; if (num9 > 0) { this.ChangeFuncEft((RES_FUNCEFT_TYPE)k, RES_VALUE_TYPE.TYPE_VALUE, num9, true); } } }