房间版本开始使用独立版本号

This commit is contained in:
MrZ626
2021-07-10 21:44:24 +08:00
parent 89218c7529
commit 00859ee26b
3 changed files with 3 additions and 9 deletions

View File

@@ -3,6 +3,7 @@ VERSION={
code=1506,
short="V0.15.6",
string="Alpha V0.15.6",
room="V1.0",
name="强化装甲 Reinforced Armor",
}
function love.conf(t)

View File

@@ -310,7 +310,7 @@ function NET.createRoom(roomName,description,capacity,roomType,roomData,password
roomInfo={
name=roomName,
type=roomType,
version=VERSION.short,
version=VERSION.room,
description=description,
},
roomData=roomData,

View File

@@ -9,13 +9,6 @@ local gc_print,gc_printf=gc.print,gc.printf
local NET=NET
local fetchTimer
local compatibleVer={
"V0.15.2",
"V0.15.3",
"V0.15.4",
"V0.15.5",
}
local roomList=WIDGET.newListBox{name="roomList",x=50,y=50,w=800,h=440,lineH=40,drawF=function(item,id,ifSel)
setFont(35)
if ifSel then
@@ -79,7 +72,7 @@ function scene.keyDown(key)
elseif roomList:getLen()>0 and key=="return"then
local R=roomList:getSel()
if NET.getlock('fetchRoom')or not R then return end
if TABLE.find(compatibleVer,R.roomInfo.version)then
if R.roomInfo.version==VERSION.room then
NET.enterRoom(R,passwordBox.value)
else
MES.new('error',"Version doesn't compatible 版本不兼容")