Server

一、啟動遊戲服務

啟動配置

客戶端開啟 Tools/命令行配置, 也可參考 Project/Config/LocalAllServer.txt(這是啟動單一服務的配置)

解析配置寫在 Project/Server/App/Program.cs

啟動服務

//啟動遊戲服務 
$ cd {project}
$ bash Start.sh Config/LocalAllServer.txt

//啟動fileServer
$ cd {project}/FileServer
$ dotnet FileServer.dll

二、遊戲服務配置

L: Location, LocationComponent

R: Realm, RealmGateAddressComponent

M: Manager, AppManagerComponent

Gate: GateSessionKeyComponent, PlayerComponent

Map: UnitComponent, ServerFrameComponent, HeartbeatMgrComponent

S: 遊戲服

從 127.0.0.1.txt 配置中可以看到將不同服務給分開配置跟啟動

三、啟動配置內容說明

使用 Visual Studio 啟動的配置是

../Config/StartConfig/LocalAllServer.txt

配置中需要修改ip到自己的機器ip

客戶端連接修改 GlobalProto.txt

修改啟動配置

1.啟動單服配置

2.啟動多服配置

--appId=1 --appType=AllServer --config=../Config/StartConfig/LocalAllServer.txt

Last updated