修复不同设备对局sid不一致

This commit is contained in:
MrZ_26
2022-10-24 14:05:25 +08:00
parent 7953cf735b
commit b0acdce294
3 changed files with 7 additions and 6 deletions

View File

@@ -19,6 +19,7 @@ return{
GAME.modeEnv.task=marginTask
local L=TABLE.shift(NETPLY.list,0)
table.sort(L,function(a,b) return a.uid<b.uid end)
math.randomseed(GAME.seed)
for i=#L,1,-1 do
table.insert(NETPLY.list,table.remove(NETPLY.list,math.random(i)))
@@ -43,5 +44,8 @@ return{
N=N+1
end
end
for i=1,#PLY_ALIVE do
MES.new('info',PLY_ALIVE[i].uid.." "..PLY_ALIVE[i].sid,5)
end
end,
}