Changed Link bypass to work on with specific links.
This commit is contained in:
@@ -5,5 +5,5 @@ If you have some <font color="LEVEL">Life Stones</font> left, you can still <fon
|
|||||||
Just tell me what you need.<br>
|
Just tell me what you need.<br>
|
||||||
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_01.htm">"I want to augment an item."</Button>
|
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_01.htm">"I want to augment an item."</Button>
|
||||||
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_02.htm">"I want to remove an augmentation."</Button>
|
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_02.htm">"I want to remove an augmentation."</Button>
|
||||||
<Button ALIGN="LEFT" ICON="RETURN" action="link blacksmith_morning001.htm">Back</Button>
|
<Button ALIGN=LEFT ICON="RETURN" action="bypass -h npc_%objectId%_Chat 0">Back</button>
|
||||||
</body></html>
|
</body></html>
|
@@ -1,7 +1,7 @@
|
|||||||
<html><body>
|
<html><body>
|
||||||
Grand Master Oltran:<br>
|
Grand Master Oltran:<br>
|
||||||
You are far from your village, adventurer. How do you feel, now that you see the great castle and the ever-changing streets that are the pride of the Humans? I'm sure you admire them, but do not be enticed by their allure. Beneath the most beautiful bed of flowers, there is often a serpent's lair. If you spend much time in this city, you may come to see what I mean...<br>
|
You are far from your village, adventurer. How do you feel, now that you see the great castle and the ever-changing streets that are the pride of the Humans? I'm sure you admire them, but do not be enticed by their allure. Beneath the most beautiful bed of flowers, there is often a serpent's lair. If you spend much time in this city, you may come to see what I mean...<br>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="link guard_class_change2001.htm">"Can you tell me about the 2nd Class Transfer?"</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ClassTransferTalk">"Can you tell me about the 2nd Class Transfer?"</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Clan">Clan</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Clan">Clan</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Alliance">Alliance</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Alliance">Alliance</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ShadowWeapons">"I want to use my Shadow Item Coupon."</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ShadowWeapons">"I want to use my Shadow Item Coupon."</Button>
|
||||||
|
@@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.bypasshandlers;
|
package handlers.bypasshandlers;
|
||||||
|
|
||||||
|
import com.l2jmobius.commons.util.CommonUtil;
|
||||||
import com.l2jmobius.gameserver.cache.HtmCache;
|
import com.l2jmobius.gameserver.cache.HtmCache;
|
||||||
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
||||||
import com.l2jmobius.gameserver.model.actor.Creature;
|
import com.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@@ -29,6 +30,48 @@ public class Link implements IBypassHandler
|
|||||||
"Link"
|
"Link"
|
||||||
};
|
};
|
||||||
|
|
||||||
|
private static final String[] VALID_BYPASSES =
|
||||||
|
{
|
||||||
|
"common/attribute_info.htm",
|
||||||
|
"common/augmentation_01.htm",
|
||||||
|
"common/augmentation_02.htm",
|
||||||
|
"common/crafting_01.htm",
|
||||||
|
"common/crafting_02.htm",
|
||||||
|
"common/crafting_03.htm",
|
||||||
|
"common/cursed_to_unidentified.htm",
|
||||||
|
"common/duals_01.htm",
|
||||||
|
"common/duals_02.htm",
|
||||||
|
"common/duals_03.htm",
|
||||||
|
"common/g_cube_warehouse001.htm",
|
||||||
|
"common/skill_enchant_help.htm",
|
||||||
|
"common/skill_enchant_help_01.htm",
|
||||||
|
"common/skill_enchant_help_02.htm",
|
||||||
|
"common/skill_enchant_help_03.htm",
|
||||||
|
"common/weapon_sa_01.htm",
|
||||||
|
"common/welcomeback002.htm",
|
||||||
|
"common/welcomeback003.htm",
|
||||||
|
"default/BlessingOfProtection.htm",
|
||||||
|
"default/SupportMagic.htm",
|
||||||
|
"default/SupportMagicServitor.htm",
|
||||||
|
"fisherman/exchange_old_items.htm",
|
||||||
|
"fisherman/fishing_manual001.htm",
|
||||||
|
"fisherman/fishing_manual002.htm",
|
||||||
|
"fisherman/fishing_manual003.htm",
|
||||||
|
"fisherman/fishing_manual004.htm",
|
||||||
|
"fisherman/fishing_manual008.htm",
|
||||||
|
"fisherman/fishing_manual009.htm",
|
||||||
|
"fisherman/fishing_manual010.htm",
|
||||||
|
"fortress/foreman.htm",
|
||||||
|
"guard/kamaloka_help.htm",
|
||||||
|
"guard/kamaloka_level.htm",
|
||||||
|
"petmanager/evolve.htm",
|
||||||
|
"petmanager/exchange.htm",
|
||||||
|
"petmanager/instructions.htm",
|
||||||
|
"teleporter/separatedsoul.htm",
|
||||||
|
"warehouse/clanwh.htm",
|
||||||
|
"warehouse/privatewh.htm",
|
||||||
|
};
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
||||||
{
|
{
|
||||||
@@ -45,9 +88,12 @@ public class Link implements IBypassHandler
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
final String content = HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath);
|
final String content = CommonUtil.contains(VALID_BYPASSES, htmlPath) ? HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath) : null;
|
||||||
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
||||||
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
if (content != null)
|
||||||
|
{
|
||||||
|
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
||||||
|
}
|
||||||
player.sendPacket(html);
|
player.sendPacket(html);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@@ -6,5 +6,5 @@ Just tell me what you need.<br>
|
|||||||
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_01.htm">"I want to augment an item."</Button>
|
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_01.htm">"I want to augment an item."</Button>
|
||||||
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_02.htm">"I want to remove an augmentation."</Button>
|
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_02.htm">"I want to remove an augmentation."</Button>
|
||||||
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_exchange.htm">"I want to exchange Life Stones."</Button>
|
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_exchange.htm">"I want to exchange Life Stones."</Button>
|
||||||
<Button ALIGN="LEFT" ICON="RETURN" action="link blacksmith_morning001.htm">Back</Button>
|
<Button ALIGN="LEFT" ICON="RETURN" action="bypass -h npc_%objectId%_Chat 0">Back</Button>
|
||||||
</body></html>
|
</body></html>
|
@@ -1,7 +1,7 @@
|
|||||||
<html><body>
|
<html><body>
|
||||||
Grand Master Oltran:<br>
|
Grand Master Oltran:<br>
|
||||||
You are far from your village, adventurer. How do you feel, now that you see the great castle and the ever-changing streets that are the pride of the Humans? I'm sure you admire them, but do not be enticed by their allure. Beneath the most beautiful bed of flowers, there is often a serpent's lair. If you spend much time in this city, you may come to see what I mean...<br>
|
You are far from your village, adventurer. How do you feel, now that you see the great castle and the ever-changing streets that are the pride of the Humans? I'm sure you admire them, but do not be enticed by their allure. Beneath the most beautiful bed of flowers, there is often a serpent's lair. If you spend much time in this city, you may come to see what I mean...<br>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="link guard_class_change2001.htm">"Can you tell me about the 2nd Class Transfer?"</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ClassTransferTalk">"Can you tell me about the 2nd Class Transfer?"</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Clan">Clan</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Clan">Clan</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Alliance">Alliance</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Alliance">Alliance</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ShadowWeapons">"I want to use my Shadow Item Coupon."</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ShadowWeapons">"I want to use my Shadow Item Coupon."</Button>
|
||||||
|
@@ -6,5 +6,5 @@ When you switch a weapon, the <font color="LEVEL">enchantment, Soul Crystal, aug
|
|||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421202">"I want to change an R95-grade weapon."</button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421202">"I want to change an R95-grade weapon."</button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421203">"I want to change an R99-grade weapon."</button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421203">"I want to change an R99-grade weapon."</button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421204">"I want to exchange a Tauti and Kelbim weapon."</button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421204">"I want to exchange a Tauti and Kelbim weapon."</button>
|
||||||
<Button ALIGN=LEFT ICON="RETURN" action="link ev_libra_black001.htm">Back</button>
|
<Button ALIGN=LEFT ICON="RETURN" action="bypass -h Quest RedLibra 34212-1.htm">Back</button>
|
||||||
</body></html>
|
</body></html>
|
@@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.bypasshandlers;
|
package handlers.bypasshandlers;
|
||||||
|
|
||||||
|
import com.l2jmobius.commons.util.CommonUtil;
|
||||||
import com.l2jmobius.gameserver.cache.HtmCache;
|
import com.l2jmobius.gameserver.cache.HtmCache;
|
||||||
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
||||||
import com.l2jmobius.gameserver.model.actor.Creature;
|
import com.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@@ -29,6 +30,51 @@ public class Link implements IBypassHandler
|
|||||||
"Link"
|
"Link"
|
||||||
};
|
};
|
||||||
|
|
||||||
|
private static final String[] VALID_BYPASSES =
|
||||||
|
{
|
||||||
|
"common/attribute_info.htm",
|
||||||
|
"common/augmentation_01.htm",
|
||||||
|
"common/augmentation_02.htm",
|
||||||
|
"common/augmentation_exchange.htm",
|
||||||
|
"common/crafting_01.htm",
|
||||||
|
"common/crafting_02.htm",
|
||||||
|
"common/crafting_03.htm",
|
||||||
|
"common/cursed_to_unidentified.htm",
|
||||||
|
"common/duals_01.htm",
|
||||||
|
"common/duals_02.htm",
|
||||||
|
"common/duals_03.htm",
|
||||||
|
"common/g_cube_warehouse001.htm",
|
||||||
|
"common/skill_enchant_help.htm",
|
||||||
|
"common/skill_enchant_help_01.htm",
|
||||||
|
"common/skill_enchant_help_02.htm",
|
||||||
|
"common/skill_enchant_help_03.htm",
|
||||||
|
"common/smelting_trade001.htm",
|
||||||
|
"common/weapon_sa_01.htm",
|
||||||
|
"common/welcomeback002.htm",
|
||||||
|
"common/welcomeback003.htm",
|
||||||
|
"default/BlessingOfProtection.htm",
|
||||||
|
"default/SupportMagic.htm",
|
||||||
|
"default/SupportMagicServitor.htm",
|
||||||
|
"fisherman/exchange_old_items.htm",
|
||||||
|
"fisherman/fish_appearance_exchange.htm",
|
||||||
|
"fisherman/fishing_manual001.htm",
|
||||||
|
"fisherman/fishing_manual002.htm",
|
||||||
|
"fisherman/fishing_manual003.htm",
|
||||||
|
"fisherman/fishing_manual004.htm",
|
||||||
|
"fisherman/fishing_manual008.htm",
|
||||||
|
"fisherman/fishing_manual009.htm",
|
||||||
|
"fisherman/fishing_manual010.htm",
|
||||||
|
"fortress/foreman.htm",
|
||||||
|
"guard/kamaloka_help.htm",
|
||||||
|
"guard/kamaloka_level.htm",
|
||||||
|
"petmanager/evolve.htm",
|
||||||
|
"petmanager/exchange.htm",
|
||||||
|
"petmanager/instructions.htm",
|
||||||
|
"teleporter/separatedsoul.htm",
|
||||||
|
"warehouse/clanwh.htm",
|
||||||
|
"warehouse/privatewh.htm",
|
||||||
|
};
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
||||||
{
|
{
|
||||||
@@ -45,9 +91,12 @@ public class Link implements IBypassHandler
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
final String content = HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath);
|
final String content = CommonUtil.contains(VALID_BYPASSES, htmlPath) ? HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath) : null;
|
||||||
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
||||||
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
if (content != null)
|
||||||
|
{
|
||||||
|
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
||||||
|
}
|
||||||
player.sendPacket(html);
|
player.sendPacket(html);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@@ -6,5 +6,5 @@ Just tell me what you need.<br>
|
|||||||
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_01.htm">"I want to augment an item."</Button>
|
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_01.htm">"I want to augment an item."</Button>
|
||||||
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_02.htm">"I want to remove an augmentation."</Button>
|
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_02.htm">"I want to remove an augmentation."</Button>
|
||||||
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_exchange.htm">"I want to exchange Life Stones."</Button>
|
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_exchange.htm">"I want to exchange Life Stones."</Button>
|
||||||
<Button ALIGN="LEFT" ICON="RETURN" action="link blacksmith_morning001.htm">Back</Button>
|
<Button ALIGN="LEFT" ICON="RETURN" action="bypass -h npc_%objectId%_Chat 0">Back</Button>
|
||||||
</body></html>
|
</body></html>
|
@@ -1,7 +1,7 @@
|
|||||||
<html><body>
|
<html><body>
|
||||||
Grand Master Oltran:<br>
|
Grand Master Oltran:<br>
|
||||||
You are far from your village, adventurer. How do you feel, now that you see the great castle and the ever-changing streets that are the pride of the Humans? I'm sure you admire them, but do not be enticed by their allure. Beneath the most beautiful bed of flowers, there is often a serpent's lair. If you spend much time in this city, you may come to see what I mean...<br>
|
You are far from your village, adventurer. How do you feel, now that you see the great castle and the ever-changing streets that are the pride of the Humans? I'm sure you admire them, but do not be enticed by their allure. Beneath the most beautiful bed of flowers, there is often a serpent's lair. If you spend much time in this city, you may come to see what I mean...<br>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="link guard_class_change2001.htm">"Can you tell me about the 2nd Class Transfer?"</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ClassTransferTalk">"Can you tell me about the 2nd Class Transfer?"</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Clan">Clan</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Clan">Clan</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Alliance">Alliance</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Alliance">Alliance</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ShadowWeapons">"I want to use my Shadow Item Coupon."</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ShadowWeapons">"I want to use my Shadow Item Coupon."</Button>
|
||||||
|
@@ -6,5 +6,5 @@ When you switch a weapon, the <font color="LEVEL">enchantment, Soul Crystal, aug
|
|||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421202">"I want to change an R95-grade weapon."</button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421202">"I want to change an R95-grade weapon."</button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421203">"I want to change an R99-grade weapon."</button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421203">"I want to change an R99-grade weapon."</button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421204">"I want to exchange a Tauti and Kelbim weapon."</button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421204">"I want to exchange a Tauti and Kelbim weapon."</button>
|
||||||
<Button ALIGN=LEFT ICON="RETURN" action="link ev_libra_black001.htm">Back</button>
|
<Button ALIGN=LEFT ICON="RETURN" action="bypass -h Quest RedLibra 34212-1.htm">Back</button>
|
||||||
</body></html>
|
</body></html>
|
@@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.bypasshandlers;
|
package handlers.bypasshandlers;
|
||||||
|
|
||||||
|
import com.l2jmobius.commons.util.CommonUtil;
|
||||||
import com.l2jmobius.gameserver.cache.HtmCache;
|
import com.l2jmobius.gameserver.cache.HtmCache;
|
||||||
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
||||||
import com.l2jmobius.gameserver.model.actor.Creature;
|
import com.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@@ -29,6 +30,51 @@ public class Link implements IBypassHandler
|
|||||||
"Link"
|
"Link"
|
||||||
};
|
};
|
||||||
|
|
||||||
|
private static final String[] VALID_BYPASSES =
|
||||||
|
{
|
||||||
|
"common/attribute_info.htm",
|
||||||
|
"common/augmentation_01.htm",
|
||||||
|
"common/augmentation_02.htm",
|
||||||
|
"common/augmentation_exchange.htm",
|
||||||
|
"common/crafting_01.htm",
|
||||||
|
"common/crafting_02.htm",
|
||||||
|
"common/crafting_03.htm",
|
||||||
|
"common/cursed_to_unidentified.htm",
|
||||||
|
"common/duals_01.htm",
|
||||||
|
"common/duals_02.htm",
|
||||||
|
"common/duals_03.htm",
|
||||||
|
"common/g_cube_warehouse001.htm",
|
||||||
|
"common/skill_enchant_help.htm",
|
||||||
|
"common/skill_enchant_help_01.htm",
|
||||||
|
"common/skill_enchant_help_02.htm",
|
||||||
|
"common/skill_enchant_help_03.htm",
|
||||||
|
"common/smelting_trade001.htm",
|
||||||
|
"common/weapon_sa_01.htm",
|
||||||
|
"common/welcomeback002.htm",
|
||||||
|
"common/welcomeback003.htm",
|
||||||
|
"default/BlessingOfProtection.htm",
|
||||||
|
"default/SupportMagic.htm",
|
||||||
|
"default/SupportMagicServitor.htm",
|
||||||
|
"fisherman/exchange_old_items.htm",
|
||||||
|
"fisherman/fish_appearance_exchange.htm",
|
||||||
|
"fisherman/fishing_manual001.htm",
|
||||||
|
"fisherman/fishing_manual002.htm",
|
||||||
|
"fisherman/fishing_manual003.htm",
|
||||||
|
"fisherman/fishing_manual004.htm",
|
||||||
|
"fisherman/fishing_manual008.htm",
|
||||||
|
"fisherman/fishing_manual009.htm",
|
||||||
|
"fisherman/fishing_manual010.htm",
|
||||||
|
"fortress/foreman.htm",
|
||||||
|
"guard/kamaloka_help.htm",
|
||||||
|
"guard/kamaloka_level.htm",
|
||||||
|
"petmanager/evolve.htm",
|
||||||
|
"petmanager/exchange.htm",
|
||||||
|
"petmanager/instructions.htm",
|
||||||
|
"teleporter/separatedsoul.htm",
|
||||||
|
"warehouse/clanwh.htm",
|
||||||
|
"warehouse/privatewh.htm",
|
||||||
|
};
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
||||||
{
|
{
|
||||||
@@ -45,9 +91,12 @@ public class Link implements IBypassHandler
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
final String content = HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath);
|
final String content = CommonUtil.contains(VALID_BYPASSES, htmlPath) ? HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath) : null;
|
||||||
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
||||||
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
if (content != null)
|
||||||
|
{
|
||||||
|
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
||||||
|
}
|
||||||
player.sendPacket(html);
|
player.sendPacket(html);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@@ -6,5 +6,5 @@ Just tell me what you need.<br>
|
|||||||
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_01.htm">"I want to augment an item."</Button>
|
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_01.htm">"I want to augment an item."</Button>
|
||||||
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_02.htm">"I want to remove an augmentation."</Button>
|
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_02.htm">"I want to remove an augmentation."</Button>
|
||||||
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_exchange.htm">"I want to exchange Life Stones."</Button>
|
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_exchange.htm">"I want to exchange Life Stones."</Button>
|
||||||
<Button ALIGN="LEFT" ICON="RETURN" action="link blacksmith_morning001.htm">Back</Button>
|
<Button ALIGN="LEFT" ICON="RETURN" action="bypass -h npc_%objectId%_Chat 0">Back</Button>
|
||||||
</body></html>
|
</body></html>
|
@@ -1,7 +1,7 @@
|
|||||||
<html><body>
|
<html><body>
|
||||||
Grand Master Oltran:<br>
|
Grand Master Oltran:<br>
|
||||||
You are far from your village, adventurer. How do you feel, now that you see the great castle and the ever-changing streets that are the pride of the Humans? I'm sure you admire them, but do not be enticed by their allure. Beneath the most beautiful bed of flowers, there is often a serpent's lair. If you spend much time in this city, you may come to see what I mean...<br>
|
You are far from your village, adventurer. How do you feel, now that you see the great castle and the ever-changing streets that are the pride of the Humans? I'm sure you admire them, but do not be enticed by their allure. Beneath the most beautiful bed of flowers, there is often a serpent's lair. If you spend much time in this city, you may come to see what I mean...<br>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="link guard_class_change2001.htm">"Can you tell me about the 2nd Class Transfer?"</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ClassTransferTalk">"Can you tell me about the 2nd Class Transfer?"</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Clan">Clan</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Clan">Clan</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Alliance">Alliance</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Alliance">Alliance</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ShadowWeapons">"I want to use my Shadow Item Coupon."</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ShadowWeapons">"I want to use my Shadow Item Coupon."</Button>
|
||||||
|
@@ -6,5 +6,5 @@ When you switch a weapon, the <font color="LEVEL">enchantment, Soul Crystal, aug
|
|||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421202">"I want to change an R95-grade weapon."</button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421202">"I want to change an R95-grade weapon."</button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421203">"I want to change an R99-grade weapon."</button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421203">"I want to change an R99-grade weapon."</button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421204">"I want to exchange a Tauti and Kelbim weapon."</button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421204">"I want to exchange a Tauti and Kelbim weapon."</button>
|
||||||
<Button ALIGN=LEFT ICON="RETURN" action="link ev_libra_black001.htm">Back</button>
|
<Button ALIGN=LEFT ICON="RETURN" action="bypass -h Quest RedLibra 34212-1.htm">Back</button>
|
||||||
</body></html>
|
</body></html>
|
@@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.bypasshandlers;
|
package handlers.bypasshandlers;
|
||||||
|
|
||||||
|
import com.l2jmobius.commons.util.CommonUtil;
|
||||||
import com.l2jmobius.gameserver.cache.HtmCache;
|
import com.l2jmobius.gameserver.cache.HtmCache;
|
||||||
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
||||||
import com.l2jmobius.gameserver.model.actor.Creature;
|
import com.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@@ -29,6 +30,51 @@ public class Link implements IBypassHandler
|
|||||||
"Link"
|
"Link"
|
||||||
};
|
};
|
||||||
|
|
||||||
|
private static final String[] VALID_BYPASSES =
|
||||||
|
{
|
||||||
|
"common/attribute_info.htm",
|
||||||
|
"common/augmentation_01.htm",
|
||||||
|
"common/augmentation_02.htm",
|
||||||
|
"common/augmentation_exchange.htm",
|
||||||
|
"common/crafting_01.htm",
|
||||||
|
"common/crafting_02.htm",
|
||||||
|
"common/crafting_03.htm",
|
||||||
|
"common/cursed_to_unidentified.htm",
|
||||||
|
"common/duals_01.htm",
|
||||||
|
"common/duals_02.htm",
|
||||||
|
"common/duals_03.htm",
|
||||||
|
"common/g_cube_warehouse001.htm",
|
||||||
|
"common/skill_enchant_help.htm",
|
||||||
|
"common/skill_enchant_help_01.htm",
|
||||||
|
"common/skill_enchant_help_02.htm",
|
||||||
|
"common/skill_enchant_help_03.htm",
|
||||||
|
"common/smelting_trade001.htm",
|
||||||
|
"common/weapon_sa_01.htm",
|
||||||
|
"common/welcomeback002.htm",
|
||||||
|
"common/welcomeback003.htm",
|
||||||
|
"default/BlessingOfProtection.htm",
|
||||||
|
"default/SupportMagic.htm",
|
||||||
|
"default/SupportMagicServitor.htm",
|
||||||
|
"fisherman/exchange_old_items.htm",
|
||||||
|
"fisherman/fish_appearance_exchange.htm",
|
||||||
|
"fisherman/fishing_manual001.htm",
|
||||||
|
"fisherman/fishing_manual002.htm",
|
||||||
|
"fisherman/fishing_manual003.htm",
|
||||||
|
"fisherman/fishing_manual004.htm",
|
||||||
|
"fisherman/fishing_manual008.htm",
|
||||||
|
"fisherman/fishing_manual009.htm",
|
||||||
|
"fisherman/fishing_manual010.htm",
|
||||||
|
"fortress/foreman.htm",
|
||||||
|
"guard/kamaloka_help.htm",
|
||||||
|
"guard/kamaloka_level.htm",
|
||||||
|
"petmanager/evolve.htm",
|
||||||
|
"petmanager/exchange.htm",
|
||||||
|
"petmanager/instructions.htm",
|
||||||
|
"teleporter/separatedsoul.htm",
|
||||||
|
"warehouse/clanwh.htm",
|
||||||
|
"warehouse/privatewh.htm",
|
||||||
|
};
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
||||||
{
|
{
|
||||||
@@ -45,9 +91,12 @@ public class Link implements IBypassHandler
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
final String content = HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath);
|
final String content = CommonUtil.contains(VALID_BYPASSES, htmlPath) ? HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath) : null;
|
||||||
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
||||||
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
if (content != null)
|
||||||
|
{
|
||||||
|
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
||||||
|
}
|
||||||
player.sendPacket(html);
|
player.sendPacket(html);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@@ -6,5 +6,5 @@ Just tell me what you need.<br>
|
|||||||
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_01.htm">"I want to augment an item."</Button>
|
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_01.htm">"I want to augment an item."</Button>
|
||||||
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_02.htm">"I want to remove an augmentation."</Button>
|
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_02.htm">"I want to remove an augmentation."</Button>
|
||||||
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_exchange.htm">"I want to exchange Life Stones."</Button>
|
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_exchange.htm">"I want to exchange Life Stones."</Button>
|
||||||
<Button ALIGN="LEFT" ICON="RETURN" action="link blacksmith_morning001.htm">Back</Button>
|
<Button ALIGN="LEFT" ICON="RETURN" action="bypass -h npc_%objectId%_Chat 0">Back</Button>
|
||||||
</body></html>
|
</body></html>
|
@@ -1,7 +1,7 @@
|
|||||||
<html><body>
|
<html><body>
|
||||||
Grand Master Oltran:<br>
|
Grand Master Oltran:<br>
|
||||||
You are far from your village, adventurer. How do you feel, now that you see the great castle and the ever-changing streets that are the pride of the Humans? I'm sure you admire them, but do not be enticed by their allure. Beneath the most beautiful bed of flowers, there is often a serpent's lair. If you spend much time in this city, you may come to see what I mean...<br>
|
You are far from your village, adventurer. How do you feel, now that you see the great castle and the ever-changing streets that are the pride of the Humans? I'm sure you admire them, but do not be enticed by their allure. Beneath the most beautiful bed of flowers, there is often a serpent's lair. If you spend much time in this city, you may come to see what I mean...<br>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="link guard_class_change2001.htm">"Can you tell me about the 2nd Class Transfer?"</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ClassTransferTalk">"Can you tell me about the 2nd Class Transfer?"</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Clan">Clan</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Clan">Clan</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Alliance">Alliance</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Alliance">Alliance</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ShadowWeapons">"I want to use my Shadow Item Coupon."</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ShadowWeapons">"I want to use my Shadow Item Coupon."</Button>
|
||||||
|
@@ -6,5 +6,5 @@ When you switch a weapon, the <font color="LEVEL">enchantment, Soul Crystal, aug
|
|||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421202">"I want to change an R95-grade weapon."</button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421202">"I want to change an R95-grade weapon."</button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421203">"I want to change an R99-grade weapon."</button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421203">"I want to change an R99-grade weapon."</button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421204">"I want to exchange a Tauti and Kelbim weapon."</button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421204">"I want to exchange a Tauti and Kelbim weapon."</button>
|
||||||
<Button ALIGN=LEFT ICON="RETURN" action="link ev_libra_black001.htm">Back</button>
|
<Button ALIGN=LEFT ICON="RETURN" action="bypass -h Quest RedLibra 34212-1.htm">Back</button>
|
||||||
</body></html>
|
</body></html>
|
@@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.bypasshandlers;
|
package handlers.bypasshandlers;
|
||||||
|
|
||||||
|
import com.l2jmobius.commons.util.CommonUtil;
|
||||||
import com.l2jmobius.gameserver.cache.HtmCache;
|
import com.l2jmobius.gameserver.cache.HtmCache;
|
||||||
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
||||||
import com.l2jmobius.gameserver.model.actor.Creature;
|
import com.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@@ -29,6 +30,51 @@ public class Link implements IBypassHandler
|
|||||||
"Link"
|
"Link"
|
||||||
};
|
};
|
||||||
|
|
||||||
|
private static final String[] VALID_BYPASSES =
|
||||||
|
{
|
||||||
|
"common/attribute_info.htm",
|
||||||
|
"common/augmentation_01.htm",
|
||||||
|
"common/augmentation_02.htm",
|
||||||
|
"common/augmentation_exchange.htm",
|
||||||
|
"common/crafting_01.htm",
|
||||||
|
"common/crafting_02.htm",
|
||||||
|
"common/crafting_03.htm",
|
||||||
|
"common/cursed_to_unidentified.htm",
|
||||||
|
"common/duals_01.htm",
|
||||||
|
"common/duals_02.htm",
|
||||||
|
"common/duals_03.htm",
|
||||||
|
"common/g_cube_warehouse001.htm",
|
||||||
|
"common/skill_enchant_help.htm",
|
||||||
|
"common/skill_enchant_help_01.htm",
|
||||||
|
"common/skill_enchant_help_02.htm",
|
||||||
|
"common/skill_enchant_help_03.htm",
|
||||||
|
"common/smelting_trade001.htm",
|
||||||
|
"common/weapon_sa_01.htm",
|
||||||
|
"common/welcomeback002.htm",
|
||||||
|
"common/welcomeback003.htm",
|
||||||
|
"default/BlessingOfProtection.htm",
|
||||||
|
"default/SupportMagic.htm",
|
||||||
|
"default/SupportMagicServitor.htm",
|
||||||
|
"fisherman/exchange_old_items.htm",
|
||||||
|
"fisherman/fish_appearance_exchange.htm",
|
||||||
|
"fisherman/fishing_manual001.htm",
|
||||||
|
"fisherman/fishing_manual002.htm",
|
||||||
|
"fisherman/fishing_manual003.htm",
|
||||||
|
"fisherman/fishing_manual004.htm",
|
||||||
|
"fisherman/fishing_manual008.htm",
|
||||||
|
"fisherman/fishing_manual009.htm",
|
||||||
|
"fisherman/fishing_manual010.htm",
|
||||||
|
"fortress/foreman.htm",
|
||||||
|
"guard/kamaloka_help.htm",
|
||||||
|
"guard/kamaloka_level.htm",
|
||||||
|
"petmanager/evolve.htm",
|
||||||
|
"petmanager/exchange.htm",
|
||||||
|
"petmanager/instructions.htm",
|
||||||
|
"teleporter/separatedsoul.htm",
|
||||||
|
"warehouse/clanwh.htm",
|
||||||
|
"warehouse/privatewh.htm",
|
||||||
|
};
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
||||||
{
|
{
|
||||||
@@ -45,9 +91,12 @@ public class Link implements IBypassHandler
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
final String content = HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath);
|
final String content = CommonUtil.contains(VALID_BYPASSES, htmlPath) ? HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath) : null;
|
||||||
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
||||||
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
if (content != null)
|
||||||
|
{
|
||||||
|
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
||||||
|
}
|
||||||
player.sendPacket(html);
|
player.sendPacket(html);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@@ -6,5 +6,5 @@ Just tell me what you need.<br>
|
|||||||
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_01.htm">"I want to augment an item."</Button>
|
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_01.htm">"I want to augment an item."</Button>
|
||||||
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_02.htm">"I want to remove an augmentation."</Button>
|
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_02.htm">"I want to remove an augmentation."</Button>
|
||||||
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_exchange.htm">"I want to exchange Life Stones."</Button>
|
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_exchange.htm">"I want to exchange Life Stones."</Button>
|
||||||
<Button ALIGN="LEFT" ICON="RETURN" action="link blacksmith_morning001.htm">Back</Button>
|
<Button ALIGN="LEFT" ICON="RETURN" action="bypass -h npc_%objectId%_Chat 0">Back</Button>
|
||||||
</body></html>
|
</body></html>
|
@@ -1,7 +1,7 @@
|
|||||||
<html><body>
|
<html><body>
|
||||||
Grand Master Oltran:<br>
|
Grand Master Oltran:<br>
|
||||||
You are far from your village, adventurer. How do you feel, now that you see the great castle and the ever-changing streets that are the pride of the Humans? I'm sure you admire them, but do not be enticed by their allure. Beneath the most beautiful bed of flowers, there is often a serpent's lair. If you spend much time in this city, you may come to see what I mean...<br>
|
You are far from your village, adventurer. How do you feel, now that you see the great castle and the ever-changing streets that are the pride of the Humans? I'm sure you admire them, but do not be enticed by their allure. Beneath the most beautiful bed of flowers, there is often a serpent's lair. If you spend much time in this city, you may come to see what I mean...<br>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="link guard_class_change2001.htm">"Can you tell me about the 2nd Class Transfer?"</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ClassTransferTalk">"Can you tell me about the 2nd Class Transfer?"</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Clan">Clan</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Clan">Clan</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Alliance">Alliance</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Alliance">Alliance</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ShadowWeapons">"I want to use my Shadow Item Coupon."</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ShadowWeapons">"I want to use my Shadow Item Coupon."</Button>
|
||||||
|
@@ -6,5 +6,5 @@ When you switch a weapon, the <font color="LEVEL">enchantment, Soul Crystal, aug
|
|||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421202">"I want to change an R95-grade weapon."</button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421202">"I want to change an R95-grade weapon."</button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421203">"I want to change an R99-grade weapon."</button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421203">"I want to change an R99-grade weapon."</button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421204">"I want to exchange a Tauti and Kelbim weapon."</button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421204">"I want to exchange a Tauti and Kelbim weapon."</button>
|
||||||
<Button ALIGN=LEFT ICON="RETURN" action="link ev_libra_black001.htm">Back</button>
|
<Button ALIGN=LEFT ICON="RETURN" action="bypass -h Quest RedLibra 34212-1.htm">Back</button>
|
||||||
</body></html>
|
</body></html>
|
@@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.bypasshandlers;
|
package handlers.bypasshandlers;
|
||||||
|
|
||||||
|
import com.l2jmobius.commons.util.CommonUtil;
|
||||||
import com.l2jmobius.gameserver.cache.HtmCache;
|
import com.l2jmobius.gameserver.cache.HtmCache;
|
||||||
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
||||||
import com.l2jmobius.gameserver.model.actor.Creature;
|
import com.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@@ -29,6 +30,51 @@ public class Link implements IBypassHandler
|
|||||||
"Link"
|
"Link"
|
||||||
};
|
};
|
||||||
|
|
||||||
|
private static final String[] VALID_BYPASSES =
|
||||||
|
{
|
||||||
|
"common/attribute_info.htm",
|
||||||
|
"common/augmentation_01.htm",
|
||||||
|
"common/augmentation_02.htm",
|
||||||
|
"common/augmentation_exchange.htm",
|
||||||
|
"common/crafting_01.htm",
|
||||||
|
"common/crafting_02.htm",
|
||||||
|
"common/crafting_03.htm",
|
||||||
|
"common/cursed_to_unidentified.htm",
|
||||||
|
"common/duals_01.htm",
|
||||||
|
"common/duals_02.htm",
|
||||||
|
"common/duals_03.htm",
|
||||||
|
"common/g_cube_warehouse001.htm",
|
||||||
|
"common/skill_enchant_help.htm",
|
||||||
|
"common/skill_enchant_help_01.htm",
|
||||||
|
"common/skill_enchant_help_02.htm",
|
||||||
|
"common/skill_enchant_help_03.htm",
|
||||||
|
"common/smelting_trade001.htm",
|
||||||
|
"common/weapon_sa_01.htm",
|
||||||
|
"common/welcomeback002.htm",
|
||||||
|
"common/welcomeback003.htm",
|
||||||
|
"default/BlessingOfProtection.htm",
|
||||||
|
"default/SupportMagic.htm",
|
||||||
|
"default/SupportMagicServitor.htm",
|
||||||
|
"fisherman/exchange_old_items.htm",
|
||||||
|
"fisherman/fish_appearance_exchange.htm",
|
||||||
|
"fisherman/fishing_manual001.htm",
|
||||||
|
"fisherman/fishing_manual002.htm",
|
||||||
|
"fisherman/fishing_manual003.htm",
|
||||||
|
"fisherman/fishing_manual004.htm",
|
||||||
|
"fisherman/fishing_manual008.htm",
|
||||||
|
"fisherman/fishing_manual009.htm",
|
||||||
|
"fisherman/fishing_manual010.htm",
|
||||||
|
"fortress/foreman.htm",
|
||||||
|
"guard/kamaloka_help.htm",
|
||||||
|
"guard/kamaloka_level.htm",
|
||||||
|
"petmanager/evolve.htm",
|
||||||
|
"petmanager/exchange.htm",
|
||||||
|
"petmanager/instructions.htm",
|
||||||
|
"teleporter/separatedsoul.htm",
|
||||||
|
"warehouse/clanwh.htm",
|
||||||
|
"warehouse/privatewh.htm",
|
||||||
|
};
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
||||||
{
|
{
|
||||||
@@ -45,9 +91,12 @@ public class Link implements IBypassHandler
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
final String content = HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath);
|
final String content = CommonUtil.contains(VALID_BYPASSES, htmlPath) ? HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath) : null;
|
||||||
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
||||||
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
if (content != null)
|
||||||
|
{
|
||||||
|
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
||||||
|
}
|
||||||
player.sendPacket(html);
|
player.sendPacket(html);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@@ -6,5 +6,5 @@ Just tell me what you need.<br>
|
|||||||
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_01.htm">"I want to augment an item."</Button>
|
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_01.htm">"I want to augment an item."</Button>
|
||||||
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_02.htm">"I want to remove an augmentation."</Button>
|
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_02.htm">"I want to remove an augmentation."</Button>
|
||||||
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_exchange.htm">"I want to exchange Life Stones."</Button>
|
<Button ALIGN="LEFT" ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/augmentation_exchange.htm">"I want to exchange Life Stones."</Button>
|
||||||
<Button ALIGN="LEFT" ICON="RETURN" action="link blacksmith_morning001.htm">Back</Button>
|
<Button ALIGN="LEFT" ICON="RETURN" action="bypass -h npc_%objectId%_Chat 0">Back</Button>
|
||||||
</body></html>
|
</body></html>
|
@@ -1,7 +1,7 @@
|
|||||||
<html><body>
|
<html><body>
|
||||||
Grand Master Oltran:<br>
|
Grand Master Oltran:<br>
|
||||||
You are far from your village, adventurer. How do you feel, now that you see the great castle and the ever-changing streets that are the pride of the Humans? I'm sure you admire them, but do not be enticed by their allure. Beneath the most beautiful bed of flowers, there is often a serpent's lair. If you spend much time in this city, you may come to see what I mean...<br>
|
You are far from your village, adventurer. How do you feel, now that you see the great castle and the ever-changing streets that are the pride of the Humans? I'm sure you admire them, but do not be enticed by their allure. Beneath the most beautiful bed of flowers, there is often a serpent's lair. If you spend much time in this city, you may come to see what I mean...<br>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="link guard_class_change2001.htm">"Can you tell me about the 2nd Class Transfer?"</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ClassTransferTalk">"Can you tell me about the 2nd Class Transfer?"</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Clan">Clan</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Clan">Clan</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Alliance">Alliance</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest Alliance">Alliance</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ShadowWeapons">"I want to use my Shadow Item Coupon."</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Quest ShadowWeapons">"I want to use my Shadow Item Coupon."</Button>
|
||||||
|
@@ -6,5 +6,5 @@ When you switch a weapon, the <font color="LEVEL">enchantment, Soul Crystal, aug
|
|||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421202">"I want to change an R95-grade weapon."</button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421202">"I want to change an R95-grade weapon."</button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421203">"I want to change an R99-grade weapon."</button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421203">"I want to change an R99-grade weapon."</button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421204">"I want to exchange a Tauti and Kelbim weapon."</button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 3421204">"I want to exchange a Tauti and Kelbim weapon."</button>
|
||||||
<Button ALIGN=LEFT ICON="RETURN" action="link ev_libra_black001.htm">Back</button>
|
<Button ALIGN=LEFT ICON="RETURN" action="bypass -h Quest RedLibra 34212-1.htm">Back</button>
|
||||||
</body></html>
|
</body></html>
|
@@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.bypasshandlers;
|
package handlers.bypasshandlers;
|
||||||
|
|
||||||
|
import com.l2jmobius.commons.util.CommonUtil;
|
||||||
import com.l2jmobius.gameserver.cache.HtmCache;
|
import com.l2jmobius.gameserver.cache.HtmCache;
|
||||||
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
||||||
import com.l2jmobius.gameserver.model.actor.Creature;
|
import com.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@@ -29,6 +30,51 @@ public class Link implements IBypassHandler
|
|||||||
"Link"
|
"Link"
|
||||||
};
|
};
|
||||||
|
|
||||||
|
private static final String[] VALID_BYPASSES =
|
||||||
|
{
|
||||||
|
"common/attribute_info.htm",
|
||||||
|
"common/augmentation_01.htm",
|
||||||
|
"common/augmentation_02.htm",
|
||||||
|
"common/augmentation_exchange.htm",
|
||||||
|
"common/crafting_01.htm",
|
||||||
|
"common/crafting_02.htm",
|
||||||
|
"common/crafting_03.htm",
|
||||||
|
"common/cursed_to_unidentified.htm",
|
||||||
|
"common/duals_01.htm",
|
||||||
|
"common/duals_02.htm",
|
||||||
|
"common/duals_03.htm",
|
||||||
|
"common/g_cube_warehouse001.htm",
|
||||||
|
"common/skill_enchant_help.htm",
|
||||||
|
"common/skill_enchant_help_01.htm",
|
||||||
|
"common/skill_enchant_help_02.htm",
|
||||||
|
"common/skill_enchant_help_03.htm",
|
||||||
|
"common/smelting_trade001.htm",
|
||||||
|
"common/weapon_sa_01.htm",
|
||||||
|
"common/welcomeback002.htm",
|
||||||
|
"common/welcomeback003.htm",
|
||||||
|
"default/BlessingOfProtection.htm",
|
||||||
|
"default/SupportMagic.htm",
|
||||||
|
"default/SupportMagicServitor.htm",
|
||||||
|
"fisherman/exchange_old_items.htm",
|
||||||
|
"fisherman/fish_appearance_exchange.htm",
|
||||||
|
"fisherman/fishing_manual001.htm",
|
||||||
|
"fisherman/fishing_manual002.htm",
|
||||||
|
"fisherman/fishing_manual003.htm",
|
||||||
|
"fisherman/fishing_manual004.htm",
|
||||||
|
"fisherman/fishing_manual008.htm",
|
||||||
|
"fisherman/fishing_manual009.htm",
|
||||||
|
"fisherman/fishing_manual010.htm",
|
||||||
|
"fortress/foreman.htm",
|
||||||
|
"guard/kamaloka_help.htm",
|
||||||
|
"guard/kamaloka_level.htm",
|
||||||
|
"petmanager/evolve.htm",
|
||||||
|
"petmanager/exchange.htm",
|
||||||
|
"petmanager/instructions.htm",
|
||||||
|
"teleporter/separatedsoul.htm",
|
||||||
|
"warehouse/clanwh.htm",
|
||||||
|
"warehouse/privatewh.htm",
|
||||||
|
};
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
||||||
{
|
{
|
||||||
@@ -45,9 +91,12 @@ public class Link implements IBypassHandler
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
final String content = HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath);
|
final String content = CommonUtil.contains(VALID_BYPASSES, htmlPath) ? HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath) : null;
|
||||||
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
||||||
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
if (content != null)
|
||||||
|
{
|
||||||
|
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
||||||
|
}
|
||||||
player.sendPacket(html);
|
player.sendPacket(html);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@@ -3,8 +3,8 @@ Welcome. What brings you here? My name's Pinter, and I'm one of the proud dwarve
|
|||||||
<a action="bypass -h npc_%objectId%_Link common/duals_01.htm">Craft a dualsword</a><br>
|
<a action="bypass -h npc_%objectId%_Link common/duals_01.htm">Craft a dualsword</a><br>
|
||||||
<a action="bypass -h npc_%objectId%_Link common/weapon_sa_01.htm">Bestow special ability on a weapon</a><br>
|
<a action="bypass -h npc_%objectId%_Link common/weapon_sa_01.htm">Bestow special ability on a weapon</a><br>
|
||||||
<a action="bypass -h npc_%objectId%_Link common/crafting_01.htm">Craft an item</a><br>
|
<a action="bypass -h npc_%objectId%_Link common/crafting_01.htm">Craft an item</a><br>
|
||||||
<a action="bypass -h npc_%objectId%_Link trainer/30298-4.htm">Seal/Unseal armor and accessories</a><br>
|
<a action="bypass -h npc_%objectId%_Chat 4">Seal/Unseal armor and accessories</a><br>
|
||||||
<a action="bypass -h npc_%objectId%_Link trainer/30298-5.htm">Augment an item</a><br>
|
<a action="bypass -h npc_%objectId%_Chat 5">Augment an item</a><br>
|
||||||
<a action="bypass -h npc_%objectId%_multisell 620">Purchase Academy equipment.</a><br>
|
<a action="bypass -h npc_%objectId%_multisell 620">Purchase Academy equipment.</a><br>
|
||||||
<a action="bypass -h npc_%objectId%_SkillList">Learn skills</a><br>
|
<a action="bypass -h npc_%objectId%_SkillList">Learn skills</a><br>
|
||||||
<a action="bypass -h npc_%objectId%_TerritoryStatus">View information about the lord and tax rate</a><br>
|
<a action="bypass -h npc_%objectId%_TerritoryStatus">View information about the lord and tax rate</a><br>
|
||||||
|
@@ -16,6 +16,8 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.bypasshandlers;
|
package handlers.bypasshandlers;
|
||||||
|
|
||||||
|
import com.l2jmobius.commons.util.CommonUtil;
|
||||||
|
import com.l2jmobius.gameserver.cache.HtmCache;
|
||||||
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
||||||
import com.l2jmobius.gameserver.model.actor.Creature;
|
import com.l2jmobius.gameserver.model.actor.Creature;
|
||||||
import com.l2jmobius.gameserver.model.actor.instance.PlayerInstance;
|
import com.l2jmobius.gameserver.model.actor.instance.PlayerInstance;
|
||||||
@@ -28,6 +30,51 @@ public class Link implements IBypassHandler
|
|||||||
"Link"
|
"Link"
|
||||||
};
|
};
|
||||||
|
|
||||||
|
private static final String[] VALID_BYPASSES =
|
||||||
|
{
|
||||||
|
"adventurer_guildsman/AboutHighLevelGuilds.htm",
|
||||||
|
"adventurer_guildsman/AboutNewLifeCrystals.htm",
|
||||||
|
"clanHallDoorman/evolve.htm",
|
||||||
|
"common/augmentation_01.htm",
|
||||||
|
"common/augmentation_02.htm",
|
||||||
|
"common/crafting_01.htm",
|
||||||
|
"common/duals_01.htm",
|
||||||
|
"common/duals_02.htm",
|
||||||
|
"common/duals_03.htm",
|
||||||
|
"common/g_cube_warehouse001.htm",
|
||||||
|
"common/skill_enchant_help.htm",
|
||||||
|
"common/skill_enchant_help_01.htm",
|
||||||
|
"common/skill_enchant_help_02.htm",
|
||||||
|
"common/skill_enchant_help_03.htm",
|
||||||
|
"common/weapon_sa_01.htm",
|
||||||
|
"common/welcomeback002.htm",
|
||||||
|
"common/welcomeback003.htm",
|
||||||
|
"default/BlessingOfProtection.htm",
|
||||||
|
"default/SupportMagic.htm",
|
||||||
|
"default/SupportMagicServitor.htm",
|
||||||
|
"fisherman/fishing_championship.htm",
|
||||||
|
"fortress/foreman.htm",
|
||||||
|
"guard/kamaloka_help.htm",
|
||||||
|
"guard/kamaloka_level.htm",
|
||||||
|
"olympiad/hero_main2.htm",
|
||||||
|
"petmanager/evolve.htm",
|
||||||
|
"petmanager/exchange.htm",
|
||||||
|
"petmanager/instructions.htm",
|
||||||
|
"seven_signs/blkmrkt_1.htm",
|
||||||
|
"seven_signs/blkmrkt_2.htm",
|
||||||
|
"seven_signs/mammblack_1a.htm",
|
||||||
|
"seven_signs/mammblack_1b.htm",
|
||||||
|
"seven_signs/mammblack_1c.htm",
|
||||||
|
"seven_signs/mammblack_2a.htm",
|
||||||
|
"seven_signs/mammblack_2b.htm",
|
||||||
|
"seven_signs/mammmerch_1.htm",
|
||||||
|
"seven_signs/mammmerch_1a.htm",
|
||||||
|
"seven_signs/mammmerch_1b.htm",
|
||||||
|
"teleporter/separatedsoul.htm",
|
||||||
|
"warehouse/clanwh.htm",
|
||||||
|
"warehouse/privatewh.htm",
|
||||||
|
};
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
||||||
{
|
{
|
||||||
@@ -44,10 +91,12 @@ public class Link implements IBypassHandler
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
final String filename = "data/html/" + htmlPath;
|
final String content = CommonUtil.contains(VALID_BYPASSES, htmlPath) ? HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath) : null;
|
||||||
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
||||||
html.setFile(player, filename);
|
if (content != null)
|
||||||
html.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0));
|
{
|
||||||
|
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
||||||
|
}
|
||||||
player.sendPacket(html);
|
player.sendPacket(html);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.bypasshandlers;
|
package handlers.bypasshandlers;
|
||||||
|
|
||||||
|
import com.l2jmobius.commons.util.CommonUtil;
|
||||||
import com.l2jmobius.gameserver.cache.HtmCache;
|
import com.l2jmobius.gameserver.cache.HtmCache;
|
||||||
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
||||||
import com.l2jmobius.gameserver.model.actor.Creature;
|
import com.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@@ -29,6 +30,35 @@ public class Link implements IBypassHandler
|
|||||||
"Link"
|
"Link"
|
||||||
};
|
};
|
||||||
|
|
||||||
|
private static final String[] VALID_BYPASSES =
|
||||||
|
{
|
||||||
|
"common/craft_01.htm",
|
||||||
|
"common/craft_02.htm",
|
||||||
|
"common/runes_01.htm",
|
||||||
|
"common/sealed_runes_02.htm",
|
||||||
|
"common/sealed_runes_03.htm",
|
||||||
|
"common/sealed_runes_04.htm",
|
||||||
|
"common/sealed_runes_05.htm",
|
||||||
|
"common/sealed_runes_06.htm",
|
||||||
|
"common/sealed_runes_07.htm",
|
||||||
|
"common/sealed_runes_08.htm",
|
||||||
|
"common/sealed_runes_09.htm",
|
||||||
|
"common/skill_enchant_help_01.htm",
|
||||||
|
"common/skill_enchant_help_02.htm",
|
||||||
|
"common/skill_enchant_help_03.htm",
|
||||||
|
"fisherman/fishing_manual001.htm",
|
||||||
|
"fisherman/fishing_manual002.htm",
|
||||||
|
"fisherman/fishing_manual003.htm",
|
||||||
|
"fisherman/fishing_manual004.htm",
|
||||||
|
"fisherman/fishing_manual005.htm",
|
||||||
|
"fortress/foreman.htm",
|
||||||
|
"petmanager/evolve.htm",
|
||||||
|
"petmanager/exchange.htm",
|
||||||
|
"petmanager/instructions.htm",
|
||||||
|
"warehouse/clanwh.htm",
|
||||||
|
"warehouse/privatewh.htm",
|
||||||
|
};
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
||||||
{
|
{
|
||||||
@@ -45,9 +75,12 @@ public class Link implements IBypassHandler
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
final String content = HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath);
|
final String content = CommonUtil.contains(VALID_BYPASSES, htmlPath) ? HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath) : null;
|
||||||
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
||||||
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
if (content != null)
|
||||||
|
{
|
||||||
|
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
||||||
|
}
|
||||||
player.sendPacket(html);
|
player.sendPacket(html);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.bypasshandlers;
|
package handlers.bypasshandlers;
|
||||||
|
|
||||||
|
import com.l2jmobius.commons.util.CommonUtil;
|
||||||
import com.l2jmobius.gameserver.cache.HtmCache;
|
import com.l2jmobius.gameserver.cache.HtmCache;
|
||||||
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
||||||
import com.l2jmobius.gameserver.model.actor.Creature;
|
import com.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@@ -29,6 +30,35 @@ public class Link implements IBypassHandler
|
|||||||
"Link"
|
"Link"
|
||||||
};
|
};
|
||||||
|
|
||||||
|
private static final String[] VALID_BYPASSES =
|
||||||
|
{
|
||||||
|
"common/craft_01.htm",
|
||||||
|
"common/craft_02.htm",
|
||||||
|
"common/runes_01.htm",
|
||||||
|
"common/sealed_runes_02.htm",
|
||||||
|
"common/sealed_runes_03.htm",
|
||||||
|
"common/sealed_runes_04.htm",
|
||||||
|
"common/sealed_runes_05.htm",
|
||||||
|
"common/sealed_runes_06.htm",
|
||||||
|
"common/sealed_runes_07.htm",
|
||||||
|
"common/sealed_runes_08.htm",
|
||||||
|
"common/sealed_runes_09.htm",
|
||||||
|
"common/skill_enchant_help_01.htm",
|
||||||
|
"common/skill_enchant_help_02.htm",
|
||||||
|
"common/skill_enchant_help_03.htm",
|
||||||
|
"fisherman/fishing_manual001.htm",
|
||||||
|
"fisherman/fishing_manual002.htm",
|
||||||
|
"fisherman/fishing_manual003.htm",
|
||||||
|
"fisherman/fishing_manual004.htm",
|
||||||
|
"fisherman/fishing_manual005.htm",
|
||||||
|
"fortress/foreman.htm",
|
||||||
|
"petmanager/evolve.htm",
|
||||||
|
"petmanager/exchange.htm",
|
||||||
|
"petmanager/instructions.htm",
|
||||||
|
"warehouse/clanwh.htm",
|
||||||
|
"warehouse/privatewh.htm",
|
||||||
|
};
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
||||||
{
|
{
|
||||||
@@ -45,9 +75,12 @@ public class Link implements IBypassHandler
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
final String content = HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath);
|
final String content = CommonUtil.contains(VALID_BYPASSES, htmlPath) ? HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath) : null;
|
||||||
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
||||||
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
if (content != null)
|
||||||
|
{
|
||||||
|
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
||||||
|
}
|
||||||
player.sendPacket(html);
|
player.sendPacket(html);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.bypasshandlers;
|
package handlers.bypasshandlers;
|
||||||
|
|
||||||
|
import com.l2jmobius.commons.util.CommonUtil;
|
||||||
import com.l2jmobius.gameserver.cache.HtmCache;
|
import com.l2jmobius.gameserver.cache.HtmCache;
|
||||||
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
||||||
import com.l2jmobius.gameserver.model.actor.Creature;
|
import com.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@@ -29,6 +30,35 @@ public class Link implements IBypassHandler
|
|||||||
"Link"
|
"Link"
|
||||||
};
|
};
|
||||||
|
|
||||||
|
private static final String[] VALID_BYPASSES =
|
||||||
|
{
|
||||||
|
"common/craft_01.htm",
|
||||||
|
"common/craft_02.htm",
|
||||||
|
"common/runes_01.htm",
|
||||||
|
"common/sealed_runes_02.htm",
|
||||||
|
"common/sealed_runes_03.htm",
|
||||||
|
"common/sealed_runes_04.htm",
|
||||||
|
"common/sealed_runes_05.htm",
|
||||||
|
"common/sealed_runes_06.htm",
|
||||||
|
"common/sealed_runes_07.htm",
|
||||||
|
"common/sealed_runes_08.htm",
|
||||||
|
"common/sealed_runes_09.htm",
|
||||||
|
"common/skill_enchant_help_01.htm",
|
||||||
|
"common/skill_enchant_help_02.htm",
|
||||||
|
"common/skill_enchant_help_03.htm",
|
||||||
|
"fisherman/fishing_manual001.htm",
|
||||||
|
"fisherman/fishing_manual002.htm",
|
||||||
|
"fisherman/fishing_manual003.htm",
|
||||||
|
"fisherman/fishing_manual004.htm",
|
||||||
|
"fisherman/fishing_manual005.htm",
|
||||||
|
"fortress/foreman.htm",
|
||||||
|
"petmanager/evolve.htm",
|
||||||
|
"petmanager/exchange.htm",
|
||||||
|
"petmanager/instructions.htm",
|
||||||
|
"warehouse/clanwh.htm",
|
||||||
|
"warehouse/privatewh.htm",
|
||||||
|
};
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
||||||
{
|
{
|
||||||
@@ -45,9 +75,12 @@ public class Link implements IBypassHandler
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
final String content = HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath);
|
final String content = CommonUtil.contains(VALID_BYPASSES, htmlPath) ? HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath) : null;
|
||||||
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
||||||
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
if (content != null)
|
||||||
|
{
|
||||||
|
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
||||||
|
}
|
||||||
player.sendPacket(html);
|
player.sendPacket(html);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@@ -2,5 +2,5 @@
|
|||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Link fisherman/fishing_manual002.htm">1. Preparing for fishing</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Link fisherman/fishing_manual002.htm">1. Preparing for fishing</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Link fisherman/fishing_manual003.htm">2. Choosing a fishing spot</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Link fisherman/fishing_manual003.htm">2. Choosing a fishing spot</Button>
|
||||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Link fisherman/fishing_manual004.htm">3. Using a float</Button>
|
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Link fisherman/fishing_manual004.htm">3. Using a float</Button>
|
||||||
<Button ALIGN=LEFT ICON="RETURN" action="bypass -h npc_%objectId%_Link fisherman/30012.htm">Home</Button>
|
<Button ALIGN=LEFT ICON="RETURN" action="bypass -h npc_%objectId%_Chat 0">Home</Button>
|
||||||
</body></html>
|
</body></html>
|
@@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
package handlers.bypasshandlers;
|
package handlers.bypasshandlers;
|
||||||
|
|
||||||
|
import com.l2jmobius.commons.util.CommonUtil;
|
||||||
import com.l2jmobius.gameserver.cache.HtmCache;
|
import com.l2jmobius.gameserver.cache.HtmCache;
|
||||||
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
import com.l2jmobius.gameserver.handler.IBypassHandler;
|
||||||
import com.l2jmobius.gameserver.model.actor.Creature;
|
import com.l2jmobius.gameserver.model.actor.Creature;
|
||||||
@@ -29,6 +30,35 @@ public class Link implements IBypassHandler
|
|||||||
"Link"
|
"Link"
|
||||||
};
|
};
|
||||||
|
|
||||||
|
private static final String[] VALID_BYPASSES =
|
||||||
|
{
|
||||||
|
"common/craft_01.htm",
|
||||||
|
"common/craft_02.htm",
|
||||||
|
"common/runes_01.htm",
|
||||||
|
"common/sealed_runes_02.htm",
|
||||||
|
"common/sealed_runes_03.htm",
|
||||||
|
"common/sealed_runes_04.htm",
|
||||||
|
"common/sealed_runes_05.htm",
|
||||||
|
"common/sealed_runes_06.htm",
|
||||||
|
"common/sealed_runes_07.htm",
|
||||||
|
"common/sealed_runes_08.htm",
|
||||||
|
"common/sealed_runes_09.htm",
|
||||||
|
"common/skill_enchant_help_01.htm",
|
||||||
|
"common/skill_enchant_help_02.htm",
|
||||||
|
"common/skill_enchant_help_03.htm",
|
||||||
|
"fisherman/fishing_manual001.htm",
|
||||||
|
"fisherman/fishing_manual002.htm",
|
||||||
|
"fisherman/fishing_manual003.htm",
|
||||||
|
"fisherman/fishing_manual004.htm",
|
||||||
|
"fisherman/fishing_manual005.htm",
|
||||||
|
"fortress/foreman.htm",
|
||||||
|
"petmanager/evolve.htm",
|
||||||
|
"petmanager/exchange.htm",
|
||||||
|
"petmanager/instructions.htm",
|
||||||
|
"warehouse/clanwh.htm",
|
||||||
|
"warehouse/privatewh.htm",
|
||||||
|
};
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
public boolean useBypass(String command, PlayerInstance player, Creature target)
|
||||||
{
|
{
|
||||||
@@ -45,9 +75,12 @@ public class Link implements IBypassHandler
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
final String content = HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath);
|
final String content = CommonUtil.contains(VALID_BYPASSES, htmlPath) ? HtmCache.getInstance().getHtm(player, "data/html/" + htmlPath) : null;
|
||||||
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
final NpcHtmlMessage html = new NpcHtmlMessage(target != null ? target.getObjectId() : 0);
|
||||||
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
if (content != null)
|
||||||
|
{
|
||||||
|
html.setHtml(content.replace("%objectId%", String.valueOf(target != null ? target.getObjectId() : 0)));
|
||||||
|
}
|
||||||
player.sendPacket(html);
|
player.sendPacket(html);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user