# HG changeset patch # User nenolod # Date 1168077615 28800 # Node ID 4333f0bbcc55d243c8d89f4bf544e27491ee58f3 # Parent 2bf7e2965eec51fc30e4ec3b5fe787d45e700e15 [svn] - select waves randomly diff -r 2bf7e2965eec -r 4333f0bbcc55 ChangeLog --- a/ChangeLog Sat Jan 06 01:59:37 2007 -0800 +++ b/ChangeLog Sat Jan 06 02:00:15 2007 -0800 @@ -1,3 +1,11 @@ +2007-01-06 09:59:37 +0000 William Pitcock + revision [896] + - actuatorbin.c was missing. + + trunk/src/rovascope/actuatorbin.c | 76 ++++++++++++++++++++++++++++++++++++++ + 1 file changed, 76 insertions(+) + + 2007-01-06 09:57:34 +0000 William Pitcock revision [894] - rovascope -- a variant of the paranormal visualization engine that is diff -r 2bf7e2965eec -r 4333f0bbcc55 src/rovascope/actuatorbin.c --- a/src/rovascope/actuatorbin.c Sat Jan 06 01:59:37 2007 -0800 +++ b/src/rovascope/actuatorbin.c Sat Jan 06 02:00:15 2007 -0800 @@ -35,18 +35,12 @@ rovascope_get_random_normal_scope(void) { struct pn_actuator *out; - static gint ret = 0; gchar *candidates[] = { "wave_horizontal", "wave_vertical", "wave_radial", }; - if (ret >= G_N_ELEMENTS(candidates)) - ret = 0; - - out = create_actuator(candidates[ret]); - - ret++; + out = create_actuator(candidates[rand() % G_N_ELEMENTS(candidates)]); return out; }