PDA

View Full Version : Adjusting character repeat rate programatically



Suvv
3rd April 2008, 05:37 PM
Hi,

Not sure how to do this so I thought the experts here might be able to help.

In short ...

I want a script that will output say "q" repeatedly at a rate determined by an axis value.

For example ... when the axis is say at 50 "q" would be output slowly but as the axis value increases so does the character rate of "q".

Anyone know how to do this?

Thanks is advance.

Suvv.

DonULFonso
3rd April 2008, 06:42 PM
Since you can calculate on-the-fly in a script this shouldn't be an issue as you'd simply vary an INTERVAL TIMER's "off"-value; you'd need to use a variable istead of a fixed value, that would be all.

Suvv
3rd April 2008, 06:51 PM
Thank you...

have done it like so ...

SCRIPT


CMS.B2 = [JS3.A3 > 140];

A1 = (255-JS3.A3)/30;
TIMER( INTERVAL, D1, 1, A1) = CMS.B2;
CMS.B1 = D1;

CMS.B3 = [JS3.A3 < 116];
A2 = JS3.A3/30;
TIMER( INTERVAL, D2, 1, A2) = CMS.B3;
CMS.B4 = D2;

ENDSCRIPT