A Unity ID allows you to buy and/or subscribe to Unity products and services, shop in the Asset Store and participate
in the Unity community.
Discussion in 'Assets and Asset Store' started by opsive, Jan 21, 2015.
On UWP built? I don't think that exists there...
For UWP it's in System, for .Net standard it's System.Reflection.
Hello, I want to know how the magic should be added, how to release, there is no magic module in the demo?
Take a look at the RPG character within the clean scene. This character has a two sets of items which use the MagicItem component.
Excuse me for the the amateur question, but I cannot see the way I can tweak some camera settings. I used the default character from the standart unity asset, and with the help of the tutorial set it up with this asset. My goal is to prevent the character from turning his body to the camera looking direction when he's staying idle, and the player only moves the mouse around.
It sounds like you want to use the adventure movement type. This is set on the RigidbodyCharacterController. In this case you don't need to change any camera settings but they are changed within camera states.
@opsive a few days waiting for the private reply...
I just replied
I can't even buy this from the asset store. Really want to try this for a new game I'm working on.
This is the message I get:
I've already emailed unity hours ago and no reply yet.
Hmm.. Unfortunately I don't have any control of that so you'll have to wait for Unity to get back to you. If you're using the new asset store you can click on "Shop on Old Store" on the top right and see if that works:
I'm having an issue trying to figure out how to make the Ride ability work with my character. I'm using the Stardudes asset for the character and have copied Blitz from the Clean Scene into my own. Currently my guy is sitting inside the horse, what options do I tweak to fix the character's positioning?
Eventually I want to add in different mounts but at the moment I'm having trouble with just the default horse.
The mounting animations use root motion so in this case it looks like you'll need to use a set of mount animations that more closely match your character's rig.
Would creating a new ability that mirrors how Ride works but places the character at a specific point within the Rideable Object be a better course of action? I'm less concerned with the mounting animations themselves and care more that the character is placed in the correct location on the rideable object.
That would also work
You could subclass the Ride ability and then position the character within the Move method.
Do I need to download the source version to be able to see the existing code for the Ride ability?
That's correct - you can get it here: http://opsive.com/assets/ThirdPersonController/documentation.php?id=50
does this character controller support box-based character colliders (as opposed to capsule based ones)?
The controller does require a CapsuleCollider, though it doesn't have to be oriented in the positive y direction. Box colliders are hard to support because there is a hard edge on the bottom corners of the box which doesn't work as well for collision detection. You can add extra colliders to the character though so as long as you have a single CapsuleCollider you'd be good to go.
Hi there. If anyone fancies trying out UMA with Opsive's third person controller:
I've notice you've done a whole rebuild to the animation set compared to your tutorial video and changed a lot of the interfaces, options,and settings. I know I can customize any animation with Mechanime but I can't seem to get it to react or do anything you show in your videos without going into the script and reading miles of code to figure out where things need to go and what I need to do to make them work with what-ever you have going on in there now. Is there a plan to expand the Manual to fit these changes and to replace the tutorials with ones that go with your new setup or should I just go out and get InVector? I can't get the character to pick up an item let alone get anything working because the information in the manual that is so well documented on the sections I need to use to Create objects is 4 sentences if a paragraph, No deep explanation, and carries no reference but the game name to the new format.
Better question is there a way I can download your older version? You know the one I hear all the good things about?
Is there a particular video that you are referring to? The character/item creation videos should be up to date. The only one that I know of which has different values is the ability one that adds the Height Change ability (the correct values are ones listed below, copied from the clean scene):
You can download older versions source code on this page but it doesn't include the rest of the files so may not work. There isn't a way to download old versions on the Asset Store.
I'm trying the latest version out on the Wii U platform and I'm getting the following message spammed to the console when running on the hardware:
ExecutionEngineException: Attempting to JIT compile method '(wrapper delegate-invoke) <Module>:invoke_Vector3__this__ ()' while running with --aot-only.
at Opsive.ThirdPersonController.SharedMethod`1[UnityEngine.Vector3].Invoke () [0x00000] in <filename unknown>:0
at Opsive.ThirdPersonController.CharacterIK.LookAtTarget () [0x00000] in <filename unknown>:0
at Opsive.ThirdPersonController.CharacterIK.OnAnimatorIK (Int32 layerIndex) [0x00000] in <filename unknown>:0
I just tried a WebGL build (which is AOT) and it worked. Did you make sure to import the source?
No, I didn't import the source. It's been a while since I used this and I forgot that was necessary for this issue. Thanks for the quick response as always. I'm really pleased to be back using your controller. I've gone round and round with other potential solutions only to be disappointed time and time again. But I now have TPC up and running with UMA 2 and it's running as smooth as can be.
I am still seeing one thing though that I remember from a long time ago. When my character jumps there is a frame rate drop of 10-15 on Wii U. I don't remember there ever being a fix for this, but maybe we can get that sorted out in the near future.
That's great to hear. If you profile the framerate drop it should help pinpoint the bottleneck, but generally when there's a framerate drop it's related to the animator updating. In 2017.2 there is a new Physics.autoSyncTransforms method which should help speed this process up though I haven't tried it yet.
I'll do some profiling when I get some time and I'll let you know the results.
I have to use 5.6 for the time being. The 2017 version for Wii U is still not ready for prime time.
@opsive It's been a while since I've used this so I'm sorry if I've asked this before. I'm going to integrate with Emerald AI and I'm not sure where to begin to look for the interfaces where I can have the AI damage the player and vice versa. Do you have some docs somewhere on the basics of this sort of integration?
This page will get you started:
Beyond that you'll want to take a look at the CharacterHealth component:
Fantastic. Thanks again.
Btw, I got the source code and now the JIT error goes away. Thanks for that as well.
@opsive I didn't have much time to do the Emerald AI integration, but I was able to easily get the player attacking the AI using a modified version of the Damaged class sample. I suspect the rest should be just as easy.
@opsive, I'm having an issue with my melee weapons. When I attack and the weapon hits anything it stops the attack animation. So it seems that when the sword collider hits anything, the attack completes but doesn't play the full animation. This doesn't look good visually and feels wrong as well. I'd like to be able to be right up against an opponent and take full swings whether they hit or not. How can I insure the attacks always follow through even when hitting an obstruction?
Also, how can I get the controller to honor the full motion for an attack? I've got Sword & Shield animset pro and when I assign the attacks to the various layers, the character still remains rooted in place when attacking and only the upper body uses the attack animation, but I put the animation reference in all layers. But maybe I missed something.
@magique - Did you check the base layer in each of the animation states in the Animation Options section of the Melee Weapon component? I think it's called Animation Options; it lists Aim, Default, Equip, Unequip, Recoil, etc
I know how to fix the issue in your previous question... But I forget what the setting is called. I think it's on the Melee Weapon component too. I'll be at my computer in about an hour; if you haven't received an official answer by then I'll load up a project and get the setting for you.
I don't believe I did that. I'll check that tonight when I get back to my dev computer.
The setting you want is Wait For End Use Event, which is under Attack Options on the MeleeWeapon component (near the bottom of the inspector).
As for the other... I was close, the section is Character Animator Options, in the Use States:
In the Layer field, ensure both "Base" and "Upper Body" are selected for each of the attacks in the chain.
With Sword & Shield Animset Pro, you'll be wanting all of the animations to run on both of these layers, as the upper body is at a 35-45 degree rotation when in the "ready" combat stance (from which all of the attack, damage, etc animations start).
Thanks for helping!
In addition, if you never want to use the recoil animations you can remove the recoil state name under the Recoil foldout. An empty state name won't be called.
Awesome. Thanks for all the help from both of you. I think this will get me past the issues for sure.
Btw, I'm still loving the switch back to TPC. It's working great for me and I feel like I'm back in control again.
@TeagansDad , @opsive Both suggestions worked perfectly and now my swordsman looks and feels a lot better. Thanks for all the help.
@magique - you're welcome!
One other thing I should mention... I found that I needed to turn off the Aim IK when the sword & shield are equipped, as it often made the sword arm move in awkward ways. That goes for the rest of Kubold's sword animation sets as well -- and probably any others that use a stance with a similar torso rotation (such as Mixamo).
I'm seeing some errors after attacking and moving around for a little bit.
Infinity or NaN floating point numbers appear when calculating the transform matrix for a Collider. Scene hierarchy path "Mercivus/Root/Global/Position/Hips/RightUpLeg/RightLeg/RightFoot"
Invalid parameter pos in Rigidbody.TransformChanged because it was infinity or NaN
Assertion failed on expression: 'IsFinite(gain)'
Assertion failed on expression: 'IsFinite(gain)'
Infinity or NaN floating point numbers appear when calculating the transform matrix for a Collider. Scene hierarchy path
Opsive.ThirdPersonController.CharacterIK:FixedUpdate() (at Assets/Third Person Controller/Scripts/Character/CharacterIK.cs:212)
Note that I'm using a UMA 2 character.
How do you do that? Is that an inspector setting somewhere? Do you mean the Can Aim flag? If so, then I agree and I already turned that off.
Also, while the OnAnimatorItemEndUse works great so the animation completes, it has undesirable side effects like continuing to damage the enemy well after the attack is complete. Because I have to move the event to the end of the animation for it to fully complete. Is there another event that will disable the weapon from causing damage, but still allow the animation to continue?
I found the solution by setting the Single Hit Attack flag.
One more thing I forgot how to do. There is a delay in between attacks and I'd like to reduce that to nearly zero if possible. I believe there is a way, but I can't remember how.
I got it closer to what I wanted.
I forgot about another issue. When I first start a scene with the character in it, he is somewhat rooted to the ground. I can walk and run, but it won't jump. It also only performs upper body attacks. But if I play with the controls and try attacking and jumping and moving simultaneously a few times then I can get it "unstuck" and then it starts behaving again.
Are you able to tell me how to reproduce this one within a demo scene? Line 212 of CharacterIK points to the hip position containing a NaN:
m_Hips.position = m_HipsPosition;
However that error relates to the right foot. Is your rig setup correctly?
Can you insert a breakpoint within Jump.CanStartAbility to determine why it's not starting?
Probably not. I'll have to get back to this one later.
This one is very interesting so far. I started debugging and the information is a dead end so far. Checking the Jump.CanStartAbility indicates that the ability can start because that function returns true. However, it never gets to the AbilityStarted function. Any advice on where it could get derailed in between these 2 functions?
Did you replace the jump event? You'll need to make sure you also add the OnAnimatorStartJump event which actually makes the character jump.
No, I didn't replace anything. I'll try the breakpoint and stepping through the code.