I created a player character and set up a scene following the first person tutorial, except that I used standard Unity colliders. When I bump into geometry with collision, my player starts rotating slowly in one direction or the other. Each impact either modifies the speed of rotation or reverses it, but there's no obvious way to cancel it completely.
I'll start from scratch to see if I missed a step somewhere or did something wrong, but figured I'd ask if anything comes to mind as a potential cause from someone with more expertise with Adventure Creator. Thanks!
It looks like you're new here. If you want to get involved, click one of these buttons!
Comments
Welcome to the community, @CraigHubbard.
You're referring to the colliders you've added for the walls, I take it?
Colliders alone shouldn't cause objects to start turning - that's more down to the use of a Rigidbody, though AC should be able to work with one just fine. Do you have a Rigidbody attached to your Player?
If so, it may be down to some field you've set inside it - you're welcome to post screenshots of your scene + wall / Player Inspectors and I'll try to spot the issue, but it's not clear if this is down to AC, Unity, or perhaps some other asset present. What are your Unity and AC versions?
It'd be worth trying out the 3D Demo game's Player character, Tin Pot, to see if he has the same issue. Doing so will help determine if the issue lies with your scene, or with the character. He can be found in /Assets/AdventureCreator/Demo/Resources. If you drop him into the scene, he'll override the Player prefab assigned in your Settings Manager temporarily.
Instead of a Rigidbody and Capsule Collider pairing, Tin Pot relies on a Character Controller component which serves the purpose of both. If he fares better in your scene, that may be the key difference.
Thanks for the quick response!
My player did indeed have a rigidbody, so I tried removing it as a test, but then I wasn't colliding at all, even with an Adventure Creator collision box and even after removing and readding the player's capsule collider. That makes me think what was happening previously is that the rigidbody must've been intersecting weirdly with geometry, causing some kind of physics issue that set it spinning. What's especially confusing is that I wasn't falling through the floor, so it's not like I wasn't colliding at all...
Anyway, I think it was a problem with the scene itself, as even swapping in your first person player prefab didn't help.
But I set up a new test scene and now everything seems to be working properly. If I ever figure out a repro, I'll let you know.
In the meantime, enough QA! Back to prototyping!