运行步骤
启动mongoDB: 命令行下mongod --dbpath [你的数据库目录]启动Server 从VS直接调试:在server.sln项目中直接调试Server.App也可以生成后,从命令行运行Bin目录下的App.dll: dotnet App.dll编辑一个shell脚本去运行 dotnet App.dll,这样才能使用ProcessHelper.Run去启动Server(我的Mac环境下代码ProcessHelper.Run无法找到dotnet,要指定完全路径,想想还是做个shell来得方便。同样的启动数据库也一样)。这样一来需要修改ServerCommandLineEditor.cs中的代码 GUILayout.BeginHorizontal(); if (GUILayout.Button("保存")) { this.Save(); } if (GUILayout.Button("启动")) { string arguments = $"--config={this.fileName}"; ProcessHelper.Run("./App", arguments, "../Bin/"); } if (GUILayout.Button("启动数据库")) { ProcessHelper.Run("mongod", @"--dbpath=db", "../Database/bin/"); } 启动客户端 运行init场景登陆后,鼠标右键点击地图,可以看到人物寻路到目的地点