Don't use loops with functions that incur time penalties. Use timers instead. Loops will tie up the script threads until no scripts will run anymore.
Melanie On 27/03/2014 12:48, Fred Folkerts wrote: > Hello, > > > I want to make use of a script for opening a door using llSetPrimitiveParams. > After a whyle the script does not react anymore on touching. > This happen for example with the following script: > > vector cut = < 0, 0.25 , 0 >; > float step = .015; > > default { > touch_start(integer total_number) { > do { > cut.x += step; > llSetPrimitiveParams([PRIM_TYPE, PRIM_TYPE_CYLINDER, > PRIM_HOLE_DEFAULT, //hole_shape > cut, // cut > 0.95, // hollow > < 0.0, 0.0, 0.0 >, // twist > < 1.0, 1.0, 0.0 >, // top_size > < 0.0, 0.0, 0.0 >]); > } > while (cut.x > 0 && cut.x < .75); > step *= -1; > } > } > When using a new prim with the same script, it works again! > Using the do-while loop in a function it most times doesnt work at all. > Fred / OSGRID > > > > _______________________________________________ > Opensim-users mailing list > Opensim-users@lists.berlios.de > https://lists.berlios.de/mailman/listinfo/opensim-users _______________________________________________ Opensim-users mailing list Opensim-users@lists.berlios.de https://lists.berlios.de/mailman/listinfo/opensim-users