[Bf-python] Did .setEuler change between 2.32 and 2.33?

Stephen Swaney sswaney at swbell.net
Wed May 5 08:47:26 CEST 2004


Lone Wolf wrote:
 When I tried to run the same python script
> using 2.33 it got hung up on the following:
> 
> mySphere.setEuler(0,rotation,0)
> 
> I believe that it said that the parameters were of an unknown
> type or something like that. 

It is traditional to include the actual message text.
Often, it contains useful information.

> I tried replacing the 'rotation'
> variable with a number and still got the same error. Perhaps
> there is a better way to rotate an object to a specific point?
> Any suggestions would be greatly appreciated!

According to the latest doc, setEuler() takes either an 
Euler object ( like from getEuler() ) or a list of floats.

A number of methods that previous took 3 values were
changed to accept a list or tuple of 3 values so things
like ob.setEuler(ob.getEuler()) would work.  We tried
to maintain backward compatibility, but that one got broken.

In the meantime, the short answer to your question is to pass
the arguments in a list like this:
mySphere.setEuler( [0,rotation,0] )

-- 
Stephen Swaney			
sswaney at swbell.net



More information about the Bf-python mailing list