Howto:Animate gear scissors: Difference between revisions

Jump to navigation Jump to search
m
→‎Required tools: Absolute value since negative numbers created by 1-x*x will cause an error when being rooted
m (Little styling)
m (→‎Required tools: Absolute value since negative numbers created by 1-x*x will cause an error when being rooted)
Line 7: Line 7:
* This little peace of nasal code. Copy and paste this code into a file called '''gearscissor.nas'''.
* This little peace of nasal code. Copy and paste this code into a file called '''gearscissor.nas'''.
  import("math");
  import("math");
  var acos = func(x) { math.atan2(math.sqrt(1-x*x), x) }
  var acos = func(x) { math.atan2(math.sqrt(math.abs(1-x*x)), x) }
  var R2D = 180.0 / math.pi;
  var R2D = 180.0 / math.pi;
   
   
483

edits

Navigation menu