Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Custom Forward/Up vectors, specify allowed rotation axes #28

Closed
wants to merge 3 commits into from

Conversation

rattuscz
Copy link

So this allowes me to setup 2D project with forward as Vector3.up and up vector as Vector3.back
With only Z axis allowed for rotation it correctly rotates the sprites.

Without changing these, the behavior should be the same as before changes - just Slerp is done on Quaternion not on the direction vector.

One major thing to still do is have the Up/Forward vectors as global options. Now it's needed to be set on each DetectableObject separately.. ( managable by prefabs I guess )

TickedVehicle computes rotation using Quaternion from ForwardVector, UpVector and AllowedRotationAxes
@ricardojmendez ricardojmendez self-assigned this Nov 14, 2014
@LordSharpe
Copy link

I've tested this on my 2D project, works well.

@ricardojmendez
Copy link
Owner

Thanks for confirming @LordSharpe. I haven't had a breather to test and integrate myself, but having external confirmation helps assure others who may want to try it.

Cheers!

@pjohalloran
Copy link
Contributor

Are you planning on merging this in? Looks useful for 2D work.

@pjohalloran pjohalloran mentioned this pull request Dec 23, 2015
@ricardojmendez
Copy link
Owner

Closing, as I've merged #39 which has a different 2D support implementation on independent behaviors.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants