I want to apply a force to object 1 based on the orientation of object 2. I have no clue how I would do this, and I suspect it would take many hours for me to figure this out. any ideas?
so - > " worldOrientation.col = x axis"
multiplier is just a number you set…
#Variables strenght = 10 #Get vector based on objectB orientation direction = [strenght, 0, 0] #X axis vector = objectB.getAxisVect(direction) #Aply force to objectA objectA.applyForce(vector, False)
thanks. it took a little fiddling to get it to work with my scripts, but it works.
um my script is 1 line, and object.worldOrientation.col is very handy for many things.
I tried it, and couldn’t make it work. I’m not sure what I did wrong.
edit: I just figured out why I couldn’t make it work. I needed to use the y axis not the x. thanks for the help. I’m sorry I didn’t give you the thanks you deserved.
I just wanted to expose the method
I use align axis to vect -> worldOrientation.col alot