ShowMessage("领取师徒礼物 $Rev: 214 $")

--[[
[author]
descript="每天可领取1次"
]]--
perday_max=1
script_name="领取师徒礼物"

function _SMain(...)

	if PlayerPackage:GetEmptySlot(0) < 1 then
		ShowMessage("背包空间不足!")
		return
	end

	while true do

		MoveToNPC(139, 132, DataBase:GetSceneID("大理"), "聂政")

		QuestFrameOptionClicked( "师徒心连心" , CMP_PART_MATCH)
		
		System:Sleep(1500)

		local strType,_,_,_,szText = DataPool:GetNPCEventList_Item(0)		
		if strType == "text" then				
			if string.find(szText, "对不起") then
				ShowMessage("领取师徒礼物：已经完成！")
				System:UpdateRecord( script_name )
				break
			end
		end
	end

end

_SMain()

