移动和旋转
This commit is contained in:
@@ -33,6 +33,26 @@ namespace NBC
|
||||
public float z { get; set; }
|
||||
}
|
||||
[ProtoContract]
|
||||
public partial class Vector2Info : AMessage, IProto
|
||||
{
|
||||
public static Vector2Info Create(Scene scene)
|
||||
{
|
||||
return scene.MessagePoolComponent.Rent<Vector2Info>();
|
||||
}
|
||||
public override void Dispose()
|
||||
{
|
||||
x = default;
|
||||
y = default;
|
||||
#if FANTASY_NET || FANTASY_UNITY
|
||||
GetScene().MessagePoolComponent.Return<Vector2Info>(this);
|
||||
#endif
|
||||
}
|
||||
[ProtoMember(1)]
|
||||
public float x { get; set; }
|
||||
[ProtoMember(2)]
|
||||
public float y { get; set; }
|
||||
}
|
||||
[ProtoContract]
|
||||
public partial class QuaternionInfo : AMessage, IProto
|
||||
{
|
||||
public static QuaternionInfo Create(Scene scene)
|
||||
@@ -115,7 +135,8 @@ namespace NBC
|
||||
{
|
||||
Id = default;
|
||||
RoleInfo = default;
|
||||
Location = default;
|
||||
Position = default;
|
||||
Rotation = default;
|
||||
State = default;
|
||||
Gears = default;
|
||||
FishingInfo = default;
|
||||
@@ -129,34 +150,16 @@ namespace NBC
|
||||
[ProtoMember(2)]
|
||||
public RoleSimpleInfo RoleInfo { get; set; }
|
||||
[ProtoMember(3)]
|
||||
public MapUnitPositionInfo Location { get; set; }
|
||||
public Vector3Info Position { get; set; }
|
||||
[ProtoMember(4)]
|
||||
public UnitStateInfo State { get; set; }
|
||||
public Vector3Info Rotation { get; set; }
|
||||
[ProtoMember(5)]
|
||||
public GearInfo Gears { get; set; }
|
||||
public UnitStateInfo State { get; set; }
|
||||
[ProtoMember(6)]
|
||||
public UnitFishingInfo FishingInfo { get; set; }
|
||||
public GearInfo Gears { get; set; }
|
||||
[ProtoMember(7)]
|
||||
public UnitFishingInfo FishingInfo { get; set; }
|
||||
[ProtoMember(8)]
|
||||
public List<KeyValueInt32> KV = new List<KeyValueInt32>();
|
||||
}
|
||||
[ProtoContract]
|
||||
public partial class MapUnitPositionInfo : AMessage, IProto
|
||||
{
|
||||
public static MapUnitPositionInfo Create(Scene scene)
|
||||
{
|
||||
return scene.MessagePoolComponent.Rent<MapUnitPositionInfo>();
|
||||
}
|
||||
public override void Dispose()
|
||||
{
|
||||
Position = default;
|
||||
Rotation = default;
|
||||
#if FANTASY_NET || FANTASY_UNITY
|
||||
GetScene().MessagePoolComponent.Return<MapUnitPositionInfo>(this);
|
||||
#endif
|
||||
}
|
||||
[ProtoMember(1)]
|
||||
public Vector3Info Position { get; set; }
|
||||
[ProtoMember(2)]
|
||||
public QuaternionInfo Rotation { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user