yep
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
using Gameboard.ShogiUI.Sockets.ServiceModels.Socket.Types;
|
||||
using Gameboard.ShogiUI.Sockets.ServiceModels.Types;
|
||||
using PathFinding;
|
||||
using System.Diagnostics;
|
||||
|
||||
@@ -18,6 +18,9 @@ namespace Gameboard.ShogiUI.Sockets.Models
|
||||
Owner = owner;
|
||||
IsPromoted = isPromoted;
|
||||
}
|
||||
public Piece(Piece piece) : this(piece.WhichPiece, piece.Owner, piece.IsPromoted)
|
||||
{
|
||||
}
|
||||
|
||||
public bool CanPromote => !IsPromoted
|
||||
&& WhichPiece != WhichPiece.King
|
||||
@@ -54,9 +57,9 @@ namespace Gameboard.ShogiUI.Sockets.Models
|
||||
_ => throw new System.NotImplementedException()
|
||||
};
|
||||
|
||||
public ServiceModels.Socket.Types.Piece ToServiceModel()
|
||||
public ServiceModels.Types.Piece ToServiceModel()
|
||||
{
|
||||
return new ServiceModels.Socket.Types.Piece
|
||||
return new ServiceModels.Types.Piece
|
||||
{
|
||||
IsPromoted = IsPromoted,
|
||||
Owner = Owner,
|
||||
|
||||
Reference in New Issue
Block a user