|
楼主 |
发表于 2019-7-1 22:50:22
|
显示全部楼层
在出神龙岛的时候,人一多,反反复复去偷令牌,中间还要等待,很是麻烦。我作了一下修改,实测可用。
lujing.lua
function outSld()
if score.party and score.party=="神龙教" then
exe('ask lu gaoxuan about ling pai')
else
exe('steal lingpai')
end
check_busy(outSldGive)
end
function outSldGive()
wait.make(function()
wait.time(2)
exe('out;#3s;give ling pai to chuan fu')
check_busy(outSldWait,3)
end)
end
function outSldWait()
wait.make(function()
wait.time(6)
locate()
check_busy(outSldCheck)
end)
end
function outSldCheck()
if locl.room=="渡口" then
exe('#3n;enter') ----------------这是公版的内容
return outSld()
else
--cntr1 = countR(20)
return walk_wait()
end
end
function outSldBoat()
if cntr1() < 1 then
return go(road.act)
end
exe('order 开船')
locate()
return check_halt(outSldBoatCheck)
end
function outSldBoatCheck()
if locl.room=="海滩" then
return outSldOver()
else
return checkWait(outSldBoat,3)
end
end
function outSldOver()
walk_wait()
end
用下面红色部分,直接把以上内容盖掉。
function outSld()
if score.party and score.party=="神龙教" then
exe('ask lu gaoxuan about ling pai')
else
exe('steal lingpai')
end
check_busy(outSldGive_test)
end
outSldGive_test=function()
DeleteTriggerGroup("outSldGive_test")
create_trigger_t('outSldGive_test1','^(> )*你给船夫一块通行令牌。','','outSldWait')
SetTriggerOption("outSldGive_test1","group","outSldGive_test")
EnableTriggerGroup("outSldGive_test",true)
outSldGive()
end
outSldGive=function()
exe('out;#3s;give ling pai to chuan fu')
create_timer_s('walkWait4',1.0,'sld_duko_test') -------这里1秒可改成2秒,看自己情况而定。
end
sld_duko_test=function()
exe('give ling pai to chuan fu')
end
function outSldWait()
EnableTriggerGroup("outSldGive_test",false)
EnableTimer('walkWait4',false)
wait.make(function()
wait.time(6)
locate()
check_busy(outSldCheck)
end)
end
function outSldCheck()
if locl.room=="渡口" then
exe('#3n;enter')
return outSld()
else
--cntr1 = countR(20)
return walk_wait()
end
end
function outSldBoat()
if cntr1() < 1 then
return go(road.act)
end
exe('order 开船')
locate()
return check_halt(outSldBoatCheck)
end
function outSldBoatCheck()
if locl.room=="海滩" then
return outSldOver()
else
return checkWait(outSldBoat,3)
end
end
function outSldOver()
walk_wait()
end |
|