#🏃┃animation
1 messages · Page 11 of 1
Oh okay ill check there then
picture from google:
similar to what iam trying to achieve
If you're doing sprite sheets, then that's of course made outside of Unity and imported as a sheet. Then you can make an animation which flips through the sprites in Unity.
so that would be a photo then allright
i tought i could use .chproj or .fla .xfl to create a less "manual" importing for animations
thanks alot
There may be plugins to allow workflows with specific file types. Something to search up
Photoshop is preferred for creating layered files for rigged sprite animation. For frame/sheet animation, you can use pretty much anything.
How would one do this?
And you mean from the beginning create a 3D character?
I essentially just have a site that allows you to make character sprites cause I can’t draw but they only are animated in the 4 directions, I just wanted to know if there was some wizardry or AI stuff that could help me lmao
Yeah
No
Make the beginning and the end match, including the tangents of the curves.
First time exporting custom animations to Unity. In Blender, the body was a child to the joints; imported through FBX they're on the same level. I put an Animator component on the package holding both the body and joints; didn't work. Tried it on both the children; didn't work. Is there a different way I should've exported them or am I just utilising the component wrong?
Nice weight and momentum there ^^
Hello, i'm a newbie at coding and game development and i'm trying to sort our some head movement
basically i want the players head to change to the appropriate animation depending on the direction of the cursor and the location of the player at the moment it seems to work depending on the direction of the cursor by comparison to the spawn point not the player.
i'm guessing its a script issue i've tried...
animator.SetFloat("mousePosX", mainCamera.ScreenToWorldPoint(Input.mousePosition.x));
animator.SetFloat("mousePosY", mainCamera.ScreenToWorldPoint(Input.mousePosition.y));
but that returns an error 😢
any tips would be greatly appreciated ❤️
Using Animation Rigging. Why on Earth does Override transform in pivot mode offset the constrained object per-frame rather than setting rotation to match?
https://i.gyazo.com/f7afd1a6235079e2b6ee8050c8abd62b.mp4
Thank you for reply, but transition is using boolean for checking if player is moving (it is checked whole time (even when changing direction))
And I am detecting if player is changing direction by comparing players previous normalised vector of forward direction and his current normalised vector of forward direction
If their absolute difference is >= 1, then direction is changed
Right, but it still seems to me that reversing the movement direction causes magnitude to pass through 0 or very close to it, which prevents the transition with condition movementSpeed > 0.7
It seems impractical to have it depend on a frame-perfect switch in input/velocity even if it would work in ideal scenario
Still that's only the thing that sticks out to me, real problem could be elsewhere
Also, it looks like you have quite long offsets of almost up to a second on some transitions which may cause them to be missed for very short states or feel sluggish even in ideal conditions
Oh you are right, I completly misswd that sry. But I think that running animation would stop since I am using that value in blend tree and the player is sprinting if the value is above 0.7
You are right, I am new to animation and am not aware of all the possibilities, I am using only couple of options in animator (actually only has exit time)
And all animations are from mixamo
@tacit hazel The speed might not be the problem as I assumed, since the variable is at least reported to stay at 1 during the turn
However you may notice that at the precise moment of turning and transition to next state, the 180Turn condition is not met
Logically if you compare the character's foward direction to find the difference over time, it'll be true only after the character's motion has reversed
The solution might be to detect raw input instead which gives you results on time, and perhaps to add some extra check to Idle state transition as a precaution to make sure it won't fire before you've determined a change in direction
You are right, that makes sense thank you
Yeah true, I've wanted to avoid adding extra check to have as clean code as possible, but I guess that this case reguires another check 🙂
What do you mean by raw input?
You'd read the input directly for the parameter so you know what keys are being pressed, rather than where the character is moving
If you're using the old Input System you'd have to specify "raw" input because otherwise you get a smoothed value that reacts with a delay
Raw returns -1, 0 and 1 right?
That would be very usefull
https://docs.unity3d.com/ScriptReference/Input.GetAxis.html
https://docs.unity3d.com/ScriptReference/Input.GetAxisRaw.html
Both of them do, but raw is instant
Again assuming this is the system and method you're using
Oh I was comparing Vector3 input values not player.forward. I dont know why i said that i was comparing forward vectors. I mislead you sry. Basically what I was doing was: I saved previous vector3 input of direction that character was suppoused to move at based on his input values. I later compared z axis value of that previous movement direction with z value of current movement direction (both of vectors are normalized) i then checked if their absolute difference is >=1
Why isnt that method instant as well
Thank you for explanation and all your help 🙂
If you mean the non-raw input it's meant as a very easy way to get smooth movement without having to do any smoothing math
But if you normalize it it'll likely be just delayed instead of smooth
That makes sense tnxx
And if I am using it to check condition in transition, result should be instant right
I think it'd be easier to make it work with that yes
You could still use the smooth input for movement itself, but check raw input for where the player actually wants to move
If you want it to be smooth, that is
Thank you very much 💪
Yes, my jumping is also laggy (if I hold SPACE button, animation triggers every 2nd jump) but unfortunately I doubt it can be fixed since it is using space and not horizontal or vertical axis
Of course it can be fixed if you identify the issue
Buttons are just a binary signal so there's no smoothing or floating point inaccuracies to worry about, unlike with axes
The most common cause for that problem you describe is simply that there's no transition to a second jump at that specific time from the current state
No transition to jumping from falling or landing
You can also make transitions from states back to themselves, such as jumping to jumping
Now since it seems you start having a lot of transitions, consider reading all about animation layers, blend trees and sub-state machines to cut down the need for so many
can I just not constrain any transforms when the animations are not playing, as how it should be?
No idea what you mean.
You can do whatever you want to with the transforms as long as you do it after the animator is done with them for that update.
bumping this, since I am still stuck on it and it seems to have gotten burried...
does anyone have an idea what could be the cause?
So, my root-motion character seems to be resetting position every time animation ends.
I don't have anything else moving it manually. It's all root motion too
bumping this since I am still stuck on
Bumping without providing any extra details is a bad idea. But it looks like you're trying to edit the transforms of as humanoid rig directly instead of editing the muscles?
Is root motion enabled in the animator?
How would I edit the muscles?
It is, however I just figured it out. I had to duplicate animations that I use AFTER I set up the rig settings on the character import.
how can I make an animation not loop while editing or slow it down? as i can make it not loop in runtime but how can I do that in the editor
Ah, yeah. Duplicated animations are disconnected from the original so changes don't propagate.
Anim loop player movement issue
Hello, I need some help. I have created and animated a character in Blender, exported it as an FBX, and imported the fbx into Unity. In the import settings, the Idle animation appears to have imported perfectly (note that the characters hands are correctly positioned on the gun). Then when I look at the created animation the hands seem to be broken (note the neutral pose of the hands and that they are not positioned on the gun). Any one know what I'm doing wrong here?
UPDATE: I seem to have gotten it working by moving the Idle animation to the front of the timeline in blender. It was previously at the end of the timeline immediately following an animation that involved VERY large position changes. My best guess is that Unity did a bad job of smoothing the transitions from the animation preceding the Idle, but that's a pretty uninformed guess. If anyone can tell me what's going on here, I would appreciate being able to avoid this in the future.
Thank you very much for detailed reply 👌👌👌😎
When a keyframe moves a transform, it stays there until another keyframe moves it but the problem is that some contexts keep this data while others reset it
So when you have animations chained together on the timeline, you need to be mindful if the pose data is modified from the previous pose or from the resting pose
I don't know the exact rules or best practices but I padded every clip with the t-pose when exporting them together as one timeline
The problem also happens outside of Unity in Blender's action editor
When switching between actions, keyframes are only added, not reset, unless you go through a fully keyed resting pose action first
In both cases you can't know for certain if you're looking at a combination of two clips or just the one, unless you isolate and confirm it
I think I see what you're saying. T-Pose between each animation on the timeline seems like a good idea. Even if it's not the "Right Way" it would certainly reveal the problem earlier so that I could address it before getting into import export hell.
I have an asset that has an idle and a run animation, but the run animation is pretty abrupt and looks odd when going from idle straight to the run animation.
Is there a way to insert one frame at the beginning of the run animation, like a transition that plays once whenever it goes from idle -> run?
I can maybe edit the sprite to add an in between frame of animation, but I don't want it part of either the run or idle animation, just in the middle.
Could also work to key every bone at the start of a clip before exporting, but that seems a bit more destructive as a process
That's what I was trying to do, but it wouldn't surprise me if I missed a bone somewhere. Without the TPoses in-between it seems like it's pretty much impossible to tell.
Anyway, thank you for your input
I was just goofing around with it, and I think I found the problem. in one of the animations I have his weapon disappear. I tried achieving this by scaling it to 0. After a little messing around I noticed that It's only keyframes after this point that get messed up. When I changed the scale to .001 instead of 0, it all started working.
I can see why scaling to 0 is a bad way to make something disappear, but I'm surprised I was allowed to get as far as I did without Blender or Unity pointing me to that problem.
Good to know to watch out for that 
how to i make the leg bone not effect the whole body
hello guys a question about cable wire & movement.
have to model a cable between 2 elements.
The ends of the cable must be mobile and able to move on 2 or even 3 axes, any idea how to do this?
Is it possible to do this via an iK structure in maya, blendeer... ? is unity going to manage it well?
Haven’t found much yet but if someone has an answer please tell me. Though I have found out how to do this in runtime just haven’t yet while editing the animation.
I don't think such options exist, but since dot and comma are shortcut keys for next/last frame, you can hold one of them for a slowed down non-looping preview
I usually just drag the seekbar manually to get a slowed down view of the animation
Gotcha thanks 🙏
If you enable sample rate here, you can change it to alter the speed of the animation without changing keyframes
But it does change the speed elsewhere too
Note that "sample rate" is not "speed" exactly so if you need to change the speed of the animation it may be better to change the state speed from Animator, or stretch out the keyframes
Ahh I see that will help me a lot thanks again
I've got this vehicle made in blender, do I need separate animation for forward and backward rotation, or can I use just a forward rotation animation that will start rolling the other direction when i ride backwards?
it is possible to mirror your animation but i have no experience with non human animations tbh
You're using a limb solver with too few transforms; it is reaching all the way to the root because you only have two leg bones
what should i choose then?
You can either make a duplicate of the animation and reverse the keyframes, or you can set the speed to negative
You just need to use a proper number of 'limb' bones in your rig, if you want to use the limb solver.
While you can use IK I probably would use a cloth sim.
Or even just physics joints on your bones
Hello, thx for your reply.
I think a I gonna proceed the following way ;
Im going to Bone the cable (inside blender) and export it as .fbx to my customer who is gonna integrate it inside unity (using joints).
The ik spline seems to me a little "complicated"(to do for me) inside blender.
I setup the aiming animation rig on the charachter enemy model which already has animations controlled by animator controller. When I play the game rig is working fine as intended but the moment I setup an avatar to run animations the game crashes. IT runs fine in both cases if there is only rig or only animation but crashes when both of them present at the same time
The model is humanoid and the animations attached are also humanoid
how do i change the number?
how can I make a animation transition preset without it changing where the transition goes to?
i hate having to change transition time every time i want to make a new transition
I just imported a mixamo animation with my skin but for some reason it won't play. I'm able to see a preview but it just wont play in the actual game, I added this to an animator which is attached to my object.
It also shows that it's playing in the animator tab
how i make it smooth
copy the start keyframe to the endkeyframe
it still have that slowning down antimation
anyone?
In Unity how can I make the railway track force the wheels to rotate when the curvature starts (the wheels of the cart will be rigged) When the cart is moving I want it to stop (get stuck) at the curvature if the wheels can't turn. This is sort of like steering simulation. I want the wheels to **steer **according to the track's curvature and according to the rig. If the rig does not allow it to steer I need it to stop moving (this is also a way for me to test if the structure of the wheel axis actually allows the steering I am looking for).
You'll probably want to infer the track position by storing the track path as a curve, or in some other form, to know when the wheel should turn
Otherwise it's just polygons with no information where it's going
Note that in reality sharp 90 degree turns aren't mechanically plausible or even possible without at least multiple axes of motion per axle and a lot of slowing down
I'm planning to switch the steering to something closer to a car's steering. So when you say curve do you mean I should generate the rails inside the engine using curves instead of importing them as a 3d mesh ?
These are supposed to be modular rails of about 2 by 1 meters per pice which the player can place in the world at their will (minecraft is a good refference for how they should work). The turns are sharp because I think it's a good way to give the player the freedom to build the railways as they see fit and it also simplifies things (while complicating this steering issue a bit).
I don't mean to generate the rails inside of the engine but I imagine you need some way to pass the information of the rail shape to the wheels through code, and a curve path system sounds most logical
I'm not sure what the design goals and constraints exactly are though
I see okay that's good enough for me. I'll note that down, I think I'll have to apply physics on the minecarts as well.
What do you think of my first Unity animation with ship size comparison?
Do you have any kind advice to recommend me?
https://youtu.be/gvUpj0xkXzk
Animations and comparisons of the ship sizes of famous pirates such as BLACKBEARD on his frigate, the HUGE 116-gun ships of the line, today's HUGE mega yachts, the world's biggest liners and supertankers.
The classes of ships include the largest sailing ships, the largest submarines, the largest ocean liners and the largest supertankers.
Suppo...
Hey guys, I am a beginner to Unity and have animated my character using Mixamo however, when I attach all my animations to the character using an Animator Controller. The character starts losing the rotation (i.e. it starts facing in some other direction) while walking forward.. Is there a way to lock their rotation?
Nevermind, it was a silly mistake from my end. I had my "Apply Root motion" enabled in the character animator.
wherever my target is the hand will be on the complete wrong side. Whats going on?
I'm using Animation Rigging Two Bone IK constraint
Overall it is quite nice; just enough secondary motion to keep it lively.
I am on my hands and knees BEGGING for an answer. The whole animation will not import whatsoever into unity (2019.4.31f1.)
On the right you can see the blender window showcasing I have BAKED, PUSHED DOWN ANIMATIONS.
On the left you can see my Blender export settings
And in the middle, you can see the import settings in Unity. Notice something? Like how they're #wrong?
Please save me I've been dealing with this for the last hour and a half
I set up the rig for the enemy to aim toward the player. Everything is set up correctly, It was working perfectly fine but when I attached the avatar to the animator controller of the enemy the unity crashes every time I play the game. I resolved this issue by making the rig object the sibling of the bone hierarchy of the enemy. But now the enemy aims a bit upward instead of toward the player. The right hands is not positioned correctly towards the player and I cannot rotate manually ofc
This happened to me when playback framerate in Blender was below 60
You'd think it was just for preview but apparently not
I can't, that's why I'm so confused
this
WH THAT FIXED IT WTH
well, kinda fixed it
Kinda?
The run animation is a little wonky, but it's fine since I now need to remake them to compensate for being 60fps. I'll just hope for the best
Okay So I have a dumb question since I am new to this- if I wanted to make a slime with blinking eyes, I make the slime and textures in Blender, and then do the animations in Unity, correct?
you can do them in blender and import to unity, or import just the model and do them in unity
For some reason my sprite says missing sprites in the Animation tab whenever I instantiate it. I assigned the sprites in the Animator Clips on the prefab. Please lmk if u got any solutions.
I retargeted an animation from one rig to another in blender using rikoko
Then I exported to unity
When I play
The gameobject moves a bit in the x axis then the animation plays as usual
How do I fix this?
I had weird problems if I didn't disable root motion
might be the issue here
Hey, how can I access this progress bar that unity displays for a blendtree in code?
normalizedTime doesnt work, it just shows the time elapsed since i entered the blendtree
State machines dont work either
Sounds like a blender problem though you might be able to fix it by cropping the imported frames in unity or making an editable duplicate in unity and editing it.
You can't WHAT? Specifically. Because that post was referring to using LateUpdate(), not to the stuff you were saying about how you think it should work.
I can move transforms on LateUpdate() even if animations keep playing yes, but I don't know why I can't move them on Update() when the animations are completely stopped
I got that "Default" animationState, it is not set to loop and it seems to play only once
I explained why.
is the animator not done with the update when the animationState has finished playing?
NO.
That has nothing to do with it.
Every single frame, the game calls Update, then it calls the Animator, then it calls LateUpdate.
So if you move something in Update, the Animator will move it right back before anything is shown.
How can I make an animation play in reverse without making a whole new animation?
Set the speed to -1
Sometimes after editing my ui animation it waits like 3 seconds before actually going visible and the animation doesn’t look right after the 3 seconds. This only happens sometimes after editing and I think it has to do with animation events. I can tell its running before the 3 seconds as the animator shows it is
It’s hard to explain and I’m on version 2021.___ something
Even harder to understand your explanation, sadly
Hi, i'm trying to animate this character i downloaded but i can't get it to work, here's a vid. Hope it's okay to post like this.
you cant see the animation popup but i run the animations and they look ok, just a huge noob with animations xD
idle (if IsWalking is true) transitions to WalkN, and WalkN (if IsWalking is false) transitions to idle. I run it and it only plays the first animation
You can change animation speed and sample rate in Unity regardless of what speed or sample rate it was exported as
That's expected when the direction states don't have transitions between them; if the only possible transition is back to idle, no other state can play before that transition occurs
You really should look into blend trees for that type of system
Yeah, like Spazi said you'd need transitions between each direction and the other directions.
yep, im a total newb, but i figured it out.
works almost perfect
In addition to those 28 transitions you're missing 80 more possible transitions
Or exactly 1 blend tree

