Jump to content

Question

Posted (edited)

I have code, tips that why not working?

 

i click tiara and nothing...

 

 

Trailer.java

package l2ro.gameserver.model.instances;

import l2ro.gameserver.model.Player;
import l2ro.gameserver.templates.npc.NpcTemplate;

public final class CustomTrainer extends NpcInstance
{
	private static final long serialVersionUID = 5938813598479742068L;
	
	public CustomTrainer(int objectId, NpcTemplate template)
	{
		super(objectId, template);
	}
	
	@Override
	public void onBypassFeedback(Player player, String command)
	{
		if (!canBypassCheck(player, this))
		{
			return;
		}
		if (command.equalsIgnoreCase("learn"))
		{
			player.sendMessage("Your gender has been changed !!");
		}
		else
		{
			super.onBypassFeedback(player, command);
		}
	}
	
	@Override
	public boolean isNpc()
	{
		return true;
	}
	
}

NPC xml

<npc id="53000" template_id="37006" name="Skill Trainer" title="Skill Trainer">
		<set name="aggroRange" value="0" />
		<set name="ai_type" value="CharacterAI" />
		<set name="baseAtkRange" value="40" />
		<set name="baseCON" value="43" />
		<set name="baseCritRate" value="40" />
		<set name="baseDEX" value="30" />
		<set name="baseHpMax" value="2444.468" />
		<set name="baseHpRate" value="1" />
		<set name="baseHpReg" value="7.5" />
		<set name="baseINT" value="21" />
		<set name="baseMAtk" value="780" />
		<set name="baseMAtkSpd" value="500" />
		<set name="baseMDef" value="382" />
		<set name="baseMEN" value="20" />
		<set name="baseMpMax" value="1345.8" />
		<set name="baseMpReg" value="2.7" />
		<set name="basePAtk" value="1303" />
		<set name="basePAtkSpd" value="253" />
		<set name="basePDef" value="471" />
		<set name="baseRunSpd" value="120" />
		<set name="baseSTR" value="40" />
		<set name="baseShldDef" value="0" />
		<set name="baseShldRate" value="0" />
		<set name="baseWIT" value="20" />
		<set name="baseWalkSpd" value="80" />
		<set name="collision_height" value="60.00" />
		<set name="collision_radius" value="20.0" />
		<set name="level" value="70" />
		<set name="rewardExp" value="0" />
		<set name="rewardRp" value="0" />
		<set name="rewardSp" value="0" />
		<set name="shots" value="NONE" />
		<set name="texture" value="" />
		<set name="type" value="CustomTrainer" />
		<!-- <set name="type" value="Npc" /> -->
		<attributes>
			<defence attribute="fire" value="150" />
			<defence attribute="water" value="150" />
			<defence attribute="wind" value="150" />
			<defence attribute="earth" value="150" />
			<defence attribute="holy" value="150" />
			<defence attribute="unholy" value="150" />
		</attributes>
	</npc>

53000.htm

<html noscrollbar>
<body>
<title>Open Beta Store</title>
<table border=0 cellpadding=0 cellspacing=0 width=292 height=358 background="l2ui_ct1.Windows_DF_TooltipBG">
	<tr>
		<td align=center>
			<br>
			<table cellpadding=0 cellspacing=0>
				<tr>
					<td align=center width=290 height=12>
						<font color="AAAAAA">Hello %nick%</font>
						<br>
					</td> 
				</tr>
				<tr>
					<td align=center>
						<font color="AAAAAA">This is a free shop for just for Beta Test.</font>
					</td> 
				</tr>
				<tr>
					<td align=center>
					<br>
						<img src="L2UI.SquareGray" width=290 height=1>
					</td> 
				</tr>
			</table>
		</td>
	</tr>
	<tr>
		<td align=center>
			<table cellspacing=0 cellpadding=0>
				<tr>
					<td align=center>
						<table cellspacing=0 cellpadding=0 border=0 width=128 height=128 valign=top background="L2UI_CH3.Icon.refinegrade2_00">
							<tr>
								<td height=33></td><td></td>
							</tr>
							<tr>
								<td width=3></td>
								<td width=32 height=32 align=center >
									<table border=0 cellspacing=0 cellpadding=0 width=32 height=32 background="icon.accessory_noblesse_tiara_i00">
										<tr>
											<td width=32 height=32 align=center valign=top>
												<button action="bypass -h CustomTrainer learn" width=34 height=34 back="L2UI_CT1.ItemWindow_DF_Frame_Down" fore="L2UI_CT1.ItemWindow_DF_Frame"/>
											</td>
										</tr>
									</table>
									<font name=CREDITTEXTNORMAL>Addd RandomSkill</font>
								</td>
							</tr>
						</table>
					</td>
				</tr>
			</table>
		</td>
	</tr>
</table>
</center>
</body>
</html>
Edited by Heroic9614

5 answers to this question

Recommended Posts

  • 0
Posted (edited)

Bypass seems wrong, such style normally is used for quests / scripts. Instance npc use bypass -h %getObjectId%_learn or so, typing from memory :P

 

