November 2, 200520 yr (P:ABSOLUTE TIME, seconds) flr 60 % )the above turns absolute time into a number from 1-60 counting down.im monkey see monkey do programer, dont really know what the flr does, know it means floor but what that is ..no clue.i know some has done this, press a button and the stop watch starts, press again stops,resets to 12:00. minute and second hands only.can some one get me started?
November 2, 200520 yr Hi Here is the code I used for the stop watch in My tiger mothhttp://library.avsim.net/sendfile.php?Loca...=ftp&DLID=62066its a mod of the one thats comes with the wright flyercheersWozza (L:Stop Watch,bool) 1 == if{ (** Init T0 if not already initialized **) (G:Var1) 0 == if{ (P:Local time,seconds) (>G:Var1) } (** Calculate delta time **) (** dT = T1 - T0 **) (P:Local time,seconds) (G:Var1) - (>L:Watch_ElapsedTime,seconds) } els{ (** Reset the clock **) 0 (L:Stop Watch,bool) } (L:Watch_ElapsedTime,seconds) 60 / flr 60 % (L:Watch_ElapsedTime,seconds) flr 60 %(L:Watch_ElapsedTime,minutes) 60 / flr 60 % 0 (>G:Var1) 0 (>L:Watch_ElapsedTime,seconds,seconds) (L:Stop Watch,bool) 0 (>L:Stop Watch,bool) ! (>L:Stop Watch,bool)
November 2, 200520 yr thanks man! this is what i came up with....man it was ugly! but it worked and in positive numbers (G:Var1) (P:ABSOLUTE TIME, seconds) - (>G:Var2) (G:Var2) 30 - 60 / (>G:Var3) (G:Var3) -1 * (>G:Var3)(G:Var2) flr 60 % -1 *(G:Var3) 1 - (P:ABSOLUTE TIME, seconds) (>G:Var1) 0 (>G:Var3)
Create an account or sign in to comment