blend tree it is, but for now, this will have to do
small project but deadline tomorrow, i'm surprised i got this far
only thing left is colliders
but is tricky since it's a 3d core with flat ground and a fixed ortographic camera, basically 2d game
Not starting to learn new systems in a pinch probably the right choice
ok ill send a video
so this is my script for when my cutscene ends it plays my transition animation. in the video you can seer the animation doesnt play at the start and then goes way to fast
I have very little art skills, but what could be a way that I could take this sprite which has 3 attack angles and change it to be a free aim. Basically detach the arm and bow?
I'm using corgi engine which already has built in mouse aim for projectiles, but it looks funny when the arrow shoots out at an angle the sprite isn't aiming at.
Not without code and/or animancer
You'd need to remove the bow/arm sprites and draw in the missing areas, basically.
how would i code interploation?
I dunno, I haven't done it.
I know it's possible because someone made an addon to do it.
But there's no built-in way.
What the fuck am I looking at here?
Okay so i show my animation at the start which is with the ui. Then the cutscene plays and then the ui animation pops up again but isn’t the same as the original animation
It’s hard to explain
Your transitions are probably fucked up
Anyone had problems with their bones getting misplaced after some time? https://cdn.discordapp.com/attachments/497872424281440267/1076981658579902474/2023-02-19_13-35-35.mp4
Not sure what you mean; if you mean the character floating, you might need to bake the y component of your root motion, or you might have a physics issue unrelated to the animation.
I tried playing the Anim without physics involved, still the same thing
baking might work?
It might; it is at the very least the first thing I'd try.
Wait no I mistaked what you said. The character floating is just the Base offset of the Navmesh, not a big deal
But see the legs? They look so broken
Plasma youll get banned lmfao
PLASMA YOU NEED THIS SERVER
Bro bruh
Oh, sorry, your example made it hard to see what you meant. Is it the bones in the wrong place, or just the mesh attached to them?
Pretty sure the bones themselfes
Might be an incorrectly set up avatar, could be IK if you are using IK
Might just be a bad animation clip
Am using IK, for the arms
Does it with all animations
exept 1 for some reason
I mean, really don't have enough info to try and debug it. An avatar issue still seems most likely.
Just using a basic tree (Ignore the name lol I was testing dif anims)
And animator has no avatar
No avatar means no retargeting
So is that good or bad?
Avatar is the default pose or something?
Oh and btw I mistaken again
The skin itself moves, not the bone
This is such a stupid issue
Huh, wonder why Animator only offers linear transitions
Nonlinear blends and extrapolation would've been really powerful
Because Unity hates animators
When creating an animation, is there a way to add a keyframe for all bones. For example I want to keyframe the rotation for all bones at key 0 in their current starting position.
Select all necessary gameobjects in the Animator's hierarchy, right click and add key on the transform component's properties
Bone rigging in humanoid charachter is influenced by animation from animator. Although the weights of the rig is set to 1
The enemy should be aiming but the hands are influenced by animator
when i turn right or left it makes the character go to the other side of the box collider
i have code that flips the sprite when turned right or left but why is it moving the sprite?
Hello!
Does anyone know how I should deal with animations in Unity that switch parents mid-animations? I have an animation which, in Blender, starts out with the gun parented to the right hand, but switches to being parented to the left hand in the middle of the animation, and then switches back to the right hand. The problem is I don't know how to translate these parent-relationships to Unity. Even if I change the weapons parent through code on the exact right frame, there's still a noticeable hitch and the weapon is aligned slightly differently each time. The video here on discord shows the intended animation in Blender, and the Drive-link below shows how it looks in Unity if I don't change the parent through code, and then how it looks when I do. How should these kinds of animations be handled? I tried Unity's animation rigging package and its multi-parent constraint, but it didn't do anything.
Thanks in advance!
https://drive.google.com/file/d/1mBmCUYVul6p9zGQhe7REjWYT2mXcbNDS/view?usp=sharing
How can I override an animation? for example when I run the animation again while its still running
I think you can make a transition from an animation state back to itself in the animator, and set exit time to off. Just right click on the state, choose Make Transition and left click on the same state again.
Does unity not inerpolate animations when playing them at slower time scale?
Is there any way to apply root motion from the object to the parent
Sure, you don't have to use animations for anything.
Anything you want to do can be done purely in code.
nvm did it :)
am happy now
Is there a way to have sprite swap and Color Tint both selected?
Is the IK on all layers?
Depends on the details. It will interpolate most things if the curve tangents aren't set to constant and you aren't using a flipbook
Yes. You can override OnAnimatorMove() to change the default behavior
There is only a base layer on this character's animator.
Could someone create me a very short animation for my rig for my indie game? I'd pay you 30$. Contact me via direct message/private message or reply to my message here if you're interested.
can anyone help me with my first animation
i made a bullet animation exported it as animation and now i am in animator but its showing nothing
what do i do?
anyone??
In this image you have not selected a gameobject with an Animator
i want it in 2d
also
@agile solstice can i add direct animation to an object like adding a sprite?
Animator works the same way regardless of dimensions
It overrides component properties in its hierarchy
For sprite animation that usually means changing the sprite reference property in Sprite Renderer component
Anyone with any tips on how to rig this model? i tried mixamo and accuRig but it just gets destroyed no matter how i arrange the joints 😅
You could just try creating the bones manually, like a primitive cave man... 😄
Like a cave man? Way too advanced for me
how can I go from one substate to another without having make n(states) transtions
say i have an idle substate with 4 animations
and a walking substate with 4 animations
i want the idle and walking substate to go to transition to a 3rd attack substate with 4 animations
do I have to make 8+ transitions telling each animation to go to the attack substate??
I swear something is wrong with my animator
I need to do a call with someone to explain it visually because I just don’t understand
Scratch that don’t reply to it
Hi could anyone please tell me how i can put all my animation frames on the first guy i drew? So when i click on the arrow on the first frame all the other ones pop up.
The assets under the arrow are individual sprites, sliced from a sprite sheet using sprite type: multiple
You don't need a sprite sheet containing each frame - for each frame
ahh okay so i need to create a sprite sheet i think! thank you i am just very new to unity
Well you don't need that
But I assumed you have that since as you say "all the other ones pop up"
yeah i want all the other ones to pop up when i click the arrow instead of them being in my character folder as individuals
anyone has FBX assets of hand poses for VR? oculus only provided the model with no animation
So, I have a root motion animation of a "mantle", and the video shows it transitioning to the idle animation, however because of the root motion the transition is very strange after the mantling is completed. Anyone know what I should do here?
Also, I can't disable the root motion for the mantle because I need it for my climbing.
Now the entire crafting process is going to be an animation that plays until the object is entirely assembled, after which the animation stops and the character plays the idle animation or another pre-defined animation (like sitting down).
The tricky thing is the location of the "building blocks" and the location of the crafting inside the perimeter will be different every time, and the terrain will contain deformities such as maybe the crafting takes place on a hill or it is done in an enclosed place such as a cave so there is not that much place to move around but the character has to move plus the animation needs to be able to be stopped at any moment (if the player gets attacked or if the player simply cancels the crafting process) but also it needs to be able to be resumed for where it left of, even if the "building blocks" places were switched in the process.
How should I do the animation in this situation so that the character is able to pick the objects from any location inside the crafting perimeter and will assemble them to the assembly location inside the perimeter based on the initial shape of whatever object it's being assembled, (in this case a minecart). ?
Will code and procedural animation need to be involved here and if so is there any documentation/tutorial name for this type of pre-programmed/pre-defined animation that is able to adapt to different situations etc.) ? Does this type of system have a name so that I can do some research on it ? ```
How many bones are too many? I'm making a mechanical model in blender thats using an armature to simplify component movement.. but there are a lot of parts
I have this rig I'm planning to duplicate 7 more times as one piece
Good question. It really depends on your target platform, though. That is probably fine for a pc build but probably a bit much for most mobile.
If it gets past a certain point it might be worth looking into vat animation or something.
But you'll probably have to test to see
Skinned meshes can get expensive, but if you don't need armature deformation you won't need them be a single mesh
Instead separate meshes parented to individual bones
Though since Blender doesn't allow parenting to bones (except with constraints) and Unity/FBX doesn't support non-armature animation, you'd have to set them up with constraints and after import replicate the relationships by parenting objects in the hierarchy
It might not be worth going through that if having them as a skinned mesh isn't too expensive
interesting! I appreciate it!
Not sure if this is the right channel, Animation/Timeline, FBX/Import...
I've got an FBX model and separate FBX animation files intended to be applied to the model. The prefab comes with an anim controller, that plays the animations in Play mode; however, I can't figure out how to apply animations in the Timeline for scrubbing.
I'm working on a cinematic/timing thing, and I need to be able to scrub in the Timeline - not just "animate when in Play mode".
Any suggestions on either merging the fbx files, or otherwise how to get the Timeline to animate the mesh? Drag-dropping just doesn't seem to work like other FBX files that have the animation as part of it do.
I guess what confuses me is that technically its only one bone per object, so only one bone is influencing the vertices (?), so then it should be performant because it's not multiple bones on a single object?
It could be
I don't know exactly how the skinned mesh renderer works internally but the Skin Weights limit in quality settings at least suggests that it's a relevant factor
But also regardless of that setting, I believe you either need to set object bounds beforehand or have them calculated at runtime for it to cull properly
With non-deformed meshes the engine can make approximations for calculating the bounds, but if individual vertices can go wandering it would make that harder
object bounds is a new term for me - could you share some info on that?
I'm having an issue with my animation rig. I am using the multi-position constraint to bind my weapon to the left clavicle of my synty model. But, the weapon isn't moving, and seems static. Has anyone ran into this issue?
Bounding boxes are coordinates that are guaranteed to contain the object between them
So it's cheaper to know where things approximately are and are not, since you need to do math on just two points in space, rather than every vertex
The engine uses them for many things, mainly rendering and physics to figure out when objects are close to intersecting to start making more accurate calculations
Most of it is handled automatically but with geometry that changes shape at runtime, like skinned meshes and particle systems there may be complexities
https://docs.unity3d.com/ScriptReference/Renderer-bounds.html
Appreciate it thank you!
Found an answer to my own question, requires blender - but got it working following this:
https://blender.stackexchange.com/questions/188309/merge-two-or-more-blender-files-with-the-same-model-but-with-different-animation
Was able to merge the mesh/animation FBX files into one single FBX file, which that combined file behaves as I needed in Timeline.
Or not - It worked for one model, but when I went to do the same to another (different fbx files, model, animations) - the rig doesn't seem attached to the mesh in blender, so when I try to combine the animations nothing happens.
So I'm still back to square one:
How to get Timeline to show animations when scrubbing in Editor, when the animations are different files than the mesh?
Ah Hah! I was trying to drag the raw FBX files, like I do for my own model/animation that works easily.
Instead, I needed to drill down into these other FBX files. Drag the 'Mesh' portion of the mesh-FBX file into Timeline as an Animation Track, then expand the Animation FBX file and drag the nested animation into Timeline on that track.
Problem solved without blender/fbx manipulation.
@agile solstice made something to test! we'll see how this works in unity lol
You can also have animations from one FBX file appended to another by using a special naming convention- have the FBX with the animation named the same as the mesh fbx but with @ and the animation name will append the animation from that file to the first file inside unity.
Looking nice! Just make sure to bake any parametric bone animations before export!
how can I go from one substate to another without having make n(states) transtions
say i have an idle substate with 4 animations
and a walking substate with 4 animations
i want the idle and walking substate to go to transition to a 3rd attack substate with 4 animations
do I have to make 8+ transitions telling each animation to go to the attack substate??
Hello, I am making a first person survival game and I have a character that can wear armor and use tools, whats the proper way of animating everything, like if i want animation for weapon reload, that includes animation of the weapon and the hands, do I make the animations together?
Hmm, the asset already has the animation files with @ just like you said. [I didn't know that was a naming convention; neat, thank you] But the model FBX was named different. - I just renamed the model FBX to be inline with the model@animation files already present - but I'm not seeing the animations showing up in the model-fbx.
Is there something else I need to do, to get it setup?
is there a way to scale up a state in an animation controller
or do I have to manually scale the images
its also a seperate animation so I could do that
Right, like that 😄
What do you mean be 'scale up a state'? Make it last longer? Make the gameobject bigger?
yeah I just made it bigger
I meant scale up the animation but I used transform.localScale = new Vector3(2,2,2);
works just fine
Yeah, far as I can tell the naming convention is there. I didn't make the files, part of an asset bundle. I copied/renamed the 'SK_GreateHornedOwl2Sided' to 'GreatHornedOwl' to try and make the auto@animation work, but I feel I'm missing something.
Still just has the 'Take 001' that's on the base/mesh (un-animated) fbx file.
And they aren't appended when you unfold the greathornedowl file?
Oh, sorry; I should've had that expanded in the screenshot. But, no, just Take001 is there.
I've tried reimport, too; on a whim, to no avail.
Yeah, not sure; maybe it's because the files were already there. I might try renaming before importing entirely. I have a workaround in the interim at least. Good to know about that feature to keep in mind, though; thank you.
Does anyone have advice for how I could make this run cycle look better?
Head motion.
Much better. I'd probably remove the front pixel that flashes occasionally, looks more like a bouncing erection than a foot.
Maybe make the pointy back of the hood bounce a bit, not as much as the cape but a tiny bit.
Hehe, it feels silly pointing something like that out but you know some players will think that
Ikr thanks for pointing it out cuz it kinda does
My only problem is it looks more like he's skipping when I do that
Instead of the head bobbing in single frames, maybe have it three up three down? Would give you extra frames to animate the back of the hood and make it less 'shaky'
Animate the eyes to get a bit smaller on the 'impact' frame?
so i was just following the brackeys video when i tried to copy the player and paste it into another lvl, everything was find until i wanted to jump, it did jump but the animation only played for like a frame, and went to idle again
its fine on the scene that i copied from but its not in the other one, heres a vid of the weird bug
what
what is that, will it help
ended up causing unity to crash haha I probably made some serious setup mistakes ( first complicated rig like this), do you or @agile solstice have any tips / resources on more complex rig building like this?
Human rigs can be pretty complex but I haven't had that kind of trouble with them
If you have many identical blades, why not export just one and assemble the thing in Unity? That'd cut the armature complexity to a fraction
Great idea!!
Would be weird to have multiple animations but technically that works!
Multiple animations?
Could have multiple animators with the same animation which are all controlled by one script as needed
As a bonus their motion can be de-synced at will
That sounds pretty fun actually
Hello! I'm not sure if this is the correct thread to ask this in but I am struggling to figure out what constraints I should use on my rig (Inverse Kinematics)
So, what I have now is an armature with the root bone in the middle, and spreading out to 8 other bones which contain the simple humanoid structure. What I want is, based on the rotation of the root bone, I want the humanoids height to change [ex. Crouch down when the root bone is titled towards them etc.. ]. I was able to achieve this in blender using basic IK but I can't seem to achieve this is Unity.
So, what would be the best way to approach this problem? Using multiple rig components with multiple constraints? Joints?
Any help would be appreciated, and sorry if I have posted this in the wrong thread! Thank you.
This is ideally what I want to achieve in Unity: https://www.youtube.com/watch?v=mFVb64OS9jE&ab_channel=Earthpix
Oh you're right! Sorry I was thinking about of that weirdly at first! I'll give that a go and let you know how it looks! Appreciate the help!
Hello can someone help me
You need to actually ask a question first. #854851968446365696
hello guys I'm trying to learn how to animate a 3d model for a project I'm working on but I'm having a little bit of trouble what I think is an the avatar mask component not working. I have some layers in my animation that should be overwriting certain bones, but they are just not animating at all. I have confirmed that any input information is being received and processed by the animator but I'm not sure what to do about this since its unfamiliar territory for me. anyone got any insights on what I could be doing wrong?
I'm an animation noob. I want an animation where my character runs forward, makes an attack animation, then runs back to where they started (classic JRPG style attack). I use a "MeleeAttack" trigger/condition to control the transition into the "Forward Run" state from the Idle state.
I also have code on my player that checks for the same "MeleeAttack" trigger and moves the player towards the target. This works (ie, animator.GetBool("MeleeAttack") returns true); however, the animation itself doesn't trigger for several more seconds - instead of "running forward" the player slides forward, then after several seconds the enter into the Forward Run and then Punch animations. Why isn't the player actually doing the run animation as soon as the trigger evaluates to true?
Additionally, the state never transitions on the Animator Graph - even though the animations actually play
have you selected the item that holds the animator in your hierarchy?
that should let you see the graph in real time if I'm not mistaken.
could exit time be causing the delay?
your idle is quite long and if it needs to finish that before transitioning that could cause some issues
I turned off exit time on the transition; and looping looping on the run animation on - the player instantly goes into the running motion but now the player transform stays in place. If I turn Exit Time back on, it moves again. I determine if I should move the player in an update loop by checking the "MeleeAttack" trigger - does this only evaluate to true the frame it flips, or does it stay true?
I'm pretty sure an animator parameter stays the same until you change it again.
OK, that's what I expect. I wonder why "hasExitTime" is causing animator.GetBool("MeleeAttack") to only evaluate to true once?
but rewinding from all that - how would you set up a simple "run to something, attack it, then run back" animation? Am I on the right track at all?
i personally would not have the movement rely on the parameters of an animator.
how would you work around that, especially if I want to wait until after the attack animation to begin retreating?
I would most likely use events to trigger and stop the movement while letting the animation do its thing, im by no means an expert though.
you could have an event that checks if your player is at the desired location and sets the animation to attack if it is.
then at the end of the attack animation, you can have an event that sets a parameter that triggers retreat animation to true.
this maybe easier if you can get on a call and share your screen
If you have time, yeah. gimme a min?
anyone here know anything about avatar masks?
Hi guys! I tried to import my psb file in unity and this happened. Can anyone help me please?
@stuck elm @agile solstice got something cool working in unity now! Appreciate your help! I did end up making it so it's just one section that repeated in unity.
Looks great 
Very cool looking!
What were you expecting to happen?
Don't start that crap again please -_-
Do you have your ground collision layers set up properly in the new scene?
Are your layers in the right order? The mask won't matter if the layer is being overwritten by another one.
I'm trying to animate a hand for a vr player, meaning I need some fingers to move separately. I currently have 2 layers each with their own mask attached and each mask has the bones for a different set of fingers so they shouldn't clash as far as I can tell. its just that when I have the mask enabled on a layer, the entire animation doesn't play instead of it filtering out the fingers not selected by the mask. I'm not sure about order since neither of them is working.
without the masks the animation plays in its entirety so I'm pretty sure the mask is somehow not interacting with the bones properly or something.
I was hoping to see it as group in each part of the body.
nevermind, i found an easier way without masks, just had to make some more animations
Can someone explain to me why when I use a multi-aim constraint, on a gameobject, it resets the pivot location from where it was set to the center point?
If I had a set of animations that I wanted to randomly play after the player has gone idle for a given time, would it be better to use Triggers, or a float and use a time for the float?
My gut is telling me a trigger, and handle the conditions via script but idk
Probably a script, since you'll want it to be tied into your input system anyway.
We've just upgraded to Unity 2022, and we're noticing the Animator.deltaPosition is no longer returning the same value as in our prior Unity version 2020. Does anyone have any insight into this? We've been searching around, but haven't been able to locate any concrete information
What even is this?
I've not noticed that, but I haven't tested for that specifically. How big a difference are we talking here? And could it be a matter of import differences?
what?
i have no idea what you mean
i did the same thing i did in both scenes and the other one just does not work
You don't need to ping me quite so many times. Especially since you literally didn't even answer my question.
as i said, idk
We have a simple example project that showcases the differences between 2020 & 2022, we're thinking the Animator.deltaPosition isn't using the base animation layer anymore, but not entirely sure. In the Demo scene after import
I can't test that at the moment, but I have briefly used 2022 and didn't see any unexpected behavior with my root motion controller. Do your other layers have root enabled in their layer mask?
can you not help me? 
Well, I don't know what the problem is so no.
hello so i just bough an asset and i want to play with it, one thing for sure is that i know this Animation can use AnnimatorOverrideController...
so i just set up a simple animation where if character moving "moveFWD" (from parameter) it will be change the animation from IdleBattle to RunFWD. using animationOverrideController, but it doesn't works the animation still keep playing from IdleBattle > ShootShotgun > Reloading and so on.
is this related to Transition? should i make a Transition from IdleBattle into RunFWD? i confuse. with this
.
That animator looks like it is designed to show off the asset, not to be used in an actual game.
aaah is that so, thank you so much have a great day! 
What is the workflow to store animations on Items - does each item have it's own instance of an Animation Controller asset and that you set the subjects animation controller to in real time?
Here is a video of the situation we're encountering after our upgrade to Unity 2022. This is the same demo project from our sample package in both versions of Unity
That looks like it might be worth submitting a bug report on
having this weird bug where the slimes get really flat during their jump animation in build mode, but when I look at their jump animation itself it is working fine. any idea?
Most likely explanation is stacking changes to the transform
Transform properties are inherited down the hierarchy, so maybe you have the same animation playing on multiple levels of the slime's GO hierarchy
Is it possible to set the offset of a Multi-Aim-Constraint with script? I cant find anything about it.
so i was just following the brackeys video when i tried to copy the player and paste it into another lvl, everything was find until i wanted to jump, it did jump but the animation only played for like a frame, and went to idle again
its fine on the scene that i copied from but its not in the other one, heres a vid of the weird bug
https://cdn.discordapp.com/attachments/502171313201479681/1078309327842050058/plz_help.mp4
Only you have the means to figure out what's different between the two
I recommend to use prefabs the gameobjects are synced and if they're not, the inspector will tell you
uh there is a new problem actually, now its like that everywhere
idk how or why
it was working a min ago
now even on the first scene its broken
How could we? You're the one following the tutorial
is there any way for the animation to be broken when you move the player into another scene?
Every single variable could be different in the character and the environment if you don't make sure they match exactly
Which is why I recommend prefabs
i did use prefabs too but it didnt work
if you cant help why do you even answer
You keep repeating the question, so I'm trying to help you understand why you aren't getting many answers
The problem is that we have literally no way of knowing how your project is different from the tutorial, or from the scenes are different from each other
We can only randomly guess what the problem might be, but if your only reply to offered solution is "didn't work", it's discouraging since you provide no details so we don't know if you even did it properly
If you followed a tutorial and it worked, and then it suddenly didn't, the only logical way forward is to compare the two, or retrace your steps and do the tutorial again so it works again
i literally downloaded the project file from the brackeys tutorial and tested it there too and that video is from that same project, you can literally test it for yourself
So download it again? You said it did work originally, right?
i said it worked on the first scene but not any other one
it worked on the scene he made but not any other scene that i make
even tho i copied it and used prefab too
nothing worked
Right, so the problem is something in your new scene
i copied every single thing from the first one
i manually checked everything
Maybe don't copy it, instead save the first scene with another name and then just modify the existing gameobjects to a new arrangement
what if i want to use multiple scenes in my game
that would just make it so i can make one scene
I think you misunderstand
If you click File>Save As> and save with a new name, it'll create a new scene with your changes
Like copying everything but no risk of losing references or anything
hmm, well i got what you mean its like duplicating but with a name change with it, but my problem is that it wont even work on the first scene anymore
As I said, download it anew if it has stopped working during your tests
@gaunt sparrow Don't crosspost. You can continue this in #💻┃unity-talk
i didnt really mean to do that they just both answered
That's why crossposting isn't allowed
It ends up wasting multiple people's time when they don't realise the problem is already being addressed
Because you crossposted. In the future, just ask in one place.
none really solved it i am just going to use another script for animation and player movement lol
sure lad
Can someone please help me? I'm having a problem and if we could call so I can screenshare because it's a bit much to explain in text :S
player movement animation and shooting animation at a same time
any one ?
i use 2 layer in animator window and layer mask (legs and ground) are unchecked but unfortunately the shooting animation call in update function so the walking animation not be set
That's not really the MO here, so you should try to describe the issue
Thanks but I managed to fix it. Someone helped me
why doesn't unity let me edit root t.z in the animation window?
I can't input anything there, even when I add keyframes
Why when I import animation from blender into unity, the animation resets the position of the gameObject?
Like If I disable the animator, the enemy moves towards player normally, but if I enable it, the enemy stays in one same spot but the walking animation works
Animations override component properties, including position in Transform component which are relative to parent gameobject
If your animated gameobject has no parent, the position override is relative to the scene itself
so then I need a parent
Yes
and I would put the animator on the parent?
No, the child
The parent would then have the components for actually moving the character
oooh okay
so if I had a enemyBehavior script, I would put it on the parent not the child, and put the animator on the child
got it
What about box colliders or rigidbodies
would it be fine either way or would I need to put it on parent
I put the colliders on the parent of the game object
Still can't figure this out. It makes sense if something else is messing with the transformation besides the animations I have set but I dont know where. All I have is: parent object with a wanderer script, rigidbody, and collider; then the child with the animator.
Rigidbody in the main parent gameobject
Colliders can be anywhere lower in the hierarchy, such as on limb bones
ah so I shouldnt have my colliders on the parent
No, that's fine too
I FIGURED THIS OUT it's that I needed to turn "loop pose" off on the jump animation. lol. lmao, even
Having an issue whereby my animation controllers don't display in the animator window?
I kind of suspect this is because of line 33 here? Restarting Unity actually clears the issue (the animation sets actually show up again) but rerunning the code reintroduces the issue [Fixed]
Hey everyone! Im having some issues while creating bones on my sprite, is there a reason that it gets messed up when I create the bones? It looks fine in the skinning editor, is there anything Im missing? I attached a gif to show the problem, thanks to anyone helping ^^
why does my animation snap right to a blend tree(no transition) even if it has transition time?
these are the settings
why arent my positions showing up from my blender project?
it just shows one clip that is scene
but i have like four
Clips can get dropped if your Blender has a preview fps below 50 when exporting, or if "force start/end keying" is enabled or other export settings are amiss
Hey! what's up? I'm a 3D sculptor and animator focused on videogames. Any experience artist in this area that could give me some tips? I make High poly>low poly characters and wanted to know some things
Don't crosspost
Be more specific
Well, I see error messages on your screen; a root not set and non normalized bone weights. The latter is likely what's causing the trouble.
I just checked and all of them are normalized :/
Or is there something Im missing?
okay, so how do i fix this? is it as simple as changing my project fps to 50? that seems too easy.
what other export settings need changing
i just have all the default settings rn except it is on cycles rendering engine
also, the animations are only a single frame each and i was hoping to just use interpolation in unity to get the actual animation so controllers that have analog triggers can control how much the hand closes and opens.
Sorry to ping you again, but Ive been looking for 2+ hours and can't find anything related to my error online for some reasons
How did you check that they were normalized?
And you're sure all vertices have weights on them?
As a side note, you'll probably get better deformation AND better weighting if you change your mesh a bit, probably adding a vertex at each joint at least
I checked for each bone if the normalize box is checked
Isn't that how i do it ? I searched online and couldn't see anything about normalizing bones
Ill try that thanks ^^
No. That checkbox only affects the tool behavior. It doesn't affect the actual weights.
Oh! How do I check that then?
Do i have to do it in the skinning editor?
why cant i move these
i cant even delete the arrow
everytime i make a transition i cant move the boxes anymore
Try restarting the editor
so its a bug
i tried and it worked but after i make another transition same thing
do anyone has this issue using the latest updates
because im using old update
Of which editor version?
it stuck
i have a script that turns on the menu by pressing esc key, and when i try to press the button it should play an animation of it going down to the top interface where there is a camera screen
it works however when i turn the menu gameobject on
i might need to redo the way i bring up the menu
Hello everyone, I'm having some trouble with applying the wave modifier in Blender and importing the resulting animation into Unity. I've tried baking the animation, but each time I apply the wave modifier, I still lose the animation. I then tried importing the animation into Unity, but it's not working as expected. Has anyone else had this issue before, and do you have any suggestions for how to solve it? Thank you in advance for your help.
If my memory serves, 2020.3.31 specifically had severe Animator UI bugs
LOL
Im so doggu doggu
SO BASSICLY THIS ISSUE IM HAVING Is THE ENGINE BUG
Probably
I don't know of many features or user errors that commonly jam entire parts of the user interface, so that's what I suspect first
Not much point being on an old LTS behind multiple rounds of patches anyhow
If you update the project's editor to a patched 2020.3. with a back-up, that's unlikely to risk your schedule or workflow
If something breaks, you can just keep working on the backup
You don't really have to "trust" it if you have a backup
Nor do you need experience to download an editor
Patch version updates are unlikely to break anything, but it's a process that can be messed up so playing it safe as possible can be a good choice
Like, if you accidentally install next year's version instead
Or delete the project instead of backing it up
Those are the big risks
Mesh modifier animation isn't exported unless converted to VAT or point cache
I will look into it and try it, thank you so much, I am still a beginner and still discovering a lot of stuff.
Your best bet would probably be to do that animation inside unity unless it is particularly complex or specific.
Can anyone please help with this? I've been stuck with this for ages. I'm following a tutorial on a full body character (with animations), though my animations won't work. https://www.youtube.com/watch?v=xWHsS7ju3m8&list=WL&index=73
I'm 99% sure my code is the same, though the character isnt the same. I think it has to do with the rigging, but I'm not sure how to change it and make it work. I used the T-Pose animation as avatar for all the animations, and applied all the other options as shown in the video. My video shows my character when pressing WASD
All the animations come from mixamo, and I'm using the new input system to make this. https://pastebin.com/nicY8kF3 https://pastebin.com/UnDsimtj
Hey does anyone know if theres a way to Have 1 state in an animator layer that doesnt inherit the avatar mask of the layer?
Anyone have experience with https://assetstore.unity.com/packages/3d/animations/basic-motions-157744 ? I've recently picked it up but something is wrong during all animations. When I'm moving at the positive Z axis everything works correctly but after I turn the character gets faster and moves in the wrong direction. This problem doesn't occur with mixamo animations. Trying to figure out what's causing this. I have included a video for you to better understand the problem. Notice after I turn 90 degrees right, when moving the character slides to left with faster speed. With 180 degrees, it moves even faster.
your animator does not have an avatar assigned
Is that an issue?
I tried putting an avatar on but it didnt change anything afaik
What avatar did u assign to it?
The T-Pose avatar, which is the avatar I used for all the animations
The animations are humanoid, and I selected 'custom avatar' (or whatever it's called) and used the T-pose avatar
I'm like 90% positive it doesn't work because of the avatar but not really sure why it didn't work when you assign an avatar though
I applied the avatar, but now I can actually walk left right back etc. First I could only walk forward with WASD
but still no animations
But I do see red gizmos that show an animation I think
Yeah Im quite sure they show the animation
I think it has to do with how the body is setup @teal frigate
I got the body from fuse
But it isnt connected to the skeleton whatsoever
but the skeleton is from mixamo, it should be rigged already
It is, but I dont think the "skin" (everything you see) is connected to the skeleton
So the "skin" isnt moving
but the skeleton is
oh I get what u mean
I think I need to put the skin from fuse to mixamo, then export it from mixamo with skin
yeah that might be the issue but I don't know what to do in this situation
I tried that, but the option 'export to mixamo' that fuse gives, doesnt work for me
Alright, well thanks for your help anyways 🙂
I got it working! It was indeed an issue with the skin
Nice
Is it possible to REMAP? or change the heiarchy of an imported animation from blender? For example, if i have a model imported as Model.fbx It has an animator on it from Unity (from the import) If i make a Empty Game Object and I nest my model in it, and i want the animator on the Empty Game Object, not my imported model, is there a way to get those animations to shift a heiarchy? Would I copy those animations and make new ones based on the copies? I've always been stuck on this concept and wasn't sure how to gain access to blender animations but be able to have the animator much higher up so that I can add other animations or other parts of an animation using Unity game objects that aren't previousy in my blender animations
So my new Prefab would be
WrapperGameObject <--- Would like Animator here, but the animations still work on Model.fbx (imported from blender)
--- Another (GameObject)
--- --- Model.fbx (imported from blender) <--- Animator
I found this... http://enemyhideout.com/2016/05/howto-remapping-the-animation-hierarchy-in-unity/ is this the way?
that does work, but i feel like I am editing a quake .ini back in the 90's any suggestions on a better workflow, thanks!
Yeah. Set up the models properly for unity before importing it 😛
Or, if all your models have the same remapping, you can make an asset processer to do it automatically on import
some of the things im not sure about is.. 1) am i making fake heiarchy in blender, based on what I want in unity? 2) sometimes I don't know the heiarchy yet until later on, so i can't exactly pre-plan some things, like I am making a door lock. i model it in blender, but in Unity its multiple layers of heiarchy with other game objects, scripts to handle lights, particle system etc.. and sometiomes I want to animate that stuff, so I want to mix and match some of the blender stuff with some custom unity stuff..
I am not a blender user myself but I know that there are preferred ways to set up the export to minimize the differences
Hey guys, I am using animations for a project that I did not prepare myself and currently find myself stuck. I am using a timeline and plugging in the animations in sequence. However. there is an idle animation that I need to work at its current location and not move to its origin whenever it is triggered in the timeline. Any tips?
Does anyone know a tutorial for me to implement hand drawn animation(for running) into my project
2d
Does anyone know how i can set this variable with a script? Because i dont know why but every Animation needs a different offset to fit
Typically, if you are going in order you'll want to match to previous
For some odd reason Match Offsets to Next or Previous is not working at all. There is no change in the idle jumping back to root
I have been told my game could use some more "bounce". My project is already using DOTween, but someone recommended to me that LeanTween would be good for this and showed me a decent looking tutorial
1)is it bad form to import both DOTween and LeanTween into a project when they really do the same thing
2) does anyone have thoughts as to which would be better (or potentially a 3rd option) for adding some 'bounce' to a game?
If you wanna see it (this version only works in Full HD 1920 * 1080)
https://galahadgaming.com/Games/Builds/
Afaik DOTween is the fastest of them and should have all the features needed
Piskel
Grafx2
Gimp
Grafx2 is actually the best one
but you can use whatever you want
it looks wierd somehow
guys how to fix this ?
That is a warning, not an error- so if it still looks okay you can ignore it. If it affects your animation too much, either remove translation keyframes from your animation before importing, or use generic animation instead of humanoid.
Actualy what i did i go to Avatar configure and in muscle settings tick the Translation DOF thats dismis the error ...... but to be honest i dont know what it actually did
Basically, humanoid animation only stores muscle positions, not actual rotation/translation/scale
ah okay got it 🙂 thanks 🙂 i would use generic but it make weird moves when its used in animation layers and with using mask so i been forced to use humanoid
its somehow work better with layers
I made the 1st character for my 2d Idle game, how does it look
Animation speeds way faster than it should be but I configure it in unity
Conceptual question. If we want to prevent foot sliding in npc. Do we match their agent speed with the animation or do we use root motion from the animation to drive the agent?
Match agent speed with animation or animation speed with agent speed
Or use root motion
Both work but root motion workflow is specifically intended to make it straightforward
Hello! Anyone can help me how to fix this one please?
Can you be more specific?
As Spazi said, either works. If you are retargeting animation from a character with very different proportions, you might also need to enable foot IK to avoid that last bit of slippage.
Not sure if there is a proper location where I can post recruitment but I'm currently working on a 2D pixel game jam, and is in need of 2D artist and people who can implement their animations in unity.
DMs are open and I can share details there.
The unity forum has a recruitment place.
i've made an animation, how do i make it so an object loops it constantly?
Hello, I have these sprites, I would like to know how to make the sprites cycle repeatedly
Make sure that the animation is set to loop in its inspector and then just add it as a state to the object's animator.
I was trying to move the hand but one of the layer didn’t move. It was one of the shading.
if someone could maybe help me by sending me a video
i feel like this has been asked before but I don't know what to search, is there a way in the editor to use an animation property for the global position of a transform instead of the local position? So if an animation moves a transform up, then rotating the parent transform wont affect the child transform moving up
normally i would just separate the transform but some animations on that transform i want to rotate, while other animations i just want bobbing up and down regardless of the rotation
Make a script that moves global position and animate the script from your animator instead of animating the transform directly
ahh nice trick, thanks
Is this the phase 2 of t-posing? I was just hoping to move the model into a basic starting pose but it balls up like this automatically
Found what I needed to find, I need to move the animator and not the object
I'm not sure if I'm just dumb or blind but I can't find a way to not make my animation play automatically when the game starts?
?
Check the animator controller window
I'm not sure where that is, I thought that was all of the animation-related windows
"Read the unity docs"
hey can you read all of the united states legal codes and tell me where it says I can't steal a car
Just read the section on animation
The Animator will always start playing the clip of the first state
You'll need an entry state with no motion
I want this:
in here:
Otherwise Attack2 can't be found by Animator.Play("Attack2")
Anyone know how?
Maybe this is related, but when I add a state to my Animator, nothing shows up
Those clips are whatever are in your animator on that object.
(I play all animations using Animator.Play, so I haven't paid any attention to the Animator states)
So how do you associate Attack2 with the animator?
Drag it into your animator
Hm, so that did add it:
But now I get this error
on start
And also, still, nothing is visible in the Animator view
don't know if it's supposed to be that way
Yeah now different animations are breaking
wtf...
I hate the animator
hey i got an animations that make my character run and when it plays another clip it goes goes back to the where the character started running from how can i make it so it play the other animation where he stopped running
hey question, this is another layer thath "addative" that i will use when trigger attack annimations
but since its addative it goes to the idlecombat looping all the time
how do i workaround that ? or is there a "null" state or something
This is amazing.
You need to select a gameobject with the Animator for the associated animation states to show up in there
Also I recommend following instructions https://youtu.be/sgHicuJAu3g
but how do i get it to update the position after the animation is done?
Oh oh, sorry, I thought you had created the animation
But the reason might be because of "Root Motion"
Look into Root Motion and that might help
its no difference if i check root motion in animator
Ah, unsure myself then
by what i know i think the motion is in the animation
unfortunately I don't think I get what you mean
this is what it looks like rn and it plays on start
Of course
You want it to transition from an entry state with no motion to another state with motion
how do I give the entry state "no motion"
it has no options
how do you know if a state has "motion"
Make a new animation clip in the Animation window for the gameobject with the Animator
Since you don't want it to do anything you won't need to keyframe anything
ooooohhhh
Then it should appear as another state in that Animator, which you can right click and set as default state
You'll then need a transition between them and a condition to trigger the transition
Anyone have advice on how to go about this movement with Unit's Animation Rig? I need to have his hands and feet working on IK, which I've figured out, but I'm not sure what to use to manipulate the torso with this same effect.
Enable root motion, and make sure that the correct gameobject in the hierarchy is set as the root node.
If the IK is correctly set up, then moving the hips should have that effect.
You can have a state with no clip
are layers used to combine animations do they serve any other purpose than this how often are they used in 2d games ?
Turn off looping on the actual animation asset.
in the animation or animator ?
ping me
I said animation
I cant seem find the turn off button
Where did you look?
Select your animation in your project file list, and in the inspector, turn off loop.
thanks
is the concept of layers valid in 2d games ?
i dont see anything related to it in the animation
How can I get these control points on my screen?
Bone Renderer component of the Animation Rigging package
Where exactly?
You need to fill the Transforms field with all the bones from the hierarchy
I did that
Assuming you did that correctly and you have gizmo visibility on, then it should be good to go
If it doesn't show up immediately you may need to select a different object or switch windows or something
I think it was a bit bumpy like that in recent versions
Why does rigidbody conflict with animation? I mean player starts to float
They both may try to override Transform component's position and rotation
For this reason you'll normally want to place the animated mesh renderer(s) as the rigidbody gameobject's child gameobjects, or always make sure the rigidbody is "kinematic" when it's being controlled by animation
It is interesting by the way
While searching help to make player movement you wont find any thing how to do it with animations hah
Look up 'root motion.'
Yes.
I use it to control my character's body, arms, and face separately.
https://gyazo.com/cfd2950b9afc4584e8096d8f97eac7d5.mp4 my little knight is bouncing around fine in the scene view, but messed up in the game view. What gives? The kings are just fine, on the other hand.
https://gyazo.com/42bcc74b18141c56fec70c11e833caf6.mp4 kings example
err... maybe the kings are a little off, too.
Ah, i think this has to do with the pivot point of my sprites, now that i look at it closer.
What are q and t properties, like left hand q? I found the third different one was range of motion
hi everyone
using UnityEngine;
public class Animplayer : MonoBehaviour
{
public Animator Anmtr;
void Update()
{
if (Input.GetMouseButtonDown(0))
{
Debug.Log("Recoil Intiated");
Anmtr.Play("Animation");
}
}
}
this script when i play my game just start playing the animation by it self
no input needed
it just loop's and loop's
Thats expected
You have to open the animator controller and change the default transition
Hi, i'm trying to make procedural animations, using Animation Rigging i can do very basic linear Vector3 interpolation between poses. The Leg hint and leg foot position seem to be ok-ish doing that. But the foot rotation is all over the place. I guess i should apply some constraint to them but haven't figured it out yet. Anyone care to give some tips?
Note: i used EulerAngle to interpolate, instead of Quaternion.
how does one check layers in 2d games animation in unity ?
So,does someone have insight or resources on creating animations in blender and having the ability to mix them? Like, if I have a walking animations, and a hand waving animation, I could get them to both play at the same time in Unity
Guys hello
how do I fix this error, I've combed the entire internet, I want to move the mesh to the stage
?
?
I imagine you wanna try #archived-code-general
That sounds like it will explain a lot of your trouble.
For Unity2D, I have a state machine set up to change the appearance of a panel from red to blue depending on player ownership of that panel. However, the panel doesn't seem to change color immediately. I have my transitions set up so that the box "has exit time" is unchecked for every transition. Is there any other common mistake I could be making that is causing the animations to not interrupt each other?
Nvm, I figured it out. There's a fixed duration for transitions too, so even though its interrupting, it still takes a set amount of time to complete the transition.
Once I set those to 0, the problem went away.
hi im trying to make a shader for 2d grass and for some reason some art will be affected correctly and some art will be affected diffrently can someone help me understand what the issue is? (the pixel art grass is affected correctly and the Forest Sprite Pack art is just being moved)
Without knowing how your shader works or any details of your meshes it is hard to guess beyond 'gremlins.'
this is the shader
and these are the sprites
Your shader is based on uvs, and the uvs of the sprite in the large spritesheet are very different from a single image.
I moved my animation from the logic to the visual gameobject but now my animation don't play
And on animator my character dessapear ? why
@ornate bridge In my experience an animation can make a character disappear only when the animation scale is way off
If you watch the animator play through the scene view, does the character appear big, small or is it just gone entirely
No he dessapear
on my player i have it
but my player have animator on logic and not the visual GO.
So look like i can't put animator on visual GO.
What does "visual" GO mean in this context
visual is root
logic is main where i have al lscript
you have to place animator component on a special GO?
Not "special", but the animation clip's animated property paths will be relative to the gameobject the Animator is on
You'll want to have the Animation window, Animator window and Scene window visible at the same time for previewing animations on the scene character
Otherwise you'll be flying blind
+the Hierarchy if you're also changing the location of the Animator
The Animation window will have warnings if the property paths do not match, and the Animator will show active states and transitions during play mode and when previewing animations
Where can I learn how to get animations from Blender to work in Unity? Everything I find seems focused on skeletal animations and I just have a few very simple animations that don't have skeletons
Hey guys, Im pretty new to Unity2D, and im working on setting up animations for this asset character. I can get the idle animation to play using the animator, but I cant get the walk animation transition to go from idle to walk once it reaches a certain speed. Any idea what I can do?
No other animation besides skeletal can be exported, as far as I know
Which kinda sucks
How I export non-skeletal animations is first convert them to skeletal by first making an armature with bones that represent the motion, then connect the parts to bones using "Child Of" constraints, so that skinned mesh isn't required
Constraints can't be exported, but as long as the object and skeleton positions match, you can parent each object to their bone in Unity
thank you! i will change it.
do you know a way to make the effect without using uv's
Good day!
I am trying to work an animation into my project:
I have the character sprite doing its sprite things. Movement, jumps, and whatnot.
All these are animated like I want them to.
Now, I have two more pieces to add, a jumping FX and a touching ground FX: When the character jumps or touches the ground, I want to add a small cloud of dust lifting from the ground or pushing away from the characters' feet accordingly.
How can I add the separate FX to the animation so that both play at the same time upon jump and touching ground?
You can use particle system and events. That's one possible way.
But if you want to play them at the same time ONLY using Animation, then you can create a new Animation Layer inside the Animator. Then set it's weight to 1. But that would imply that you can not use the Legacy Animation component.
Hm, thank you, I'll try and work this out.
You'll need some way of converting postion into a ramp the shader can use- world position, object position, transformed uvs, a controll texture, vertex colors... there's no single 'right answer' but the easiest is probably to write a script that reads the rect information from your sprite and applies it as an offset to yout shader.
does anyone know how I would go about making a child object's animation change without changing any of the other animations attached to that object?
You can use a layer mask to only affect that object, or you could give the child its own animator
i think i understand the issue. i need the local sprite uvs does someone know how to do that?
you would have to do some math with the texel size property
i did it! i used this shader and a script witch on collision adds the velocity of the object to the "offset" vector in the shader this is the final shader graph:
So I’m trying to import this guy to VRChat/Bonelab. The mangled Unity armature and how it’s supposed to look in Blender is shown
Is there a way to fix it in Unity?
I'm having a problem with Humanoid rigs. Whenever I change to that my animation seems to get a broken hip. In Maya the animation is fine and baked it into the rig. But in Unity it seems to be broken the moment it goes Humanoid. I checked the configuration of the avatar, hips are assigned.
But I also have a pelvis bone underneat the hip which can actually rotate the pelvis + legs, while the hip bone is basically controlling the entire body and is only child of Rootbone.
I'm afraid that any animation the pelvis has won't get transferred on the hip bone. But even changing the Hip in the config to Pelvis, won't change a thing.
HELP???
I'm having an issue with my 2d animation- the animation itself is bouncy and nice, but when i actually attach them to a player, it suddenly becomes stiff/tied to something else. how do i get it to keep its bouncy?
it feels like unity is anchoring the sprite and the animation transformations to something other than what it is set to
im not sure how to fix this
like it's disregarding my transforms and going to just the sprite order from my slice
You need to give the character a parent object that moves around instead of the character
What the animator does is edit the x y z values with the values that are in the key frames
Why is is when I use my reload animation it works, but when I try to reload again it dosent work
You'd have to look at your Animator states during play mode to get information about what's happening
yeah that fixed it thanks
How do I make it so my mag only drops once my hand has reached it
Animate it to do that? I feel like we're missing some crucial detail
Make it do it faster?
Perhaps you mean to control the mag with physics? I'm not sure
See the mag is already moving when the animation beings
begins*
Then the hand catches up with it
So the keyframe for its motion is too early, or it doesn't have a keyframe for the starting position
or both
I would probably use a parent constraint to animate switching of the mag's parent from the gun to the hand when grabbed
But you'll want to have a firm grasp of how keyframes work in the first place before attempting that
Anyone know why my weapon sway dosent work when I have an animation component on my gun
Animator (and Animation, though you shouldn't be using that) override transform values (and other properties), so they conflict with code that also alter transform values
Not sure this is the place i should ask for this, but is there any way to make an animated material?
By looking it up online, it only tells me how to animate models
Like, i have 32 different animation frames for water, how can i make it so that it cycles through the 32 frames
Hey there!
I am curious if there is any efficient worklow available to have dynamic face animations for audio files. I think about something quite flexible that adapts to any audio speech I associate it with. Can anyone drop me some keywords for Unity systems that can make this possible?
Your character is not actually humanoid in the way unity means, so there won't be a 1:1 translation between the two formats.
You'd probably need to do some alterations to the rig outside of unity to make it compatible, or maybe combine the animation of the extra bones ising an asset preprocesser.
Depending on type of object, your rendering path and material there are lots of ways. For instance, a sprite can be animated directly from the animator while a mesh can be animated by script or inside the shader.
its a plane
it doesnt really matter to me how i can do it as long as it works lol
Sprite Animations are animation clips that are created for 2D assets. There are various ways to create Sprite Animations. One way is to create them from a Sprite Sheet, a collection of Sprites arranged in a grid. The Sprites are then compiled into an Animation Clip that will play each Sprite in order to create the animation, much like a flipbook...
im trying to do it on a 3d object
😅
You just said it was a plane. Sprites are planes(well, quads usually)
Hi everyone....
Is there today a solution to bake animations from IK rigged humanoids which are made with the Animation Rigging Package? For our project we need to keep the utilization at the lowest level.
Is there a guide on how to animate interactions with other objects? Like If I want my player, interacting with a vending machine to have an animation. Or if I want them to sit on a chair, but I have hundreds of the same chair I want to have the ability to sit on?
I don't know of tutorials but there's two parts to it generally
- To make the character interact with the object you'd run checks to verify that they're in the correct relative position to stat the animation, and/or move them to the correct position
For example to sit on a stool the character could initiate the animation from any direction, but would have to be at a certain distance to it
- To make the objects respond to the interaction, you'd either trigger a corresponding animation, or script the character to influence the object directly, or let the character take control of the object's IK targets or constraints
Creativity is pretty much the limit how to achieve and combine those
Many games for example let furniture prefabs define specific animation start points with transforms and when interacting with the furniture while close enough to the start point, the char would move to it and start the animation
See the last solution is what I was thinking about doing but wasn't too sure if there was a better way
Better is subjective
Except I would just keep the animations as part of the character and not the furniture. But keep the transforms and information on where the animation can start from on each object.
The real question is how do I accomplish the start and end point
points
Emptys in blender? Emptry's in Unity?
If the objects need to move, they'd have their own animations that'd sync with the character interaction
Those are the same thing really
Sure if you include empties in export
If I have like, a control panel with levers, and I know the character will always pull the levers in the same order, it's enough to have one clip for both and start them at the same time
If the order of the lever pulls can vary per character, I'd have a separate clip for each pull on the control panel and have the character's animation trigger the corresponding pull animations on the panel, using animation events or interfaces or whatever
is there a way to make sure animations are synced?
Or is that just some code I'm going to have to do on my end
Like a singleton animation handler or somthing
If characters can pull the levers at different orders and at entirely different speeds, I'd have to set the lever animations so that they can read a float from the character animator to know how much the lever needs to be pulled at any given time
It should be enough to just start them at the same time
A singleton would be unnecessary
Just let the character send info to the object when they meet
The same way a character shooting a laser at an object would send damage info
gotcha
In fact if a character is hitting a lot of buttons on a control panel, I'd perhaps instead do raycasts from the hands that genericly presses any button it hits, than try to send info about each individual press
atp why not just attach coliders to the hands for the duration the player its in its vicinity?
and make the buttons animated on an event
That's also a good idea! Creativity indeed is the limit
I'm currently trying to implement root motion animations on a character using NavMesh. I just can't get it to work and I'm at my wit's end. Can somebody help me, please?
This is my character.
The character on the left is complete with a NavMeshAgent and a script. The one next to him is just the basic model with an animation controller and root motion applied.
The difference is noticeable. The colorless one slides around while the textured one doesn't.
If I remove the script of the Colorless guy it works correctly, so definitely something is at fault there.
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.AI;
using UnityEngine.Experimental.AI;
public class CharacterWanderBehaviour : MonoBehaviour
{
[SerializeField]
private NavMeshAgent _navMeshAgent;
[SerializeField]
private float _maxWalkDistance = 10f;
[SerializeField]
private float _minWaitTime = 5f;
[SerializeField]
private float _maxWaitTime = 20f;
public bool IsWaiting;
private Animator _animator;
private Vector3 _currentDestination;
private Vector3 _worldDeltaPosition = Vector3.zero;
private Vector3 position = Vector3.zero;
private Transform _target;
void Start()
{
_animator = GetComponent<Animator>();
_navMeshAgent.destination = Vector3.positiveInfinity;
_navMeshAgent.isStopped = true;
_navMeshAgent.updatePosition = false;
}
private void Update()
{
if (_navMeshAgent.remainingDistance <= _navMeshAgent.stoppingDistance)
{
if (IsWaiting == false)
{
//StartCoroutine(WaitBeforeWandering());
}
}
_worldDeltaPosition = _navMeshAgent.nextPosition - transform.position;
if(_worldDeltaPosition.magnitude > _navMeshAgent.radius)
{
_navMeshAgent.nextPosition = transform.position + 0.9f * _worldDeltaPosition;
}
}
private void OnAnimatorMove()
{
position = _animator.rootPosition;
position.y = _navMeshAgent.nextPosition.y;
transform.position = position;
}
//... continue in another message
}
{
//continuation
private Vector3 GetRandomPositionOnNavmesh()
{
Vector3 direction = Random.insideUnitSphere * _maxWalkDistance;
direction += transform.position;
NavMeshHit hit;
NavMesh.SamplePosition(direction, out hit, Random.Range(0f, _maxWalkDistance), 1);
return hit.position;
}
private IEnumerator WaitBeforeWandering()
{
IsWaiting = true;
_animator.SetBool("IsWaiting", true);
_animator.SetBool("IsWalking", false);
float passedTime = 0f;
float timeToWait = Random.Range(_minWaitTime, _maxWaitTime);
while (passedTime < timeToWait)
{
yield return null;
passedTime += Time.deltaTime;
}
GoToARandomPosition();
}
private void GoToARandomPosition()
{
_navMeshAgent.destination = GetRandomPositionOnNavmesh();
_navMeshAgent.isStopped = false;
IsWaiting = false;
_animator.SetBool("IsWaiting", false);
_animator.SetBool("IsWalking", true);
}
}
Can someone please take a look? I've been looking at this for four five hours now, but not because it's beautiful.
Is it possible to play a upper and lower body animation at the same time?
Or the same animation twice "overlayed" at different speeds?
Hey guys. I've been using root motion animations and have had an issue in the past with applying gravity during animations. Briefly, when the character walked on uneven terrain, gravity was not applied correctly.
At the time, I searched the forums and found the solution to my problem: Just add a curve in the animation clips called "GravityWeight" with value 1.
Today the question came to me: Is there somewhere in the Unity documentation all the curves that I can use in humanoid animations that are already handled by the engine itself?
This question came to me because I would like to increase my character's range of motion based on some parameter.
Yes.
Kinda, though it might have issues.
For the former, you can use a layer mask. For the latter you can use an additive layer.
Not as far as I know. If you find one please let us know!
Hello, pretty basic question I assume...
I have a bunch of character sprite sheets, all sheets are the same size and follow the same pattern for the character animations. Is it possible to create ONE single set of animations in Unity (like walking in all 4 directions, idle, attacking...), and then load whatever sprite sheet image you need for each character? Or do I have to create all animations separately for each sprite sheet / character in my game?
It is very possible but not nearly as easy as it should be.
Since unity's handling of sprites is insane under the hood.
Nvm... Just found the holy grail to do this ! It's a small script that comes in a plugin called "Animancer Lite", just place the texture sheet for each different animated character in the scene and it will display the same animation but changes the sprites to the ones in the sheet provided for each character. This just saved me a ton of time. Also thanks for answering!
Whats a good intro cutscene length? Smaller sized game. Were 1:09 currently but 30 seconds feels more natural. Any advice here?
How to make sure that when you click the button again, the OpenScroll animation is not called and the button went out of the selection state?
Don't use an Anystate for that but only have it from states that you should be able to open it from
hi does anyone know how I could turn rotating an object into an animation?
Five seconds tops, skippable
By keyframing the transform's rotation
How does Unity internally convert a regular animation to a humanoid one through an Avatar definition?
Or more specifically: What are some resources (or relevant classes in the UnityCSReference github repository of Unity-Technologies) on how unity handles the creation of humanoid animation keyframes under the hood/in code, given a regular animation clip and the humanoid avatar definition? And how does it apply the humanoid animation properties (e.g. "Chest Front-Back", "Left Forearm Stretch"), back to the actual transforms of a character?
For the second way, animation to actual transform positions, a simple approach is to just sample/play the humanoid animation on a cloned object of the original character and then retrieve the transform values. I don't really know about the other way around though.
Not sure if this goes here or into the coding channels, but I thought it might be more fitting here
Maybe I could look into tools that solve something similar? I've seen "Baker" from RootMotion and more relevant perhaps "Animation Converter" from SoxwareInteractive. But if someone has other suggestions, I'd be happy to hear about them
Skippable, yes.
5 seconds? Based on what?
Opinion
The question is entirely subjective
The answer doesn't only depend who you're asking and their general preference of cutscenes, but also the content of the cutscene
How dragged out or packed in it might feel depends on how much story you're trying to tell relative to time
I prefer games that are capable of telling their story without resorting to taking control away from the player
True. Thats a fair opinion. The intro cutscene is to give the player enough understanding of why the player is that character, how they got there, and their purpose. We crushed the scene down to about 45 seconds, with a goal of about 30 in the end.
It also depends on the genre and platform
People who play Flappy Bird vs those who play Final Fantasy games have very different expectations
The entire game is basically katamari with abilities.
Katamari intro scene explains that you're building the moon, our game has you come from the moon and crashing, then your "alternate characters" abilities* take off in different directions and you track them down as part of the gameplay, to gain those abilities. So a 30 second cutscene makes sense. Any longer or shorter might as well not have it.
You'll probably want to compare to how similar games are doing it, and then test with your target playerbase
Hi! im in desperate need for help here
I've run into some weird mesh deformations on the animations of my player. I want it to be able to walk and shoot, so I set up a base layer for the locomotion animations and an attack layer that overrides the upper body of the character when any of the two attack abilities are activated. It was working fine on other characters but with these one I seem to be getting some weird head deformations while it perfomes both animations, any idea what could be happening?
Does that model have any additional bones that aren't listed in the mask?
I just check the bones in the mask and there is none missing
Ok, this might sound silly but what happens if you disable the animator entirely and manipulate the bones in question manually?
(This is just to eliminate bad weights or the like in the model.)
And it definitely only happens when both animations play?
Is it a humanoid rig or a generic one?
its a generic one
Mmm no I notice it does it as well when its just attacking and not moving but its more subtle so I must have missed it
but I think you're right, its something in the model since I just tried moving the head and its not working as it should.
weird thing its working fine in blender...maybe its an export error?
Ok, first thing to check is whether increasing the max bone influences setting fixes it.
quick question guys, i have a parameter isRunning and a blend tree with my idle, walk and run animation, can i still set the blend animation of run to activate only when holding shift for example?
nevermind i found the issue.. i was writing IsRunning instead of isRunning lol.
Hello does anyone know how i can use multiple keys in a transform animation?
Can you be more specific?
Like right now my object goes from its regular position to the end position i put in my animation, but i want to make it go from the start position to the end position, and then go behind the start position and back to the start position
does anyone know how i can get rid of the jittering
i think it has something to do with my code but i cant figure it out
private void Movement()
{
var horizontalInput = Input.GetAxis("Horizontal");
var verticalInput = Input.GetAxis("Vertical");
bool isRunning = Input.GetKey(KeyCode.LeftShift);
if (Mathf.Abs(horizontalInput) > _threshold || Mathf.Abs(verticalInput) > _threshold)
{
var camera = Camera.main;
var forward = camera.transform.forward;
var right = camera.transform.right;
forward.y = 0f;
right.y = 0f;
forward.Normalize();
right.Normalize();
var desiredMoveDirection = forward * verticalInput + right * horizontalInput;
transform.rotation = Quaternion.Slerp(transform.rotation, Quaternion.LookRotation(desiredMoveDirection), 0.2f);
// Set the movement speed based on whether running is active or not
var speed = isRunning ? MoveSpeed * RunMultiplier : MoveSpeed * 0.5f;
transform.Translate(desiredMoveDirection * speed * Time.deltaTime, Space.World);
// Set the animator parameters based on the movement speed and whether running is active
_animator.SetFloat("MoveSpeed", speed);
if (isRunning)
{
_animator.SetFloat("AnimSpeed", 1f, 0.2f, Time.deltaTime);
}
else if (speed > 0f)
{
_animator.SetFloat("AnimSpeed", 0.5f, 0.2f, Time.deltaTime);
}
else
{
_animator.SetFloat("AnimSpeed", 0f, 0.2f, Time.deltaTime);
}
// Set the running parameter based on whether running is active
_animator.SetBool("isRunning", isRunning);
}
else
{
_animator.SetFloat("MoveSpeed", 0f);
_animator.SetFloat("AnimSpeed", 0f, 0.2f, Time.deltaTime);
_animator.SetBool("isRunning", false);
}
}
Is there supposed to be actual animation going on, or just poses?
Anyone know why my DAZ JCM shape keys are kinda off in Unity3d?
I would show a pic but it does contain some nudity.
Has anyone here work with daz characters to unity? If have a issue that I cannot fully explain here. I would like to DM you, if you could help?
how's that?
It looks like the animations aren't synced up very well
Blends should always be between synced animations
I imported a animation from mixamo and put it on my character but when press play my character that has the animation changes positions, does anyone know why this is?
I have 0 code on the character that is changing positions
When I check the apply root motion box the position is fixed but I do not want to use root motion is there any other way to fix this?
Bake the root motion into the pose for each animation.
lol how do i bake
do i need to convert to humanoid in order to bake?
Anyone ever handle duel quaternion skinning in unity?
Or how to keep the preserve volume on your rig when you export to unity?
It is kinda janky since it is handled largely in shader.
But it works
I saw this, I thinking about using it. The only problem I see is that I have a custom skin shader that I created with shader graph. This asset requires me to use there shader, I think. Any way is there a way I can just plug it in to my custom skin shader in shadergraph?
Also concerned about when it was last updated. Been awhile.
In the start I click normally, at the end I spam my pickaxe. How do I make it so when I spam it dosent do that annoying glitchy interupting thing?
Well, you can take it apart to see how it works. It isn't a very commonly used thing; corrective blendshapes seem to be the more popular solution to that problem.
You'll want to make the transition back to the swinging state itself instantaneous with no offset
can anyone help me with this issue?
@lapis sluice is the method being called in FixedUpdate()?
yes 😔
sigh
FixedUpdate is for physics methods of rigidbodies, which you can set to Interpolate
it happens to the best of us
is it possible to instantly skip the entry animation when an object is spawned in?
i would like to avoid the brief flicker of the split second of equip animation playing
Is there a way to animate a material? i tried looking it up on google/youtube but couldnt find what i was looking for
basically, i want to be able to make an object cycle through pre-existing frames
You'd usually set keyframe interpolation mode to constant to make the change have no inbetweens, but if that doesn't work across separate clips why not just keyframe the mesh renderers being enabled/disabled
thanks, i ended up fixing it by only spawning the mesh without any animator attached
That's smarter
Unless you need to have the weapons pop in/out with animated motion, there's no need to use the Animator for this
yeah
im not sure but maybe you could try shaders?
im really new to unity, i dont even know how to use shaders
Material properties, such as tiling and offset can be keyframed, but the animator will change the shader material asset
i really have no idea what that meant
like, i understand the tiling and offset part, but you lost me at keyframe
Have you made animations before? Keyframes are a pretty basic concept in that context
nah i literally just got into unity lol
only things ive done so far are VRChat maps, and they really dont require any knowledge about anything
You have to find some tutorials or courses
There are official resources as well !learn
🧑🏫 Unity Learn can offer you over 750 hours of free live and on-demand learning content for all levels of experience! Make sure to check it out at https://learn.unity.com/
can someone help me with the blend tree animations? im still having some issues where my character doesnt move his feet at all
ill show my code as well just in case
private void Movement()
{
var horizontalInput = Input.GetAxis("Horizontal");
var verticalInput = Input.GetAxis("Vertical");
bool isRunning = Input.GetKey(KeyCode.LeftShift);
if (Mathf.Abs(horizontalInput) > _threshold || Mathf.Abs(verticalInput) > _threshold)
{
var camera = Camera.main;
var forward = camera.transform.forward;
var right = camera.transform.right;
forward.y = 0f;
right.y = 0f;
forward.Normalize();
right.Normalize();
var desiredMoveDirection = forward * verticalInput + right * horizontalInput;
transform.rotation = Quaternion.Slerp(transform.rotation, Quaternion.LookRotation(desiredMoveDirection), 0.2f);
// Set the movement speed based on whether running is active or not
var speed = isRunning ? MoveSpeed * RunMultiplier : MoveSpeed * 0.5f;
transform.Translate(desiredMoveDirection * speed * Time.deltaTime, Space.World);
// Set the animator parameters based on the movement speed and whether running is active
_animator.SetFloat("MoveSpeed", speed);
if (isRunning)
{
_animator.SetFloat("AnimSpeed", 1f, 0.2f, Time.deltaTime);
}
else if (speed > 0f)
{
_animator.SetFloat("AnimSpeed", 0.5f, 0.2f, Time.deltaTime);
}
else
{
_animator.SetFloat("AnimSpeed", 0f, 0.2f, Time.deltaTime);
}
// Set the running parameter based on whether running is active
_animator.SetBool("isRunning", isRunning);
}
else
{
_animator.SetFloat("MoveSpeed", 0f);
_animator.SetFloat("AnimSpeed", 0f, 0.2f, Time.deltaTime);
_animator.SetBool("isRunning", false);
}
}```
if anyone is curious\
each animation is looped, could that be an issue?
@lapis sluice You're not really showing us the inspector but I suspect root motion is on
in the animator component
if it is, you need to turn it off
that sort of animation where he just start and leans into it is typical of rootmotion where it shouldn't be
On an unrelated note; a bit of a stupid question but do you guys know if I should always be using the default foot IK feature in the animator for all animations? I checked for one and it looks good, better than off.
But are there any performance issues with raycasts or some sort of weird behaviour? Basically I'm asking if it safe to turn it on for all animations without thinking
then click on the individual animations
and enable loop pose
loop time and loop pose
and enable the first two bakes into pose with the (original) option
hi guys, how can I reuse animations on a different skin?
I can't find any tutorials on it on YT
Specifically for 2D animations on a sprite sheet
Is there something like conditions that will transition to next state if condition is met but not lock the animation?
i want to make certain landings and stops go to the locomotion state if speed is greater or less than 1 but conditions as they are will lock that animation in place till the condition is met
should i just do this through script or is there a way to do this through the animator?
just the first 2?
before this i baked all of them
Not sure what you mean by "lock"
If no available transition's conditions are met, the state will not change
Do you have a practical example
well for the landings and stops i'd like certain ones like rolling/skid stops to stop if < 1 speed and hard landings or stops with no movement to stop playing if > 1 speed. I was wondering if instead of adding animation events to all of these animations if I could somehow do this through the animator like how they have conditions (but making it a condition to end the animation early and go forward with the transition instead of being a required condition to transition)
That sounds perfectly doable with transitions and conditions
You could have skidding transition to rolling with exit time, but have both of them and their transition interruptable by transition to stopping in case of a sudden stop
Can you show a screenshot of that? and basically more info
anim import settings
yes
ill drop it here in a bit
the other ones are exactly the same
That looks fine althought the third bake into pose never works for me
I have to turn it off
lemme try it
goes without saying I Guess, but have you rigged it to the right avatar? And does it work in preview?
yeah heres a preview
of what happens
Speed 1?