This commit is contained in:
2025-08-25 23:56:13 +08:00
parent 8c3be0a5bb
commit e0665aae01
15 changed files with 211 additions and 105 deletions

View File

@@ -1,24 +1,24 @@
syntax = "proto3";
package Fantasy.Network.Message;
message RoleGearItemInfo
message UnitGearItemInfo
{
int64 Id = 1; //唯一id
int32 ConfigId = 2; //配置id
}
message RoleGearInfo
message UnitGearInfo
{
RoleGearItemInfo Rod = 1;
RoleGearItemInfo Reel = 2;
RoleGearItemInfo Bobber = 3;
RoleGearItemInfo Hook = 4;
RoleGearItemInfo Bait = 5;
RoleGearItemInfo Lure = 6;
RoleGearItemInfo Weight = 7;
RoleGearItemInfo Line = 8;
RoleGearItemInfo Leader = 9;
RoleGearItemInfo Feeder = 10;
UnitGearItemInfo Rod = 1;
UnitGearItemInfo Reel = 2;
UnitGearItemInfo Bobber = 3;
UnitGearItemInfo Hook = 4;
UnitGearItemInfo Bait = 5;
UnitGearItemInfo Lure = 6;
UnitGearItemInfo Weight = 7;
UnitGearItemInfo Line = 8;
UnitGearItemInfo Leader = 9;
UnitGearItemInfo Feeder = 10;
}
message Vector3Info
@@ -35,7 +35,7 @@ message QuaternionInfo
float w = 4;
}
message RoleFishingInfo
message UnitFishingInfo
{
float LineLength = 1;//线长度
float ReelSpeed = 2;//收线速度
@@ -43,37 +43,51 @@ message RoleFishingInfo
int RodSetting = 4;
}
message RoleStateInfo
message UnitStateInfo
{
int32 State = 1; //状态id
repeated string Args = 2; //状态参数
}
message MapRoleInfo
message MapUnitInfo
{
int64 Id = 1; //用户id
RoleSimpleInfo RoleInfo = 2; //基础信息
MapRolePositionInfo Location = 3; //位置信息
RoleStateInfo State = 4; //状态信息
RoleGearInfo Gears = 5; //钓组数据
RoleFishingInfo FishingInfo = 6; //钓鱼状态信息
MapUnitPositionInfo Location = 3; //位置信息
UnitStateInfo State = 4; //状态信息
UnitGearInfo Gears = 5; //钓组数据
UnitFishingInfo FishingInfo = 6; //钓鱼状态信息
repeated KeyValueInt32 KV = 7; //属性信息
}
message MapRolePositionInfo
message MapUnitPositionInfo
{
Vector3Info Position = 1;
QuaternionInfo Rotation = 2;
}
C2Map_CreateMapRequest // ICustomRouteRequest,Map2C_CreateMapResponse,MapRoute
message C2Map_CreateRoomRequest // ICustomRouteRequest,Map2C_CreateRoomResponse,MapRoute
{
int32 MapId = 1;//地图id
int32 MapId = 1;//房间id
string Password = 2;//进入密码
}
message Map2C_CreateMapResponse // ICustomRouteResponse
message Map2C_CreateRoomResponse // ICustomRouteResponse
{
repeated MapRoleInfo Roles = 1;//地图玩家列表
int32 MapId = 1;//地图id
int64 RoomId = 2;//房间id
}
message C2Map_EnterRoomRequest // ICustomRouteRequest,Map2C_EnterRoomResponse,MapRoute
{
int32 MapId = 1;//房间id
string Password = 2;//进入密码
}
message Map2C_EnterRoomResponse // ICustomRouteResponse
{
int32 MapId = 1;//地图id
int64 RoomId = 2;//房间id
}
message C2Map_EnterMapRequest // ICustomRouteRequest,Map2C_EnterMapResponse,MapRoute
@@ -84,13 +98,14 @@ message C2Map_EnterMapRequest // ICustomRouteRequest,Map2C_EnterMapResponse,MapR
message Map2C_EnterMapResponse // ICustomRouteResponse
{
repeated MapRoleInfo Roles = 1;//地图玩家列表
repeated MapUnitInfo Roles = 1; //地图玩家列表
int64 MapId = 2; //地图id
}
message C2Map_Move // ICustomRouteMessage,MapRoute
{
MapRolePositionInfo Location = 1;
MapUnitPositionInfo Location = 1;
bool IsStop = 2;
}
@@ -98,7 +113,7 @@ message C2Map_Move // ICustomRouteMessage,MapRoute
///用户进入地图
message Map2C_RoleEnterMapNotify // ICustomRouteMessage,MapRoute
{
MapRoleInfo Info = 1;
MapUnitInfo Info = 1;
}
///用户离开地图
@@ -111,26 +126,26 @@ message Map2C_RoleExitMapNotify // ICustomRouteMessage,MapRoute
message Map2C_RoleStateNotify // ICustomRouteMessage,MapRoute
{
int64 Id = 1;
RoleStateInfo State = 2;
UnitStateInfo State = 2;
}
///玩家钓组状态变化
message Map2C_RoleGearStateNotify // ICustomRouteMessage,MapRoute
{
int64 Id = 1;
RoleFishingInfo State = 2;
UnitFishingInfo State = 2;
}
///玩家钓组变化
message Map2C_RoleGearChangeNotify // ICustomRouteMessage,MapRoute
{
int64 Id = 1;
RoleGearInfo Gears = 2; //钓组数据
UnitGearInfo Gears = 2; //钓组数据
}
///玩家位置变化
message Map2C_MoveNotify
{
int64 Id = 1;
MapRolePositionInfo Location = 2;
MapUnitPositionInfo Location = 2;
}

View File

@@ -18,7 +18,11 @@ message KeyValueStringInt64
string Key = 1; //键
int64 Value = 2; //值
}
message KeyValueInt32
{
int32 Key = 1; //键
int32 Value = 2; //值
}
message KeyValueInt64
{
int64 Key = 1; //键

View File

@@ -2,4 +2,5 @@
GateRoute = 1001 // Gate
SocialRoute = 1002 // Social
GameRoute = 1003 // Game
MapRoute = 1004 // Map
MapRoute = 1004 // Map
RoomRoute = 1005 // Room