Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
1
Question by Martin 3 · Oct 09, 2010 at 04:03 PM · animation3dmodel

Unity3d Starcraft 2 Model animation

Hi! At first I'd like to say that I'm very new to Unity, so maybe my following question is stupid, but I hope you all can help me with it! :)

I have a problem with animation playing in Unity3d. I have downloaded a starcraft 2 model (Not blizzards model, but from someone, who made that model for starcraft 2 editor). The model is in a .m3 format. I learned how to open it in 3ds Max, and export it to another file. I choose to export it to .3ds format. Then I imported it to Unity, and it looks perfect. Now the problem is that the all the animations like shooting, running etc. is only in one file "Take001" instead of one file per animation. Now I dont know how to make unity to know when the Character should run and when to shoot. I cant animate, so I dont know anything aobut it, so is there a way of solving the problem, or is there a better way of doing all these steps?

I hope you can help me! :)

edit: In 3ds Max, you can view all the animations. there are about 15.

edit 2 : So, I somehow found out that animations are stored in one file, and that they can be separated in Unity, but how?

Script: the idea with this script is that it plays walk animation when the object is moving along the z axis, it play T_right (turn right) animation when not moving, but rotating, and to make it play stand animation when not moving or rotating

// Animations

if(moveDirection.z != 0) { animation.CrossFade("walk"); }

 if(rotation.y != 0 && moveDirection.z == 0) 
 {
 animation.CrossFade("T_right");
 }



 if(moveDirection.z == 0 && rotation.y == 0) 
 {
 animation.CrossFade("Stand");
 }

Comment
Add comment · Show 3
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Phantomb · Mar 16, 2016 at 02:56 PM 0
Share

Hey man, I know this post is quite old, but I'm trying to do a similar thing. Can you tell me how you managed to export the model (including textures & animations) and import it in Unity? Thanks a bunch!

avatar image Cherno Phantomb · Mar 16, 2016 at 03:11 PM 0
Share

"quite old"... it's been almost six years! :D

I'd be surprised if there wasn't a multitude of tools and plugins to import a SC2 model with animations and materials into $$anonymous$$ax. Once it's there, you can easily export it to FBX.

avatar image Phantomb Cherno · Mar 16, 2016 at 04:12 PM 0
Share

There are some, but most are unfortunately outdated and can't be used anymore since a major internal SC data overhaul less than a year ago... :c

1 Reply

· Add your reply
  • Sort: 
avatar image
0
Best Answer

Answer by Mike 3 · Oct 10, 2010 at 03:31 PM

In unity, expand the model and click the Take001 animation - it should bring up the animation import inspector.

What you need to do is click the split toggle, and then type in the name, start and end frames for each animation in the grid below it.

You can most likely figure out the names and frames from the model in 3dsmax.

Comment
Add comment · Show 4 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Martin 3 · Oct 10, 2010 at 05:17 PM 0
Share

Ah. Thanks a lot! I though none was going to answer this question anymore. Now I seem to have this problem that my model only want to play the first animation - run. Even that I make it "idle" in the script, its just still stuck on the run animation. Why?

avatar image Martin 3 · Oct 10, 2010 at 05:19 PM 0
Share

And second problem is that when I run, the run animation runs fine, but every time the animation have played, it makes a little pause, where the character animation freezes, and then It begins again. How to make it not make that pause?

avatar image Mike 3 · Oct 10, 2010 at 05:36 PM 0
Share

For the second problem, it could be the frame numbers are off slightly - unity uses 0 for the first frame, check if 3dsmax uses 1 or 0. For the first problem, not really sure, could you put the script into your question?

avatar image Martin 3 · Oct 10, 2010 at 05:47 PM 0
Share

Posted the part of the script now. The animation pause problem is still there. I tried to change the start of the animation "walk" from 0 to 1, but it still makes that pause. Can it be that I left something unchecked?

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

2 People are following this question.

avatar image avatar image

Related Questions

Animation cant be found even if attached to object? 1 Answer

How to get my humanoid models base position in the scene view into a T-Pose 1 Answer

My animation is changing the position of root bone 1 Answer

Best ANIMATED Models to buy? 0 Answers

how to extend a character's animation 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges