diff --git a/Assets/Resources/Prefabs/Player/Human_Male.prefab b/Assets/Resources/Prefabs/Player/Human_Male.prefab index a51f21cb0..0275733d5 100644 --- a/Assets/Resources/Prefabs/Player/Human_Male.prefab +++ b/Assets/Resources/Prefabs/Player/Human_Male.prefab @@ -225,7 +225,7 @@ PrefabInstance: objectReference: {fileID: 0} - target: {fileID: -8679921383154817045, guid: 284185ec1f1e5c6409bed7bc27c6c215, type: 3} propertyPath: m_LocalPosition.x - value: 0 + value: 0.215 objectReference: {fileID: 0} - target: {fileID: -8679921383154817045, guid: 284185ec1f1e5c6409bed7bc27c6c215, type: 3} propertyPath: m_LocalPosition.y @@ -2594,8 +2594,8 @@ MonoBehaviour: FeetLengthAdjust: 0 baseTransform: {fileID: 0} Hips: {fileID: 2121359798269357256} - ScaleReferenceMode: 3 - finalScaleReference: 0.9072804 + ScaleReferenceMode: 1 + finalScaleReference: 0.85559285 finalScaleReferenceSqrt: 0.1 customScaleReferenceValue: 0.5 DelayedInitialization: 0 diff --git a/Assets/Resources/config/ConfigAssets.asset b/Assets/Resources/config/ConfigAssets.asset index a1f78b2ce..14bd62c5f 100644 --- a/Assets/Resources/config/ConfigAssets.asset +++ b/Assets/Resources/config/ConfigAssets.asset @@ -12,3 +12,331 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 3d8691ef03f74aedb6cfd67e53cf664f, type: 3} m_Name: ConfigAssets m_EditorClassIdentifier: + BaitConfigArr: + - id: 500001 + modelPath: baits/worm_01/worm_01 + group: 0 + type: 0 + acceptFish: + weightFishAccept: {x: 0, y: 3} + weight: 2.5 + lenght: 0 + amount: 1 + Level: 1 + - id: 500002 + modelPath: baits/fly/fly + group: 0 + type: 0 + acceptFish: + weightFishAccept: {x: 0, y: 3} + weight: 2.5 + lenght: 0 + amount: 1 + Level: 1 + - id: 500003 + modelPath: baits/black_leech/black_leech + group: 0 + type: 0 + acceptFish: + weightFishAccept: {x: 0, y: 3} + weight: 2.5 + lenght: 0 + amount: 1 + Level: 1 + - id: 500004 + modelPath: baits/bread/bread + group: 0 + type: 0 + acceptFish: + weightFishAccept: {x: 0, y: 3} + weight: 2.5 + lenght: 0 + amount: 1 + Level: 1 + BobberConfigArr: + - id: 300001 + modelPath: bobbers/expressfishing/bob_25003/bob_25003 + group: 0 + type: 2 + weight: 0.5 + displacement: 3 + isNightLight: 0 + Level: 1 + amount: 1 + - id: 300002 + modelPath: bobbers/expressfishing/bob_25162_25163/bob_25162 + group: 0 + type: 0 + weight: 0.8 + displacement: 3 + isNightLight: 0 + Level: 1 + amount: 1 + - id: 300003 + modelPath: bobbers/expressfishing/bob_25166_25167/bob_25166 + group: 0 + type: 0 + weight: 0.8 + displacement: 3 + isNightLight: 0 + Level: 1 + amount: 1 + - id: 300004 + modelPath: bobbers/expressfishing/bob_25001/bob_25001 + group: 0 + type: 0 + weight: 0.8 + displacement: 3 + isNightLight: 0 + Level: 1 + amount: 1 + FeederConfigArr: + - id: 900001 + modelPath: Feeders/Feeder 1/FeedTrash 1 + group: 0 + type: 0 + weight: 5 + capacity: 100 + Level: 1 + amount: 1 + FishAcceptConfigArr: + - id: 2100001 + bait: 500189 + min: 0.3 + max: 26 + - id: 2100001 + bait: 500135 + min: 0.3 + max: 25 + FishConfigArr: + - id: 2200001 + speciesName: 10 + isEnabled: 1 + type: 0 + maxWeight: 34 + speciesCoins: 4 + rankingPoint: 1 + modelPath: + - Burbot_B + imagePath: [] + modelTrophyPath: [] + weightLenghtValues: [] + weightLengthCurve: + serializedVersion: 2 + m_Curve: [] + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + acceptFishBaits: [] + acceptFishLures: [] + - id: 2200002 + speciesName: 11 + isEnabled: 1 + type: 0 + maxWeight: 40 + speciesCoins: 4 + rankingPoint: 1 + modelPath: + - CarpCommon_B + imagePath: [] + modelTrophyPath: [] + weightLenghtValues: [] + weightLengthCurve: + serializedVersion: 2 + m_Curve: [] + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + acceptFishBaits: [] + acceptFishLures: [] + - id: 2200003 + speciesName: 14 + isEnabled: 1 + type: 0 + maxWeight: 45 + speciesCoins: 4 + rankingPoint: 1 + modelPath: + - CarpGrass_B + imagePath: [] + modelTrophyPath: [] + weightLenghtValues: [] + weightLengthCurve: + serializedVersion: 2 + m_Curve: [] + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + acceptFishBaits: [] + acceptFishLures: [] + - id: 2200004 + speciesName: 16 + isEnabled: 1 + type: 0 + maxWeight: 3 + speciesCoins: 4 + rankingPoint: 1 + modelPath: + - CarpCrucian_B + imagePath: [] + modelTrophyPath: [] + weightLenghtValues: [] + weightLengthCurve: + serializedVersion: 2 + m_Curve: [] + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + acceptFishBaits: [] + acceptFishLures: [] + HookConfigArr: + - id: 700001 + modelPath: hooks/alliance/c_hook_20789_20794/c_hook_20789 + group: 0 + color: Nickel + type: 1 + zadzior: 1 + size: 1 + amount: 1 + Level: 1 + - id: 700102 + modelPath: hooks/berserk_hooks/triple_20569_20577/triple_20569 + group: 0 + color: Nickel + type: 1 + zadzior: 1 + size: 1 + amount: 1 + Level: 1 + LeadersConfigArr: [] + LineConfigArr: + - id: 400001 + modelPath: Lines/UFE Mono/UFE monoClear + group: 0 + type: 0 + length: 75 + strength: 1.51 + size: 0.12 + Level: 1 + - id: 400002 + modelPath: Lines/UFE Mono/UFE monoClear + group: 0 + type: 0 + length: 75 + strength: 2.51 + size: 0.16 + Level: 1 + LureConfigArr: + - id: 600001 + modelPath: lures/express_fishing/crankbaits_1/775/crankbaits_775 + group: 0 + type: 0 + acceptFish: + weightFishAccept: {x: 0, y: 3} + weight: 5.3 + lenght: 80 + amount: 0 + Level: 1 + hook: c6ae0a00 + - id: 600002 + modelPath: lures/express_fishing/poppers_1/poppers_590/poppers_590 + group: 0 + type: 0 + acceptFish: + weightFishAccept: {x: 0, y: 3} + weight: 5.3 + lenght: 80 + amount: 0 + Level: 1 + hook: c6ae0a00 + - id: 600003 + modelPath: lures/express_fishing/softplastic/ef_supergrab_6/softplastic_g_1622 + group: 0 + type: 0 + acceptFish: + weightFishAccept: {x: 0, y: 3} + weight: 5.3 + lenght: 80 + amount: 0 + Level: 1 + hook: + - id: 600004 + modelPath: lures/express_fishing/softplastic/ef_superminnow_6/softplastic_m_1634 + group: 0 + type: 0 + acceptFish: + weightFishAccept: {x: 0, y: 3} + weight: 5.3 + lenght: 80 + amount: 0 + Level: 1 + hook: + ReelConfigArr: + - id: 200001 + modelPath: reels/syberia/spin_5002/spin_5002 + group: 0 + type: 0 + strength: 3 + gearRatio: {x: 6.2, y: 1} + size: 2000 + Level: 1 + - id: 200002 + modelPath: reels/syberia/spin_5036/spin_5036 + group: 0 + type: 0 + strength: 4.5 + gearRatio: {x: 6.2, y: 1} + size: 2000 + Level: 1 + RingConfigArr: + - id: 1100001 + modelPath: rod_rings/rumoi/rumoi_oxiline_spin + group: 0 + - id: 1100002 + modelPath: rod_rings/smt/smt_pure_ceramic_bolo + group: 0 + RodConfigArr: + - id: 100001 + modelPath: rods/syberia/tele_10037/tele_10037_t13 + group: 0 + type: 1 + length: 3,7 + weight: 250 + strength: 40.82 + maxRange: 67 + ring: 0 + - id: 100002 + modelPath: rods/syberia/bolo_10021/bolo_10021_LB400 + group: 0 + type: 0 + length: 2,5 + weight: 120 + strength: 1.59 + maxRange: 30 + ring: 1100002 + - id: 100003 + modelPath: rods/syberia/spin_10034/spin_10034_S60H + group: 0 + type: 0 + length: 2,5 + weight: 120 + strength: 1.59 + maxRange: 30 + ring: 1100001 + UnitConfigArr: + - id: 310001 + Type: 1 + - id: 310002 + Type: 2 + - id: 310003 + Type: 3 + - id: 310004 + Type: 4 + WeightConfigArr: + - id: 800001 + modelPath: Weights/Weight2_5g + group: 0 + type: 0 + weight: 3 + Level: 1 + amount: 1 diff --git a/Assets/Scripts/Configs/Mem/ConfigBase.cs b/Assets/Scripts/Configs/Mem/ConfigBase.cs index 6c0934d5e..88acd92e0 100644 --- a/Assets/Scripts/Configs/Mem/ConfigBase.cs +++ b/Assets/Scripts/Configs/Mem/ConfigBase.cs @@ -18,8 +18,6 @@ namespace NBF [Serializable] public abstract class ConfigBase { - public string name; - public int id; } diff --git a/Assets/Scripts/Fishing2/Helper/ProtoHelper.cs b/Assets/Scripts/Fishing2/Helper/ProtoHelper.cs index bece7b9ee..0922b3380 100644 --- a/Assets/Scripts/Fishing2/Helper/ProtoHelper.cs +++ b/Assets/Scripts/Fishing2/Helper/ProtoHelper.cs @@ -12,7 +12,7 @@ namespace NBF.Fishing2 MapUnitInfo mapUnit = new MapUnitInfo(); mapUnit.Id = self.RoleId; mapUnit.RoleInfo = self.ToSimpleInfo(); - mapUnit.Gears = self.Gears; + // mapUnit.Gears = self.Gears; return mapUnit; } diff --git a/Assets/Scripts/Fishing2/Unit/Move/CharacterControllerComponent.cs b/Assets/Scripts/Fishing2/Unit/Move/CharacterControllerComponent.cs index 48dade45a..fd4f24583 100644 --- a/Assets/Scripts/Fishing2/Unit/Move/CharacterControllerComponent.cs +++ b/Assets/Scripts/Fishing2/Unit/Move/CharacterControllerComponent.cs @@ -289,14 +289,12 @@ namespace NBF.Fishing2 private void StartMovement(MoveState moveState) { targetPosition = moveState.startPosition; - PlayerAsset.InputMagnitude = 0.5f; Debug.Log($"开始移动 - 位置: {moveState.startPosition}"); } private void StopMovement(MoveState moveState) { targetPosition = moveState.startPosition; - PlayerAsset.InputMagnitude = 0; Debug.Log($"停止移动 - 最终位置: {moveState.startPosition}"); } @@ -344,6 +342,8 @@ namespace NBF.Fishing2 Vector3 totalMovement = currentVelocity * Time.deltaTime; totalMovement.y = verticalVelocity * Time.deltaTime; + Log.Info($"移动=== Id={Parent.Id} 位置: {characterController.transform.position} 移动量: {totalMovement}"); + characterController.Move(totalMovement); } @@ -351,14 +351,13 @@ namespace NBF.Fishing2 private void InterpolatePositionAndRotation() { // 只对非本地玩家进行插值 - var mapUnit = Parent as MapUnit; - if (!mapUnit.IsSelf()) + if (!IsSelf) { // 插值位置 - characterController.transform.position = Vector3.Lerp( - characterController.transform.position, - targetPosition, - positionLerpSpeed * Time.deltaTime); + // characterController.transform.position = Vector3.Lerp( + // characterController.transform.position, + // targetPosition, + // positionLerpSpeed * Time.deltaTime); // 插值旋转 - 使用更平滑的插值方法 characterController.transform.rotation = Quaternion.Slerp( diff --git a/Assets/Scripts/Generate/NetworkProtocol/CommonProtoData.cs b/Assets/Scripts/Generate/NetworkProtocol/CommonProtoData.cs index 4d3c9abf0..d0ec126b8 100644 --- a/Assets/Scripts/Generate/NetworkProtocol/CommonProtoData.cs +++ b/Assets/Scripts/Generate/NetworkProtocol/CommonProtoData.cs @@ -82,12 +82,12 @@ namespace NBC BaseInfo = default; RoleId = default; Items.Clear(); + ItemBinds.Clear(); Fishs.Clear(); Activities.Clear(); Currency.Clear(); Slots.Clear(); Skills.Clear(); - Gears.Clear(); MapId = default; #if FANTASY_NET || FANTASY_UNITY GetScene().MessagePoolComponent.Return(this); @@ -100,17 +100,17 @@ namespace NBC [ProtoMember(3)] public List Items = new List(); [ProtoMember(4)] - public List Fishs = new List(); + public List ItemBinds = new List(); [ProtoMember(5)] - public List Activities = new List(); + public List Fishs = new List(); [ProtoMember(6)] - public List Currency = new List(); + public List Activities = new List(); [ProtoMember(7)] - public List Slots = new List(); + public List Currency = new List(); [ProtoMember(8)] - public List Skills = new List(); + public List Slots = new List(); [ProtoMember(9)] - public List Gears = new List(); + public List Skills = new List(); [ProtoMember(10)] public int MapId { get; set; } } @@ -199,6 +199,29 @@ namespace NBC public int Count { get; set; } } /// + /// 玩家当前使用钓组信息 + /// + [ProtoContract] + public partial class ItemBindInfo : AMessage, IProto + { + public static ItemBindInfo Create(Scene scene) + { + return scene.MessagePoolComponent.Rent(); + } + public override void Dispose() + { + Item = default; + BindItems.Clear(); +#if FANTASY_NET || FANTASY_UNITY + GetScene().MessagePoolComponent.Return(this); +#endif + } + [ProtoMember(1)] + public long Item { get; set; } + [ProtoMember(2)] + public List BindItems = new List(); + } + /// /// 物品信息 /// [ProtoContract] diff --git a/Assets/Scripts/Generate/NetworkProtocol/GameMessage.cs b/Assets/Scripts/Generate/NetworkProtocol/GameMessage.cs index b63f5ca3c..d1129c55b 100644 --- a/Assets/Scripts/Generate/NetworkProtocol/GameMessage.cs +++ b/Assets/Scripts/Generate/NetworkProtocol/GameMessage.cs @@ -9,4 +9,304 @@ using NBC.Serialize; namespace NBC { + /// + /// /////////// ******** 物品信息 *******///////////// + /// + /// + /// 请求背包列表 + /// + [ProtoContract] + public partial class C2Game_GetItemsRequest : AMessage, ICustomRouteRequest, IProto + { + public static C2Game_GetItemsRequest Create(Scene scene) + { + return scene.MessagePoolComponent.Rent(); + } + public override void Dispose() + { +#if FANTASY_NET || FANTASY_UNITY + GetScene().MessagePoolComponent.Return(this); +#endif + } + [ProtoIgnore] + public Game2C_GetItemsResponse ResponseType { get; set; } + public uint OpCode() { return OuterOpcode.C2Game_GetItemsRequest; } + [ProtoIgnore] + public int RouteType => Fantasy.RouteType.GameRoute; + } + /// + /// 请求背包列表响应 + /// + [ProtoContract] + public partial class Game2C_GetItemsResponse : AMessage, ICustomRouteResponse, IProto + { + public static Game2C_GetItemsResponse Create(Scene scene) + { + return scene.MessagePoolComponent.Rent(); + } + public override void Dispose() + { + ErrorCode = default; + Items.Clear(); + Rigs.Clear(); +#if FANTASY_NET || FANTASY_UNITY + GetScene().MessagePoolComponent.Return(this); +#endif + } + public uint OpCode() { return OuterOpcode.Game2C_GetItemsResponse; } + [ProtoMember(1)] + public List Items = new List(); + [ProtoMember(2)] + public List Rigs = new List(); + [ProtoMember(3)] + public uint ErrorCode { get; set; } + } + /// + /// 请求使用物品 + /// + [ProtoContract] + public partial class C2Game_UseItemRequest : AMessage, ICustomRouteRequest, IProto + { + public static C2Game_UseItemRequest Create(Scene scene) + { + return scene.MessagePoolComponent.Rent(); + } + public override void Dispose() + { +#if FANTASY_NET || FANTASY_UNITY + GetScene().MessagePoolComponent.Return(this); +#endif + } + [ProtoIgnore] + public Game2C_UseItemResponse ResponseType { get; set; } + public uint OpCode() { return OuterOpcode.C2Game_UseItemRequest; } + [ProtoIgnore] + public int RouteType => Fantasy.RouteType.GameRoute; + } + /// + /// 请求使用物品响应 + /// + [ProtoContract] + public partial class Game2C_UseItemResponse : AMessage, ICustomRouteResponse, IProto + { + public static Game2C_UseItemResponse Create(Scene scene) + { + return scene.MessagePoolComponent.Rent(); + } + public override void Dispose() + { + ErrorCode = default; +#if FANTASY_NET || FANTASY_UNITY + GetScene().MessagePoolComponent.Return(this); +#endif + } + public uint OpCode() { return OuterOpcode.Game2C_UseItemResponse; } + [ProtoMember(1)] + public uint ErrorCode { get; set; } + } + /// + /// 物品变化 + /// + [ProtoContract] + public partial class Game2C_ItemChange : AMessage, ICustomRouteMessage, IProto + { + public static Game2C_ItemChange Create(Scene scene) + { + return scene.MessagePoolComponent.Rent(); + } + public override void Dispose() + { + Type = default; + Items.Clear(); + Removes.Clear(); +#if FANTASY_NET || FANTASY_UNITY + GetScene().MessagePoolComponent.Return(this); +#endif + } + public uint OpCode() { return OuterOpcode.Game2C_ItemChange; } + [ProtoIgnore] + public int RouteType => Fantasy.RouteType.GameRoute; + [ProtoMember(1)] + public int Type { get; set; } + [ProtoMember(2)] + public List Items = new List(); + [ProtoMember(3)] + public List Removes = new List(); + } + /// + /// /////////// ******** 鱼护 *******///////////// + /// + /// + /// 请求鱼护列表 + /// + [ProtoContract] + public partial class C2Game_GetFishsRequest : AMessage, ICustomRouteRequest, IProto + { + public static C2Game_GetFishsRequest Create(Scene scene) + { + return scene.MessagePoolComponent.Rent(); + } + public override void Dispose() + { +#if FANTASY_NET || FANTASY_UNITY + GetScene().MessagePoolComponent.Return(this); +#endif + } + [ProtoIgnore] + public Game2C_GetFishsResponse ResponseType { get; set; } + public uint OpCode() { return OuterOpcode.C2Game_GetFishsRequest; } + [ProtoIgnore] + public int RouteType => Fantasy.RouteType.GameRoute; + } + /// + /// 请求鱼护列表响应 + /// + [ProtoContract] + public partial class Game2C_GetFishsResponse : AMessage, ICustomRouteResponse, IProto + { + public static Game2C_GetFishsResponse Create(Scene scene) + { + return scene.MessagePoolComponent.Rent(); + } + public override void Dispose() + { + ErrorCode = default; + Fishs.Clear(); +#if FANTASY_NET || FANTASY_UNITY + GetScene().MessagePoolComponent.Return(this); +#endif + } + public uint OpCode() { return OuterOpcode.Game2C_GetFishsResponse; } + [ProtoMember(1)] + public List Fishs = new List(); + [ProtoMember(2)] + public uint ErrorCode { get; set; } + } + /// + /// 鱼护变化 + /// + [ProtoContract] + public partial class Game2C_FishChange : AMessage, ICustomRouteMessage, IProto + { + public static Game2C_FishChange Create(Scene scene) + { + return scene.MessagePoolComponent.Rent(); + } + public override void Dispose() + { + Type = default; + Fishs.Clear(); + Removes.Clear(); +#if FANTASY_NET || FANTASY_UNITY + GetScene().MessagePoolComponent.Return(this); +#endif + } + public uint OpCode() { return OuterOpcode.Game2C_FishChange; } + [ProtoIgnore] + public int RouteType => Fantasy.RouteType.GameRoute; + [ProtoMember(1)] + public int Type { get; set; } + [ProtoMember(2)] + public List Fishs = new List(); + [ProtoMember(3)] + public List Removes = new List(); + } + /// + /// 请求出售 + /// + [ProtoContract] + public partial class C2Game_SellFishRequest : AMessage, ICustomRouteRequest, IProto + { + public static C2Game_SellFishRequest Create(Scene scene) + { + return scene.MessagePoolComponent.Rent(); + } + public override void Dispose() + { + Ids.Clear(); +#if FANTASY_NET || FANTASY_UNITY + GetScene().MessagePoolComponent.Return(this); +#endif + } + [ProtoIgnore] + public Game2C_SellFishResponse ResponseType { get; set; } + public uint OpCode() { return OuterOpcode.C2Game_SellFishRequest; } + [ProtoIgnore] + public int RouteType => Fantasy.RouteType.GameRoute; + [ProtoMember(1)] + public List Ids = new List(); + } + /// + /// 请求出售响应 + /// + [ProtoContract] + public partial class Game2C_SellFishResponse : AMessage, ICustomRouteResponse, IProto + { + public static Game2C_SellFishResponse Create(Scene scene) + { + return scene.MessagePoolComponent.Rent(); + } + public override void Dispose() + { + ErrorCode = default; + Awards.Clear(); +#if FANTASY_NET || FANTASY_UNITY + GetScene().MessagePoolComponent.Return(this); +#endif + } + public uint OpCode() { return OuterOpcode.Game2C_SellFishResponse; } + [ProtoMember(1)] + public List Awards = new List(); + [ProtoMember(2)] + public uint ErrorCode { get; set; } + } + /// + /// /////////// ******** 商店 *******///////////// + /// + /// + /// 请求购买 + /// + [ProtoContract] + public partial class C2Game_BuyRequest : AMessage, ICustomRouteRequest, IProto + { + public static C2Game_BuyRequest Create(Scene scene) + { + return scene.MessagePoolComponent.Rent(); + } + public override void Dispose() + { +#if FANTASY_NET || FANTASY_UNITY + GetScene().MessagePoolComponent.Return(this); +#endif + } + [ProtoIgnore] + public Game2C_GetFishsResponse ResponseType { get; set; } + public uint OpCode() { return OuterOpcode.C2Game_BuyRequest; } + [ProtoIgnore] + public int RouteType => Fantasy.RouteType.GameRoute; + } + /// + /// 请求购买响应 + /// + [ProtoContract] + public partial class Game2C_BuyResponse : AMessage, ICustomRouteResponse, IProto + { + public static Game2C_BuyResponse Create(Scene scene) + { + return scene.MessagePoolComponent.Rent(); + } + public override void Dispose() + { + ErrorCode = default; + Awards.Clear(); +#if FANTASY_NET || FANTASY_UNITY + GetScene().MessagePoolComponent.Return(this); +#endif + } + public uint OpCode() { return OuterOpcode.Game2C_BuyResponse; } + [ProtoMember(1)] + public List Awards = new List(); + [ProtoMember(2)] + public uint ErrorCode { get; set; } + } } diff --git a/Assets/Scripts/Generate/NetworkProtocol/OuterOpcode.cs b/Assets/Scripts/Generate/NetworkProtocol/OuterOpcode.cs index 16493aacf..5d4482248 100644 --- a/Assets/Scripts/Generate/NetworkProtocol/OuterOpcode.cs +++ b/Assets/Scripts/Generate/NetworkProtocol/OuterOpcode.cs @@ -2,61 +2,73 @@ namespace Fantasy { public static partial class OuterOpcode { - public const uint C2Map_CreateRoomRequest = 2281711377; - public const uint Map2C_CreateRoomResponse = 2415929105; + public const uint C2Game_GetItemsRequest = 2281711377; + public const uint Game2C_GetItemsResponse = 2415929105; + public const uint C2Game_UseItemRequest = 2281711378; + public const uint Game2C_UseItemResponse = 2415929106; + public const uint Game2C_ItemChange = 2147493649; + public const uint C2Game_GetFishsRequest = 2281711379; + public const uint Game2C_GetFishsResponse = 2415929107; + public const uint Game2C_FishChange = 2147493650; + public const uint C2Game_SellFishRequest = 2281711380; + public const uint Game2C_SellFishResponse = 2415929108; + public const uint C2Game_BuyRequest = 2281711381; + public const uint Game2C_BuyResponse = 2415929109; + public const uint C2Map_CreateRoomRequest = 2281711382; + public const uint Map2C_CreateRoomResponse = 2415929110; public const uint C2G_ExitRoomRequest = 268445457; public const uint G2C_ExitRoomResponse = 402663185; public const uint C2G_EnterMapRequest = 268445458; public const uint G2C_EnterMapResponse = 402663186; - public const uint Map2C_ChangeMap = 2147493649; + public const uint Map2C_ChangeMap = 2147493651; public const uint C2A_LoginRequest = 268445459; public const uint A2C_LoginResponse = 402663187; public const uint C2G_LoginRequest = 268445460; public const uint G2C_LoginResponse = 402663188; public const uint G2C_RepeatLogin = 134227729; - public const uint C2Game_GetRoleInfoRequest = 2281711378; - public const uint Game2C_GetRoleInfoResponse = 2415929106; - public const uint Map2C_RoleEnterRoomNotify = 2147493650; - public const uint Map2C_RoleExitRoomNotify = 2147493651; - public const uint C2Map_RolePropertyChange = 2147493652; - public const uint Map2C_RoleStateNotify = 2147493653; - public const uint Map2C_RoleGearChangeNotify = 2147493654; - public const uint Map2C_RolePropertyChangeNotify = 2147493655; - public const uint C2Map_Move = 2147493656; - public const uint C2Map_Look = 2147493657; - public const uint Map2C_MoveNotify = 2147493658; - public const uint Map2C_LookeNotify = 2147493659; - public const uint C2S_GetConversationsRequest = 2281711379; - public const uint S2C_GetConversationsResponse = 2415929107; - public const uint C2S_SendMailRequest = 2281711380; - public const uint S2C_SendMailResponse = 2415929108; - public const uint C2S_DeleteMailRequest = 2281711381; - public const uint S2C_DeleteMailResponse = 2415929109; - public const uint S2C_HaveMail = 2147493660; - public const uint S2C_MailState = 2147493661; - public const uint C2S_CreateChannelRequest = 2281711382; - public const uint S2C_CreateChannelResponse = 2415929110; - public const uint C2S_JoinChannelRequest = 2281711383; - public const uint S2C_JoinChannelResponse = 2415929111; - public const uint C2S_SendMessageRequest = 2281711384; - public const uint S2C_SendMessageResponse = 2415929112; - public const uint S2C_Message = 2147493662; - public const uint C2S_CreateClubRequest = 2281711385; - public const uint S2C_CreateClubResponse = 2415929113; - public const uint C2S_GetClubInfoRequest = 2281711386; - public const uint S2C_GetClubInfoResponse = 2415929114; - public const uint C2S_GetMemberListRequest = 2281711387; - public const uint S2C_GetMemberListResponse = 2415929115; - public const uint C2S_GetClubListRequest = 2281711388; - public const uint S2C_GetClubListResponse = 2415929116; - public const uint C2S_JoinClubRequest = 2281711389; - public const uint S2C_JoinClubResponse = 2415929117; - public const uint C2S_LeaveClubRequest = 2281711390; - public const uint S2C_LeaveClubResponse = 2415929118; - public const uint C2S_DissolveClubRequest = 2281711391; - public const uint S2C_DissolveClubResponse = 2415929119; - public const uint C2S_DisposeJoinRequest = 2281711392; - public const uint S2C_DisposeJoinResponse = 2415929120; - public const uint S2C_ClubChange = 2147493663; + public const uint C2Game_GetRoleInfoRequest = 2281711383; + public const uint Game2C_GetRoleInfoResponse = 2415929111; + public const uint Map2C_RoleEnterRoomNotify = 2147493652; + public const uint Map2C_RoleExitRoomNotify = 2147493653; + public const uint C2Map_RolePropertyChange = 2147493654; + public const uint Map2C_RoleStateNotify = 2147493655; + public const uint Map2C_RoleGearChangeNotify = 2147493656; + public const uint Map2C_RolePropertyChangeNotify = 2147493657; + public const uint C2Map_Move = 2147493658; + public const uint C2Map_Look = 2147493659; + public const uint Map2C_MoveNotify = 2147493660; + public const uint Map2C_LookeNotify = 2147493661; + public const uint C2S_GetConversationsRequest = 2281711384; + public const uint S2C_GetConversationsResponse = 2415929112; + public const uint C2S_SendMailRequest = 2281711385; + public const uint S2C_SendMailResponse = 2415929113; + public const uint C2S_DeleteMailRequest = 2281711386; + public const uint S2C_DeleteMailResponse = 2415929114; + public const uint S2C_HaveMail = 2147493662; + public const uint S2C_MailState = 2147493663; + public const uint C2S_CreateChannelRequest = 2281711387; + public const uint S2C_CreateChannelResponse = 2415929115; + public const uint C2S_JoinChannelRequest = 2281711388; + public const uint S2C_JoinChannelResponse = 2415929116; + public const uint C2S_SendMessageRequest = 2281711389; + public const uint S2C_SendMessageResponse = 2415929117; + public const uint S2C_Message = 2147493664; + public const uint C2S_CreateClubRequest = 2281711390; + public const uint S2C_CreateClubResponse = 2415929118; + public const uint C2S_GetClubInfoRequest = 2281711391; + public const uint S2C_GetClubInfoResponse = 2415929119; + public const uint C2S_GetMemberListRequest = 2281711392; + public const uint S2C_GetMemberListResponse = 2415929120; + public const uint C2S_GetClubListRequest = 2281711393; + public const uint S2C_GetClubListResponse = 2415929121; + public const uint C2S_JoinClubRequest = 2281711394; + public const uint S2C_JoinClubResponse = 2415929122; + public const uint C2S_LeaveClubRequest = 2281711395; + public const uint S2C_LeaveClubResponse = 2415929123; + public const uint C2S_DissolveClubRequest = 2281711396; + public const uint S2C_DissolveClubResponse = 2415929124; + public const uint C2S_DisposeJoinRequest = 2281711397; + public const uint S2C_DisposeJoinResponse = 2415929125; + public const uint S2C_ClubChange = 2147493665; } } diff --git a/Assets/Scripts/Generate/NetworkProtocol/RoomMessage.cs b/Assets/Scripts/Generate/NetworkProtocol/RoomMessage.cs index 4370832e4..56c73cf38 100644 --- a/Assets/Scripts/Generate/NetworkProtocol/RoomMessage.cs +++ b/Assets/Scripts/Generate/NetworkProtocol/RoomMessage.cs @@ -225,6 +225,7 @@ namespace NBC Rotation = default; Direction = default; IsStop = default; + IsRun = default; Timestamp = default; #if FANTASY_NET || FANTASY_UNITY GetScene().MessagePoolComponent.Return(this); @@ -244,6 +245,8 @@ namespace NBC [ProtoMember(5)] public bool IsStop { get; set; } [ProtoMember(6)] + public bool IsRun { get; set; } + [ProtoMember(7)] public long Timestamp { get; set; } } /// diff --git a/Assets/Scripts/Model/Assets/PlayerAsset.cs b/Assets/Scripts/Model/Assets/PlayerAsset.cs index 885f673ab..45d7c6b6b 100644 --- a/Assets/Scripts/Model/Assets/PlayerAsset.cs +++ b/Assets/Scripts/Model/Assets/PlayerAsset.cs @@ -29,33 +29,6 @@ namespace NBF #region 动画 #region 参数定义 - private static readonly int InputHorizontalHash = Animator.StringToHash("InputHorizontal"); - private static readonly int InputVerticalHash = Animator.StringToHash("InputVertical"); - private static readonly int InputMagnitudeHash = Animator.StringToHash("InputMagnitude"); - private static readonly int IsSprintingHash = Animator.StringToHash("IsSprinting"); - public float InputHorizontal - { - get => Animator.GetFloat(InputHorizontalHash); - set => Animator.SetFloat(InputHorizontalHash, value); - } - public float InputVertical - { - get => Animator.GetFloat(InputVerticalHash); - set => Animator.SetFloat(InputVerticalHash, value); - } - public float InputMagnitude - { - get => Animator.GetFloat(InputMagnitudeHash); - set => Animator.SetFloat(InputMagnitudeHash, value); - } - public bool IsSprinting - { - get => Animator.GetBool(IsSprintingHash); - set => Animator.SetBool(IsSprintingHash, value); - } - - - diff --git a/Assets/Scripts/Model/Net/Net.cs b/Assets/Scripts/Model/Net/Net.cs index f488db1e7..f1d6d912b 100644 --- a/Assets/Scripts/Model/Net/Net.cs +++ b/Assets/Scripts/Model/Net/Net.cs @@ -39,6 +39,7 @@ namespace NBF private static void OnConnectComplete() { Log.Debug("连接成功"); + // 心跳 Session.AddComponent().Start(HeartbeatInterval); } diff --git a/Config/fishing gear-渔具.xlsx b/Config/fishing gear-渔具.xlsx index e1fb0f36b..f9ed12d9a 100644 Binary files a/Config/fishing gear-渔具.xlsx and b/Config/fishing gear-渔具.xlsx differ diff --git a/Config/~$fishing gear-渔具.xlsx b/Config/~$fishing gear-渔具.xlsx new file mode 100644 index 000000000..fd5ec1854 Binary files /dev/null and b/Config/~$fishing gear-渔具.xlsx differ diff --git a/Fishing2.sln.DotSettings.user b/Fishing2.sln.DotSettings.user index 693d08ffe..0f7534b34 100644 --- a/Fishing2.sln.DotSettings.user +++ b/Fishing2.sln.DotSettings.user @@ -31,6 +31,7 @@ ForceIncluded ForceIncluded ForceIncluded + ForceIncluded ForceIncluded ForceIncluded <AssemblyExplorer> diff --git a/UserSettings/EditorUserSettings.asset b/UserSettings/EditorUserSettings.asset index 17674f295..201b361f7 100644 --- a/UserSettings/EditorUserSettings.asset +++ b/UserSettings/EditorUserSettings.asset @@ -9,32 +9,32 @@ EditorUserSettings: value: 18134705175a055722080a3115371d4a0d55006876786860616b0471b8b07a68ffab74f9ee2a3a30300cea1a11320d0beb1a0c25f7060f494b4cc80018eb09361fc211cb1f862d19c51d19dcc413d6ade0d8ddfcddf9f4d9d29195fcfde6ebeae6f0a9c9afa6f8c5b89ff7a1aacececac4eba4d7c9d28bda flags: 0 RecentlyUsedSceneGuid-0: - value: 57030605040158595e085f7745760e441416492f7a7d27617c704f64e4e46d60 - flags: 0 - RecentlyUsedSceneGuid-1: value: 07070052520d08590b5b5f7149200744474f4e7d7d2c7067757e4d6ae0e3673a flags: 0 - RecentlyUsedSceneGuid-2: + RecentlyUsedSceneGuid-1: value: 5457515604055e5d5c5f5a2012270d44444e4d73742a7e637f2c1f65b3b7603c flags: 0 - RecentlyUsedSceneGuid-3: + RecentlyUsedSceneGuid-2: value: 51500d5451575a5a545655754173594415164f727b2a7e67797c1b6bb4e2303e flags: 0 - RecentlyUsedSceneGuid-4: + RecentlyUsedSceneGuid-3: value: 52550d0256025d0c08595f2347735c4417154078747172642f784f66b4b8366c flags: 0 - RecentlyUsedSceneGuid-5: + RecentlyUsedSceneGuid-4: value: 005752035c000a090b5a0d711376074443151b282e297f32742f4564b5b63660 flags: 0 - RecentlyUsedSceneGuid-6: + RecentlyUsedSceneGuid-5: value: 50035657070c0b0c55565d7b427a0c44154e4c2e7b7d75627f2c1c32e3b46639 flags: 0 - RecentlyUsedSceneGuid-7: + RecentlyUsedSceneGuid-6: value: 5300575451055d580b585f20457a5944134e197d7b2e22617e7a1e66bae1313a flags: 0 - RecentlyUsedSceneGuid-8: + RecentlyUsedSceneGuid-7: value: 5301015556035e585c57082643210e4410164b7d2a2923327a791e35e3b3636f flags: 0 + RecentlyUsedSceneGuid-8: + value: 0652525055575c5d5c0f5c7a1477094440151a2b2f2a2434747d4835e1e46661 + flags: 0 RecentlyUsedSceneGuid-9: value: 5505015f5c515a085f5b092149760f441716407a787d7564287b1b36e7e1366e flags: 0