Search Unity

Assets Third Person Templates by Invector

Discussion in 'Works In Progress' started by Invector, Aug 20, 2015.

  1. Hawk0077

    Hawk0077

    Joined:
    Nov 6, 2017
    Posts:
    585
    I am using the latest version, not sure what number at present. I did fix it though. Heres how:

    The issue was related to the player Layer. In the demo scenes provided and when I added a controller to my scene, the Player Layer was set to PLAYER. But with that setting my character fell through the terrain.

    So, I changed the Layer to Default which caused the issues above.

    After posting I searched the demo scenes and they were all set to Player Layer which I couldn't understand. So I set my character to Player (children too) then changed only the top level game object to default which stopped the player falling through the terrain and the glitchy camera as described above. Since then everythings worked fine.

    Version says 1.3.2 for shooter template in PDF
     
  2. Invector

    Invector

    Joined:
    Jun 23, 2015
    Posts:
    896
    Layers are very important to be set up correctly, you see the Player and his children gameObjects must be set as "Player", the ground can use a different layer from "Default" but you must assign it in the Controller > Ground Layer, otherwise it will fall through, and the Camera uses the Culling Layer as obstacle, the default layer is "Default", so every object that uses default will be cull.
     
  3. SickaGamer

    SickaGamer

    Joined:
    Jan 15, 2018
    Posts:
    829
    Any new updates coming to the TPC?
     
  4. Hawk0077

    Hawk0077

    Joined:
    Nov 6, 2017
    Posts:
    585
    Terrain - Layer Set To = Terrain
    Ground (in controller) - Layer Set To = Terrain

    Player & Children - Layer Set To = Player

    RESULT = Character falls through the floor/terrain.

    Player (main gameobject) - Layer Set To = Default
    Children - Layer Set To Player

    RESULT

    Character works okey and doesn't fall through the floor.

    Culling Layer ios curently set to (new layer created ) Culling Layer.
    I have tried using Culling = Default Leyer .... Makes no difference (as far as my current use and configs are concerned).

    The same happens in the demo scenes.
     
    Last edited: Oct 9, 2019
  5. rasto61

    rasto61

    Joined:
    Nov 1, 2015
    Posts:
    316
    Do you have Terrain/Player interaction enabled in your Collision Matrix?
     
    Hawk0077 likes this.
  6. Hawk0077

    Hawk0077

    Joined:
    Nov 6, 2017
    Posts:
    585
    I dont believe so based on my understanding. Which isnt a lot in these cases.
     

    Attached Files:

    Last edited: Oct 9, 2019
  7. rasto61

    rasto61

    Joined:
    Nov 1, 2015
    Posts:
    316
    Yes, so you need to check that and can just keep the entire player on the Player layer, and it wont fall through if you have the Terrain layer defined in the TPC ground.
     
  8. Hawk0077

    Hawk0077

    Joined:
    Nov 6, 2017
    Posts:
    585
    When I select the checkmark Player /Terrain after I press Play the checkmark gets deselected?
     

    Attached Files:

  9. rasto61

    rasto61

    Joined:
    Nov 1, 2015
    Posts:
    316
    Then that means some script in your project is disabling the collision between the two layers. You need to check for Physics.IgnoreLayerCollision in all the scripts in your project.
     
    Hawk0077 likes this.
  10. Hawk0077

    Hawk0077

    Joined:
    Nov 6, 2017
    Posts:
    585
    Thanks, much appreciated.
     
  11. Hawk0077

    Hawk0077

    Joined:
    Nov 6, 2017
    Posts:
    585
    Hi, I am trying to get the rights analog stick (xbox360 controller) to return to the center position of the character AFTER I make a camera movement up or down.

    For instance if I move the right stick to the right then let go, I have to use the right stick to return to the center position.

    I realise that there is a camera follow script but that makes the right stick inactive and so having the right stick return to center after a movement would be better if it can be done.

    Is there a piece of code I can add somewhere to get the camera to behave this way?

    I thought I found the SNAP checkbox in the input settings and that it would do this automaticaly but it doesnt work.

    Any ideas? thanks
     
  12. MagiSoftworks

    MagiSoftworks

    Joined:
    Feb 12, 2019
    Posts:
    108
    Anyone getting this creating a new Item Handler? I've been able to move components up and down in order to see the new drop down handler but cant on this one.
     

    Attached Files:

  13. junaid_techving

    junaid_techving

    Joined:
    Jul 16, 2018
    Posts:
    2
    Hi ! well you are doing great ...
    I just want to extend the behaviour of Third Person Controller and NPC/AI. I want to perform grapple damage in which Third person Controller and AI Controller both behaviours will have to extend. So do you have any solution regarding to it?
     
  14. MagiSoftworks

    MagiSoftworks

    Joined:
    Feb 12, 2019
    Posts:
    108
    Hi Team - Having trouble adjusting the right hand on the bow setup. => Shooter Manager => IK => Right Hand but I don't see field to adjust? Probably missing something.
    Thanks!
     
    SickaGamer likes this.
  15. MagiSoftworks

    MagiSoftworks

    Joined:
    Feb 12, 2019
    Posts:
    108
    Don't know about this - I removed component then set back up and now visible. No biggie- Happened a couple times.
     
  16. Hawk0077

    Hawk0077

    Joined:
    Nov 6, 2017
    Posts:
    585
    Hi, is there a way to get the camera look (using right joystick of 360 controller) to return to the behind the character view automatically. Si that if I am in a car or on a horse for instance and look to my left or right, the camera snaps back to the original behind the character view?

    Any ideas how this can be or is c=done would be appreciated, thanks

    Oh for an example I believe Forza does this and the latest Grid game and many others besides. Much appreciated, thanks.
     
  17. Kazuya321

    Kazuya321

    Joined:
    Sep 18, 2019
    Posts:
    23
    how to do when my AI companion suddenly takes that signal on the screen with the image damage
     
  18. scumprince

    scumprince

    Joined:
    Sep 30, 2019
    Posts:
    3
    Hello there. Don't understand how to setup combat scene. I create melee controller, then I create Simple AI, and It should just work? Now enemy chasing the player, but player can't attack him and enemy doesn't attack as well. Ive checked documentation and vids, but can't find combat setup.
     
  19. Invector

    Invector

    Joined:
    Jun 23, 2015
    Posts:
    896
    It's not a feature included out of the box, but you could use the 'lockCamera' option of the tpCamera to 'reset' to the characters back.

    I'm sorry but I didn't quite get your question, is the damage image being triggered by the AI Companion?

    Check your layers, all the information about setuping layers and tags to apply or receive damage are available in the documention
     
  20. SickaGamer

    SickaGamer

    Joined:
    Jan 15, 2018
    Posts:
    829
    When is the next version of TPC coming out?
     
  21. Invector

    Invector

    Joined:
    Jun 23, 2015
    Posts:
    896
    Pretty soon 1-2 weeks, get ready for some changes!
    After this release, we will focus on a new series of video tutorials ;)

    Here is a preview of the changelog

    Shooter v2.5.0 CORE UPDATE & New Features - xx/11/2019

    - Project upgraded from 5.6.2 to 2018.4.12 LTS with all the warnings regarding deprecated variables are now fixed
    - Big jump from 1.3.2 to 2.5.0 to match other versions of the template
    - Add new Welcome Window - Make sure to import the 'ProjectSettings' after you import the package
    - Change Mobile, Topdown, 2.5D, ClickToMove and the vMansion examples are now separated add-ons and can be install from the WelcomeWindow/Add-ons
    - CORE UPDATE - new methods to Move and Rotate the Character it's now much more fluid
    - CORE UPDATE - tpMotor, tpAnimator, tpController, and tpInput was improved and restructured, check the documentation to see the flowchart demonstrating the new structure
    - Improved 2.5Input scripts are no longer needed, now you just need to overwrite the methods ControlLocomotionType and ControlRotateType to create new Controller styles
    - Improved 2.5Shooter Aim to be more accurate with the cursor position
    - Improved ClickToMove with better target selection and collision detection
    - Improved Ladder System, now supports inclined angles, new ladder model with each step set to 0.5f of height, add ClimbSpeed & FastClimbSpeed with an option to consume stamina
    - Add New Animations for the Ladder System and better match target to entry and exit
    - Add 'AutoReload' option for Shooter Weapons - automatically performs a reload if there is ammo left
    - Add 'DontUseReload' option for weapons that use a single amount of bullet 'xx' instead of 'xx/xx'
    - Add transition to Sprint if you're Crouching
    - Add 'SprintOnlyFree' option to switch to free locomotion while sprinting
    - Add 'UseLeanAnimations' option to use the lean left/right animations while turning on free locomotion, disable it when using a TopDownController
    - Add 'RotateWithCamera' option to each LocomotionType (Free or Strafe) to make the character Rotate with the Camera forward while standing still
    - Add 'MovementSmooth' and 'AnimationSmooth' values for each LocomotionType (Free or Strafe) to have better control of the smoothness you need when moving the character or the locomotion animation speed
    - Add Roll options such as UseRollRootMotion, UseRollGravity, RollSpeed, RollRotationSpeed and TimeToRollAgain
    - Add vAnimatorParameters to manage all the animator parameters and convert string to hash to increase performance
    - Add new parameters 'IsSprinting' to the animator to know if the character is sprinting or not (useful to create directional transitions)
    - Add new options for the Jump/Airborne you can now use the current Rigidbody Velocity to influence on the jump speed direction
    - Add 'Jump and Rotate' to rotate while jump/airborne, 'AirSpeed' to control the speed while jump/airborne, 'AirSmooth' to control the smoothness
    - Add 'Velocity Multiplier' option for the Ragdoll, it gets the current velocity of the character rigidbody and applies to the ragdoll when enabled, creating a more realistic transition
    - Fix Reloading when having ammo in the current clip but no ammo left
    - Fix bug when entering the ladder and some animations didn't reset (ex: aiming, crouching, blocking)
    - Fix Ragdoll Component not being added when creating a ragdoll, now all the colliders are set to CollisionMode Speculate
    - ADD-ON Swimming now has an input to swim up/down, demo scene improved with generic action climb instead of the old system to exit the swim
    - Removed XInput.dll from the project
    - Removed vCharacterStandlone, use vHealthController instead

    And here is a preview of the new structured we did for the core scripts:

     
  22. SickaGamer

    SickaGamer

    Joined:
    Jan 15, 2018
    Posts:
    829
    A new inventory GUI? :)
     
  23. SickaGamer

    SickaGamer

    Joined:
    Jan 15, 2018
    Posts:
    829
    @Malbers FYI on an updated controller.
     
  24. Malbers

    Malbers

    Joined:
    Aug 7, 2015
    Posts:
    1,599
    Invector likes this.
  25. SickaGamer

    SickaGamer

    Joined:
    Jan 15, 2018
    Posts:
    829
    @Malbers Can you do a new tutorial for this once it comes out? Thanks!
     
  26. Malbers

    Malbers

    Joined:
    Aug 7, 2015
    Posts:
    1,599
    SickaGamer likes this.
  27. Kazuya321

    Kazuya321

    Joined:
    Sep 18, 2019
    Posts:
    23
    the question is this: how to do when my CompanionAi takes shots, that I see it on my screen with the signal of a red image?
     
  28. Kazuya321

    Kazuya321

    Joined:
    Sep 18, 2019
    Posts:
    23
    please how to fix outdated Application.loadedLevelName
     
  29. Invector

    Invector

    Joined:
    Jun 23, 2015
    Posts:
    896
    Oh it's simple you can use the Event OnReceiveDamage to active an Image UI
    What version of Unity are you using?
     
  30. Kazuya321

    Kazuya321

    Joined:
    Sep 18, 2019
    Posts:
    23
    thanks but after having put the red photo of damageImage which is on vUI in OnReceiveDamage and now which function must put?
     
  31. Kazuya321

    Kazuya321

    Joined:
    Sep 18, 2019
    Posts:
    23
    I have an error while importing the script vfireprojectile on my project directly an error message, help me please to correct this error:
    vFireProjectile.cs(24,63): error CS0246: The type or namespace name `vLockOnTargetControl' could not be found. Are you missing an assembly reference?



    Capture d’écran 06-11-2019 23.29.11.png
     
  32. magique

    magique

    Joined:
    May 2, 2014
    Posts:
    3,683
    It will no longer on anything before 2018.4.12 LTS?
     
  33. Hawk0077

    Hawk0077

    Joined:
    Nov 6, 2017
    Posts:
    585
    I have a couple of issue I need help with thanks.

    First, is there a way to stop camera going through trees, walls and objects? I tried changing the clippins, adding wall clip, and several other methods but nothing works. Any ideas appreciated, thanks.

    Second, I have the default state for walking around and want to change to another state when I get on a horse so I can change the distance. How do I do that and is there a script that will do it.

    Many thanks.
     
  34. Invector

    Invector

    Joined:
    Jun 23, 2015
    Posts:
    896
    Yep, it's time to move on and enjoy the new features and bug fixes from the new versions of Unity ;)

    1- Check the "Culling Layer" of your tpCamera, the default is "Default" so if your objects are using a different layer it won't be culled.

    2- You can use the method ChangeCameraState from the tpInput to set a different camera state when riding a horse.
     
    Hawk0077 and Malbers like this.
  35. Invector

    Invector

    Joined:
    Jun 23, 2015
    Posts:
    896
    What version are you running? we have a "vFireProjectile" in the project today :confused:
     
  36. magique

    magique

    Joined:
    May 2, 2014
    Posts:
    3,683
    Can you check the publisher forums and see what the percentage of Unity developers is on newer versions versus older versions?
     
  37. Invector

    Invector

    Joined:
    Jun 23, 2015
    Posts:
    896
  38. wood333

    wood333

    Joined:
    May 9, 2015
    Posts:
    653
    In a world where your project only contains a few Unity Store assets, each of which support the latest Unity, this may be true. But my project has many assets, and updating to newer versions of Unity is a great way to miss production deadlines in an endless quest for the latest greatest features.
     
  39. magique

    magique

    Joined:
    May 2, 2014
    Posts:
    3,683
    Can you explain what about these new improvements requires Unity 2018 to accomplish? I'm just curious because Invector has always been one of the last great assets to continue to support older versions and now that is about to end.
     
  40. Kazuya321

    Kazuya321

    Joined:
    Sep 18, 2019
    Posts:
    23
    I use the version: shooter Template v1.2.3
     
  41. Invector

    Invector

    Joined:
    Jun 23, 2015
    Posts:
    896
    The new features don't 'require' Unity 2018, but I think it's time to move on from 5.6.2, we fixed several warnings from an old API that soon it will not be supported anymore, we can take advantages of the Package Manager, improved Profiler, updated Collab, stable editor, improved Animator Controller window with zoom and option do copy parameters which is a lifesaver, and a lot more... It's not like we're going directly to the latest version available, we're going to a very stable LTS (Long term support) release which will have support for the next 2 years.

    Just like we always recommend using the latest version of our packages, Unity also recommends keeping the editor updated, of course this is not possible when you're developing a game and it's on an advanced stage, but if you started on an LTS version of the Editor it's more likely to still enjoy the latest features and bug fixes of a stable editor.
     
    Malbers likes this.
  42. Malbers

    Malbers

    Joined:
    Aug 7, 2015
    Posts:
    1,599
    I fully support this decision! with my assets I upgraded to 2018.3.2.. to take advantage of the new Prefab system and all of the things you also said. ;) So yeah go for it!!
     
    SickaGamer and Invector like this.
  43. SickaGamer

    SickaGamer

    Joined:
    Jan 15, 2018
    Posts:
    829
    Are we getting our new release this week?!
     
  44. Invector

    Invector

    Joined:
    Jun 23, 2015
    Posts:
    896
    I think it's possible yeah, just finishing up some editors and updating the documentation and it could be released within the end of the week in the vStore and next week on the AssetStore ;)
     
  45. Kazuya321

    Kazuya321

    Joined:
    Sep 18, 2019
    Posts:
    23
    Excuse me, I use the version: shooter Template v1.2.3
     
  46. daniozi117

    daniozi117

    Joined:
    Mar 4, 2016
    Posts:
    27
    I have issue with stealth animation. I am applying it on meleeCombat animator. All works fine but in the end the root motion doest not allow AI to step back and die animations are running two times.
     
  47. RadJack

    RadJack

    Joined:
    Nov 16, 2019
    Posts:
    1
    Really like this Third Person Asset. Although I don't have enough money for the melee template. I was wondering if you were gonna add a free demo version of the melee combat template?
     
  48. Invector

    Invector

    Joined:
    Jun 23, 2015
    Posts:
    896
    Can you post a screenshot or the path of the folder in which the 'vFireProjectile' is?
     
  49. Invector

    Invector

    Joined:
    Jun 23, 2015
    Posts:
    896
    Did you copy the "Stealth Kill" and "Stealth Kill Passive" substates from the example animator controller to your own animator controller and did the exit transitions as the example has? It should be working as expected if you set up correctly
     
  50. Invector

    Invector

    Joined:
    Jun 23, 2015
    Posts:
    896
    Nope, we will not be creating lite versions of the shooter or melee templates, the only free lite version is the basic locomotion > https://assetstore.unity.com/packag...person-controller-basic-locomotion-free-82048