sign() question

Discuss Lemur and share techniques.
Post Reply
oran-outan
Newbie
Posts: 39
Joined: 18 Dec 2011 17:30

sign() question

Post by oran-outan »

hi

if i used : dir = sign(speed) I receive value like :

0. nan 0.
nan nan 0.
...

my code is :

(script on frame) :
decl i;
for (i=0;i<3;i++){
Accel_XYZ = accelerometer;
}

(on expression) : speed = Accel_XYZ-Last_XYZ

speed values are float whose oscillate between +0. / -0.
sign can run with float ?
my interest is detect if I'm on acceleration or deceleration.

thanks for your help
O-O
Post Reply