Forum rules - please read before posting.

First person player movement method with custom camera script

Hello, I found some advice on a smooth first person camera on this forum, the integration works well using basic camera script, but only if I use direct movement control,since the game is in first person I would like to use the movements taken directly from first person movement method, does anyone have any advice for me? I would like to avoid having to rewrite a script for the first person and integrate it later, need to simplify everything keeping AC as much original as possible, thanks in advance: D

Comments

  • What trouble are you having with the provided first-person camera that is making you resort to a custom script? A "Free-aim acceleration" field is provided in the Settings Manager.

    To use a custom free-aiming script, set the Movement method to Direct, and the Direct-movement type to Tank Controls. You'll also have to ensure that the custom script turns the character left and right - not the camera child - so that their forward-facing direction changes as you free-aim.

  • Hi Chris, problem is that even tweaking parameters in free-aim acceleration i get a sense of jerky camera movement, let me say its much better than the original one but not yet what i'm looking for. I did a try changing movement method to direct and change movement type to tank control but it gives me only forward and backward movement avoiding strafe (maybe i'm missing something?), while the custom script is the one from torahhorse, which has already a rotation X dedicated for player and Y only for camera.

  • My mistake - yes, that would prevent srafing.

    Typically, it's necessary to override both movement and free-aiming for a custom first-person control - see e.g. the integrations for UFPS or Unity's Third Person Controller.

    Can you share a link for me to look at?

  • edited March 2020

    Ok perfect, i did a few videos i'll delete later.
    This is camera mouse look from torahhorse

    And this is the AC orginal one:

    This is the link for the first person drifter from torahhorse:
    http://www.torahhorse.com/index.php/portfolio/first-person-drifter-for-unity/

    Just a note:
    The AC one camera looks like is jumping "pixels" from my view, so i had to reduce the freelook sensitivity to place cursor in the right points i wanted to look, if i keep freelook sensitivity higher than actual 5 x and 5 y i'll not be able easily point cursor. Free-aim settings are the default, while for input settings i've follow the input setting section from the AC site web.

  • You're linking to a character controller asset, though - not just a camera script. This drifter asset should be able to handle the movement as well.

    What you'll want to do is use this as a custom motion controller to override AC's player movement completely - which would be more clean than trying to merge half and half together.

    See the Manual's "Custom motion controllers" chapter, as well as the example integrations on the AC wiki. The script/steps in the page I linked to above is very generic - removing any references to "RigidbodyFirstPersonController" should get you most of the way there.

  • Ok, now its clear, thanks again i appreciate :blush:

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.