# 'wait' command in Multi Script



## gmet (Aug 25, 2010)

Guys,

I have alsmost finished a wordbuilder multiscript for EWQLSC, however I need to implement a 'wait' command which Multi KSP doesn't recognise. Does anyone know of a clever workaround to specify a delay in ms?

Regards,

Justin


----------



## gmet (Aug 25, 2010)

There is this work-around to calculate the time between note-ons and Multi KSP understands this. I, however, need to specify a wait time after a single note-on. Any ideas using the $ENGINE time parameters?



> *on init*
> ``*declare* $lasttime
> ``*declare* $Offset
> ``*declare* ui_value_edit $ms_value(0,1000,1)
> ...


----------



## Mark Belbin (Aug 26, 2010)

Justin,

I'm sure you're trying to do it all in the multiscript for a ton of good reasons, but if you're stuck, perhaps you could create a simple script to put in slot 1 of each of the instruments which takes conditions and values from your multiscript to invoke the wait....

I haven't done a lot of multiscripting, so I'm not even sure what the methods are to pass data from multi to instrument script. You could trigger notes that aren't mapped, set controller values, for sure, if they're adequate for your needs. Do multiscripts handle setting of PGS key values? If so, that might work too.

Just some random, probably-not-very-useful thoughts, FWIW.

Good luck,
Mark


----------



## EvilDragon (Aug 26, 2010)

A good way of communicating with multiscripts is using NRPN. Not sure that PGS works.


----------



## gmet (Aug 26, 2010)

I'm pleased to report that the 'wait' command does indeed work in multiscripts. I was using millisecond(ms) values instead of microsecond(us) :oops: 

Justin


----------



## Mark Belbin (Aug 26, 2010)

Ouch. That one's bitten me on rear end before too(As regards engine uptime being in milli, as opposed to micro)! Wish I'd thought of it, but I guess I took your statemnt that it didn't work as gospel, as opposed to something to investigate...

Glad you figured it out!


----------



## gmet (Aug 28, 2010)

Thanks for the support guys. I have now finished it and a demo ishere.

Justin


----------