And you miss showChatWindow / getHtmlPatch? Check other instances, the structure.

Edited by SweeTs
  • 0
Posted (edited)

Instance - https://pastebin.com/2mqfFCPA put your htm into custom folder. The inNpc() method is not necessary, I guess.

 

Bypass - checked L2Ro htm and seems like the npc bypass looks like, but it's not as a button

[npc_%objectId%_learn|Press me]

Button

<button value="Press me" action="bypass npc_%objectId%_learn" width=34 height=34 back="L2UI_CT1.ItemWindow_DF_Frame_Down" fore="L2UI_CT1.ItemWindow_DF_Frame">
Edited by SweeTs
  • 0
Posted (edited)

http://imgur.com/a/VqSwG

 

 

this is problem... :/

[21.07.17 14:11:43:018]  WARN model.Player: Direct access to bypass: npc_268436770_learn / Player: Test
[21.07.17 14:11:43:550]  WARN model.Player: Direct access to bypass: npc_268436770_learn / Player: Test
[21.07.17 14:11:43:730]  WARN model.Player: Direct access to bypass: npc_268436770_learn / Player: Test
[21.07.17 14:11:43:895]  WARN model.Player: Direct access to bypass: npc_268436770_learn / Player: Test
[21.07.17 14:11:44:081]  WARN model.Player: Direct access to bypass: npc_268436770_learn / Player: Test
[21.07.17 14:11:44:248]  WARN model.Player: Direct access to bypass: npc_268436770_learn / Player: Test
[21.07.17 14:11:44:433]  WARN model.Player: Direct access to bypass: npc_268436770_learn / Player: Test
[21.07.17 14:11:44:574]  WARN model.Player: Direct access to bypass: npc_268436770_learn / Player: Test
Edited by Heroic9614

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



  • Posts

    • 🎉 ¡Llega EuroLatinL2! 🎉 🌍 Un servidor Interlude x20 con esencia retail y ajustes justos para una experiencia única. 🧠 Desarrollado por profesionales rusos, EuroLatinL2 está basado en el cliente original de Lineage II Interlude. Buscamos revivir lo mejor de la vieja escuela con un balance perfecto entre nostalgia y jugabilidad moderna. 🛡️ ¿Qué hace diferente a EuroLatinL2? ✨ Rates Mid x20 – Equilibrados para un progreso fluido, sin perder el desafío. 🧪 Experiencia 100% retail con leves ajustes para mantener el interés. ⚔️ Raid Bosses épicos ajustados al nivel 80. 💡 Nada de GM Shop, sin buffs OP, sin teleport personalizados. ⛩️ Solo tiendas y contenido original de Lineage II. 🧙 Buffer básico (solo Prophet), duración de 60 minutos. 🔄 Sistema de héroes cada 15 días y Olimpiadas 2h por día. 🛒 Sistema de donaciones solo para servicios estéticos y premium (sin pay-to-win). 🧬 Sistema de skins para armas y armaduras (solo apariencia). 💤 AutoFarm disponible solo con adena/premium, opcional. 🔥 ¿Quieres volver a disfrutar Lineage II como en sus mejores tiempos? 💬 Completa quests, forma grupos reales, derrota jefes con estrategia, y recolecta recetas (¡incluso para Soulshots!). ⏳ ¡La apertura está muy cerca! 🚪 No te quedes fuera de esta aventura. Vive Lineage II como debe ser. 🌐 Sitio oficial: https://eurolatin.eu 📣 ¡Comparte con tu clan y prepárate para la nostalgia! #Lineage2 #Interlude #EuroLatinL2 #L2Classic #PvE #PvP #NostalgiaL2
    • Still looking to adapt packets to allow modern client to connect on my GF Extender.
    • Καλησπέρα,  Αναζητώ Lineage II C3 Rise of Darkness client (καθαρή έκδοση) και το απαραίτητο αρχείο System για Windows 10/11 Προσφέρω αμοιβή για τη βοήθεια  Ευχαριστώ.   Good evening,  I am looking for a Lineage II C3 Rise of Darkness client and the necessary System file for Windows 10/11 compatibility I am willing to pay for assistance  Thank you    Add me Discord: devibtv  or dm here                                                        @AlisaCodeDragon
    • Sorry, I didn't get to read everything you actually wrote, I don't think it has value. Regards.
    • "Why do you have problems with all forum users?" I dont. I respond based on how people act toward me or my clients! You are defending someone who has been trash-talking me and attacking me directly. And somehow you think I’m the one creating the problem? Did you even bother to check what actually happened, or did you just jump on his side?    While there is another guy that knows and calls him out, he is a known scammer. on this very same topic   If you believe I have issues with all forum users, name them, vilmis is not all forum users.   Besides, this looks like you are just another Vilmis alt accounts blindly backing him without facts.   Tinker123aa I have an alergy on scammers you see, ill wait for your list of all forum users tho.
  • Topics

×
×
  • Create New...

AdBlock Extension Detected!

Our website is made possible by displaying online advertisements to our members.

Please disable AdBlock browser extension first, to be able to use our community.

I've Disabled AdBlock