Skip to content

Commit

Permalink
Implement TRADE_ADMIN handler
Browse files Browse the repository at this point in the history
  • Loading branch information
ethanmoffat committed Jun 1, 2024
1 parent 01a00d1 commit 002e4cc
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions EOLib/PacketHandlers/Trade/TradeAdminHandler.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
using AutomaticTypeMapper;
using EOLib.Domain.Login;
using EOLib.Domain.Trade;
using Moffat.EndlessOnline.SDK.Protocol.Net;
using Moffat.EndlessOnline.SDK.Protocol.Net.Server;

namespace EOLib.PacketHandlers.Trade
{
[AutoMappedType]
public class TradeAdminHandler : TradeOfferUpdateHandler<TradeAdminServerPacket>
{
public override PacketFamily Family => PacketFamily.Trade;

public override PacketAction Action => PacketAction.Admin;

public TradeAdminHandler(IPlayerInfoProvider playerInfoProvider,
ITradeRepository tradeRepository)
: base(playerInfoProvider, tradeRepository)
{
}

public override bool HandlePacket(TradeAdminServerPacket packet)
{
Handle(packet.TradeData);
return true;
}
}
}

0 comments on commit 002e4cc

Please sign in to comment.