Forum rules - please read before posting.

What is the "Advanced third-person camera"?

2»

Comments

  • Just manually disabled, either while editing or during gameplay. Also if using the Object: Visibility action to make the mesh invisible.

    btw It's not that important for me right now because I'm not actually using it in my current project, but I just thought I'd let you know. If it can't be recreated by anyone else then it is probably just something in my scene.

  • edited September 2019

    So the advanced camera works great! Except in the case of (as usual with me, it seems) saving and loading.

    Whenever I save and load a game, there is a chance that the camera will now be incredibly jittery when I make my character run, and rotate much faster than normal. It seems to be very arbitrary and it doesn't always happen, so I can't pinpoint exactly what causes it.

    Here's a video showing what it looks like:

    For contrast, here is a video showing how the camera usually works:

    (please forgive my crappy placeholder trees!)

    I have a "remember advanced third person camera" component attached to the camera. Is there anything else I need?

    Thanks again!

    -Dave

    edit: I think it may be caused by using your new actionlist command to rotate the camera relative to the target? I am noticing that when this jitteryness happens, it's always after I use that command (combined with a save/reload). Except, like I said, it doesn't ALWAYS happen. So... urf.

  • I shall attempt a recreation. Can you share screenshots of your camera's Inspector, and also that of your Player (the full root GameObject)?

  • Here are screenshots of the inspector! https://imgur.com/a/reYjvyL

    The player object is on the left side on the hierarchy. I selected the "root" gameobject, but I am not sure that is what you mean. I am still very knew to all this terminology!

  • No problem - the "root" refers to the topmost-level in the Hierarchy. In this case, your Player's root is the "Fia" GameObject.

    I've made a quick tweak to the camera package, which may or may not have an effect. Give it a go, and if this still occurs, let's see the Player's root Inspector.

    Even if it seems random, there'll be a consistency somewhere. Are you saving/loading during the rotation caused by the Action, or after? Lets see the Action as well.

    It's hard to tell from the video, but it appears the jitteriness is coming from the rotation, not movement. Is that so? If you move only forward (with the camera directly behind the Player), is there any jittering?

  • No problem - the "root" refers to the topmost-level in the Hierarchy. In this case, your Player's root is the "Fia" GameObject.

    Ah. I have about a dozen components attached to Fia, which will take up several screens to show all of it. I'll see if I continue to have trouble before doing all that.

    I've made a quick tweak to the camera package, which may or may not have an effect. Give it a go, and if this still occurs, let's see the Player's root Inspector.

    Will nab and try!

    Even if it seems random, there'll be a consistency somewhere. Are you saving/loading during the rotation caused by the Action, or after? Lets see the Action as well.

    I am saving and loading AFTER the rotation caused by the action.

    It's hard to tell from the video, but it appears the jitteriness is coming from the rotation, not movement. Is that so? If you move only forward (with the camera directly behind the Player), is there any jittering?

    You are right! The jitters only happen during rotation and movement. The camera also feels like it is moving faster than before.

    Anyway, stand by while I redownload and test it...

  • edited September 2019

    And no joy. :(

    Here's everything in Fia's inspector. There's... a lot. Sorry.
    https://imgur.com/a/wB75ruc

    Here's my camera action as well. There are two. One to set the camera to the right position, and another to transition back to it.
    https://imgur.com/a/hxYSlAs

    Thanks again for all the help!

  • As this only appears to affect rotation, it's unlikely this is related to the player. Still, since you are using some non-AC/Unity scripts, drop Tin Pot into your scene and see if it still occurs. If so, we can rule out it being UCC-related.

    If you downloaded AC in 2018.3 or later, your Tin Pot prefab'll rely on root motion like yours, so it should otherwise be similar enough. He can be found in /Assets/AdventureCreator/Demo/Resources.

    If you get the same behaviour, I think I'll need to have the same scene to play with as I can't get such a problem to occur on my end. This should just be a case of PMing me your scene file, your Manager asset files, and any graphical assets used by the scene's geometry. Such files can be packed up into a .unitypackage file (Assets -> Export package..) - send them over and I'll take a look.

  • I stand corrected, actually. There is jitter when there isn't any rotation. It's just verrry hard to notice. I'll see about packaging up the files!

  • OK I tested it out with Tin Pot and did NOT get the same behavior! So it has something to with my character. Hm. I admit I'm stumped!

  • edited September 2019

    OK. Which Unity version are you using? Just to be clear: your Tin Pot has Root Motion checked in his Animator?

    Most of the third-party components on your Player won't be related - LipSync, UMA Expression shouldn't contribute. Dynamic Character Avatar.. I'm not sure about. My understanding is it's visual only, and shouldn't affect motion - try removing it from the live Player once the game begins.

    While Tin Pot also uses Root Motion (in 2018.3 and later), the key difference between him and your own Player is that he relies on a Character Controller rather than a Rigidbody/Capsule Collider combo. A character that has root motion will ignore the Rigidbody anyway. Try giving your Player (or a copy of, just to test with) the same setup.

  • edited September 2019

    Heh. Sorry for my absolute awful newbie questions, but what do you mean by "character controller"? I am still terribly new to all this. I used a rigidbody/capsule collider combo because that's what the character wizard set up by default. So I should... not do that? What should I use instead?

    I am using Unity 2019.2.0f.1 and the most recent version of AC (I updated yesterday!). And yes, "root motion" was checked.

  • The Character Controller is a Unity component designed to make it easier to script character movement.

    AC defaults to the Rigidbody / Capsule Collider, but the Character Controller can sometimes be more appropriate (e.g. if using root motion, at least so far as my experience goes).

    It may or may not help here, but as Tin Pot (which does seem to work here) does have one, it'd be worth trying out. You can attach such a component by typing in "Character Controller" in the "Add component" menu at the bottom of Fia's Inspector.

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.