Files
chuanqi-server/server/s1/LogicServer/data/functions/GlobalMiscExpand/ScriptTimeRun.txt
aixianling 06658f112f init
2024-12-13 13:41:02 +08:00

71 lines
1.6 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

--ScriptTimeConfig中调用的方法放在这里,被全局脚本包含
--#include "data\config\misc\ScriptTimerSystemMsg.txt" once ScriptTImer执行的一些系统公告配置
--重置系统级的一些数据一个服在0点会调用一次
function ResetSysDate()
refreshStore()
System.RefeshWorldLevel()
end
--定时保存文件(商城动态文件)
function SaveFiles()
System.saveFiles()
end
--[[每日清除商城某些ladble的商品数据
0表示是普通的商城1表示限时抢购2-神秘商店3-绑定元宝商城4-职业宗师商店
玩家购买1、3的商品需要每天重置其购买数量
普通的商城:商品不限购
]]
function refreshStore()
System.refreshStore(3) --清空绑定元宝tab页的商品购买数据
System.refreshStore(1) --限时抢购
System.refreshStore(4) --职业宗师商店
end
--周一0点重置
function WeekReset()
end
--更新排行榜
function updateRankData()
System.updateRankData()
end
--每30分钟更新头衔在updateRankData后更新
function updateMaintainTopTitle()
System.CallmaintainTopTitle()
end
--ScriptTimer通用的系统公告
function SystemMsg(id)
id = tonumber(id)
local msgCfg
for i,v in ipairs(ScriptTimerSystemMsgConfig) do
if v.id == id then
msgCfg = v
end
end
if not msgCfg then
return
end
if type(msgCfg.CondFunc) == "function" then
if not msgCfg.CondFunc() then
return
end
end
System.broadcastTipmsg(msgCfg.msg, msgCfg.type)
end
--发送怪的死亡次数到后台
function CountMonsterDeadToLog()
--System.sendMonsterDeadToLog()
end
--发送物品产出统计
function CountItemOutPutToLog()
System.sendItemOutPutToLog()
end