Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice

Third Person Controller - Third Person, AI, Multiplayer, Mobile Framework

Discussion in 'Assets and Asset Store' started by opsive, Jan 21, 2015.

Thread Status:
Not open for further replies.
  1. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,093
    The ability start/stop types changed with the most recent version so take a look at the bottom of this post for what to update them to.

    Did you download a new set of Adventure Creator files? It should be fixed in the latest version. With the new Adventure Creator files the sample scene should switch cameras when you enter the green trigger.
     
  2. namdo

    namdo

    Joined:
    Feb 23, 2015
    Posts:
    200
    Yes its the run turn. I use adventure mode because I don't like root motion.
    I added run using Speed change but she still can't turn up left when running. Instead of 360 degrees, it's more like 270 degree movement.
     
  3. Porto881

    Porto881

    Joined:
    Jul 11, 2013
    Posts:
    74
    I get an error when importing the new AC-files:
    Assets/Third Person Controller/Integrations/Adventure Creator/Integration/AdventureCreatorControllerBridge.cs(10,18): error CS0101: The namespace `Opsive.ThirdPersonController.ThirdParty.AdventureCreator' already contains a definition for `AdventureCreatorControllerBridge'
     
  4. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,093
    Root motion is independent of the movement type so you may still have it enabled. You can disable root motion at the top of the RigidbodyCharacterController. In terms of the speed change, have you tested Naomi in the adventure scene? When you are in adventure mode only the straight run animation plays because the movement is independent of the camera.

    Make sure you first remove the previous version of the Adventure Creator files.
     
  5. Porto881

    Porto881

    Joined:
    Jul 11, 2013
    Posts:
    74
    That did the trick, it seems to be working now :) But the weird falling state is still there even though I changed the new start/stop types, I changed a couple of animations on my character though so maybe thats the problem. I´m gonna change character so it doesn´t really matter right now. I will ask for help if I encounter it later.
     
  6. MIK3K

    MIK3K

    Joined:
    Sep 10, 2014
    Posts:
    144
    I had this same thing. Just check the settings in your abilities. I think I changed the fall "stop type" to manual. Had to check all the other settings also because my character was stuck in the crawl, but it's all good now. I was setting up a new character and compared settings between the two is how I found the settings different on the old character.

    Edit - Actually, I may have got that wrong. The character was set to a "grounded" state in one of the settings and that has changed in the animator. I just deleted that field I think it was in the "animator monitor" component of the character under "rigid body character controller."

    The best thing might be to take a few minutes to set up a new character, add some abilities per the dev's videos, and just compare the abilities and animator monitor settings between the old and the new character. Shouldn't take more than half an hour. It helped me understand a little better how everything works.
     
    Last edited: Jan 5, 2016
    opsive likes this.
  7. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,093
    Thanks @MIK3K! Yeah I debated if I wanted to make this change knowing it would require you to set the start/stop type again but I figured that it is better in the long run. It is also only an enum change so it doesn't take much to update from a previous version. If you compare your character to a demo scene character or look at the start/stop types within the release notes thread you can quickly get everything back to normal.

    For reference the fall ability should have:
    Start Type: Automatic
    Stop Type: Manual
     
  8. Gametyme

    Gametyme

    Joined:
    May 7, 2014
    Posts:
    617
    I copied the settings from the adventure AC for quick movement to the shooter AC and still only quick stops even when turning.
     
  9. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,093
    As a test does the adventure scene correctly quick turn? Have you tried copying the ability values from that scene? And just to be sure, your custom character is using the adventure movement type, correct? The quick turn animation will only play if the character tuns more than the rotation on the y axis is more than the quick turn angle value. This will only happen if the character can freely turn.
     
  10. Gametyme

    Gametyme

    Joined:
    May 7, 2014
    Posts:
    617
    Yes the adventure scene turns correctly. Im using the shooter AC, doug, I copied the settings for the quick turn and added the stated to the shooter AC.
     
  11. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,093
    What movement type are you using?
     
  12. Gametyme

    Gametyme

    Joined:
    May 7, 2014
    Posts:
    617
    Whatever the default is for the shooter Demo.
     
  13. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,093
    That's the combat movement. The quick turn won't play with the combat movement type because your character isn't turning around quickly. With the adventure movement type the character can do a 180 turn extremely quickly. This is because the camera is independent of the character's rotation. With combat movement you'd have to swing the camera around in less than the Quick Turn Wait amount of time in order for the quick turn to be activated. This is hard to do so it isn't likely unless you have a high value for the Quick Turn Wait field. In short, quick turn doesn't make as much sense for the combat movement type.
     
  14. Gametyme

    Gametyme

    Joined:
    May 7, 2014
    Posts:
    617
    Had to read this again as I was busy at work the first time I read it. Now I see why it won't work.
     
    Last edited: Jan 6, 2016
  15. magique

    magique

    Joined:
    May 2, 2014
    Posts:
    4,013
    I'm happy to see version 1.2 released. I've downloaded this morning and am going to give it a try this week. The new abilities look very promising.
     
  16. blockimperium

    blockimperium

    Joined:
    Jan 21, 2008
    Posts:
    452
    Quick question. I installed this new version into a project but did not include the demo content. When I went to run the character builder it was complaining:

    Unable to find built in animator controller. Please select the one that you'd like to use.

    I shouldn't need to include the demo content in order to have this work properly should I? I don't need the demo stuff, but did need the CHaracter Builder to work properly with me being able to select an animator controller properly.
     
  17. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,093
    Version 1.2 moved stuff out of the Resources folder so unnecessary animations wouldn't be included in your build. For example, previously if you used the shooter controller the adventure animations would also be included because of the adventure controller in the Resources folder. Now all of the animator controllers are in their respective folders.

    If you don't want any of the demo content make sure you at least import the shooter and adventure controller. In the next version I can add the ability to select which controller you want to use if it can't find the built-in controllers, similar to how the generic model character builder works.
     
    blockimperium likes this.
  18. blockimperium

    blockimperium

    Joined:
    Jan 21, 2008
    Posts:
    452
    Love the idea, but from an implementation perspective its a bit confusing what to do next from a user perspective. For most of the assets in the production build I uncheck all of the documentation/demo stuff from all of our plugins for pretty much the same reason you're doing it - save space. To me, putting all of that in the demo hierarchy is a bit misleading since you really need some of that content in order for the product to work properly.

    In the interim, when I re-add TPC to the project - do I need to import the demos content and then remove other content that I don't need? Also, maybe demo isn't the best term for this content - I would think maybe "extras" or similar so that it doesn't get culled by default.
     
  19. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,093
    You need some of the demo content only if you want to use the included animations. You could create a new animator controller from scratch and use all of your own animations which would prevent you from needing any of the demo content. This is actually what I did with the horse for the generic model screenshot - I created a new animator controller and just added the Idle and Movement states.

    Do you want to use the included animations? If so you'll need to import everything from the Animator and Animations folders within the various demo folders.

    Looking at the Character Builder again I was wrong in my previous post - it will already allow you to select an animator controller if it can't find one within the demos folder. So you should be good to go from that side of things.

    Edit: Thinking about it some more, did you deselect the demo folder upon import with the previous versions as well? In that case you wouldn't have gotten any of the animations so the animator controllers within the Resources folder would have pointed to missing clips.
     
    Last edited: Jan 6, 2016
  20. blockimperium

    blockimperium

    Joined:
    Jan 21, 2008
    Posts:
    452
    No, in previous versions we were still testing so all of the demo content was included in those test projects. When we went to build our production-focussed deployment we started removing all of the cruft content from the various projects and built a new clean project/scene for everything.
     
  21. Porto881

    Porto881

    Joined:
    Jul 11, 2013
    Posts:
    74
    I have som trouble replacing animations, I got them from mixamo and I get most of them working but whenver i replace the walking animation in Base/Movement/Walking the animation works for like 0.5 seconds and then the character just stops and only the arms are moving.
     
  22. TheLetterS

    TheLetterS

    Joined:
    Jan 22, 2013
    Posts:
    31
    Make sure you check that the walking animation is set up to loop (check box under the animation settings). Also make sure you replaced that walk on the base layer and the upper body layer so it's all the same animation. Hope that helps!
     
  23. Porto881

    Porto881

    Joined:
    Jul 11, 2013
    Posts:
    74
    I´ll look into that. Another problem I have is that the Max step height doesn´t seem to work properly or I´m doing it wrong. Regardless of what value I put in there my character can´t walk in stairs, it just stops on the first step.
     
  24. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,093
    As a test what happens if you disable the Environment/CollisionMesh_Stairs from the clean scene - can Dom get up the stairs? You shouldn't need to change any parameters for this to work.
     
  25. Porto881

    Porto881

    Joined:
    Jul 11, 2013
    Posts:
    74
    Yes he can get up there even when that is disabled.
     
  26. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,093
    Are your stairs taller than the stairs within the clean scene? Have you tried using the same step settings as Dom?
     
  27. Porto881

    Porto881

    Joined:
    Jul 11, 2013
    Posts:
    74
    My steps are actually not as tall as the one in the cleane scene. Tried the same settings as Dom but it doesn´t work.
     
  28. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,093
    Can you send me your steps so I can try it out?
     
  29. Porto881

    Porto881

    Joined:
    Jul 11, 2013
    Posts:
    74
    They are probuilder so I don´t know if you can test it? I had it working the other day but then I changed my character and now it doesn´t work. The weird thing is that nothing at all happens when I change the values.
     
  30. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,093
    I have a ProBuilder license so you should be able to just send me the scene along with the model files. You don't need to include ProBuilder (or Third Person Controller)
     
  31. Porto881

    Porto881

    Joined:
    Jul 11, 2013
    Posts:
    74
    My project is enormous so I don´t really know how to do that.
     
  32. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,093
    You should be able to create a new scene and strip it down so it only includes the stairs. This way you will only have to send me the scene, character, and stairs assets. If that doesn't work can you reproduce it in any other way? Maybe by using cubes?
     
  33. Porto881

    Porto881

    Joined:
    Jul 11, 2013
    Posts:
    74
    I tried using Unity cubes but that doesn´t work either :/ I have never sent a scene to someone so I don´t really know how to do that so that you get the right things.
     
  34. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,093
    It doesn't work in that you aren't able to reproduce it or the character isn't able to go up the stairs?

    You can send the scene by exporting to a unity package. Make sure only the assets that are selected to be exported. You do not need to export ProBuilder or the Third Person Controller to reduce size. Once you do that you can then upload it to a file hosting service such as Dropbox and then send me a PM or email with the link.
     
    Last edited: Jan 7, 2016
  35. Porto881

    Porto881

    Joined:
    Jul 11, 2013
    Posts:
    74
    Making the steps smaller, like very small helps so I guess I´ll just have to live with that, it´s very weird that changing the values does absolutely nothing though.

    Tried making a new scene and exporting but I don´t really know how to get it right.
     
  36. Porto881

    Porto881

    Joined:
    Jul 11, 2013
    Posts:
    74
    Scrath that: It only worked when i ran up the stairs, walking doesn´t work :/
     
  37. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,093
    What values are you changing? A raycast is fired at the Step Offset location in the direction that your character is moving. If that raycast hits an object it will then determine how tall that object is. Anything over the Max Step Height will stop the character from moving. The values that you'll want to play with are Max Step Height and Step Offset.

    What if you use just a simple cube? Are you able to set the scale of that cube to something that the character doesn't like? If you are you can then just tell me the transform values so I can try the same thing on my end.

    Try increasing the step speed.
     
  38. Porto881

    Porto881

    Joined:
    Jul 11, 2013
    Posts:
    74
    A cube of 0.25 units tall is possible to get up on, everything over that is impossible. My steps on my stairs are like 0.15 units high though so I don´t really know where the problem is. I have changed the following: Max step height. step offset and step speed. It doesn´t matter what I set the values to, the character can barely get up a .1 units tall object :/
     
  39. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,093
    I just placed a cube at position (0, 0.3, -22) with a scale of (1, 0.5, 1) within the clean scene. This positions it directly in front of Dom. I then modified the Max Step Height to 0.6 and kept the Step Offset at (0, 0.1, 0.1) and a Step Speed of 2. With these settings Dom was able to step on top of the cube.

    Feel free to send me an email or PM so we can keep working on this in private rather than adding a lot of small posts to this thread.
     
  40. rpg_gamer

    rpg_gamer

    Joined:
    Nov 28, 2012
    Posts:
    214
  41. rpg_gamer

    rpg_gamer

    Joined:
    Nov 28, 2012
    Posts:
    214
    and the docs for setting this up with uma aren't very detailed.
     
  42. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,093
    Great to hear that you're enjoying it!

    Looking specifically at that asset, do you know if you can still call the standard UMA callbacks? You'll need a way to call the UMACharacterBuilder.BuilderCharacter method after the character has been generated. With standard UMA I do this within the UMADynamicAvatar component.

    The UMA integration is pretty straight forward so it doesn't take much. Is there a specific part that you think that I can expand on? With UMA you just need to make sure you use the Unity event system to tell the Third Person Controller to either add the character components or to do anything specific to your character, such as add the Fall and Jump abilities.
     
  43. wood333

    wood333

    Joined:
    May 9, 2015
    Posts:
    851
    I have Unity 5.3.0f4. I created a fresh project with only QHierarcy and Third Person Controller, downloaded and imported today. When I run the clean scene demo, Unity appears to be refreshing or downloading something, evidenced by green shading creeping across the Unity Icon the in Windows 7 tray. This results in a big frame rate drop and renders the clean scene demo unusable. In contrast, this does not happen when I load and play the Third Person Shooter demo, which functions without issue.
     
  44. Licarell

    Licarell

    Joined:
    Sep 5, 2012
    Posts:
    434
    Hey @opsive just to put a bug in your ear... I don't know if you have had a look at Gaia but he is building a new release with one button integration of various 3rd party products... I think he has Motion Controller set up maybe you could drop him a line to have your 3rd person controller set up as well...

    Just a thought....
     
  45. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,093
    The difference between the Clean scene and the Shooter scene is that the Clean scene uses Unity 5 lighting so it could be trying to compute the Enlighten data. Try to disable continuous baking and see if that helps. The Third Person Controller does not do any downloads.
     
    Last edited: Jan 7, 2016
  46. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,093
    Thanks for letting me know! Yes, I'll definitely contact the Giaia developer. Though shouldn't the terrain be controller independent? I'm wondering what type of integration he is building in...
     
  47. Licarell

    Licarell

    Joined:
    Sep 5, 2012
    Posts:
    434
    Just ways to help make things easier...

    Also I think he is adding NPC characters and 3rd person controllers to his spawners... at least I think so...o_O
     
    Last edited: Jan 7, 2016
  48. rpg_gamer

    rpg_gamer

    Joined:
    Nov 28, 2012
    Posts:
    214

    aah ok. Let me take a screenshot. So I know when, after you save the character you make with this plugin it saves to a txt file of course. The Character you put out in your scene which has a script on it that loads that text file is just pretty much a blank "ethan" character, with a set of invisible bones on it.

    When the scene starts I notice it does load the uma dynamic character script onto the character, but it doesn't exist beforehand.

    I tried just adding character setup, and the other needed script onto that game object and seeing if third person controller would take care of it that way but not quite. arms cross weirdly, and the character doesn't move. hrm



    there's how the character is set up, the player gameobject just has an animator on it and that's it, bones are a child of that object, and the selected child is the onject that has the script on it which loads the uma data.
     
  49. wood333

    wood333

    Joined:
    May 9, 2015
    Posts:
    851
    I had never opened the lighting window before. (First time for everything.) Under scene tab Other Settings the "auto" box was checked, (and in addition, both Precomputed Realtime GI and Baked GI boxes were checked). When I unchecked the "auto" box, the process terminated, and the issue was resolved.

    I assume these three boxes were checked pursuant to the demo scene setup provided by TPC. I created a test scene in the same project that was empty except for a camera, and none of the above mentioned boxes were checked.

    Thanks for the helpful info.
     
  50. opsive

    opsive

    Joined:
    Mar 15, 2010
    Posts:
    5,093
    That would make sense. I sent Adam a message so we'll see what comes out of it. Thanks for letting me know!


    Glad you figured it out!
     
Thread Status:
Not open for further replies.