Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 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
0
Question by jun_jun · Dec 30, 2016 at 01:37 PM · instantiateassetbundleanimationclip

Can't Instantiate AnimationClip from AssetBundle correctly

It doesn't work when I tried to Instantiate AnimationClip from AssetBundle.

Details;

  1. Get AnimationClip data from AssetBundle.

  2. Duplicate AnimationClip using Instantiate().

  3. Overwrite AnimationClip of Animator with duplicated AnimationClip.

  4. Animation does not work without any error logs (animation should be played according to overwrote AnimationClip)

If I instantiated AnimationClip from resources which loaded via Resource.Load, it works fine. directly getting an instance from Resource.Load is OK as well.

  • AnimationClip From AssetBundle.Load -> OK.

  • AnimationClip From AssetBundle.Load with Instantiate() -> "NG".

  • AnimationClip From Resources.Load -> OK.

  • AnimationClip From Resources.Load with Instantiate() -> OK.

What is the difference?

If samples is needed, it is ready.

my environment is as follows;

  • MacOSX: 10.12

  • Unity: 5.4, 5.5 (checked in each version)

  • Unity Editor: MacOSX

  • Test scene : Assets/TestScene.unity (A Cube's animation is override in each cases.)

  • Test script : AnimationClipTest.cs

link text

animationclipfromassetbundleunitypackage.zip (269.4 kB)
Comment
Add comment · Show 1
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 Figo_Hunter · Aug 07, 2019 at 07:09 AM 1
Share

I have the exact same problem. I would like to know whether your asset bundles placed inside Unity Project? I have tested get all bindings and corresponding curve from the AssetBundle AnimationClip. However, I could not get any binding. Therefore I have a hypothesis that the Instantiate function and other Editor function that can grab the AnimationClip Info is to find the original file as asset bond with the AnimationClip. As my AssetBundle is outside the project root path, so those approaches can not access to the asset info and reproduce another one.

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by wechat_os_Qy0x0jQTqfX92xnxoRn9ZHsxQ · Nov 16, 2019 at 03:00 PM

same problem

Comment
Add comment · 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

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

8 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

instantiating transform.translate in the wrong position? 1 Answer

Create an AssetBundle with prefabs containing imported models 0 Answers

Set animation clip humanoid 0 Answers

Lag when Instantiating a loaded AssetBundle 2 Answers

How to destroy instantiated object 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