Weles 8 Posted December 26, 2017 Share Posted December 26, 2017 /// UserInterface -> Packet.h /// Search: SE_EQUIP_RAMADAN_RING, Add below: SE_EQUIP_WELES_RING1, /// UserInterface -> InstanceBase.h /// Search: EFFECT_RAMADAN_RING_EQUIP, Add below: EFFECT_WELES_RING1_EQUIP, /// UserInterface -> PythonCharacterManagerModule.cpp /// Search: PyModule_AddIntConstant(poModule, "EFFECT_RAMADAN_RING_EQUIP", CInstanceBase::EFFECT_RAMADAN_RING_EQUIP); Add below: PyModule_AddIntConstant(poModule, "EFFECT_WELES_RING1_EQUIP", CInstanceBase::EFFECT_WELES_RING1_EQUIP); /// UserInterface -> PythonNetworkStreamPhaseGameItem.cpp /// Search: case SE_EQUIP_RAMADAN_RING: effect = CInstanceBase::EFFECT_RAMADAN_RING_EQUIP; break; Add below: case SE_EQUIP_WELES_RING1: effect = CInstanceBase::EFFECT_WELES_RING1_EQUIP; break; /// game/src -> char_item.cpp /// Search: if (true == CItemVnumHelper::IsRamadanMoonRing(dwVnum)) { this->EffectPacket(SE_EQUIP_RAMADAN_RING); } Add below: else if (true == CItemVnumHelper::IsWELESRing1(dwVnum)) { this->EffectPacket(SE_EQUIP_WELES_RING1); } /// game/src -> item.cpp /// Search: if (true == CItemVnumHelper::IsRamadanMoonRing(GetVnum()) || true == CItemVnumHelper::IsHalloweenCandy(GetVnum()) || true == CItemVnumHelper::IsHappinessRing(GetVnum()) || true == CItemVnumHelper::IsLovePendant(GetVnum())) Add to the function: || true == CItemVnumHelper::IsWELESRing1(GetVnum()) Example: if (true == CItemVnumHelper::IsRamadanMoonRing(GetVnum()) || true == CItemVnumHelper::IsHalloweenCandy(GetVnum()) || true == CItemVnumHelper::IsHappinessRing(GetVnum()) || true == CItemVnumHelper::IsLovePendant(GetVnum()) || true == CItemVnumHelper::IsWELESRing1(GetVnum())) /// common -> leght.h /// Search: SE_EQUIP_RAMADAN_RING, Add below: SE_EQUIP_WELES_RING1, /// common -> VnumHelper.h /// Search: static const bool IsRamadanMoonRing(DWORD vnum) { return 71135 == vnum; } Add below: static const bool IsWELESRing1(DWORD vnum) { return YOUR_ID == vnum; } /// root -> playersettingsmodule.py /// Search: chrmgr.RegisterCacheEffect(chrmgr.EFFECT_RAMADAN_RING_EQUIP, "", "d:/ymir work/effect/etc/buff/buff_item1.mse") Add below: chrmgr.RegisterCacheEffect(chrmgr.EFFECT_WELES_RING1_EQUIP, "", "d:/ymir work/effect/etc/buff/your_effect.mse") /// item_proto /// Type: 16 Subtype: 0 WearFlags: 128 2 Link to comment Share on other sites More sharing options...
amosth 9 Posted July 1, 2018 Share Posted July 1, 2018 How do I add multiple items and different effects? Link to comment Share on other sites More sharing options...
Weles 8 Posted July 1, 2018 Author Share Posted July 1, 2018 @amosth Hey you need to do the tutorial again just changing the name, e.g. "IsWELESRing1" to "IsWELESRing2" Link to comment Share on other sites More sharing options...
amosth 9 Posted July 1, 2018 Share Posted July 1, 2018 3 hours ago, Weles said: @amosth Hey you need to do the tutorial again just changing the name, e.g. "IsWELESRing1" to "IsWELESRing2" item_proto and the calculation of wearflag to IsWELESRing2? Link to comment Share on other sites More sharing options...
Weles 8 Posted July 1, 2018 Author Share Posted July 1, 2018 No no, item proto any id and wearflag always this same (128) 1 Link to comment Share on other sites More sharing options...
amosth 9 Posted July 1, 2018 Share Posted July 1, 2018 1 minute ago, Weles said: No no, item proto any id and wearflag always this same (128) thanks man Link to comment Share on other sites More sharing options...
Weles 8 Posted July 1, 2018 Author Share Posted July 1, 2018 No problem Link to comment Share on other sites More sharing options...
Sevenfoldia 29 Posted May 13, 2022 Share Posted May 13, 2022 Thanks, very usefull. With this tutorial I figured out how to implement effects for various effects for potions. Link to comment Share on other sites More sharing options...
minigutza 54 Posted January 29, 2023 Share Posted January 29, 2023 Where i can set the bonuses tho? Cuz in item_proto they are not specified, even in your tutorial is not specified. How do i set what i want to get from those items? Thanks. Link to comment Share on other sites More sharing options...
Recommended Posts