public static void OnChatButtonClicked(bool firstButton)
{
NPC npc = Main.npc[Main.player[Main.myPlayer].talkNPC];
if (npc.modNPC != null)
{
bool shop = false;
npc.modNPC.OnChatButtonClicked(firstButton, ref shop);
Main.PlaySound(12, -1, -1, 1);
if (shop)
{
Main.playerInventory = true;
Main.npcChatText = "";
Main.npcShop = Main.MaxShopIDs - 1;
Main.instance.shop[Main.npcShop].SetupShop(npc.type);
}
}
}