Page 1 of 1

Window stay on action

Posted: Sun Jan 20, 2008 10:20 pm
by Void
I'm having a hard time finding a way to keep the same window open after pressing a link inside a npc's html (a bypass to the server). Anyone got a little hint for me?

Thanks in advance.

Posted: Sun Jan 20, 2008 11:52 pm
by Fulminus
I am not sure I understand what you are saying.

Are you saying that when you click on a link, the dialog closes instead of showing you the next page of that dialog?
Or are you saying that if you have a dialog open (say from some NPC or shop or whatever that you were talking to earlier) and you speak with some other NPC, the first dialog closes and in its place you only see the last NPC's text?

Posted: Mon Jan 21, 2008 1:22 am
by Void
fulminus wrote:I am not sure I understand what you are saying.

Are you saying that when you click on a link, the dialog closes instead of showing you the next page of that dialog?
Or are you saying that if you have a dialog open (say from some NPC or shop or whatever that you were talking to earlier) and you speak with some other NPC, the first dialog closes and in its place you only see the last NPC's text?
No... let me explain through an example:

I'm talking to npc X, the dialog window opens. Inside I have some text and some buttons that bypass commands to the server :
<button value="Text" action="bypass -h npc_%objectId%_MyCommand 1">
<button value="Text" action="bypass -h npc_%objectId%_MyCommand 2">
...
I want to do more than one bypass without talking to the npc again (window closes when you click one of the buttons)

Posted: Mon Jan 21, 2008 7:32 pm
by Fulminus
When you click on a bypass, a command is sent to the server and an action is taken. Typically, that action opens another htm dialog, or some different interface (like a shop, multisell, augmentation, skill-learn, etc).

You can easily code your bypasses such that, after the run the requested command, they reopen the same htm that the player was just viewing. Technically, this will close the dialog and pop-up a new dialog that happens to have the same text. However, as far as the player can see, it's just the same page staying up (except refreshing the scroll to the top of the text again). If your text can fit without scrolling, the player won't even know the difference...