房间创建和进入相关逻辑和协议

This commit is contained in:
2025-08-27 00:04:40 +08:00
parent 7325e268ce
commit f6d85a1e0a
45 changed files with 1246 additions and 729 deletions

View File

@@ -3,12 +3,38 @@ using Fantasy.Platform.Net;
namespace NB.Common;
public class SceneConfigHelper
public static class SceneConfigHelper
{
public static SceneConfig GetConfigByRouteType(int routeType)
{
var sceneType = SceneType.Game;
if (routeType == RouteType.GameRoute)
{
sceneType = SceneType.Game;
}
else if (routeType == RouteType.SocialRoute)
{
sceneType = SceneType.Social;
}
else if (routeType == RouteType.MapRoute)
{
sceneType = SceneType.Map;
}
else if (routeType == RouteType.GateRoute)
{
sceneType = SceneType.Gate;
}
return GetConfig(sceneType);
}
public static SceneConfig GetConfig(int sceneType)
{
var gameSceneConfigs = SceneConfigData.Instance.GetSceneBySceneType(sceneType);
return gameSceneConfigs.First();
}
}