22 lines
852 B
Plaintext
22 lines
852 B
Plaintext
|
|
function _Dps_SetEquinherit_Main_() {
|
|
Cb_ModItemattr_Leave_Func.addinfoMax <- function(args) {
|
|
local Config = GlobalConfig.Get("黄金品级调整箱_Lenheart.json");
|
|
local SUser = User(args[1]);
|
|
local pack = NativePointer(args[2]);
|
|
local a = NativePointer(pack.add(20).readPointer());
|
|
local itemSold = a.add(13).add(6).readShort();
|
|
local equSold = a.add(13).add(0).readShort();
|
|
local InvenObj = SUser.GetInven();
|
|
if (InvenObj) {
|
|
local ItemObj = InvenObj.GetSlot(1, itemSold);
|
|
local equObj = InvenObj.GetSlot(1, equSold);
|
|
|
|
if (ItemObj.GetIndex() == Config["黄金品级调整箱id"]) {
|
|
equObj.SetAdd_Info(999999998);
|
|
equObj.Flush();
|
|
SUser.SendUpdateItemList(1, 0, equSold);
|
|
}
|
|
}
|
|
}
|
|
} |