修游戏中有人退出房间有一处复制漏改
观战时会默认视角为sid最小的人
This commit is contained in:
@@ -433,7 +433,7 @@ end
|
|||||||
--Remove player when leave
|
--Remove player when leave
|
||||||
local function _playerLeaveRoom(uid)
|
local function _playerLeaveRoom(uid)
|
||||||
for i=1,#PLAYERS do if PLAYERS[i].uid==uid then table.remove(PLAYERS,i) break end end
|
for i=1,#PLAYERS do if PLAYERS[i].uid==uid then table.remove(PLAYERS,i) break end end
|
||||||
for i=1,#PLY_ALIVE do if PLY_ALIVE[i].uid==uid then table.remove(PLAYERS,i) break end end
|
for i=1,#PLY_ALIVE do if PLY_ALIVE[i].uid==uid then table.remove(PLY_ALIVE,i) break end end
|
||||||
if uid==USER.uid and SCN.cur=='net_game' then
|
if uid==USER.uid and SCN.cur=='net_game' then
|
||||||
SCN.back()
|
SCN.back()
|
||||||
else
|
else
|
||||||
|
|||||||
@@ -253,6 +253,8 @@ function scene.update(dt)
|
|||||||
for i=1,#NETPLY.list do
|
for i=1,#NETPLY.list do
|
||||||
NETPLY.list[i].readyMode='Playing'
|
NETPLY.list[i].readyMode='Playing'
|
||||||
end
|
end
|
||||||
|
noKey=PLAYERS[1].uid~=USER.uid
|
||||||
|
noTouch=noKey
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user