2009/12/15 zryip theSlug <[email protected]>
>
>
> 2009/12/15 Tim Selander <[email protected]>
>
> Is there any way in RR to check for user input during a repeat loop? I'd
>> like a loop to continue until the user types a certain key -- at which point
>> the script would exit the handler.
>>
>> Tim Selander
>> Tokyo, Japan
>> _______________________________________________
>> use-revolution mailing list
>> [email protected]
>> Please visit this url to subscribe, unsubscribe and manage your
>> subscription preferences:
>> http://lists.runrev.com/mailman/listinfo/use-revolution
>
>
Hi again,
In my previous solution I proposed this loop :
*repeat* until charToNum("s") is in the keysDown
However, the use of "is in" to test the presence of a number in a list is
risky. Because for example, "122" may be in "1222,256"
So to prevent bugs prefers this handler to my previous solution :
*on* mouseUp
*put* 0 into fld "Msg"
*repeat* until charToNum("s") is among the items of the keysDown
*-- the charToNum function is necessary to compare the key with the
content returned by the keysDown function. The keysDown function returns a
list of keys in ascii form separated by commas.*
*add* 1 to fld "Msg"
*wait* 30 ticks
*end* *repeat*
*end* mouseUp
- Zryip TheSlug - wish you the best ! 8)
>
_______________________________________________
use-revolution mailing list
[email protected]
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-revolution