Jump to content
  • 0

onFirstTalk Function


janiko
 Share

Question

Hi, i was writing Seven Signs quest but onFirstTalk function i stuck.

when i talk to npc example : 

npcId == WestTeleportControlDevice

 

it shows me exact html what is written onFirstTalk function but,

when i press to teleport button it has no reaction.

 

Bypass of html

<a action="bypass -h Quest ToTheMonastery TeleWest">Move to West Watcher's Room</a>

 

i have written TeleWest function to teleport on exact cordinates, but no reaction,

hope mxc will help

	@Override
public String onFirstTalk(L2Npc npc, L2PcInstance player)
{
     	  int npcId = npc.getNpcId();
	if(npcId == WestTeleportControlDevice)
		return "32816-01.htm";
	else if(npcId == NorthTeleportControlDevice)
		return "32817-01.htm";
	else if(npcId == EastTeleportControlDevice)
		return "32818-01.htm";
	else if(npcId == SouthTeleportControlDevice)
		return "32819-01.htm";

	for(int[] d : desks)
		if(Util.ArrayContains(d, npcId))
		{
			if(npcId == d[0])
				return npcId + "-01.htm";
			else
				return "empty_desk.htm";
		}

	return null;
}

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

  • 0

Bypasses are related to onAdvEvent.

 

onFirstTalk changes behavior of the first HTM (the one shown when you double click on a NPC).

 

Btw you don't show anything related to TeleWest, so I can't say what you did wrong. Check panda sig.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

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.

 Share



×
×
  • 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