|
shalimar GURU
Joined: 04 Aug 2002 Posts: 4691 Location: Pensacola, FL, USA
|
Posted: Thu Oct 04, 2007 6:15 am
[2.04] #MATH with extra parenthasis |
#MATH sideC (%sqrt((@sideA*@sideA)-(@sideB*@sideB)))
The extra evaluation parenthesis throw off the command, resulting in a value of 0. I was using it for order of operations (though i now see it isnt needed).
P.S. is there a way to do sines and cosines in CMUD? |
|
_________________ Discord: Shalimarwildcat |
|
|
|
Tech GURU
Joined: 18 Oct 2000 Posts: 2733 Location: Atlanta, USA
|
Posted: Fri Oct 05, 2007 1:11 am |
This worked for me with the extra parenthesis.
To answer your PS question, the answer is yes. You can use the Lua math functions: math.sqrt, math.log, math.tan, math.cos and math.sin. math.pi |
|
_________________ Asati di tempari! |
|
|
|
Zugg MASTER
Joined: 25 Sep 2000 Posts: 23379 Location: Colorado, USA
|
Posted: Fri Oct 05, 2007 1:22 am |
Maybe you can give us the exact values of the variables that was causing it to fail. I can't get it to fail here either.
|
|
|
|
shalimar GURU
Joined: 04 Aug 2002 Posts: 4691 Location: Pensacola, FL, USA
|
Posted: Fri Oct 05, 2007 1:45 am |
Bah... i hate it when i cant reproduce an error the next day.
|
|
_________________ Discord: Shalimarwildcat |
|
|
|
|
|