PDA

View Full Version : [TLBB] xin scrip đổi exp thành điểm tặng ( knb )



saodzi
10-03-19, 08:48 PM
bạn nào có scrip đổi exp thành điểm tặng ( knb ) thì cho mình xin với.

binhbet
13-03-19, 08:27 PM
bạn nào có scrip đổi exp thành điểm tặng ( knb ) thì cho mình xin với.

của bác đây

-- 领奖NPC


x000181_g_scriptId = 000181


x000181_g_PrimaryAward = 1
x000181_g_Award2 = 2
x000181_g_Award3 = 3


x000181_g_Intro = 4


x000181_g_NewCard1 = 5
x000181_g_NewCard2 = 6
x000181_g_NewCard3 = 7
x000181_g_NewCard4 = 10
x000181_g_NewCard5 = 11
x000181_g_NewCard6 = 12
x000181_g_NewCard7 = 13
x000181_g_NewCard8 = 14


x000181_g_NewCardIntro = 9
x000181_g_VirtualNew = 30505080




--**********************************
--事件交互入口
--**********************************
function x000181_OnDefaultEvent( sceneId, selfId, targetId )
BeginEvent( sceneId )
AddText( sceneId, "#Y#bC醕 h?t緄 疴y 瓞 鸨i v鄋g l Kim Nguy阯 B鋙 瘊ng kh鬾g?" )
AddText( sceneId, "#YC醕 h?懈nh 鸨i l bao nhi陁?" )
-- local nam = LuaFnGetName( sceneId, selfId )
-- if nam == "V鬝ong.00" then
-- AddNumText( sceneId, x000181_g_scriptId, "Mua Hoa Mai Kh鬷(1500蠱P)", 2, 1005 )
-- end

