Files
DP-S_Script/示例项目/副本使用道具奖励/副本使用道具奖励.nut
2026-04-16 16:27:53 +08:00

32 lines
864 B
Plaintext

function _Dps_ReturnDuplicateItems_Main_() {
local Config = GlobalConfig.Get("副本使用道具奖励.json");
//分解券
Cb_History_ItemDown_Func.DWSSSS <- function(user, date) {
local itemId = date[15].tointeger();
local PartyObj = user.GetParty();
if (date[18].tointeger()!= 3) return;
if (PartyObj) {
local Bfobj = PartyObj.GetBattleField();
local DgnObj = Bfobj.GetDgn();
if (DgnObj) {
local Dungeon_Id = DgnObj.GetId();
local FBSYDJ = Config["副本返还配置列表"];
foreach(ints in FBSYDJ) {
if (ints[0] == Dungeon_Id && itemId == ints[1]) {
user.GiveItem(ints[2].tointeger(), ints[3].tointeger());
}
}
}
}
}
}