Page 1 of 1
Help needed, dialog
Posted: Wed Sep 14, 2005 8:43 am
by rylleman
I've been pulling my hair for quite some time now trying to figure out whats wrong.
I've got a dialog in my script that won't show. I've checked a lot of other scripts with dialogs and the one in my script is working just like those but it won't show.
I also have a bit of trouble with return values from the LM.GUI.ALERT_WARNING at line 128, I don't think I'm using the right code there.
Could both problems be related?
Any help would be very appriciated!
the script
-david
Posted: Thu Sep 15, 2005 10:42 am
by rylleman
Ok, I've solved the first issue. Don't know what was wrong, I rewrote the whole dialog code from scratch and now it works.
But the ALERT_WARNING still doesn't work.
LM.GUI.ALERT_WARNING issue:
In the Scripting reference LM states "After the user clicks a button in the laert box, the function returns 0, 1, or 2, depending if the user pressed button 1, 2, or 3."
But I cant find anything on how to use those values, nor can I find any script using more than one button.
the code I have is;
LM.GUI.Alert(LM.GUI.ALERT_WARNING, "Warning text", "warning line 2", nil, "OK", "CANCEL", nil)
if LM.GUI.ALERT_WARNING == 0 then
print ("ok")
elseif LM.GUI.ALERT_WARNING == 1 then
print ("cncl")
break
end
This is obviously not the right code. How should it look?
-david
Posted: Thu Sep 15, 2005 1:59 pm
by rylleman
Never mind, I figured it out myself.
Posted: Thu Sep 15, 2005 2:11 pm
by Rai López
...SORRY!

If I could I'd help you in this kind of issues, but I only can say you:
GOOD LUCK & CHEER UP! 
(sorry...)
Posted: Thu Sep 15, 2005 3:28 pm
by rylleman
No problem Ramón!, I like you anyway...
I finally managed to get it right and has posted the script in its own thread, Random Switches. Enjoy!
Posted: Thu Sep 15, 2005 3:39 pm
by Rai López
Jaja...
THANK YOU!

...YOU
TOO!!!

I can't wait to try it! BYE!
Posted: Thu Sep 15, 2005 8:14 pm
by mr. blaaa
Well, i'd really like to help but this seems to be some lua internal commands.
And my skills in lua arent very good
But i can make you an Operation Flashpoint map with tons of scripts and dialogues if you wish (Who the hell here needs OFP maps???)
BTW: What exactly will your script do?