AddNumText( sceneId, x000181_g_scriptId, "T読 h?鸨i 5 v鄋g l 50 KNB", 2, 990 )
-- AddNumText( sceneId, x000181_g_scriptId, "T読 h?鸨i 10 v鄋g l 100 KNB", 2, 992 )
AddNumText( sceneId, x000181_g_scriptId, "T読 h?鸨i 50 v鄋g l 500 KNB", 2, 994 )
AddNumText( sceneId, x000181_g_scriptId, "T読 h?鸨i 100 v鄋g l 1000 KNB", 2, 996 )
AddNumText( sceneId, x000181_g_scriptId, "T読 h?鸨i 1000 v鄋g l 10000 KNB", 2, 998 )
AddNumText( sceneId, x000181_g_scriptId, "C Gi?V鄋g", 5, 10 )
-- AddNumText( sceneId, x000181_g_scriptId, "Gi緄 thi畊 h?th痭g khuy猲 m鉯", 11, x000181_g_Intro )
-- AddNumText( sceneId, x000181_g_scriptId, "Gi緄 thi畊 v?h?th痭g th?t鄆 ph?, 11, x000181_g_NewCardIntro )
EndEvent( sceneId )
DispatchEventList( sceneId, selfId, targetId )
end


--**********************************
--事件列表选中一项
--**********************************
function x000181_OnEventRequest( sceneId, selfId, targetId, eventId )


if GetNumText() == 10 then
BeginEvent( sceneId )
AddText( sceneId, "Kh鬾g n阯 瓞 ti玭 v鄋g qu?nhi玼 tr阯 tay n鋓 v?ng鈔 kh? C醕 H?h銀 nghe l秈 ta c v鄋g v鄌 r呓ng s?kh鬾g bao gi?m 疬.#r#Y L遳 ?#W Tay n鋓 ph鋓 c騨 韙 nh#Y 3#W ?tr痭g. N猽 M GM kh鬾g ch竨 tr醕h nhi甿!" )
AddText( sceneId, " - Ph?qu鈔 l?h誴 s?c 疬#Y 2000 v鄋g" )
AddText( sceneId, " - Th s醫 l?h誴 s?c 疬#Y 8000 v鄋g" )
AddText( sceneId, " - Tham lang l?h誴 s?c 疬#Y 20000 v鄋g" )
AddNumText( sceneId, x000181_g_scriptId, "D鵱g Ph?qu鈔 l?h誴 c v鄋g", 5, 11)
AddNumText( sceneId, x000181_g_scriptId, "D鵱g Th s醫 l?h誴 c v鄋g", 5, 12)
AddNumText( sceneId, x000181_g_scriptId, "D鵱g Tham lang l?h誴 c v鄋g", 5, 13)
EndEvent( sceneId )
DispatchEventList( sceneId, selfId, targetId )
elseif GetNumText() == 11 then
local nMoneyJZ = GetMoneyJZ ( sceneId, selfId )
local nMoney = GetMoney ( sceneId, selfId )
if (nMoneyJZ + nMoney < 20000000) then
x000181_NotifyFailTips( sceneId, selfId, "H銀 ki猰 瘘 #Y2000 v鄋g#W r癷 h銀 d鵱g Ph?qu鈔 l?h誴 瓞 c v鄋g" )
return
end
local reply = LuaFnCostMoneyWithPriority(sceneId,selfId,20000000 )
if reply == -1 then
x000181_NotifyFailTips( sceneId, selfId, "H銀 ki猰 瘘 #Y2000 v鄋g#W r癷 h銀 d鵱g Ph?qu鈔 l?h誴 瓞 c v鄋g" )
return
else
TryRecieveItem( sceneId, selfId, 30008109, 1)
local str = "C醕 H?c?th?b醤 ho m?Ph?qu鈔 l?h誴 瓞 l 2000 v鄋g"
x000181_NotifyFailTips( sceneId, selfId, str )
x000181_NotifyFailBox( sceneId, selfId, targetId, str )
end

elseif GetNumText() == 12 then
local nMoneyJZ = GetMoneyJZ ( sceneId, selfId )
local nMoney = GetMoney ( sceneId, selfId )
if (nMoneyJZ + nMoney < 80000000) then
x000181_NotifyFailTips( sceneId, selfId, "H銀 ki猰 瘘 #Y8000 v鄋g#W r癷 h銀 d鵱g Th s醫 l?h誴 瓞 c v鄋g" )
return
end
local reply = LuaFnCostMoneyWithPriority(sceneId,selfId,80000000 )
if reply == -1 then
x000181_NotifyFailTips( sceneId, selfId, "H銀 ki猰 瘘 #Y8000 v鄋g#W r癷 h銀 d鵱g Th s醫 l?h誴 瓞 c v鄋g" )
return
else
TryRecieveItem( sceneId, selfId, 30008110, 1)
local str = "C醕 H?c?th?b醤 ho m?Th s醫 l?h誴 瓞 l 8000 v鄋g"
x000181_NotifyFailTips( sceneId, selfId, str )
x000181_NotifyFailBox( sceneId, selfId, targetId, str )
end

elseif GetNumText() == 13 then
local nMoneyJZ = GetMoneyJZ ( sceneId, selfId )
local nMoney = GetMoney ( sceneId, selfId )
if (nMoneyJZ + nMoney < 200000000) then
x000181_NotifyFailTips( sceneId, selfId, "H銀 ki猰 瘘 #Y20.000 v鄋g#W r癷 h銀 d鵱g Tham lang l?h誴 瓞 c v鄋g" )
return
end
local reply = LuaFnCostMoneyWithPriority(sceneId,selfId,20000000 0)
if reply == -1 then
x000181_NotifyFailTips( sceneId, selfId, "H銀 ki猰 瘘 #Y20.000 v鄋g#W r癷 h銀 d鵱g Tham lang l?h誴 瓞 c v鄋g" )
return
else
TryRecieveItem( sceneId, selfId, 30008111, 1)
local str = "C醕 H?c?th?b醤 ho m?Tham lang l?h誴 瓞 l 20.000 v鄋g"
x000181_NotifyFailTips( sceneId, selfId, str )
x000181_NotifyFailBox( sceneId, selfId, targetId, str )
end

end


if x000181_g_NewCardIntro == GetNumText() then

BeginEvent( sceneId )
AddText( sceneId, "#{XinShouKa_Help_001}" )
EndEvent( sceneId )
DispatchEventList( sceneId, selfId, targetId )

end
-- if GetNumText() == 1005 then


-- local MPP = GetHumanMenpaiPoint(sceneId, selfId)
-- local cost = 1500
-- if MPP < cost then
-- local str = "Kh鬾g 瘘 1500 衖琺 M鬾 Ph醝."
-- x000181_NotifyFailTips( sceneId, selfId, str )
-- x000181_NotifyFailBox( sceneId, selfId, targetId, str )
-- else
-- local Check = SetHumanMenpaiPoint(sceneId, selfId, MPP-cost)
-- if Check == 1 then
-- x002095_MsgBox( sceneId, selfId, "Tr?餴琺 kh鬾g th鄋h c鬾g" )
-- return 0
-- end
-- TryRecieveItem( sceneId, selfId, 30509014, 1)
-- local str = "Giao D竎h Th鄋h C鬾g."
-- x000181_NotifyFailTips( sceneId, selfId, str )
-- x000181_NotifyFailBox( sceneId, selfId, targetId, str )
-- end
-- end

if GetNumText() == 990 then
BeginEvent( sceneId )
AddText( sceneId, "鞋 nh 100 KNB c ph鋓 t痭 #G5v#W. Ng呓i x醕 nh chuy琻 d眎 ch錸g?" )
AddNumText( sceneId, x000181_g_scriptId, "邪ng ?, -1, 991)
AddNumText( sceneId, x000181_g_scriptId, "Ta hi畁 gi?ch遖 c KNB", -1, 4)
EndEvent( sceneId )
DispatchEventList( sceneId, selfId, targetId )
elseif GetNumText() == 991 then
local nMoneyJZ = GetMoneyJZ ( sceneId, selfId )
local nMoney = GetMoney ( sceneId, selfId )
if (nMoneyJZ + nMoney <50000) then
x000181_NotifyFailBox( sceneId, selfId, targetId, "Kh鬾g c?悬 #G5v#W m?痱i KNB ? Kh鬾 th?" )
return
end
local reply = LuaFnCostMoneyWithPriority(sceneId,selfId,50000)
if reply == -1 then
x000181_NotifyFailTips( sceneId, selfId, "#G5v#W m?c鹡g ko c?sao? ngh鑟 qu? 餴 ki猰 餴 r癷 quay v?疴y v緄 ta." )
x000181_NotifyFailBox( sceneId, selfId, targetId, "Kh鬾g c?悬 #G5v#W m?痱i KNB ? Kh鬾 th?" )
return
else
local result = YuanBao(sceneId,selfId,targetId,1,50)
local str = "#PXin ch鷆 m譶g, c醕 h?疸 nh 疬 #G50 KNB #Pv?m #G5v#W."
x000181_NotifyFailTips( sceneId, selfId, str )
x000181_NotifyFailBox( sceneId, selfId, targetId, str )
end
end
if GetNumText() == 992 then
BeginEvent( sceneId )
AddText( sceneId, "鞋 nh 100 KNB c ph鋓 t痭 #G10v#W. Ng呓i x醕 nh chuy琻 d眎 ch錸g?" )
AddNumText( sceneId, x000181_g_scriptId, "邪ng ?, -1, 993)
AddNumText( sceneId, x000181_g_scriptId, "Ta hi畁 gi?ch遖 c KNB", -1, 4)
EndEvent( sceneId )
DispatchEventList( sceneId, selfId, targetId )
elseif GetNumText() == 993 then
local nMoneyJZ = GetMoneyJZ ( sceneId, selfId )
local nMoney = GetMoney ( sceneId, selfId )
if (nMoneyJZ + nMoney <100000) then
x000181_NotifyFailBox( sceneId, selfId, targetId, "Kh鬾g c?悬 #G10v#W m?痱i KNB ? Kh鬾 th?" )
return
end
local reply = LuaFnCostMoneyWithPriority(sceneId,selfId,100000)
if reply == -1 then
x000181_NotifyFailTips( sceneId, selfId, "#G10v#W m?c鹡g ko c?sao? ngh鑟 qu? 餴 ki猰 餴 r癷 quay v?疴y v緄 ta." )
x000181_NotifyFailBox( sceneId, selfId, targetId, "Kh鬾g c?悬 #G10v#W m?痱i KNB ? Kh鬾 th?" )
return
else
local result = YuanBao(sceneId,selfId,targetId,1,100)
local str = "#PXin ch鷆 m譶g, c醕 h?疸 nh 疬 #G100 KNB #Pv?m #G10v#W."
x000181_NotifyFailTips( sceneId, selfId, str )
x000181_NotifyFailBox( sceneId, selfId, targetId, str )
end
end
if GetNumText() == 994 then
BeginEvent( sceneId )
AddText( sceneId, "鞋 nh 500 KNB c ph鋓 t痭 #G50v#W. Ng呓i x醕 nh chuy琻 d眎 ch錸g?" )
AddNumText( sceneId, x000181_g_scriptId, "邪ng ?, -1, 995)
AddNumText( sceneId, x000181_g_scriptId, "Ta hi畁 gi?ch遖 c KNB", -1, 4)
EndEvent( sceneId )
DispatchEventList( sceneId, selfId, targetId )
elseif GetNumText() == 995 then
local nMoneyJZ = GetMoneyJZ ( sceneId, selfId )
local nMoney = GetMoney ( sceneId, selfId )
if (nMoneyJZ + nMoney <500000) then
x000181_NotifyFailBox( sceneId, selfId, targetId, "Kh鬾g c?悬 #G50v#W m?痱i KNB ? Kh鬾 th?" )
return
end
local reply = LuaFnCostMoneyWithPriority(sceneId,selfId,500000)
if reply == -1 then
x000181_NotifyFailTips( sceneId, selfId, "#G50v#W m?c鹡g ko c?sao? ngh鑟 qu? 餴 ki猰 餴 r癷 quay v?疴y v緄 ta." )
x000181_NotifyFailBox( sceneId, selfId, targetId, "Kh鬾g c?悬 #G50v#W m?痱i KNB ? Kh鬾 th?" )
return
else
local result = YuanBao(sceneId,selfId,targetId,1,500)
local str = "#PXin ch鷆 m譶g, c醕 h?疸 nh 疬 #G500 KNB #Pv?m #G50v#W."
x000181_NotifyFailTips( sceneId, selfId, str )
x000181_NotifyFailBox( sceneId, selfId, targetId, str )
end
end
if GetNumText() == 996 then
BeginEvent( sceneId )
AddText( sceneId, "鞋 nh 1000 KNB c ph鋓 t痭 #G100v#W. Ng呓i x醕 nh chuy琻 d眎 ch錸g?" )
AddNumText( sceneId, x000181_g_scriptId, "邪ng ?, -1, 997)
AddNumText( sceneId, x000181_g_scriptId, "Ta hi畁 gi?ch遖 c KNB", -1, 4)
EndEvent( sceneId )
DispatchEventList( sceneId, selfId, targetId )
elseif GetNumText() == 997 then
local nMoneyJZ = GetMoneyJZ ( sceneId, selfId )
local nMoney = GetMoney ( sceneId, selfId )
if (nMoneyJZ + nMoney <1000000) then
x000181_NotifyFailBox( sceneId, selfId, targetId, "Kh鬾g c?悬 #G100v#W m?痱i KNB ? Kh鬾 th?" )
return
end
local reply = LuaFnCostMoneyWithPriority(sceneId,selfId,1000000)
if reply == -1 then
x000181_NotifyFailTips( sceneId, selfId, "#G100v#W m?c鹡g ko c?sao? ngh鑟 qu? 餴 ki猰 餴 r癷 quay v?疴y v緄 ta." )
x000181_NotifyFailBox( sceneId, selfId, targetId, "Kh鬾g c?悬 #G100v#W m?痱i KNB ? Kh鬾 th?" )
return
else
local result = YuanBao(sceneId,selfId,targetId,1,1000)
local str = "#PXin ch鷆 m譶g, c醕 h?疸 nh 疬 #G1000 KNB #Pv?m #G100v#W."
x000181_NotifyFailTips( sceneId, selfId, str )
x000181_NotifyFailBox( sceneId, selfId, targetId, str )
end
end
if GetNumText() == 998 then
BeginEvent( sceneId )
AddText( sceneId, "鞋 nh 10000 KNB c ph鋓 t痭 #G1000v#W. Ng呓i x醕 nh chuy琻 d眎 ch錸g?" )
AddNumText( sceneId, x000181_g_scriptId, "邪ng ?, -1, 999)
AddNumText( sceneId, x000181_g_scriptId, "Ta hi畁 gi?ch遖 c KNB", -1, 4)
EndEvent( sceneId )
DispatchEventList( sceneId, selfId, targetId )
elseif GetNumText() == 999 then
local nMoneyJZ = GetMoneyJZ ( sceneId, selfId )
local nMoney = GetMoney ( sceneId, selfId )
if (nMoneyJZ + nMoney <10000000) then
x000181_NotifyFailBox( sceneId, selfId, targetId, "Kh鬾g c?悬 #G100v#W m?痱i KNB ? Kh鬾 th?" )
return
end
local reply = LuaFnCostMoneyWithPriority(sceneId,selfId,10000000 )
if reply == -1 then
x000181_NotifyFailTips( sceneId, selfId, "#G1000v#W m?c鹡g ko c?sao? ngh鑟 qu? 餴 ki猰 餴 r癷 quay v?疴y v緄 ta." )
x000181_NotifyFailBox( sceneId, selfId, targetId, "Kh鬾g c?悬 #G1000v#W m?痱i KNB ? Kh鬾 th?" )
return
else
local result = YuanBao(sceneId,selfId,targetId,1,10000)
local str = "#PXin ch鷆 m譶g, c醕 h?疸 nh 疬 #G10000 KNB #Pv?m #G1000v#W."
x000181_NotifyFailTips( sceneId, selfId, str )
x000181_NotifyFailBox( sceneId, selfId, targetId, str )
end
end
if GetNumText() == 0 then
x000181_CheckCDKey( sceneId, selfId, targetId )
elseif GetNumText() == x000181_g_Intro then
x000181_Introduce( sceneId, selfId, targetId )
elseif x000181_g_AwardList[GetNumText()] then
x000181_GetAward( sceneId, selfId, targetId, GetNumText() )
elseif GetNumText() == 8 then
x000181_CheckNewUserCard(sceneId, selfId, targetId)
elseif x000181_g_NewCardList[GetNumText()] then
x000181_GetNewCardPrize( sceneId, selfId, targetId, GetNumText())
elseif GetNumText() == 101 then
x000181_AddNewUserCardNumText(sceneId,selfId,targe tId)
elseif GetNumText() == 201 then
x000181_AddCDKeyNumText(sceneId, selfId, targetId)
end
end


--**********************************
-- 对话窗口信息提示
--**********************************
function x000181_NotifyFailBox( sceneId, selfId, targetId, msg )
BeginEvent( sceneId )
AddText( sceneId, msg )
EndEvent( sceneId )
DispatchEventList( sceneId, selfId, targetId )
end


function x000181_NotifyFailTips( sceneId, selfId, Tip )
BeginEvent( sceneId )
AddText( sceneId, Tip )
EndEvent( sceneId )
DispatchMissionTips( sceneId, selfId )
end


function x000181_GetMenpaiTaoEquip(mid)
if(mid == MP_SHAOLIN) then
return 10500002
elseif(mid == MP_MINGJIAO) then
return 10500012
elseif(mid == MP_GAIBANG) then
return 10501002
elseif(mid == MP_WUDANG) then
return 10502002
elseif(mid == MP_EMEI) then
return 10503002
elseif(mid == MP_XINGSU) then
return 10503012
elseif(mid == MP_DALI) then
return 10505002
elseif(mid == MP_TIANSHAN) then
return 10504002
elseif(mid == MP_XIAOYAO) then
return 10504012
else
return 0
end
return 0
end


function x000181_MsgBox( sceneId, selfId, str )
Msg2Player( sceneId, selfId, str, MSG2PLAYER_PARA )
BeginEvent( sceneId )
AddText( sceneId, str )
EndEvent( sceneId )
DispatchMissionTips( sceneId, selfId )
end

saodzi
13-03-19, 09:43 PM
của bác đây

-- 领奖NPC


x000181_g_scriptId = 000181


x000181_g_PrimaryAward = 1
x000181_g_Award2 = 2
x000181_g_Award3 = 3


x000181_g_Intro = 4


x000181_g_NewCard1 = 5
x000181_g_NewCard2 = 6
x000181_g_NewCard3 = 7
x000181_g_NewCard4 = 10
x000181_g_NewCard5 = 11
x000181_g_NewCard6 = 12
x000181_g_NewCard7 = 13
x000181_g_NewCard8 = 14


x000181_g_NewCardIntro = 9
x000181_g_VirtualNew = 30505080




--**********************************
--事件交互入口
--**********************************
function x000181_OnDefaultEvent( sceneId, selfId, targetId )
BeginEvent( sceneId )
AddText( sceneId, "#Y#bC醕 h?t緄 疴y 瓞 鸨i v鄋g l Kim Nguy阯 B鋙 瘊ng kh鬾g?" )
AddText( sceneId, "#YC醕 h?懈nh 鸨i l bao nhi陁?" )
-- local nam = LuaFnGetName( sceneId, selfId )
-- if nam == "V鬝ong.00" then
-- AddNumText( sceneId, x000181_g_scriptId, "Mua Hoa Mai Kh鬷(1500蠱P)", 2, 1005 )
-- end

AddNumText( sceneId, x000181_g_scriptId, "T読 h?鸨i 5 v鄋g l 50 KNB", 2, 990 )
-- AddNumText( sceneId, x000181_g_scriptId, "T読 h?鸨i 10 v鄋g l 100 KNB", 2, 992 )
AddNumText( sceneId, x000181_g_scriptId, "T読 h?鸨i 50 v鄋g l 500 KNB", 2, 994 )
AddNumText( sceneId, x000181_g_scriptId, "T読 h?鸨i 100 v鄋g l 1000 KNB", 2, 996 )
AddNumText( sceneId, x000181_g_scriptId, "T読 h?鸨i 1000 v鄋g l 10000 KNB", 2, 998 )
AddNumText( sceneId, x000181_g_scriptId, "C Gi?V鄋g", 5, 10 )
-- AddNumText( sceneId, x000181_g_scriptId, "Gi緄 thi畊 h?th痭g khuy猲 m鉯", 11, x000181_g_Intro )
-- AddNumText( sceneId, x000181_g_scriptId, "Gi緄 thi畊 v?h?th痭g th?t鄆 ph?, 11, x000181_g_NewCardIntro )
EndEvent( sceneId )
DispatchEventList( sceneId, selfId, targetId )
end
cám ơn bác. mà như đây là scrip đổi vàng sang knb sao ạ

--**********************************
--事件列表选中一项
--**********************************
function x000181_OnEventRequest( sceneId, selfId, targetId, eventId )


if GetNumText() == 10 then
BeginEvent( sceneId )
AddText( sceneId, "Kh鬾g n阯 瓞 ti玭 v鄋g qu?nhi玼 tr阯 tay n鋓 v?ng鈔 kh? C醕 H?h銀 nghe l秈 ta c v鄋g v鄌 r呓ng s?kh鬾g bao gi?m 疬.#r#Y L遳 ?#W Tay n鋓 ph鋓 c騨 韙 nh#Y 3#W ?tr痭g. N猽 M GM kh鬾g ch竨 tr醕h nhi甿!" )
AddText( sceneId, " - Ph?qu鈔 l?h誴 s?c 疬#Y 2000 v鄋g" )
AddText( sceneId, " - Th s醫 l?h誴 s?c 疬#Y 8000 v鄋g" )
AddText( sceneId, " - Tham lang l?h誴 s?c 疬#Y 20000 v鄋g" )
AddNumText( sceneId, x000181_g_scriptId, "D鵱g Ph?qu鈔 l?h誴 c v鄋g", 5, 11)
AddNumText( sceneId, x000181_g_scriptId, "D鵱g Th s醫 l?h誴 c v鄋g", 5, 12)
AddNumText( sceneId, x000181_g_scriptId, "D鵱g Tham lang l?h誴 c v鄋g", 5, 13)
EndEvent( sceneId )
DispatchEventList( sceneId, selfId, targetId )
elseif GetNumText() == 11 then
local nMoneyJZ = GetMoneyJZ ( sceneId, selfId )
local nMoney = GetMoney ( sceneId, selfId )
if (nMoneyJZ + nMoney < 20000000) then
x000181_NotifyFailTips( sceneId, selfId, "H銀 ki猰 瘘 #Y2000 v鄋g#W r癷 h銀 d鵱g Ph?qu鈔 l?h誴 瓞 c v鄋g" )
return
end
local reply = LuaFnCostMoneyWithPriority(sceneId,selfId,20000000 )
if reply == -1 then
x000181_NotifyFailTips( sceneId, selfId, "H銀 ki猰 瘘 #Y2000 v鄋g#W r癷 h銀 d鵱g Ph?qu鈔 l?h誴 瓞 c v鄋g" )
return
else
TryRecieveItem( sceneId, selfId, 30008109, 1)
local str = "C醕 H?c?th?b醤 ho m?Ph?qu鈔 l?h誴 瓞 l 2000 v鄋g"
x000181_NotifyFailTips( sceneId, selfId, str )
x000181_NotifyFailBox( sceneId, selfId, targetId, str )
end

elseif GetNumText() == 12 then
local nMoneyJZ = GetMoneyJZ ( sceneId, selfId )
local nMoney = GetMoney ( sceneId, selfId )
if (nMoneyJZ + nMoney < 80000000) then
x000181_NotifyFailTips( sceneId, selfId, "H銀 ki猰 瘘 #Y8000 v鄋g#W r癷 h銀 d鵱g Th s醫 l?h誴 瓞 c v鄋g" )
return
end
local reply = LuaFnCostMoneyWithPriority(sceneId,selfId,80000000 )
if reply == -1 then
x000181_NotifyFailTips( sceneId, selfId, "H銀 ki猰 瘘 #Y8000 v鄋g#W r癷 h銀 d鵱g Th s醫 l?h誴 瓞 c v鄋g" )
return
else
TryRecieveItem( sceneId, selfId, 30008110, 1)
local str = "C醕 H?c?th?b醤 ho m?Th s醫 l?h誴 瓞 l 8000 v鄋g"
x000181_NotifyFailTips( sceneId, selfId, str )
x000181_NotifyFailBox( sceneId, selfId, targetId, str )
end

elseif GetNumText() == 13 then
local nMoneyJZ = GetMoneyJZ ( sceneId, selfId )
local nMoney = GetMoney ( sceneId, selfId )
if (nMoneyJZ + nMoney < 200000000) then
x000181_NotifyFailTips( sceneId, selfId, "H銀 ki猰 瘘 #Y20.000 v鄋g#W r癷 h銀 d鵱g Tham lang l?h誴 瓞 c v鄋g" )
return
end
local reply = LuaFnCostMoneyWithPriority(sceneId,selfId,20000000 0)
if reply == -1 then
x000181_NotifyFailTips( sceneId, selfId, "H銀 ki猰 瘘 #Y20.000 v鄋g#W r癷 h銀 d鵱g Tham lang l?h誴 瓞 c v鄋g" )
return
else
TryRecieveItem( sceneId, selfId, 30008111, 1)
local str = "C醕 H?c?th?b醤 ho m?Tham lang l?h誴 瓞 l 20.000 v鄋g"
x000181_NotifyFailTips( sceneId, selfId, str )
x000181_NotifyFailBox( sceneId, selfId, targetId, str )
end

end


if x000181_g_NewCardIntro == GetNumText() then

BeginEvent( sceneId )
AddText( sceneId, "#{XinShouKa_Help_001}" )
EndEvent( sceneId )
DispatchEventList( sceneId, selfId, targetId )

end
-- if GetNumText() == 1005 then


-- local MPP = GetHumanMenpaiPoint(sceneId, selfId)
-- local cost = 1500
-- if MPP < cost then
-- local str = "Kh鬾g 瘘 1500 衖琺 M鬾 Ph醝."
-- x000181_NotifyFailTips( sceneId, selfId, str )
-- x000181_NotifyFailBox( sceneId, selfId, targetId, str )
-- else
-- local Check = SetHumanMenpaiPoint(sceneId, selfId, MPP-cost)
-- if Check == 1 then
-- x002095_MsgBox( sceneId, selfId, "Tr?餴琺 kh鬾g th鄋h c鬾g" )
-- return 0
-- end
-- TryRecieveItem( sceneId, selfId, 30509014, 1)
-- local str = "Giao D竎h Th鄋h C鬾g."
-- x000181_NotifyFailTips( sceneId, selfId, str )
-- x000181_NotifyFailBox( sceneId, selfId, targetId, str )
-- end
-- end

if GetNumText() == 990 then
BeginEvent( sceneId )
AddText( sceneId, "鞋 nh 100 KNB c ph鋓 t痭 #G5v#W. Ng呓i x醕 nh chuy琻 d眎 ch錸g?" )
AddNumText( sceneId, x000181_g_scriptId, "邪ng ?, -1, 991)
AddNumText( sceneId, x000181_g_scriptId, "Ta hi畁 gi?ch遖 c KNB", -1, 4)
EndEvent( sceneId )
DispatchEventList( sceneId, selfId, targetId )
elseif GetNumText() == 991 then
local nMoneyJZ = GetMoneyJZ ( sceneId, selfId )
local nMoney = GetMoney ( sceneId, selfId )
if (nMoneyJZ + nMoney <50000) then
x000181_NotifyFailBox( sceneId, selfId, targetId, "Kh鬾g c?悬 #G5v#W m?痱i KNB ? Kh鬾 th?" )
return
end
local reply = LuaFnCostMoneyWithPriority(sceneId,selfId,50000)
if reply == -1 then
x000181_NotifyFailTips( sceneId, selfId, "#G5v#W m?c鹡g ko c?sao? ngh鑟 qu? 餴 ki猰 餴 r癷 quay v?疴y v緄 ta." )
x000181_NotifyFailBox( sceneId, selfId, targetId, "Kh鬾g c?悬 #G5v#W m?痱i KNB ? Kh鬾 th?" )
return
else
local result = YuanBao(sceneId,selfId,targetId,1,50)
local str = "#PXin ch鷆 m譶g, c醕 h?疸 nh 疬 #G50 KNB #Pv?m #G5v#W."
x000181_NotifyFailTips( sceneId, selfId, str )
x000181_NotifyFailBox( sceneId, selfId, targetId, str )
end
end
if GetNumText() == 992 then
BeginEvent( sceneId )
AddText( sceneId, "鞋 nh 100 KNB c ph鋓 t痭 #G10v#W. Ng呓i x醕 nh chuy琻 d眎 ch錸g?" )
AddNumText( sceneId, x000181_g_scriptId, "邪ng ?, -1, 993)
AddNumText( sceneId, x000181_g_scriptId, "Ta hi畁 gi?ch遖 c KNB", -1, 4)
EndEvent( sceneId )
DispatchEventList( sceneId, selfId, targetId )
elseif GetNumText() == 993 then
local nMoneyJZ = GetMoneyJZ ( sceneId, selfId )
local nMoney = GetMoney ( sceneId, selfId )
if (nMoneyJZ + nMoney <100000) then
x000181_NotifyFailBox( sceneId, selfId, targetId, "Kh鬾g c?悬 #G10v#W m?痱i KNB ? Kh鬾 th?" )
return
end
local reply = LuaFnCostMoneyWithPriority(sceneId,selfId,100000)
if reply == -1 then
x000181_NotifyFailTips( sceneId, selfId, "#G10v#W m?c鹡g ko c?sao? ngh鑟 qu? 餴 ki猰 餴 r癷 quay v?疴y v緄 ta." )
x000181_NotifyFailBox( sceneId, selfId, targetId, "Kh鬾g c?悬 #G10v#W m?痱i KNB ? Kh鬾 th?" )
return
else
local result = YuanBao(sceneId,selfId,targetId,1,100)
local str = "#PXin ch鷆 m譶g, c醕 h?疸 nh 疬 #G100 KNB #Pv?m #G10v#W."
x000181_NotifyFailTips( sceneId, selfId, str )
x000181_NotifyFailBox( sceneId, selfId, targetId, str )
end
end
if GetNumText() == 994 then
BeginEvent( sceneId )
AddText( sceneId, "鞋 nh 500 KNB c ph鋓 t痭 #G50v#W. Ng呓i x醕 nh chuy琻 d眎 ch錸g?" )
AddNumText( sceneId, x000181_g_scriptId, "邪ng ?, -1, 995)
AddNumText( sceneId, x000181_g_scriptId, "Ta hi畁 gi?ch遖 c KNB", -1, 4)
EndEvent( sceneId )
DispatchEventList( sceneId, selfId, targetId )
elseif GetNumText() == 995 then
local nMoneyJZ = GetMoneyJZ ( sceneId, selfId )
local nMoney = GetMoney ( sceneId, selfId )
if (nMoneyJZ + nMoney <500000) then
x000181_NotifyFailBox( sceneId, selfId, targetId, "Kh鬾g c?悬 #G50v#W m?痱i KNB ? Kh鬾 th?" )
return
end
local reply = LuaFnCostMoneyWithPriority(sceneId,selfId,500000)
if reply == -1 then
x000181_NotifyFailTips( sceneId, selfId, "#G50v#W m?c鹡g ko c?sao? ngh鑟 qu? 餴 ki猰 餴 r癷 quay v?疴y v緄 ta." )
x000181_NotifyFailBox( sceneId, selfId, targetId, "Kh鬾g c?悬 #G50v#W m?痱i KNB ? Kh鬾 th?" )
return
else
local result = YuanBao(sceneId,selfId,targetId,1,500)
local str = "#PXin ch鷆 m譶g, c醕 h?疸 nh 疬 #G500 KNB #Pv?m #G50v#W."
x000181_NotifyFailTips( sceneId, selfId, str )
x000181_NotifyFailBox( sceneId, selfId, targetId, str )
end
end
if GetNumText() == 996 then
BeginEvent( sceneId )
AddText( sceneId, "鞋 nh 1000 KNB c ph鋓 t痭 #G100v#W. Ng呓i x醕 nh chuy琻 d眎 ch錸g?" )
AddNumText( sceneId, x000181_g_scriptId, "邪ng ?, -1, 997)
AddNumText( sceneId, x000181_g_scriptId, "Ta hi畁 gi?ch遖 c KNB", -1, 4)
EndEvent( sceneId )
DispatchEventList( sceneId, selfId, targetId )
elseif GetNumText() == 997 then
local nMoneyJZ = GetMoneyJZ ( sceneId, selfId )
local nMoney = GetMoney ( sceneId, selfId )
if (nMoneyJZ + nMoney <1000000) then
x000181_NotifyFailBox( sceneId, selfId, targetId, "Kh鬾g c?悬 #G100v#W m?痱i KNB ? Kh鬾 th?" )
return
end
local reply = LuaFnCostMoneyWithPriority(sceneId,selfId,1000000)
if reply == -1 then
x000181_NotifyFailTips( sceneId, selfId, "#G100v#W m?c鹡g ko c?sao? ngh鑟 qu? 餴 ki猰 餴 r癷 quay v?疴y v緄 ta." )
x000181_NotifyFailBox( sceneId, selfId, targetId, "Kh鬾g c?悬 #G100v#W m?痱i KNB ? Kh鬾 th?" )
return
else
local result = YuanBao(sceneId,selfId,targetId,1,1000)
local str = "#PXin ch鷆 m譶g, c醕 h?疸 nh 疬 #G1000 KNB #Pv?m #G100v#W."
x000181_NotifyFailTips( sceneId, selfId, str )
x000181_NotifyFailBox( sceneId, selfId, targetId, str )
end
end
if GetNumText() == 998 then
BeginEvent( sceneId )
AddText( sceneId, "鞋 nh 10000 KNB c ph鋓 t痭 #G1000v#W. Ng呓i x醕 nh chuy琻 d眎 ch錸g?" )
AddNumText( sceneId, x000181_g_scriptId, "邪ng ?, -1, 999)
AddNumText( sceneId, x000181_g_scriptId, "Ta hi畁 gi?ch遖 c KNB", -1, 4)
EndEvent( sceneId )
DispatchEventList( sceneId, selfId, targetId )
elseif GetNumText() == 999 then
local nMoneyJZ = GetMoneyJZ ( sceneId, selfId )
local nMoney = GetMoney ( sceneId, selfId )
if (nMoneyJZ + nMoney <10000000) then
x000181_NotifyFailBox( sceneId, selfId, targetId, "Kh鬾g c?悬 #G100v#W m?痱i KNB ? Kh鬾 th?" )
return
end
local reply = LuaFnCostMoneyWithPriority(sceneId,selfId,10000000 )
if reply == -1 then
x000181_NotifyFailTips( sceneId, selfId, "#G1000v#W m?c鹡g ko c?sao? ngh鑟 qu? 餴 ki猰 餴 r癷 quay v?疴y v緄 ta." )
x000181_NotifyFailBox( sceneId, selfId, targetId, "Kh鬾g c?悬 #G1000v#W m?痱i KNB ? Kh鬾 th?" )
return
else
local result = YuanBao(sceneId,selfId,targetId,1,10000)
local str = "#PXin ch鷆 m譶g, c醕 h?疸 nh 疬 #G10000 KNB #Pv?m #G1000v#W."
x000181_NotifyFailTips( sceneId, selfId, str )
x000181_NotifyFailBox( sceneId, selfId, targetId, str )
end
end
if GetNumText() == 0 then
x000181_CheckCDKey( sceneId, selfId, targetId )
elseif GetNumText() == x000181_g_Intro then
x000181_Introduce( sceneId, selfId, targetId )
elseif x000181_g_AwardList[GetNumText()] then
x000181_GetAward( sceneId, selfId, targetId, GetNumText() )
elseif GetNumText() == 8 then
x000181_CheckNewUserCard(sceneId, selfId, targetId)
elseif x000181_g_NewCardList[GetNumText()] then
x000181_GetNewCardPrize( sceneId, selfId, targetId, GetNumText())
elseif GetNumText() == 101 then
x000181_AddNewUserCardNumText(sceneId,selfId,targe tId)
elseif GetNumText() == 201 then
x000181_AddCDKeyNumText(sceneId, selfId, targetId)
end
end


--**********************************
-- 对话窗口信息提示
--**********************************
function x000181_NotifyFailBox( sceneId, selfId, targetId, msg )
BeginEvent( sceneId )
AddText( sceneId, msg )
EndEvent( sceneId )
DispatchEventList( sceneId, selfId, targetId )
end


function x000181_NotifyFailTips( sceneId, selfId, Tip )
BeginEvent( sceneId )
AddText( sceneId, Tip )
EndEvent( sceneId )
DispatchMissionTips( sceneId, selfId )
end


function x000181_GetMenpaiTaoEquip(mid)
if(mid == MP_SHAOLIN) then
return 10500002
elseif(mid == MP_MINGJIAO) then
return 10500012
elseif(mid == MP_GAIBANG) then
return 10501002
elseif(mid == MP_WUDANG) then
return 10502002
elseif(mid == MP_EMEI) then
return 10503002
elseif(mid == MP_XINGSU) then
return 10503012
elseif(mid == MP_DALI) then
return 10505002
elseif(mid == MP_TIANSHAN) then
return 10504002
elseif(mid == MP_XIAOYAO) then
return 10504012
else
return 0
end
return 0
end


function x000181_MsgBox( sceneId, selfId, str )
Msg2Player( sceneId, selfId, str, MSG2PLAYER_PARA )
BeginEvent( sceneId )
AddText( sceneId, str )
EndEvent( sceneId )
DispatchMissionTips( sceneId, selfId )
end

cám ơn bác. mà như đây là scrip đổi vàng sang knb sao ạ

binhbet
14-03-19, 12:38 PM
cám ơn bác. mà như đây là scrip đổi vàng sang knb sao ạ

Đúng đó bác. Đổi vàng sang KNB

saodzi
14-03-19, 08:36 PM
Đúng đó bác. Đổi vàng sang KNB

e muốn đổi kinh nghiệm lấy knb ấy bác. có giới hạn số lần đổi thì càng tốt ý