bthhhz
03-05-15, 05:48 AM
Mình chạy mấy cái linux thấy có cái lỗi này ngay từ lúc chạy sv . mình đọc qua thì ko có phát hiện lỗi nhưng mà gameserver nó báo mãi ko biết nguyên nhân do đâu
<b><font color=red>[Chỉ có thành viên mới xem link được. <a href="register.php"> Nhấp đây để đăng ký thành viên......</a>]</font></b>
code của script đó
Include( "\\script\\missions\\leaguematch\\head.lua" )
TB_WLLS_JOIN_SAY = {
"Thêi gian vµo khu vùc ®· hÕt, lÇn sau h·y tíi sím h¬n!",
"Cha vµo ®éi, kh«ng thÓ vµo héi trêng",
"Mçi ®Þa ®iÓm chØ chøa tèi ®a ®îc 400 ®éi!",
"Liªn ®Êu th¸ng nµy, ®éi b¹n ®· tham gia ®ñ sè trËn!",
"Xin lçi! Thµnh viªn trong ®éi cña b¹n ®· vµo khu vùc chuÈn bÞ, h·y thö l¹i",
"Sè ngêi ®· ®ñ, kh«ng thÓ vµo",
}
TB_WLLS_PHASE_MSG = {
"Vâ l©m liªn ®Êu ®ang trong giai ®o¹n nghØ ng¬i, cã thÓ nhËn thëng theo tõng cÊp bËc. H¹n chÕ %s",
"Vâ l©m liªn ®Êu s¾p b¾t ®Çu, h·y kiÓm tra chiÕn ®éi. H¹n chÕ %s",
"Vâ l©m liªn ®Êu t¹m thêi kÕt thóc ", -- ²»Ò»¶¨ÊǽñÌìÔÙûÓбÈÈüÁË
"Vâ l©m liªn ®Êu %d chÝnh thøc vµo giai ®o¹n b¸o danh, c¸c ®éi h·y mau ®¨ng ký!",
}
--ÏòÖ¸¶¨½ÇÉ«Ãû·¢ÏûÏ¢
function wlls_gw_say(rolename, str, b_msg, b_sync)
local n_playeridx = SearchPlayer(rolename)
if (n_playeridx > 0) then
local n_old = PlayerIndex
PlayerIndex = n_playeridx
if b_msg then
Msg2Player(str)
else
local str_npc = GetNpcName(GetLastDiagNpc())
if (str_npc ~= "ÁªÈüʹÕß" and str_npc ~= "ÎäÁÖТÐãÁªÈü¹ÙÔ±" and str_npc ~= "»á³¡¹ÙÔ±") then str_npc = "Quan viªn liªn ®Êu" end
Say(str_npc..":"..str, 0)
end
if b_sync then
wlls_sync_lginfo(LG_GetLeagueObjByRole(WLLS_LGTYPE , rolename))
end
PlayerIndex = n_old
end
end
--µ±Ç°±ÈÈü½×¶Îµ÷Õû
function wlls_setphase(n_sid, n_type, n_phase, n_mid, n_next, tbOpen)
_M("wlls_setphase", n_sid, n_type, n_phase, n_mid, n_next, tbOpen)
--ÊýÖµ»¯£¬°²È«Æð¼û
n_sid = tonumber(n_sid)
n_type = tonumber(n_type)
n_phase = tonumber(n_phase)
n_mid = tonumber(n_mid)
n_next = tonumber(n_next)
local nClose = 0
for i = 1, getn(tbOpen) do
if (FALSE(tbOpen[i])) then
nClose = SetBit(nClose, i, 1)
end
end
_M("{"..join(tbOpen).."}", nClose)
--±¸·Ý¾ÉÖµ
local n_oldsid = GetGlbValue(GLB_WLLS_SID)
local n_oldtype = GetGlbValue(GLB_WLLS_TYPE)
local n_oldphase = GetGlbValue(GLB_WLLS_PHASE)
local n_oldmid = GetGlbValue(GLB_WLLS_MATCHID)
local n_oldnext = GetGlbValue(GLB_WLLS_NEXT)
local nOldClose = GetGlbValue(GLB_WLLS_CLOSE)
--Îޱ仯ֱ½Ó·µ»Ø
if (n_oldsid == n_sid and
n_oldtype == n_type and
n_oldphase == n_phase and
n_oldmid == n_mid and
n_oldnext == n_next and
nOldClose == nClose) then --Îޱ仯ֱ½Ó·µ»Ø
return
end
--±£´æТֵ
SetGlbValue(GLB_WLLS_SID, n_sid)
SetGlbValue(GLB_WLLS_TYPE, n_type)
SetGlbValue(GLB_WLLS_PHASE, n_phase)
SetGlbValue(GLB_WLLS_MATCHID, n_mid)
SetGlbValue(GLB_WLLS_NEXT, n_next)
SetGlbValue(GLB_WLLS_CLOSE, nClose)
if (n_phase == 1) then //Dòng 84 chỗ này
local str = format(TB_WLLS_PHASE_MSG[1], WLLS_TAB[n_next].name)
Msg2SubWorld(str)
elseif (n_phase == 2) then --±ÈÈüÆÚ£¬ÎÞ±ÈÈü
if (n_oldsid ~= n_sid) then --ТÈü¼¾
local str = format(TB_WLLS_PHASE_MSG[2], WLLS_TAB[n_type].name)
Msg2SubWorld(str)
else
Msg2SubWorld(TB_WLLS_PHASE_MSG[3])
end
elseif (n_phase == 4) then --¿ªÊ¼±ÈÈü
local tb_sub = wlls_get_subworld(2)
local n_oldsub = SubWorld
--È¡Ïû¿ÉÄÜÕýÔڵȴý¿ªÊ¼µÄ±ÈÈ ü
for n_idx, nGroupIdx in tb_sub do
SubWorld = n_idx
CloseMission(WLLS_MSID_SCHEDULE)
end
if (n_mid <= 0) then --Relay¸Õ¸ÕÆô¶¯£¬²»ÄÜ¿ªÊ¼±ÈÈü
SetGlbValue(GLB_WLLS_PHASE, 3) --×èÖ¹¼ÌÐø½øÈë×¼±¸³¡
if (n_oldmid > 0) then
--Ϊ¿ÉÄÜÒѾ¿ªÊ¼±ÈÈüµÄÍæ¼Ò» Ö¸´±ÈÈüID
SetGlbValue(GLB_WLLS_MATCHID, n_oldmid)
end
else
--¹Ø±ÕÈ«¾Ö¼ÆʱMission
CloseGlbMission(WLLS_MSID_GLB)
if (nClose ~= 3) then -- ²»ÊÇËùÓбÈÈü¶¼¹ØÁË
--´ò¿ªÈ«¾Ö¼ÆʱMission
OpenGlbMission(WLLS_MSID_GLB)
local str = format(TB_WLLS_PHASE_MSG[4], mod(n_mid, 100))
Msg2SubWorld(str)
AddGlobalNews(str)
WriteLog(date("%Y/%m/%d-%H:%M\t")..str)
--¿ªÆôËùÓÐ×¼±¸³¡
local tbGroup = {}
local n_oldsub = SubWorld
for n_idx, nGroupIdx in tb_sub do
SubWorld = n_idx
local nMType = wlls_get_mapinfo()
local nLevel = wlls_get_level(nMType)
if (not FALSE(tbOpen[nLevel])) then -- ûÓйرյĻ°
tbGroup[getn(tbGroup)+1] = nGroupIdx
print("sever lien dau chuan bi "..wlls_get_desc(3).."sever")
OpenMission(WLLS_MSID_SCHEDULE)
end
end
if (getn(tbGroup) > 0) then
local szParam = GetPlayerCount().." "..join(tbGroup).." 1" -- 1±íʾÊÇ¿ªÊ¼±¨ÃûºóµÄµÚÒ»´Î� �㱨
LG_ApplyDoScript(0, "", "", "\\script\\leaguematch\\joinmatch.lua", "wlls_GsState", szParam , "", "")
end
end
end
SubWorld = n_oldsub
else
print("Vo lam lien dau giai doan:"..n_phase.."("..n_mid..") ???")
end
end
--ÈÃÖ¸¶¨½ÇÉ«½øÈëÖ¸¶¨·þÎñÆ÷µ Ä×¼±¸³¡£¬¼ÓÈëÖ¸¶¨ÕóÓª
function wlls_player_join(str_playername, n_mtype, n_group, n_mscamp)
_M("wlls_player_join", str_playername, n_mtype, n_group, n_mscamp)
if (GetGlbValue(GLB_WLLS_PHASE) ~= 4) then --ʱ¼äÒѹý
n_group = nil
n_mtype = 1
end
local n_playeridx = SearchPlayer(str_playername)
if (n_playeridx > 0) then
local n_old = PlayerIndex
PlayerIndex = n_playeridx
if n_group then --relayÈÏΪ¿ÉÒÔ½øÈë
if not wlls_en_check() then --¿ç·þʧ°ÜÔõôÅжϣ¿£¿£¿£¡£ ¡£¡
local szResult = n_mtype.." "..n_group.." "..GetName()
LG_ApplyDoScript(0, "", "", "\\script\\leaguematch\\joinmatch.lua", "wlls_onleave", szResult , "", "")
return
end
SetTask(WLLS_TASKID_ORGCAMP, n_mscamp)
--Çå³ý¸½¼Ó״̬
for i = 1, getn(WLLS_FORBID_ITEM) do
RemoveSkillState(WLLS_FORBID_ITEM[i][3])
end
for i = 1, getn(WLLS_FORBID_STATES) do
RemoveSkillState(WLLS_FORBID_STATES[i][2])
end
Msg2Player("Khi vµo khu vùc chuÈn bÞ, vËt phÈm sÏ kh«ng thÓ di chuyÓn, nhng vÉn cã thÓ sö dông trong thanh c«ng cô");
SetRevPos(wlls_get_mapid(1, n_mtype, n_group), 1) --ÖØÉúµãÔÚËùÔÚ±ÈÈü·þÎñÆ÷µÄ» ᳡
local n_mapid = wlls_get_mapid(2, n_mtype, n_group)
_M(n_mapid, "wlls_get_mapid", n_mtype, n_group)
NewWorld(n_mapid, WLLS_MAPPOS_PRE[1], WLLS_MAPPOS_PRE[2])
else --²»ÄܽøÈë
Say(TB_WLLS_JOIN_SAY[n_mtype], 0)
end
PlayerIndex = n_old
end
end
-- ·µ»ØÖ¸¶¨½±Æ·ÐÅÏ¢
function wlls_get_awardinfo(n_type, n_level, n_award)
local str = WLLS_LEVEL_DESC[n_level] .. " (" .. WLLS_TAB[n_type].name .. ")´Î"
local tb_award = WLLS_TAB[n_type].award_rank[n_level]
local n_start, n_end = 1, 1
if (n_award > 1) then
n_start = tb_award[n_award - 1][1] + 1
end
n_end = tb_award[n_award][1]
if (n_start ~= n_end) then
str = str .. n_start .. "~" .. n_end
else
str = str .. n_end
end
str = str .. "½±Àø (" .. tb_award[n_award][3] .. ") "
return str
end
-- ·µ»ØÖ¸¶¨ÅÅÃûÓ¦¸ÃÁìÈ¡µÄ½±Ï î
function wlls_get_rankinfo(tb_award, n_rank)
if (n_rank <= 0) then
return nil
end
local n_award
for i = getn(tb_award), 1, -1 do
if (tb_award[i][1] >= n_rank) then
n_award = i
else
break
end
end
return n_award
end
--²éѯ±¾½ÇÉ«ÒÑÁìÈ¡ÁËʲô½±À ø
function wlls_awardinfo(b_Msg)
local str
local n_got = GetTask(WLLS_TASKID_GOTAWARD)
local n_type = GetByte(n_got, 4)
local n_level = GetByte(n_got, 3)
local n_award = GetByte(n_got, 2)
local n_sid = GetByte(n_got, 1)
if (n_award == 0) then
if (n_sid == 0) then
str = "δÁì¹ý"
else
str = "Ãû´Î" .. n_sid .. "´Ë´ÎÁªÈü£¬Î´ÖªÄÚÈÝ"
end
else
str = "Ãû´Î " .. n_sid .. "´Ë´Î" .. wlls_get_awardinfo(n_type, n_level, n_award)
end
local n_awardex = GetTask(WLLS_TASKID_AWARDEX)
local n_type = GetByte(n_awardex, 4)
local n_level = GetByte(n_awardex, 3)
local n_awarderr= GetByte(n_awardex, 2)
local n_award = GetByte(n_awardex, 1)
if b_Msg then
Msg2Player(str)
end
return str
end
function wlls_reload(bRelay)
LoadScript( "\\script\\missions\\leaguematch\\npc\\officer.lua" )
LoadScript( "\\script\\missions\\leaguematch\\npc\\helper.lua" )
LoadScript( "\\script\\missions\\leaguematch\\npc\\signup.lua" )
LoadScript( "\\script\\missions\\leaguematch\\npc\\housecarl.lu a" )
LoadScript( "\\script\\missions\\leaguematch\\npc\\chefu.lua" )
LoadScript( "\\script\\missions\\leaguematch\\npc\\chuwuxiang.l ua" )
LoadScript( "\\script\\missions\\leaguematch\\npc\\yaoshang.lua" )
LoadScript( "\\script\\missions\\leaguematch\\combat\\mission.l ua" )
LoadScript( "\\script\\missions\\leaguematch\\combat\\playerdea th.lua" )
LoadScript( "\\script\\missions\\leaguematch\\schedule\\newworl d.lua" )
LoadScript( "\\script\\missions\\leaguematch\\schedule\\mission .lua" )
LoadScript( "\\script\\missions\\leaguematch\\schedule\\newworl d.lua" )
LoadScript( "\\script\\missions\\leaguematch\\glbmission\\missi on.lua" )
LoadScript( "\\script\\missions\\leaguematch\\glbmission\\comba t.lua" )
LoadScript( "\\script\\missions\\leaguematch\\glbmission\\sched ule.lua" )
LoadScript( "\\script\\global\\server_playerlevelup.lua" )
LoadScript( "\\script\\global\\login.lua" )
if (bRelay) then
LG_ApplyDoScript(0, "", "", "\\script\\leaguematch\\joinmatch.lua", "ReloadAllScript", "" , "", "")
end
Msg2Player("WLLS file vo lam lien dau "..date())
print("===============WLLS file vo lam lien dau "..date())
end
<b><font color=red>[Chỉ có thành viên mới xem link được. <a href="register.php"> Nhấp đây để đăng ký thành viên......</a>]</font></b>
code của script đó
Include( "\\script\\missions\\leaguematch\\head.lua" )
TB_WLLS_JOIN_SAY = {
"Thêi gian vµo khu vùc ®· hÕt, lÇn sau h·y tíi sím h¬n!",
"Cha vµo ®éi, kh«ng thÓ vµo héi trêng",
"Mçi ®Þa ®iÓm chØ chøa tèi ®a ®îc 400 ®éi!",
"Liªn ®Êu th¸ng nµy, ®éi b¹n ®· tham gia ®ñ sè trËn!",
"Xin lçi! Thµnh viªn trong ®éi cña b¹n ®· vµo khu vùc chuÈn bÞ, h·y thö l¹i",
"Sè ngêi ®· ®ñ, kh«ng thÓ vµo",
}
TB_WLLS_PHASE_MSG = {
"Vâ l©m liªn ®Êu ®ang trong giai ®o¹n nghØ ng¬i, cã thÓ nhËn thëng theo tõng cÊp bËc. H¹n chÕ %s",
"Vâ l©m liªn ®Êu s¾p b¾t ®Çu, h·y kiÓm tra chiÕn ®éi. H¹n chÕ %s",
"Vâ l©m liªn ®Êu t¹m thêi kÕt thóc ", -- ²»Ò»¶¨ÊǽñÌìÔÙûÓбÈÈüÁË
"Vâ l©m liªn ®Êu %d chÝnh thøc vµo giai ®o¹n b¸o danh, c¸c ®éi h·y mau ®¨ng ký!",
}
--ÏòÖ¸¶¨½ÇÉ«Ãû·¢ÏûÏ¢
function wlls_gw_say(rolename, str, b_msg, b_sync)
local n_playeridx = SearchPlayer(rolename)
if (n_playeridx > 0) then
local n_old = PlayerIndex
PlayerIndex = n_playeridx
if b_msg then
Msg2Player(str)
else
local str_npc = GetNpcName(GetLastDiagNpc())
if (str_npc ~= "ÁªÈüʹÕß" and str_npc ~= "ÎäÁÖТÐãÁªÈü¹ÙÔ±" and str_npc ~= "»á³¡¹ÙÔ±") then str_npc = "Quan viªn liªn ®Êu" end
Say(str_npc..":"..str, 0)
end
if b_sync then
wlls_sync_lginfo(LG_GetLeagueObjByRole(WLLS_LGTYPE , rolename))
end
PlayerIndex = n_old
end
end
--µ±Ç°±ÈÈü½×¶Îµ÷Õû
function wlls_setphase(n_sid, n_type, n_phase, n_mid, n_next, tbOpen)
_M("wlls_setphase", n_sid, n_type, n_phase, n_mid, n_next, tbOpen)
--ÊýÖµ»¯£¬°²È«Æð¼û
n_sid = tonumber(n_sid)
n_type = tonumber(n_type)
n_phase = tonumber(n_phase)
n_mid = tonumber(n_mid)
n_next = tonumber(n_next)
local nClose = 0
for i = 1, getn(tbOpen) do
if (FALSE(tbOpen[i])) then
nClose = SetBit(nClose, i, 1)
end
end
_M("{"..join(tbOpen).."}", nClose)
--±¸·Ý¾ÉÖµ
local n_oldsid = GetGlbValue(GLB_WLLS_SID)
local n_oldtype = GetGlbValue(GLB_WLLS_TYPE)
local n_oldphase = GetGlbValue(GLB_WLLS_PHASE)
local n_oldmid = GetGlbValue(GLB_WLLS_MATCHID)
local n_oldnext = GetGlbValue(GLB_WLLS_NEXT)
local nOldClose = GetGlbValue(GLB_WLLS_CLOSE)
--Îޱ仯ֱ½Ó·µ»Ø
if (n_oldsid == n_sid and
n_oldtype == n_type and
n_oldphase == n_phase and
n_oldmid == n_mid and
n_oldnext == n_next and
nOldClose == nClose) then --Îޱ仯ֱ½Ó·µ»Ø
return
end
--±£´æТֵ
SetGlbValue(GLB_WLLS_SID, n_sid)
SetGlbValue(GLB_WLLS_TYPE, n_type)
SetGlbValue(GLB_WLLS_PHASE, n_phase)
SetGlbValue(GLB_WLLS_MATCHID, n_mid)
SetGlbValue(GLB_WLLS_NEXT, n_next)
SetGlbValue(GLB_WLLS_CLOSE, nClose)
if (n_phase == 1) then //Dòng 84 chỗ này
local str = format(TB_WLLS_PHASE_MSG[1], WLLS_TAB[n_next].name)
Msg2SubWorld(str)
elseif (n_phase == 2) then --±ÈÈüÆÚ£¬ÎÞ±ÈÈü
if (n_oldsid ~= n_sid) then --ТÈü¼¾
local str = format(TB_WLLS_PHASE_MSG[2], WLLS_TAB[n_type].name)
Msg2SubWorld(str)
else
Msg2SubWorld(TB_WLLS_PHASE_MSG[3])
end
elseif (n_phase == 4) then --¿ªÊ¼±ÈÈü
local tb_sub = wlls_get_subworld(2)
local n_oldsub = SubWorld
--È¡Ïû¿ÉÄÜÕýÔڵȴý¿ªÊ¼µÄ±ÈÈ ü
for n_idx, nGroupIdx in tb_sub do
SubWorld = n_idx
CloseMission(WLLS_MSID_SCHEDULE)
end
if (n_mid <= 0) then --Relay¸Õ¸ÕÆô¶¯£¬²»ÄÜ¿ªÊ¼±ÈÈü
SetGlbValue(GLB_WLLS_PHASE, 3) --×èÖ¹¼ÌÐø½øÈë×¼±¸³¡
if (n_oldmid > 0) then
--Ϊ¿ÉÄÜÒѾ¿ªÊ¼±ÈÈüµÄÍæ¼Ò» Ö¸´±ÈÈüID
SetGlbValue(GLB_WLLS_MATCHID, n_oldmid)
end
else
--¹Ø±ÕÈ«¾Ö¼ÆʱMission
CloseGlbMission(WLLS_MSID_GLB)
if (nClose ~= 3) then -- ²»ÊÇËùÓбÈÈü¶¼¹ØÁË
--´ò¿ªÈ«¾Ö¼ÆʱMission
OpenGlbMission(WLLS_MSID_GLB)
local str = format(TB_WLLS_PHASE_MSG[4], mod(n_mid, 100))
Msg2SubWorld(str)
AddGlobalNews(str)
WriteLog(date("%Y/%m/%d-%H:%M\t")..str)
--¿ªÆôËùÓÐ×¼±¸³¡
local tbGroup = {}
local n_oldsub = SubWorld
for n_idx, nGroupIdx in tb_sub do
SubWorld = n_idx
local nMType = wlls_get_mapinfo()
local nLevel = wlls_get_level(nMType)
if (not FALSE(tbOpen[nLevel])) then -- ûÓйرյĻ°
tbGroup[getn(tbGroup)+1] = nGroupIdx
print("sever lien dau chuan bi "..wlls_get_desc(3).."sever")
OpenMission(WLLS_MSID_SCHEDULE)
end
end
if (getn(tbGroup) > 0) then
local szParam = GetPlayerCount().." "..join(tbGroup).." 1" -- 1±íʾÊÇ¿ªÊ¼±¨ÃûºóµÄµÚÒ»´Î� �㱨
LG_ApplyDoScript(0, "", "", "\\script\\leaguematch\\joinmatch.lua", "wlls_GsState", szParam , "", "")
end
end
end
SubWorld = n_oldsub
else
print("Vo lam lien dau giai doan:"..n_phase.."("..n_mid..") ???")
end
end
--ÈÃÖ¸¶¨½ÇÉ«½øÈëÖ¸¶¨·þÎñÆ÷µ Ä×¼±¸³¡£¬¼ÓÈëÖ¸¶¨ÕóÓª
function wlls_player_join(str_playername, n_mtype, n_group, n_mscamp)
_M("wlls_player_join", str_playername, n_mtype, n_group, n_mscamp)
if (GetGlbValue(GLB_WLLS_PHASE) ~= 4) then --ʱ¼äÒѹý
n_group = nil
n_mtype = 1
end
local n_playeridx = SearchPlayer(str_playername)
if (n_playeridx > 0) then
local n_old = PlayerIndex
PlayerIndex = n_playeridx
if n_group then --relayÈÏΪ¿ÉÒÔ½øÈë
if not wlls_en_check() then --¿ç·þʧ°ÜÔõôÅжϣ¿£¿£¿£¡£ ¡£¡
local szResult = n_mtype.." "..n_group.." "..GetName()
LG_ApplyDoScript(0, "", "", "\\script\\leaguematch\\joinmatch.lua", "wlls_onleave", szResult , "", "")
return
end
SetTask(WLLS_TASKID_ORGCAMP, n_mscamp)
--Çå³ý¸½¼Ó״̬
for i = 1, getn(WLLS_FORBID_ITEM) do
RemoveSkillState(WLLS_FORBID_ITEM[i][3])
end
for i = 1, getn(WLLS_FORBID_STATES) do
RemoveSkillState(WLLS_FORBID_STATES[i][2])
end
Msg2Player("Khi vµo khu vùc chuÈn bÞ, vËt phÈm sÏ kh«ng thÓ di chuyÓn, nhng vÉn cã thÓ sö dông trong thanh c«ng cô");
SetRevPos(wlls_get_mapid(1, n_mtype, n_group), 1) --ÖØÉúµãÔÚËùÔÚ±ÈÈü·þÎñÆ÷µÄ» ᳡
local n_mapid = wlls_get_mapid(2, n_mtype, n_group)
_M(n_mapid, "wlls_get_mapid", n_mtype, n_group)
NewWorld(n_mapid, WLLS_MAPPOS_PRE[1], WLLS_MAPPOS_PRE[2])
else --²»ÄܽøÈë
Say(TB_WLLS_JOIN_SAY[n_mtype], 0)
end
PlayerIndex = n_old
end
end
-- ·µ»ØÖ¸¶¨½±Æ·ÐÅÏ¢
function wlls_get_awardinfo(n_type, n_level, n_award)
local str = WLLS_LEVEL_DESC[n_level] .. " (" .. WLLS_TAB[n_type].name .. ")´Î"
local tb_award = WLLS_TAB[n_type].award_rank[n_level]
local n_start, n_end = 1, 1
if (n_award > 1) then
n_start = tb_award[n_award - 1][1] + 1
end
n_end = tb_award[n_award][1]
if (n_start ~= n_end) then
str = str .. n_start .. "~" .. n_end
else
str = str .. n_end
end
str = str .. "½±Àø (" .. tb_award[n_award][3] .. ") "
return str
end
-- ·µ»ØÖ¸¶¨ÅÅÃûÓ¦¸ÃÁìÈ¡µÄ½±Ï î
function wlls_get_rankinfo(tb_award, n_rank)
if (n_rank <= 0) then
return nil
end
local n_award
for i = getn(tb_award), 1, -1 do
if (tb_award[i][1] >= n_rank) then
n_award = i
else
break
end
end
return n_award
end
--²éѯ±¾½ÇÉ«ÒÑÁìÈ¡ÁËʲô½±À ø
function wlls_awardinfo(b_Msg)
local str
local n_got = GetTask(WLLS_TASKID_GOTAWARD)
local n_type = GetByte(n_got, 4)
local n_level = GetByte(n_got, 3)
local n_award = GetByte(n_got, 2)
local n_sid = GetByte(n_got, 1)
if (n_award == 0) then
if (n_sid == 0) then
str = "δÁì¹ý"
else
str = "Ãû´Î" .. n_sid .. "´Ë´ÎÁªÈü£¬Î´ÖªÄÚÈÝ"
end
else
str = "Ãû´Î " .. n_sid .. "´Ë´Î" .. wlls_get_awardinfo(n_type, n_level, n_award)
end
local n_awardex = GetTask(WLLS_TASKID_AWARDEX)
local n_type = GetByte(n_awardex, 4)
local n_level = GetByte(n_awardex, 3)
local n_awarderr= GetByte(n_awardex, 2)
local n_award = GetByte(n_awardex, 1)
if b_Msg then
Msg2Player(str)
end
return str
end
function wlls_reload(bRelay)
LoadScript( "\\script\\missions\\leaguematch\\npc\\officer.lua" )
LoadScript( "\\script\\missions\\leaguematch\\npc\\helper.lua" )
LoadScript( "\\script\\missions\\leaguematch\\npc\\signup.lua" )
LoadScript( "\\script\\missions\\leaguematch\\npc\\housecarl.lu a" )
LoadScript( "\\script\\missions\\leaguematch\\npc\\chefu.lua" )
LoadScript( "\\script\\missions\\leaguematch\\npc\\chuwuxiang.l ua" )
LoadScript( "\\script\\missions\\leaguematch\\npc\\yaoshang.lua" )
LoadScript( "\\script\\missions\\leaguematch\\combat\\mission.l ua" )
LoadScript( "\\script\\missions\\leaguematch\\combat\\playerdea th.lua" )
LoadScript( "\\script\\missions\\leaguematch\\schedule\\newworl d.lua" )
LoadScript( "\\script\\missions\\leaguematch\\schedule\\mission .lua" )
LoadScript( "\\script\\missions\\leaguematch\\schedule\\newworl d.lua" )
LoadScript( "\\script\\missions\\leaguematch\\glbmission\\missi on.lua" )
LoadScript( "\\script\\missions\\leaguematch\\glbmission\\comba t.lua" )
LoadScript( "\\script\\missions\\leaguematch\\glbmission\\sched ule.lua" )
LoadScript( "\\script\\global\\server_playerlevelup.lua" )
LoadScript( "\\script\\global\\login.lua" )
if (bRelay) then
LG_ApplyDoScript(0, "", "", "\\script\\leaguematch\\joinmatch.lua", "ReloadAllScript", "" , "", "")
end
Msg2Player("WLLS file vo lam lien dau "..date())
print("===============WLLS file vo lam lien dau "..date())
end