audriuziz Posted April 10, 2019 Posted April 10, 2019 Hello, on acis my multishop only show first html windows. Not show's other chats, anyone can help? public void showChatWindow(Player player, int val) { final NpcHtmlMessage html = new NpcHtmlMessage(getObjectId()); html.setFile("data/html/mods/donateNpc/" + getNpcId()+ (val == 0 ? "" : "-" + val) + ".htm"); html.replace("%objectId%", getObjectId()); player.sendPacket(html); }
0 Tryskell Posted April 10, 2019 Posted April 10, 2019 (edited) Your custom NPC must correctly override onBypassFeedback, using a if (command.equalsIgnoreCase("whateverCustomCommand") { } else super.onBypassFeedBack.... The super.onBypassFeedBack sends the client to "basic" NPC commands, such as Chat. Before the super.onBypass, you can put any new custom commands you want using if / else if / else if / else if /.... Almost all, if not all, Folk (new name for old L2NpcInstance) derivated NPCs act similar, I invite you to read about them to see what they can override. If it's not working, I invite you to read about Chat command and how it's implemented on bypasses of existing HTMs (tip : there are 936 results in more than 800 files), because you probably made an error writting it. Edited April 10, 2019 by Tryskell
Question
audriuziz
Hello, on acis my multishop only show first html windows. Not show's other chats, anyone can help?
public void showChatWindow(Player player, int val) { final NpcHtmlMessage html = new NpcHtmlMessage(getObjectId()); html.setFile("data/html/mods/donateNpc/" + getNpcId()+ (val == 0 ? "" : "-" + val) + ".htm"); html.replace("%objectId%", getObjectId()); player.sendPacket(html); }
1 answer to this question
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now