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 are updating our Terms of Service for all Unity subscription plans, effective October 13, 2022, to create a more streamlined, user-friendly set of terms. Please review them here: unity.com/legal/terms-of-service.
    Dismiss Notice
  3. Have a look at our Games Focus blog post series which will show what Unity is doing for all game developers – now, next year, and in the future.
    Dismiss Notice
  4. Join us on Thursday, September 29, for a day with Unity's SRP teams here on the forum or on Reddit, and discuss topics around URP, HDRP, and the Scriptable Render Pipeline in general.
    Dismiss Notice

Motion Controller

Discussion in 'Assets and Asset Store' started by Tryz, Feb 21, 2014.

  1. Subliminum

    Subliminum

    Joined:
    Nov 9, 2017
    Posts:
    97
    Have you set the Motions to Override Layers? Override.jpg

    that plus the motions themselves need to start playing whatever animation in sync. So make sure that the transition>animation state timing matches up for both Actor's animation controllers, and that the moment when the motions on both actors start the synced phase is the same too.
     
  2. LeakySink

    LeakySink

    Joined:
    Apr 9, 2012
    Posts:
    141
    @Subliminum Great suggestion, thanks! Now I'm good.

    Has anybody had experience writing their own motions and integrating them with the rest of their code? As they inherit from the MotionControllerMotion I can't access any of the basic mono behaviours I normally world, getcomponent etc.
     
    Subliminum likes this.
  3. TeagansDad

    TeagansDad

    Joined:
    Nov 17, 2012
    Posts:
    955
    MotionControllerMotion will have a reference to the MotionController at runtime. So you can just call mMotionController.gameObject.GetComponent() and the like.
     
  4. msik

    msik

    Joined:
    Dec 7, 2017
    Posts:
    11
    Should I be using reactors to enable ragdoll on death?

    What I did:
    - add a Unity Event Proxy Reactor to the ActorCore
    - MessageReceived > 1108
    - ReactorAction > EnableRagdoll()
    Issue:
    Ragdoll is enabled on the player whether the player kills someone or is killed.
     
  5. msik

    msik

    Joined:
    Dec 7, 2017
    Posts:
    11
    Should I be using a Reactor / MessageID when I want something to only trigger on the actor's self? Such as the above example or say blocking. Or should I be using animation events? State set? State change?

    Is there a MessageID for initiating a block or parry? IE - when you first begin the blocking animation.
    I found that:
    MSG_COMBAT_DEFENDER_ATTACKED_BLOCKED = 1103;
    is called when any actor successfully blocks an attack. I want to drain stamina when the player initiates a block.
    What is MSG_COMBAT_DEFENDER_ATTACKED_PARRIED hooked up to? I couldn't find parrying in the animator or controls.
     
  6. msik

    msik

    Joined:
    Dec 7, 2017
    Posts:
    11
    I have the sword and shield on layer 1 and archery on layer 2.
    How would I go about adding new weapons, some of which have unique animations and some that are the same type.
    Example 1: The player can equip different swords and shields.
    Would I have to re-create layer 1 for each set or can I re-use the layer since the weapon/shield combo uses the same animations and logic?
    Example 2: The player can equip a two-handed sword.
    Would I have to re-create layer 1 and swap out the animations or is there a simple approach?
     
  7. msik

    msik

    Joined:
    Dec 7, 2017
    Posts:
    11
    I followed your YouTube tutorial (
    )
    for adding an attack animation for when a different weapon is equipped. Has something changed with Attack Styles since then? When I equip sword and shield all of the listed Attack Styles disappear under BasicMeleeAttack except for Forward and Back Slash. So when I add my own Attack Style (Two Handed Sword slash) it just disappears from the list and thus I can't update the attack style using a Reactor in the way you did with PC_Reactions in the aforementioned video.

    edit: figured out this one, I had an Attack Profile attached to my weapon, which overrides the Attack Styles with the ones you assign
    e2: So I guess an Attack Profile essentially replaces the need for the behavior seen in PC_Reactions?
     
    Last edited: May 13, 2021
    Subliminum likes this.
  8. LeakySink

    LeakySink

    Joined:
    Apr 9, 2012
    Posts:
    141
    Hey! Thanks for all the answers they really are helpful.

    My new problem is BasicMeleeAttack, so with many motions I've just made my own, inherited from MotionControllerMotion and done various things, getting my own components and interacting with my logic and managers etc. However with BasicMeleeAttack I've needed to change it directly to get around the attack profile reactor stuff (can't figure that out) but inside BasicMeleeAttack I can't find a way to get data into or out of that class, I can't reference any of my external classes within it, I can't access that class externally via getcomponent. I even tried making an intermediary class that exists in one of the ootii namespaces that can reference my stuff but also be accessed inside BasicMeleeAttack and that still didn't work.

    Say I wanted in a completely external script, to gain access to the chain index from BasicMeleeAttack (assuming it was public not private) can somebody please explain how I would do that?
     
  9. KeithBrown

    KeithBrown

    Joined:
    Apr 1, 2017
    Posts:
    183

    From the documentation:


    Code (CSharp):
    1. using UnityEngine;
    2. using com.ootii.Actors.AnimationControllers;
    3. public class dev_Simple_Code : MonoBehaviour
    4. {
    5.      protected MotionController mMotionController = null;
    6.  
    7.      void Start()
    8.      {
    9.           mMotionController = gameObject.GetComponent<MotionController>();
    10.      }
    11.      
    12.      void Update()
    13.      {
    14.           MotionControllerMotion lMotion = mMotionController.GetMotion(0, "MyJump");
    15.           MotionControllerMotion lMotion2 = mMotionController.GetMotion<Jump>(0);
    16.      }
    17. }
    You can find this on page 28 at https://ootii.com/Unity/MotionController/MC2Guide.pdf
     
    LeakySink and Subliminum like this.
  10. KeithBrown

    KeithBrown

    Joined:
    Apr 1, 2017
    Posts:
    183
    You could also be having an issue with the assembly definitions. If you are modifying Ootii's code, it is in an assembly definition and that will need to be modified to gain access to other code I believe.
     
    LeakySink likes this.
  11. msik

    msik

    Joined:
    Dec 7, 2017
    Posts:
    11
    How do all of the different "Forms" relate? Like for Sword_01 in the inventory it's 100 for equip, unequip, including the weapon set.
    The shield_01 however, has form 400 under items in the Basic Inventory, but shares the form 100 in the weapon set Sword and Shield. Although that is named Current Form.
    I can see that shield_01 has no equip motion because it it assigned to the LEFT_LOWER_ARM for the sword and shield weapon set and so I guess it doesn't need an equip motion, but what is the 400 form for then?
     
    ham187 likes this.
  12. msik

    msik

    Joined:
    Dec 7, 2017
    Posts:
    11
    Curious why this line is commented out in BasicMeleeBlock.cs:
    if (mCombatant.SecondaryWeapon != null)

    I'm trying to build a custom motion for parrying and this was causing block to compete with it. If I set Parry to a lower priority it would be activated instead, but then Block wasn't being activated at all. I instead uncommented this line and this allows me to activate parry if I add the opposite check in TestActivate() for secondaryWeapon == null.
     
  13. msik

    msik

    Joined:
    Dec 7, 2017
    Posts:
    11
    Should I be creating a unique equip / unequip motion for each weapon in my inventory?
    I can see that sword_01 uses BasicEquip1 and longbow_01 uses BasicEquip2.
    I thought maybe this was because they are on separate layers (1 and 2 respectively).
    Reusing BasicEquip1 for my 2 Handed sword and setting a unique equip motion (639 - still not sure if this should match the current form of the weapon set) seems to allow me to equip the 2 Handed sword with input '3'; however, I cannot switch back to any other weapon with '1' or '2' as it breaks the animator parameters somewhere. The character gets locked into an idle animation.

    So where did I go wrong here?
    And where does the mapping of '3' come from?
    e: seems like the equip input is based on the index of the weapon sets
    Solved: had L1MotionPhase on the unequip transition set to incorrect int
     
    Last edited: May 14, 2021
  14. LeakySink

    LeakySink

    Joined:
    Apr 9, 2012
    Posts:
    141
    @KeithBrown Thanks for the advice! Will check out that solution.

    My next problem is related to the camera vs input processing, I'm trying to make a resident evil style camera where on entering a new trigger a new camera is enabled, that works fine in that I just update the camera rig in the motioncontroller to the new camera and everything is now relative to the new camera, no problem, except then you end up just running right back towards that previous camera, so I tried queuing up updating the camera rig until no input is pressed, that works but has some other issues so what I really need to do is at the input level preserve the forward input while it's still being held down but update the other directional input on camera switch, then when no input is pressed set it all back to normal. That stuff is a bit of a black box with little documentation does anybody have any suggestions?

    @msik I would just create your own block & parry motion together rather than editing BasicMeleeBlock. I've had more success just making new ones.

    Appreciate everybody's time, thanks again.
     
    msik likes this.
  15. Recon03

    Recon03

    Joined:
    Aug 5, 2013
    Posts:
    759

    First I would ONLY use one camera.. Second, be sure you are enabling and disabling the other cameras to perform which ever functions you want it to. Keep it simple. If you are wanting to use two Cameras that is be sure to switch to the other, and have the one camera disabled while performing those functions. This way it can't go back to the previous, it sounds to me like you have both enabled the whole time and are just switching views.

    It sounds to me like you have conflicting cameras.... I don't use more than one camera for Unity, Unreal or any engine. Allow it to move, perform the functions you want it to.

    For example say you have first person camera, and you want it to be third, have to switch camera's.. or you can have it move to the third person spot. ( easy to do) . Having one camera saves having conflicts with cameras and other headaches.
     
  16. Recon03

    Recon03

    Joined:
    Aug 5, 2013
    Posts:
    759

    You can copy some of the old motion and edit it to make your own, I did that when I first started using MC years ago.. Just becareful that you make changes where its needed. with the new motion...

    When I used MC, I stripped it to bare bones, and added all of my own motions, and functions. I only used Climbing, and the bare controller itself. That was basically it.

    PS: Use what Otti has as a guide, go through each motion, functions in code as well, to see how it did it so you understand how it works, go through all of the motions/animations graphs , settings etc as well....

    This way you 100% understand how it all works, before moving on... Its best to go through all of it when editing....
     
    msik likes this.
  17. LeakySink

    LeakySink

    Joined:
    Apr 9, 2012
    Posts:
    141
    @Recon03 I'm using one camera, with several virtual cameras I switch between, the issue is that I need to preserve the forward momentum from the previous camera while it's still being held down otherwise say the cameras face opposite one another the character will just constantly run back and forth between them when the button is held down.
     
  18. Recon03

    Recon03

    Joined:
    Aug 5, 2013
    Posts:
    759

    It sounds to me, then you need to use priority between cameras, so you can still be able to use the state of the other .


    I use the old camera system as I made a custom one years ago... but since you are using the new one, this is state base, and more animation base. You can set prioity of one camera, and have the other blending to the another. with your virtural cameras.





    Priority
    Weight, the larger the value, the higher the priority. For example: a VirtualCamera in a non-Live state, when its Priority value is greater than or equal to the VirtualCamera in the current Live state and is in the active state, then CinemachineBrain will select it as the new VirtualCamera in the Live state.

    see the blend Hint...

    BlendHint

    As you can see from the first example, when a VirtualCamera is mixed with another VirtualCamera, the Camera will have a course of action, and it will be accompanied by the rotation of the Camera. The setting can choose the route mode when mixing to this VirtualCamera or mixing from this VirtualCamera to others.

    Read the link below..

    https://www.codetd.com/en/article/11882085

    This sounds like is what your trying to do...
     
    Last edited: May 16, 2021
  19. Tryz

    Tryz

    Joined:
    Apr 22, 2013
    Posts:
    3,395
    Hey all!

    Wow. It's been a while, but I'm back and working on catching up on the emails and posts.

    For those of you that didn't know, my family and I moved to Japan for 2 years and I led the software and game development integration and completion of the Mario Kart AR ride.



    Of course no one expected the pandemic and all the vendors were sent home; leaving me and a really small team. Unfortunately, it also meant I couldn't come home for about a year and a half. Needless to say, that wasn't the plan.

    So, in late February we finally returned home and were able to see my kids, mom, and family. I also started a new job with Universal Creative in Orlando... March and April were a blur.

    Things have finally started to calm down and I'm trying to catch up. I know I'm behind on support and I'm sure I've taken my hits in reviews, but I haven't abandoned the assets.

    On a cool side note, I got to work with some amazing and iconic folks at Nintendo. That was mind-blowingly awesome. :)
     
    BroVodo, Kaen_SG, schmosef and 9 others like this.
  20. dmenefee

    dmenefee

    Joined:
    Oct 14, 2019
    Posts:
    119
    Welcome home! Feel free to share stories :).
    Cheers,
    A very satisfied customer
     
    TeagansDad and Tryz like this.
  21. drcfrx

    drcfrx

    Joined:
    Jan 26, 2013
    Posts:
    52
    I'm not religious at all, but, damn, ALLELUIAH!!
     
    TeagansDad and Tryz like this.
  22. unity_zI0bplWwlBVpmA

    unity_zI0bplWwlBVpmA

    Joined:
    Feb 22, 2020
    Posts:
    2
    Please how i can fix and modify the spine position and rotation on the archery motion pack?
     

    Attached Files:

  23. Tryz

    Tryz

    Joined:
    Apr 22, 2013
    Posts:
    3,395
    I'm guessing that it's the "Look IK". I use this to help force the bow to look forward with the camera when you're aiming and firing.



    The nock of the bow gets pulled by the right index finger. Than, the forward direction of the arrow is changed to that of the angle.

    So, if you're using a custom bow with a nock in an odd position or rotation, the forward direction could be messed up and the spine will get messed up.

    You can start by disabling "Look IK" to see if that's the culprit. If it is, you can change the IK Angles to better fit your skeleton and have a look at the bow setup. I talk about that in the User's Guide on page 18.
     
    Subliminum likes this.
  24. msik

    msik

    Joined:
    Dec 7, 2017
    Posts:
    11
    To expand on this. If I have a kick motion on my base layer and the rest of my melee attacks are on my Upper layer how can I prevent the kicks and melee from interrupting each other? With "Override Layers" enabled on kick, it gives the desired behavior of nothing interrupting kick, but how can I prevent the opposite as well? I tried checking the base layer motion in the melee motion scripts TestInterruption(...), but while it initially prevents the interruption the kick motion FOA is still happening and part of the kick happens near the end of the melee motion. Like the KickMotion.Activate is called() it just doesn't interrupt the animation at first.

    Code (CSharp):
    1. var baseMotion = mMotionController.MotionLayers[0].ActiveMotion;
    2.  
    3. if (baseLayerMotion is KickMotion) return false;
    edit: Solved. checked for the opposite in TestActivate() of Kick
     
    Last edited: Jun 9, 2021
    BroVodo likes this.
  25. msik

    msik

    Joined:
    Dec 7, 2017
    Posts:
    11
    Swapping cameras while moving breaks the input values and input magnitude. You can test this in the "demo_MotionController" scene.
     
  26. msik

    msik

    Joined:
    Dec 7, 2017
    Posts:
    11
    Another issue I'm experiencing: activating a camera motor transition through code (p28: https://ootii.com/Unity/CameraController/CCUsersGuide.pdf) and then activating another one by using the typical key input is breaking the character controller as walking/running stops working.
     
  27. msik

    msik

    Joined:
    Dec 7, 2017
    Posts:
    11
    I think you already did this right? I can see that AttackProfiles have a property InventorySlotID. The only issue is that this property doesn't seem to be assigned to the player's attack style when the weapon is equipped. I managed to fix it by adding
    Code (CSharp):
    1. lStyle.InventorySlotID = lStyleDefinition.InventorySlotID;
    inside the second foreach loop of SetAttackStyles() of my custom version of BasicAttackProfilesReactor.

    edit: also needed to assign the owner to secondary weapon in BasicItemEquip on CreateItem(), otherwise the Attacker property will be null in WeaponCore
     
    Last edited: Jun 24, 2021
    BroVodo likes this.
  28. ddesmond

    ddesmond

    Joined:
    Feb 9, 2010
    Posts:
    163
    Welcome back @Tryz , what is the effort to get motion controller to work with Game Creator?
     
  29. khushalkhan

    khushalkhan

    Joined:
    Aug 6, 2016
    Posts:
    84
    @Tryz almost all of your assets needs to be updated new unity versions
     
  30. aggaton

    aggaton

    Joined:
    Jul 3, 2021
    Posts:
    101
    @Tryz I've added this package to my project, as soon as I do I get below errors:

    Code (CSharp):
    1. Assets\ootii\Assets\Framework_v1\Code\Input\UnityInputSystemSource.cs(4,19): error CS0234: The type or namespace name 'InputSystem' does not exist in the namespace 'UnityEngine' (are you missing an assembly reference?)
    2.  
    3. Assets\ootii\Assets\Framework_v1\Code\Input\UnityInputSystemSource.cs(5,19): error CS0234: The type or namespace name 'InputSystem' does not exist in the namespace 'UnityEngine' (are you missing an assembly reference?)
    4.  
    5. Assets\ootii\Assets\Framework_v1\Code\Input\UnityInputSystemSource.cs(25,24): error CS0246: The type or namespace name 'PlayerInput' could not be found (are you missing a using directive or an assembly reference?)
    6.  
    7. Assets\ootii\Assets\Framework_v1\Code\Input\UnityInputSystemSource.cs(841,16): error CS0246: The type or namespace name 'Key' could not be found (are you missing a using directive or an assembly reference?)
    8.  
    9. Assets\ootii\Assets\Framework_v1\Code\Input\UnityInputSystemSource.cs(24,16): error CS0246: The type or namespace name 'PlayerInput' could not be found (are you missing a using directive or an assembly reference?)
    10.  
    11.  
    I assume that is because the new InputSystem is in use, probably by one of my other packages I have installed. How do I get your package to stop giving these errors so I can try and use it?
     
  31. FargleBargle

    FargleBargle

    Joined:
    Oct 15, 2011
    Posts:
    749
    My main project is running fine on the 2020.3.15F2 LTS release, but I've tested Motion Controller, Camera Controller, Shooter Pack, Sword & Shield Pack, Swimming Pack, and Mount Points with no issues in 2021.1.16F1 as well. What needs to be updated? Are you talking about a 2021.2 beta version? o_O
     
  32. luekio

    luekio

    Joined:
    Jan 23, 2018
    Posts:
    24
    Hey folks, can anyone comment if a climbing system has fully integrated yet? There are various links pointing to add ons like this> https://ootii.com/knowledge-base/climbing-motion-pack/ but I can't find really any example of what it looks like once implemented, plus it's very old so I don't know if it's implemented into the controller by default by now. Any insight appreciated
     
  33. FargleBargle

    FargleBargle

    Joined:
    Oct 15, 2011
    Posts:
    749
    While basic vertical climbing on walls and ladders is built-in, the Climbing Motion Pack was put out for free on the Vault back in 2018. While I did some beta testing on it then, I'm not even sure it still works with the latest versions of Motion Controller. There was talk of developing a more advanced / robust paid version at some point, but it all got shelved when Tim started working with Universal. The free version is pretty much as is, more of a tech demo than a production ready pack you can seamlessly drop into a game. I made a video showing some of what it could and couldn't do:



    I had hopes that it would eventually allow climbing on uneven and non-vertical surfaces, but it hasn't happened yet.
    In the mean time, there's been some discussion about other ways of achieving some of those goals: 1, 2

    I still hope @Tryz will return to this some day, because it would be an incredibly useful pack if it was polished up a bit.
     
    Last edited: Aug 21, 2021
  34. luekio

    luekio

    Joined:
    Jan 23, 2018
    Posts:
    24
    Thanks for the reply, Fargle!

    I had managed to dig the pieces out for this too last night, it sorta worked but their were some issues I think because it's so old. Yah it's certainly too bad it's not a working part of the MC.
     
  35. FargleBargle

    FargleBargle

    Joined:
    Oct 15, 2011
    Posts:
    749
    Your question prompted me to revisit earlier attempts at climbing non-vertical surfaces. I followed @Tryz advice, and wrote a script that tilts the player to match the surface normal of a wall or ladder. Here's what it looks like:



    Code (CSharp):
    1. using System.Collections;
    2. using System.Collections.Generic;
    3. using UnityEngine;
    4. using com.ootii.Actors;
    5. using com.ootii.Actors.AnimationControllers;
    6.  
    7. public class ConformalClimb : MonoBehaviour
    8. {
    9.     private GameObject myPlayer; // Player GameObject - must have "Player" tag
    10.     private ActorController AC; // Actor Controller script
    11.     private MotionController MC; // Motion Controller script
    12.     public bool climbing = false; // Flag set while climbing walls or ladders
    13.     public MotionControllerMotion lastMotion = null; // Cache for last motion
    14.     public MotionControllerMotion currentMotion = null; // Current motion
    15.     public string currentMotionName; // Names "ClimbWall" and "ClimbLadder" must be applied to motions
    16.     public bool playerActive = false; // Flag is set true after short delay to allow finding Player
    17.     public LayerMask ignoreLayers; // Layers to be ignored by raycast - typically the Player
    18.     public float hitDistance; // Offset distance from Player to climb object
    19.  
    20.     void Start()
    21.     {
    22.         StartCoroutine(GetPlayer());
    23.     }
    24.  
    25.     public virtual IEnumerator GetPlayer()
    26.     {
    27.         myPlayer = GameObject.FindWithTag("Player"); // player must be tagged as Player
    28.         yield return null;
    29.         if (myPlayer == null)
    30.         {
    31.             Debug.Log("Conformal Climb could not find player.");
    32.         }
    33.         AC = myPlayer.GetComponent("ActorController") as ActorController; // Get Actor Controller component
    34.         MC = myPlayer.GetComponent("MotionController") as MotionController; // Get Motion Controller component
    35.         yield return new WaitForSeconds(0.1f);
    36.         playerActive = true;
    37.     }
    38.  
    39.     void LateUpdate()
    40.     {
    41.         if (playerActive)
    42.         {
    43.             lastMotion = currentMotion;
    44.             currentMotion = MC.ActiveMotion;
    45.             if (currentMotion != null)
    46.             {
    47.                 currentMotionName = currentMotion.Name;
    48.                 if (currentMotionName == "ClimbLadder" || currentMotionName == "ClimbWall")
    49.                 {
    50.                     climbing = true;
    51.                     Ray ray = new Ray(transform.position, transform.forward);
    52.                     RaycastHit hit;
    53.                     Physics.Raycast(ray, out hit, ignoreLayers);
    54.                     if (hit.normal != Vector3.zero)
    55.                     {
    56.                         AC.transform.forward = -hit.normal;
    57.                     }
    58.                     if (Physics.Raycast(transform.position, transform.forward, out hit, ignoreLayers))
    59.                     {
    60.                         hitDistance = hit.distance;
    61.                         print("Climb object: " + hit.transform + ", distance: " + hit.distance + ", direction: " + hit.normal);
    62.                         Debug.DrawRay(transform.position, transform.forward * 5, Color.red);
    63.                         Debug.DrawRay(hit.point, hit.normal * 5, Color.green);
    64.                     }
    65.                 }
    66.                 else climbing = false;
    67.                 if (currentMotion != lastMotion)
    68.                 {
    69.                     Debug.Log("Current motion: " + currentMotion.Name + " - Climbing: " + climbing);
    70.                 }
    71.             }
    72.         }
    73.     }
    74. }
    75.  

    A few caveats: Overhangs are still a bit iffy. It works as long as they're not too extreme, but as in real life, you can fall to your death if you push it too far. Besides tilting, it would be nice if it pushed the player into the wall to keep him in contact, but that part is still giving me fits. The top and bottom of the climb can also be problematic, causing juddering during the transitions. The fix is to add a trigger collider that only activates the prefab containing the script - which is attached to the player - when needed. Just design the climbable object so it's not needed at the top and bottom. You also need to tag the player as "Player", and explicitly name the "ClimbLadder" and "ClimbWall" motions in the MC inspector for the script to recognize when they're active.

    You can get the climbing wall prop and script prefab here if you want to try it out. Just drop them into the basic Ootii Climbing Demo - but remember to make the changes mentioned above, or it won't work. ;)
     
    Last edited: Aug 23, 2021
    luekio likes this.
  36. Recon03

    Recon03

    Joined:
    Aug 5, 2013
    Posts:
    759

    Hey, I have not used in ages,anyways, my kids wanted to learn, so I been letting them use MC, and all of the packs..

    and noticed shooter is fine, but archery, and sword, no matter what I do, to install MIXAMO animations , the player falls through the world once I equip a weapon.

    I remember people used to have this issue before and when it did it was because people installed the wrong version of MIXAMO, you needed Unity FBX.. and need to over write the meta files with the ones TIM have.

    So I used to use MC alot back in the day. So, did something change? if not, not sure what the heck is causing this, I have not dug into it a lot but I figured to ask, before I spent a ton of time with it. Thanks
     
  37. FargleBargle

    FargleBargle

    Joined:
    Oct 15, 2011
    Posts:
    749
    If you mean the player sinks into the ground up to his waist, that usually means the packs aren't set up right. Be sure to follow the instructions at the start of the user guides for the packs. My own procedure is as follows:
    1. Install the new pack
    2. Close Unity
    3. Add the exact Mixamo animations specified in the setup instructions to the Animations\Mixamo folder
    4. Unpack the AnimationMeta.zip file from the pack's Extras folder to the Animations\Mixamo folder
    5. Check that the names of the animations match the names of the unpacked metafiles and none are missing
    6. Restart Unity
    7. Open the pack's demo scene
    8. In the Motion Controller Packs settings, run the Pack Setup for the pack you just installed
    At this point, the pack should work without the player falling into the floor. If some packs work and some don't, pay particular attention to step 5 above. Sometimes Mixamo changes the names, or you download animations using different settings, and the names no longer match the metafiles in the Extras folder. The metafile names are what Motion Controller is looking for, so if your downloaded animation names are not exactly the same, they need to be renamed to match the metafiles. Good luck.

    Archery Pack User Guide
    Sword & Shield Pack User Guide
     
    Last edited: Sep 9, 2021
  38. Recon03

    Recon03

    Joined:
    Aug 5, 2013
    Posts:
    759

    Ya, I have set these up hundreds of times in the old days. They are set up right, the Shooter works fine, I even made new projects to see, if it was a Unity issue, or project. So, I get the process. never had it do these before, I admit its been awhile, but I did it about 6 times in 6 new projects, every time, the Shooter would work, but archery and Sword would fail. So, I notice though, it don't seem to import when I add meta files, so I thought it was Unity being stupid so I restarted it, I went to the demo.

    So I followed this to the step, 6 times. So, at a loss.


    The only thing I did notice, though the meta files and the Mixamo files have different amounts... So, some seem to be missing???


    the meta files for sword I see 46 files. Mixamo has 52 files as an example.


    Its these ones there is no meta for. from, the pack.

    Ybot at standing, has 4 files, that aren't in the animation replacement meta.
    from the pack, does not have those.


    the archery mixamo has 40 files. the meta 82 ...files, so no way can any of this match..


    So, what has changed?? any idea? honestly i'm not a huge Mixamo user, typically I use my own, but this is for the kids to learn. So not sure how they are saving anything. I know Unity can be a real pain, as I had to help folks over the years with these stupid issues.

    So I know MIXAMO, it must be Unity FBX files, so that is a none issue, for the F*** of it, I tried normal FBX and manually started to set them up, and most of the issue is fixed, but some animations still go through the ground. but I WOULD rather, just have it set up, so the kids can play , learn , while I work on my UE game lol...
     

    Attached Files:

    Last edited: Sep 10, 2021
  39. Recon03

    Recon03

    Joined:
    Aug 5, 2013
    Posts:
    759
    I forgot to add as well, there are 4 Y bot, Disarm bows, in the Sword Meta data.... not sure what that is about, but not Sword shield disarm, or equip in the beta data.

    Now that is when it goes under the ground, when you equip.. So that animation is not there. and its meta data is named bow... How come?

    I don't remember it being this way... I checked this now 8 times, .... its not correct. As seen in the SS.

    So it is a matching issue for names and animations. Which is what I thought was the issue . Mixamo has changed some animations. and the meta data is named wrong.. I don't see animations for EQUIP or Disarm anymore in the pack. not that I see anyways. there was a lot of doubles and others, I had to take it. like extra idles and so forth .
     

    Attached Files:

    • rr.jpg
      rr.jpg
      File size:
      364.9 KB
      Views:
      171
    TeagansDad likes this.
  40. Recon03

    Recon03

    Joined:
    Aug 5, 2013
    Posts:
    759
    last, I checked, I get a files errors, its not caching, so no matter what. it keeps adding the typical 1, to the end of the file name, so, this has caused most of the issues. Unity has got worse with importing, and cache issues.. Anyways, prolly just going to do this all manually when I some time, but this needs to be updated at one point, this no longer matches, the packs.. due to changes . in the meta data there is improper names, and some that have Ybot at the start, these FBX don't even exist anymore.

    So this is the other issue .. if I get some time, I will try and fix it, if someone beats me to it great, if I do, I will send it here.

    But 100% there is some out date and missed names files for sure.. for Archery, Sword.

    Shooter is good to go. I have not checked swimming or magic yet.


    Unity keeps looking for a file name with a 1, which there NEVER was one... its duplicating it... which means its not caching this is an old issue that got worse, this has happen no matter how many projects I made.. .I even tried it on one animation, and one meta file, same thing, so in part, there is a Unity issue here. as well... This is why these days I don't use Unity, its a damn headache...anymore ...



    EDIT: I had said piss on it, and did it the way I normally add my own animations.... and helped other Unity users... I set them up all manually. Using my own set up. it works now..

    I got rid of the meta files and just started fresh.


    But, others need to make sure that they checked the names, as MIXAMO has changed some of there stuff some are also doubled, Unity cache issues for importing as gotten worse over the years, so be sure to delete your Library folder.. Use a new project. I normally help Unity users over the years and seen this got worse before I had retired.

    This is NOT TIM's fault in any way to be clear.. .This is due to Unity and Mixamo issues.. Just so i'm clear and fair to Tim as I always have been to asset developers. But I wanted to post this incase others have problems...

    Thanks Fargle anyways, I know you still use MC more than most, so thanks for that information. I knew about this from before. though. I never been a fan of MIXAMO stuff myself but it good for folks who want to get started, so I wanted to let them kids use.

    But they are all good now. but it will break from other users... watch for the changes... or just do what I did and ignore the meta files and import animations your self, like you would any other.
     
    Last edited: Sep 10, 2021
  41. FargleBargle

    FargleBargle

    Joined:
    Oct 15, 2011
    Posts:
    749
    What I did long ago was save working sets of Mixamo animations for each pack, that all have the correct files and names. Whenever I do a new install, I just drop them into the Mixamo folder, add the metafiles from the Extras folder, and I'm good to go. Since the metafile parameters may be different between pack releases, I always try to use the ones that are included with each pack, but the names shouldn't change, so they should still work with my animations.

    I always place the animations and metafiles in the Mixamo folder with Unity turned off, to eliminate the possibility of overwriting the correct metafiles with incorrect generated ones before I'm finished. Once I'm done, I start Unity, it sees that metafiles for the animations already exist, and leaves them alone. Any downloaded animations that don't have metafiles are not used, so ignore them. The shooter pack also contains a number of .anim files, along with their metafiles, that contain pistol animations not included in the Pro Rifle Pack from Mixamo. Glad you got it working. :)
     
    Recon03 likes this.
  42. Recon03

    Recon03

    Joined:
    Aug 5, 2013
    Posts:
    759

    Oh ok, that explains why there is issues now you saved from before. I prolly did some where on an old PC, but I have 4 of them, so who knows where there at lol.. Ya, there is a lot that has changed about 8 or so in one and about 7 in the other I think.

    all it did was break , it was Unity not caching properly, I normally don't use MIXAMO, unless I want something fast to prototype real fast, other wise I used my own, so I was never big on them. It was my lazy way out if I did use lol.

    Not a big deal, ya I just did it manually and ignored the meta files, so, that was better than wasting time, trying to mess with the meta files and Unity cache issues. Unity cache issues, got worse, and importing as well.

    I been yelling at Unity for years to address that lol. I seen this a lot when I did a lot of unofficial support for some other asset developers over the years and work I did for clients..

    Anyways thanks for your input and help, though FargleBargle!


    as far as the shooter pack, ya, its been so long since I used these, I had used for a mobile game I had sold years back, so its been awhile, I made my own controller since. But I want my little ones to use it to learn from, and its great for prototyping! MC that is and its packs!
     
  43. Recon03

    Recon03

    Joined:
    Aug 5, 2013
    Posts:
    759

    Ya I do that sometimes, I should of tried this. didn't think of it at the time

    Thanks for reminding me ! lol
     
  44. TeagansDad

    TeagansDad

    Joined:
    Nov 17, 2012
    Posts:
    955
    You know, it never even occurred to me that Mixamo had changed some of the animations. Probably because it doesn't look like those are really maintained or updated at all anymore. I remember they changed a bunch of the animation names quite a while back, when they did a major re-org. I had no idea they were still messing around with it from time to time.

    Like @FargleBargle, I just keep a set of working Mixamo animations & metadata and just copy that into new projects. So I never would have come across the problem myself.

    When I get a chance, I'll re-download the Sword and Bow animations and get them all set up properly again. Ugh.
     
    Recon03 likes this.
  45. FargleBargle

    FargleBargle

    Joined:
    Oct 15, 2011
    Posts:
    749
    Let me know when you do. If you change the included metadata names, it means I'll need to set my own packs up again as well. The old animations only work as long as the metadata names stay the same. :rolleyes:
     
    Recon03 likes this.
  46. Recon03

    Recon03

    Joined:
    Aug 5, 2013
    Posts:
    759
    Ya, I never really used Mixamo, that often, and changed PC's a few times since, so I tend to clean my server, Qnap off due to my work client work, so sadly I didn't have the old stuff, so ya, it caused some issues. but when I looked at it myself, since the kids where using, I was like just down load them!! to the kids I looked and they where right it was not working and that was the reason. So I had to tell my kids sorry since things have changed since the last time I actually used Mixamo which had to be 3-5 years? so.

    Ya, I would just save the files some where, and if its possible, send to other users? or have an update Meta Files, of the changes? prolly only two ways to actually address this for users who may not know better. or that are newer.

    I personally use my own animations but the kids wanted to learn, so I took the time to set them all up on my own for them.. but for others, that may not know how, you may want to for sure do one of the two ways, this way this won't be a problem.
     
  47. Recon03

    Recon03

    Joined:
    Aug 5, 2013
    Posts:
    759

    Ya, sadly which doesn't do much, unless you have the old ones? Maybe they can have two meta files saved? The old and new, this way vets, and other users are good to go? just a suggestion. have a folder, updated MIXAMO, meta:) that is what I would do, this way vet users aren't messed up either. :) I wish I had the room to save all this crap as it is, I have 30tb, worth of data from clients and my own stuff over the years. now that i'm retired I need to start trashing stuff .:)
     
  48. Recon03

    Recon03

    Joined:
    Aug 5, 2013
    Posts:
    759
    not going to happen.. :) if you seen my server, Qnap and users like myself, you would know why... Unity Clients, Unreal clients, Investor clients, AAA, clients, AA, Clients, other clients, nearly 30 years worth.. Plus, my own crap over the years, so that is just more junk, I have to save. lol... I would just add new updated folder of meta data of Mixamo, problem solved. and keep the old for users like Fargle.:)




    PS:
    I been showing my kids how to set up Unity animations anyways and make there own.. so that won't be an issue for them going forward, they need to learn anyways.
     
  49. AlexTai

    AlexTai

    Joined:
    Feb 8, 2018
    Posts:
    1
    Hi!

    I have already sent an email to ootii, but I post here, in case someone has already encountered this problem.

    I am using the NavMeshInputSource on one NPC and it works well in the editor, i can use it in the same scene as my player character with a Motion Controller and Camera Controller on it.
    The problem is when I build the game, the camera controller on the player is not working anymore.
    I unchecked every "find input" to be sure the player is receiving input from easy input, and my NPC from the NavMeshInputSource.

    If I delete the NavMeshInputSource, everything works fine for the player in the build again.

    Do you have any idea what mistake I might have made, or things I can do to make the build work like in the editor?

    I work in Unity 2019.4.28f1.

    Thanks everyone in this forum, during past years i always find responses for a lot of stuff in this forum :)

    Edit:
    I tried to change the execution order of the scripts "NavmeshInputSource" and "CameraController" but it doesn't change anything.
    After more testing, I can confirm that the camera controller behaves in the build as if it had no more input, and not as if it had taken the input from the NPC/NavmeshInputSource.

    Final edit 12/10:
    If anyone is having the same problem. I finally tried an update of the camera controller and it looks like the issue is resolved!

    Alex
     
    Last edited: Oct 12, 2021
  50. magique

    magique

    Joined:
    May 2, 2014
    Posts:
    3,965
    I am currently developing an advanced AI system called SoulLink, which will integrate out of the box with Ootii controllers. Development is in early alpha state and testing is set to begin by the end of the year at the latest. To follow along with development, please join my discord channel:

    discord.gg/ncW9UmU
     

    Attached Files:

unityunity