Search Unity

Runtime Asset Importing ?

Discussion in 'General Discussion' started by grabiller, Apr 8, 2010.

Thread Status:
Not open for further replies.
  1. grabiller

    grabiller

    Joined:
    Nov 7, 2009
    Posts:
    1
    Hi,

    Sorry if this has been asked before :

    Let's say I'm creating a Machinima application with Unity, and I would like the user of this application to be able to load contents on the fly ( characters, props, etc.. in *.obj or another format at runtime ).

    Is this possible with Unity ?

    Or is using the editor the only way to import assets ?

    Is there some API usable at runtime to import assets on the fly ?

    Thanks.
    Guy.
     
  2. HiggyB

    HiggyB

    Unity Product Evangelist

    Joined:
    Dec 8, 2006
    Posts:
    6,183
    First off, welcome to the forums! :)

    Yes, there are different ways to load assets on the fly depending on exactly what type of assets you're talking about:

    - You can use the WWW class to load things like data (pull XML, hit a PHP file to query a database, etc.) as well as load images (JPG/PNG only) or stream audio/video on demand (requires Unity Pro).

    - If you want to load geometry (meshes) at run-time, and they're in a text based format then you can load those via the WWW class then use the Mesh class to build the geometry at run-time. I do believe that some folks have scripts done and at the ready for this already, I'm just not in possession of URLs at this moment.

    - If you want to load geometry (meshes, with textures, sounds, etc.) at run-time then you can also use Asset Bundles, but these are supported in content made with Unity Pro only and the user of your application will need to own Unity Pro in order to create those Asset Bundles.
     
  3. Eric5h5

    Eric5h5

    Volunteer Moderator Moderator

    Joined:
    Jul 19, 2006
    Posts:
    32,401
    Fortunately, by an amazing coincidence, I just happen to have such an URL, here!

    --Eric
     
  4. HiggyB

    HiggyB

    Unity Product Evangelist

    Joined:
    Dec 8, 2006
    Posts:
    6,183
    And I've now saved a bookmark, thanks!
     
  5. Melvin Eng

    Melvin Eng

    Joined:
    Jul 4, 2014
    Posts:
    12
    Hi there,

    Let's say I have 2 Unity applications each running on a PC(both connected by LAN): 1 records live game-play to video files during run-time, the other then loads these video files remotely over the LAN for playback(via Windows file-sharing functionality).
    So is this actually doable? (btw I'll be using Unity Pro to develop both applications)


    Cheers :)
    Melvin Eng
    Workshop Foundry
     
    Last edited: Jun 10, 2015
  6. Aurore

    Aurore

    Director of Real-Time Learning

    Joined:
    Aug 1, 2012
    Posts:
    3,106
    5 year old post. Please create a new thread in the correct forum.
     
Thread Status:
Not open for further replies.