//------------------------------------------------------------------------- public override object excute(EffectMgr effect_mgr, EffectContext effect_context, string[] predefine_param, string[] effect_param) { Item item = effect_context.item; Entity et = effect_context.EtActor; return(null); }
//--------------------------------------------------------------------- public override void defAllProp(Dictionary <string, string> map_param) { EffectMgr = new EffectMgr(); mPropIsBot = defProp <bool>(map_param, "IsBot", false); mPropAccountId = defProp <string>(map_param, "AccountId", ""); mPropAccountName = defProp <string>(map_param, "AccountName", ""); mPropActorId = defProp <ulong>(map_param, "ActorId", 0); mPropNickName = defProp <string>(map_param, "NickName", ""); mPropIcon = defProp <string>(map_param, "Icon", ""); mPropIpAddress = defProp <string>(map_param, "IpAddress", ""); mPropGender = defProp <bool>(map_param, "Gender", false); mPropIndividualSignature = defProp <string>(map_param, "IndividualSignature", "这家伙很懒,什么也没留下!"); mPropLevel = defProp <int>(map_param, "Level", 1); mPropExperience = defProp <int>(map_param, "Experience", 0); PropGold = defProp <int>(map_param, "Gold", 100); mPropProfileSkinTableId = defProp <int>(map_param, "ProfileSkinTableId", 1); mPropIsVIP = defProp <bool>(map_param, "IsVIP", false); mPropVIPDataTime = defProp <DateTime>(map_param, "VIPDataTime", DateTime.Now); mPropVIPPoint = defProp <int>(map_param, "VIPPoint", 0); mPropGameTotal = defProp <int>(map_param, "GameTotal", 0); mPropGameWin = defProp <int>(map_param, "GameWin", 0); mPropJoinDateTime = defProp <DateTime>(map_param, "JoinDataTime", DateTime.Now); mPropLastOnlineDateTime = defProp <DateTime>(map_param, "LastOnlineDateTime", DateTime.Now); mPropIsAFK = defProp <bool>(map_param, "IsAFK", false); }
//------------------------------------------------------------------------- public override object excute(EffectMgr effect_mgr, EffectContext effect_context, string[] predefine_param, string[] effect_param) { //EbLog.Note("EffectCreateStatus.excute()"); Item item = effect_context.item; Entity et = effect_context.EtActor; // 创建Status var co_status = et.getComponent <CellStatus <DefStatus> >(); co_status.createStatus(item); return(null); }
//------------------------------------------------------------------------- public override object excute(EffectMgr effect_mgr, EffectContext effect_context, string[] predefine_param, string[] effect_param) { //EbLog.Note("EffectTakeoffEquip.excute()"); Item item = effect_context.item; Entity et = effect_context.EtActor; // 从装备背包中移除 var co_equip = et.getComponent <CellEquip <DefEquip> >(); item = co_equip.takeoffEquip((Ps.EquipSlot)item.TbDataItem.ItemTypeId); return(null); }
//------------------------------------------------------------------------- public override object excute(EffectMgr effect_mgr, EffectContext effect_context, string[] predefine_param, string[] effect_param) { //EbLog.Note("EffectTakeonEquip.excute()"); Item item = effect_context.item; Entity et = effect_context.EtActor; // 添加到装备背包 var co_equip = et.getComponent <CellEquip <DefEquip> >(); co_equip.takeonEquip(item); return(null); }
//------------------------------------------------------------------------- public override void init() { EffectMgr = new EffectMgr(); LastLevel = Def.mPropLevel.get(); Def.mPropExperience.OnChanged = _onPropExperienceChanged; Def.mPropLevel.OnChanged = _onPropLevelChanged; Def.mPropIsAFK.OnChanged = _onPropIsAFKChanged; Def.PropGold.OnChanged = _onPropGoldChanged; Def.mPropIpAddress.OnChanged = _onPropIpAddressChanged; Def.mPropNickName.OnChanged = _onPropNickNameChanged; Def.mPropIndividualSignature.OnChanged = _onPropIndividualSignatureChanged; _showExperience(); }
//------------------------------------------------------------------------- public override object excute(EffectMgr effect_mgr, EffectContext effect_context, string[] predefine_param, string[] effect_param) { Item item = effect_context.item; Entity et = effect_context.EtActor; UnitConsumables unit_consumable = (UnitConsumables)item.UnitLink; foreach (var i in unit_consumable.TbDataUnitConsumables.ListEffect) { TbDataEffect data_effect = EbDataMgr.Instance.getData <TbDataEffect>(i.EffectId); effect_mgr.doEffect(effect_context, data_effect.ScriptName, data_effect.PredefineParamList, i.ListParam); } item.ItemData.n -= (byte)item.TbDataItem.MainOperateInfo.SubOverlapNum; return(null); }
//------------------------------------------------------------------------- public abstract object excute(EffectMgr effect_mgr, EffectContext effect_context, string[] predefine_param, string[] effect_param);