Hi there,
I have been having trouble with compound_to_world(). If I run the following program...
-----------------------------------
GlowScript 2.0 VPython
obj1 = cylinder( pos = vec(0,0,0), radius = 0.2, axis = vec(+1,0,0), color = color.yellow )
obj2 = cylinder( pos = vec(0,0,0), radius = 0.2, axis = vec(-1,0,0), color = color.orange )
obj = compound( [obj1, obj2] )
obj.rotate( angle = pi/2, pos = vec(0,0,0), axis=vec(0,0,-1))
world_pos = obj.compound_to_world( vec(1, 0, 0))
print( world_pos)
-----------------------------------
... I get an error message on the second last line saying, "TypeError: up.mag2 is not a function".
What am I doing wrong?
Thanks,
Murray.