openkore icon indicating copy to clipboard operation
openkore copied to clipboard

Talknpc when many NPCs standing on the same cell

Open deezar opened this issue 10 years ago • 17 comments

When there are more than one NPC standing on a cell, talknpc command will only talk to the first npc in the NPC list (nl). This is a problem if you want to talk the other NPC than the first one.

talk command cannot fully substitute because it doesn't support NPC conversation codes.

Possible solution is adding NPC number (from nl) support to the talknpc command. Example: talknpc <NPC#> <NPC conversation codes>

deezar avatar Sep 21 '16 05:09 deezar

Cool idea, but I'm curious what server you're playing on that has multiple NPCs stacked on top of each other?

itsrachelfish avatar Sep 21 '16 18:09 itsrachelfish

I've seen several times in iRO servers. A visible NPC stacked under an invisible NPC making bot unable to initiate talknpc sequences.

deezar avatar Sep 24 '16 05:09 deezar

@deezar Good to know. I play on iRO as well, can you give some examples so we can test?

Exact maps / coordinates would be very helpful. Thanks! :+1:

itsrachelfish avatar Sep 29 '16 00:09 itsrachelfish

idRO has some after the server merger, some Kafras are stacked.

cydh avatar Oct 12 '16 08:10 cydh

It's not the best idea to use the number from nl to specify NPC since it's not permanent. What about using NPC's name?

Also if some NPCs are invisible then maybe we can give priority to the one which is visible. Which NPCs exacly have this problem?

farrainbow avatar Dec 05 '16 22:12 farrainbow

@farrainbow I often use the nl command then the number of npc when I manually using openkore so this is a no fail situation, but when you write a macro often the location is needed then this situation is kind of troublesome.

flacrasec avatar Dec 05 '16 23:12 flacrasec

So can we have some examples?

farrainbow avatar Dec 06 '16 08:12 farrainbow

sorry I personally never experienced the issue I was just wondering if happened, but I dont Understando why the examples did not show up.

flacrasec avatar Dec 06 '16 11:12 flacrasec

i remember the orc lady valentine event years ago, many npcs hide on the same spot

c4c1n6kr3m1 avatar Dec 08 '16 15:12 c4c1n6kr3m1

Now you can add many npc steps into talk command and it will not talk to invisible npcs

Henrybk avatar Aug 14 '17 14:08 Henrybk

@Henrybk Can you clarify? From wiki the talknpc command still looks the same. http://openkore.com/index.php/Talknpc

There's a situation when multiple NPCs stack over a single cell (intentionally or not). It's also possible to have two visible NPCs at the same spot. I cannot remember exactly where is the example of such spot in official server but I could confirm there's. For private servers, they could intentionally do this to render talknpc command unusable.

deezar avatar Sep 21 '17 08:09 deezar

@farrainbow Good suggestion. Using full or part of NPC name would be more favourable since nl doesn't guarantee npc order. Example: talknpc "<NPC name>" <NPC conversation codes>

deezar avatar Sep 21 '17 08:09 deezar

use talk instead of talknpc with talk you give the index of npc (which you can find using nl command thus it has 0 chances of choosing the wrong npc

Nipodemos avatar Sep 21 '17 13:09 Nipodemos

@Nipodemos In my opinion, talk cannot replace the convenience of talknpc. The first command is more suitable for manual play (XKore) rather than the latter command. Imagine an NPC which has 10 response dialogs, talknpc can usually complete it in one macro while talk command requires 10 automacros to effectively respond dialogs.

deezar avatar Sep 22 '17 10:09 deezar

no, you do'nt need 10 automacros, you will just nedd 10 lines you can use: (assuming that you have autoTalkCont 1) &talk(Kafra Employee) talk resp 1 talk resp 3 talk resp 2 talk resp 0

on eventMacro it works perfectly.

Nipodemos avatar Sep 22 '17 15:09 Nipodemos

@Nipodemos I have never tried eventMacro. I'll give it a try. Just a question though, wouldn't it cause disconnection if macro sends talk resp too fast or just faster than response dialog actually appears for you to choose?

deezar avatar Sep 25 '17 17:09 deezar

This is not a problem, Openkore answer's on each 1.5 second , so no DC It will look for an answer only when it needs

And it will continue the conversation normally (the 'c' step) it is automatic when autoTalkCont is 1

Nipodemos avatar Sep 26 '17 01:09 Nipodemos