Jump to content

Consecutive message boxes


Recommended Posts

I want to show two message boxes. I can't use the dialog command, because I want to attach a script to the OK-button.

The problem: the first box doesn't wait for the OK-button to be pushed, it just runs through.

Edited by MKW
Link to comment



Have you used a button script before? It's a great feature for what you want to do.


I attached a screen captured image of the message box window, and here is the direction on how to use a button script feature.


Fill in the Button 1 or 2 text box if you want to customize your buttons. After that, click,

Click on Script to run when button clicked...


After that, create a script to execute when the button is clicked. Go to IF-THEN and there should be an option that says, "if a button is clicked on a message box.."


Does this make sense? Good luck! Let me know how it goes! :D




Edited by J2B2
Link to comment


That's a nice workaround, but it doesn't really solve my problem.

The first message is optional. It is nested in an if-statement.

The second message should be shown every time.


btw: I think it is a bug, which should be fixed.

Link to comment

The first message is optional. It is nested in an if-statement.

The second message should be shown every time.


You could create a messagebox in the 'else' part which is identical to the secondary messagebox in the 'if' part.

In this code, if variable var equals "something" msgbox1 will be displayed followed by msgbox2

if var is not equal to "something" just the 'copy of msgbox2' is displayed:


function zonezone2:OnEnter()
-- #GroupDescription=enterzone --
-- #Comment=enterzone Comment --
if   Wherigo.NoCaseEquals(var,"something") then
Wherigo.MessageBox{Text=[[copy of msgbox2 ]],}
------End Builder Generated functions, Do not Edit, this will be overwritten------
------Builder Generated callbacks, Do not Edit, this will be overwritten------
cartlua.MsgBoxCBFuncs.MsgBoxCB1 = function(action)
if action ~= nil then
-- #GroupDescription=oinclick --
-- #Comment=oinclick Comment --

Link to comment

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.

Reply to this topic...

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

  • Create New...