#Rotation lock

1 messages · Page 1 of 1 (latest)

green wren
#

You want the ball to rotate, while keeping the explosion pos static, relative to ball's position

#

So as long as you only rotate ball, but move Player you're good

#

Ah

#

I think you could achieve that with obscure Quaternion calculations

#

But it seems, that like for me, quaternions are way too abstract

#

So if I did a roll-a-ball, how would I keep a child of an object static

#

That's the question

#

A first would be to lock the rotation of the explosion pos so it's always (0,0,0)

leaden haven
#

just add a rigidbody and lock the z rotation, and turn off gravity. you can set its collider to trigger so it dosnt hit anything. This is a solution I wrote for completely locking camera rotation without using a RigidBody. Just create this script and add it to your camera (or whatever you want to lock)

green wren
#

Then, apply an offset forwards

#

Oh there we go

leaden haven
#

yes but you cant change the ammount later

#

bro im just trying to spit fax about programming

#

LOL