canceling button script
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
-
- Posts: 35
- Joined: Sun Feb 02, 2014 12:20 am
canceling button script
how can we stop the execution of a script embedded in button A by clicking on button B.
Re: canceling button script
Hi.
You can do this by including a test in the "A" script, though I would imagine it will be in a loop. Something like:
if the mouse is down and the mouseLoc is within the rect of btn "b" then...
Craig Newman
You can do this by including a test in the "A" script, though I would imagine it will be in a loop. Something like:
if the mouse is down and the mouseLoc is within the rect of btn "b" then...
Craig Newman
Re: canceling button script
Hi Ferhan,
I showed you that here;
http://forums.runrev.com/phpBB2/viewtop ... 263#p97046
In that I used the optionKey but it could have been a button on a card.
If that is not what you meant then just write back, saying how you would need it different.
Simon
I showed you that here;
http://forums.runrev.com/phpBB2/viewtop ... 263#p97046
In that I used the optionKey but it could have been a button on a card.
If that is not what you meant then just write back, saying how you would need it different.
Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!
Re: canceling button script
Simon makes, (likely, since I have not seen what he sent you) the same point, in that some property outside the script can be used as a way to interrupt that script.
I am sure that he suggests testing for the state of the optionKey, just like I suggested testing for the condition of the mouse in conjunction with its loc.
The lesson here is the same. You create an environment where this sort of thing is managed. A further lesson is to understand how LC makes its inner workings accessible, in a very "live" way, and provides the hooks you can exploit to do what you need.
Craig
I am sure that he suggests testing for the state of the optionKey, just like I suggested testing for the condition of the mouse in conjunction with its loc.
The lesson here is the same. You create an environment where this sort of thing is managed. A further lesson is to understand how LC makes its inner workings accessible, in a very "live" way, and provides the hooks you can exploit to do what you need.
Craig