mirror of
https://github.com/islehorse/HISP.git
synced 2025-04-21 20:25:51 +12:00
implement MULTIHORSES
This commit is contained in:
parent
e58835467a
commit
2b9ed092bc
6 changed files with 96 additions and 4 deletions
|
@ -155,6 +155,19 @@ namespace HISP.Player
|
|||
foreach (HorseInstance inst in HorsesOffered) // Transfer Horses
|
||||
{
|
||||
inst.Owner = OtherTrade.Trader.Id;
|
||||
|
||||
// Dismount horse if its traded
|
||||
if (Trader.CurrentlyRidingHorse != null)
|
||||
{
|
||||
if (Trader.CurrentlyRidingHorse.RandomId == inst.RandomId)
|
||||
{
|
||||
byte[] disMounted = PacketBuilder.CreateChat(Messages.TradeRiddenHorse, PacketBuilder.CHAT_BOTTOM_RIGHT);
|
||||
Trader.Facing %= 5;
|
||||
Trader.CurrentlyRidingHorse = null;
|
||||
Trader.LoggedinClient.SendPacket(disMounted);
|
||||
}
|
||||
}
|
||||
|
||||
Trader.HorseInventory.DeleteHorse(inst, false);
|
||||
OtherTrade.Trader.HorseInventory.AddHorse(inst, false);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue