Fix Crashing in Tack Shop Giveaway

This commit is contained in:
Bluzume 2021-11-28 13:00:56 -05:00
parent 4293657614
commit 5ff04d3f0e

View file

@ -128,7 +128,7 @@ namespace HISP.Game.Events
int winIndx = GameServer.RandomNumberGenerator.Next(0, usersHere.Length);
User winner = usersHere[winIndx];
winner.HorseInventory.AddHorse(HorseGiveaway);
winner.HorseInventory.AddHorse(HorseGiveaway, true, true);
winner.TrackedItems.GetTrackedItem(Tracking.TrackableItem.TackShopGiveaway).Count++;
byte[] horseWonMessage = PacketBuilder.CreateChat(Messages.FormatEventTackShopGiveawayWon(winner.Username, HorseGiveaway.Breed.Name, ShopName, Town.Name, usersHere.Length), PacketBuilder.CHAT_BOTTOM_RIGHT);