Core/Gossip: Implemented new gossip option type GOSSIP_OPTION_TRANSMOGRIFIER
This commit is contained in:
@@ -39,6 +39,7 @@ namespace Framework.Constants
|
||||
Unlearnpettalents_Old = 17, // deprecated
|
||||
Learndualspec = 18, //Unit_Npc_Flag_Trainer (16) (Bonus Option For Trainer)
|
||||
Outdoorpvp = 19, //Added By Code (Option For Outdoor Pvp Creatures)
|
||||
Transmogrifier = 20, //UNIT_NPC_FLAG_TRANSMOGRIFIER
|
||||
Max
|
||||
}
|
||||
|
||||
|
||||
@@ -2366,6 +2366,7 @@ namespace Game.Entities
|
||||
case GossipOption.Petitioner:
|
||||
case GossipOption.Tabarddesigner:
|
||||
case GossipOption.Auctioneer:
|
||||
case GossipOption.Transmogrifier:
|
||||
break; // no checks
|
||||
case GossipOption.Outdoorpvp:
|
||||
if (!Global.OutdoorPvPMgr.CanTalkTo(this, creature, menuItems))
|
||||
@@ -2573,6 +2574,9 @@ namespace Game.Entities
|
||||
Global.BattlegroundMgr.SendBattlegroundList(this, guid, bgTypeId);
|
||||
break;
|
||||
}
|
||||
case GossipOption.Transmogrifier:
|
||||
GetSession().SendOpenTransmogrifier(guid);
|
||||
break;
|
||||
}
|
||||
|
||||
ModifyMoney(-cost);
|
||||
|
||||
@@ -291,5 +291,10 @@ namespace Game
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void SendOpenTransmogrifier(ObjectGuid guid)
|
||||
{
|
||||
SendPacket(new OpenTransmogrifier(guid));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -64,6 +64,21 @@ namespace Game.Network.Packets
|
||||
public List<uint> FavoriteAppearances = new List<uint>();
|
||||
}
|
||||
|
||||
class OpenTransmogrifier : ServerPacket
|
||||
{
|
||||
public OpenTransmogrifier(ObjectGuid guid) : base(ServerOpcodes.OpenTransmogrifier, ConnectionType.Instance)
|
||||
{
|
||||
Guid = guid;
|
||||
}
|
||||
|
||||
public override void Write()
|
||||
{
|
||||
_worldPacket.WritePackedGuid(Guid);
|
||||
}
|
||||
|
||||
ObjectGuid Guid;
|
||||
}
|
||||
|
||||
struct TransmogrifyItem
|
||||
{
|
||||
public void Read(WorldPacket data)
|
||||
|
||||
Reference in New Issue
Block a user