Page 1 of 1

The script doesn't work before a certain time

PostPosted: Tue Feb 16, 2010 7:55 pm
by Rideg
Hello, I'm having problems with spawning stuff though they doesn't spawn before sim.time is around 12 sec. I'm posting the script so you can see for yourself
Code: Select all
(e)=>{
    (sim.time - e.geom.controllerAcc) >= scene.my.simtime ? {         Scene.addPolygon({             surfaces := scene.my.surfaces;             angle := math.atan(e.normal(1) / (e.normal(0) + 1)) * 2;             opaqueBorders := false;             collideWater := true;             vel := -3 * scene.my.vector1;             angvel := 10.0;             heteroCollide := false;             color := [0.487, 0.5, 0.0, 1.0];             drawBorder := false;             collideSet := 8;             buttonDestroy := "x";             entityID := 9661;             zDepth := 1873;             geomID := 45;             pos := scene.my.ejectpos1;             polyTrans := [0.9896672, 0.0, 0.0, 0.9896672]         });         scene.addPen({             geom := 45;             relPoint := [0.20296955, 0.0];             color := [0.3, 0.3, 0.3, 0.5];             fadeTime := 0.5;             size := 0.04;             entityID := 9888;             zDepth := 1872         });         e.geom.controllerAcc = sim.time     } : {} }

Re: The script doesn't work before a certain time

PostPosted: Tue Feb 16, 2010 8:35 pm
by standardtoaster
Did you make sure that the controllerAcc was set to zero when you started?

Re: The script doesn't work before a certain time

PostPosted: Tue Feb 16, 2010 10:06 pm
by Rideg
whoops my bad Thank you :P