first commit
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
using NitroxModel.Packets;
|
||||
using NitroxServer.GameLogic;
|
||||
using NitroxServer.GameLogic.Bases;
|
||||
|
||||
namespace NitroxServer.Communication.Packets.Processors;
|
||||
|
||||
public class PieceDeconstructedProcessor : BuildingProcessor<PieceDeconstructed>
|
||||
{
|
||||
public PieceDeconstructedProcessor(BuildingManager buildingManager, PlayerManager playerManager) : base(buildingManager, playerManager) { }
|
||||
|
||||
public override void Process(PieceDeconstructed packet, Player player)
|
||||
{
|
||||
if (buildingManager.ReplacePieceByGhost(player, packet, out _, out int operationId))
|
||||
{
|
||||
packet.BaseData = null;
|
||||
SendToOtherPlayersWithOperationId(packet, player, operationId);
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user