huangyuhao80 1 неделя назад
Родитель
Сommit
5841227fb7
1 измененных файлов с 3 добавлено и 1 удалено
  1. 3 1
      meta/userapi/lua/ActTotalRecharge.lua

+ 3 - 1
meta/userapi/lua/ActTotalRecharge.lua

@@ -38,7 +38,7 @@ function ActTotalRecharge.getData(actor)
38 38
     end
39 39
     -- 结束时间
40 40
     local currTime = getbaseinfo("nowsec")
41
-    if not data.endTime or data.endTime >= currTime then
41
+    if not data.endTime or data.endTime <= currTime then
42 42
         ActTotalRecharge.onEnd(actor)
43 43
 
44 44
         local weekSecs = 3600 * 24 * 7
@@ -46,6 +46,8 @@ function ActTotalRecharge.getData(actor)
46 46
         local weeks = math.floor((currTime - openTimeSec) / weekSecs)
47 47
 
48 48
         data.endTime = openTimeSec + (weeks + 1) * weekSecs
49
+        data.count = 0
50
+        data.rewardList = {}
49 51
 
50 52
         setplaydef(actor, _playerDbKey(), data)
51 53
     end