Hi Anthony ,
In our project we will be importing all the products(3D models of Furniture Etc) through Addressable assets. In your code I have noticed that there is a very important function being used to create and move the Products in the scene. Also the prefab list seems important in most steps.
My question is that since we will not have prefabs in our main project and we are able to download the assets in the project via API but what could be the best way to use them as 'Modules' ? Because we would like to use your existing system of creating the Module in scene and also to be able to move/ modify these as well.

Looking Forward for your suggestions.

    12 days later

    bigknockdown Hi! Very sorry for the late reply!

    What I would do in this case, would be to have the prefab modules already made and packed in the addressable packages.
    The download and unpack would be a scene happening before Home Designer scenes. once everything is downloaded, I would rebuild the module list (skipping the json) and fill a scriptable object at runtime with all the modules data.
    Then launch the home designer scene and replace the module json reading by the scriptable object.

    Not sure if that answering your question so let me know if I misunderstood.
    Anthony

      10 months later

      bigknockdown Did you get the success with your question?

      I am trying to add the same functionality and looking out for ways.

      Please let me know.

      Rohit

        powergamer
        So what we ended up doing is we created prefabs of our 3D Products , in those prefabs we added two joints each.
        Created addressable assets and uploaded to CCDN
        While downloading and creating an instance of a product we added the Module component in runtime.
        So basically we implemented our own way of bringing the product into the scene , but we are still using the popup which comes up when you click on a module which helps you to move the product around.

          bigknockdown
          This is a speedy reply.
          Thank you very much. In my case, third parties will hold their .glb files on our server.
          So I need to get those .glb files and do something with them. Because those prefabs I can not create in the editor as I don't know which 3D model the user will upload.

          I will also use the same pop-ups to move these objects,. Now my challenges are.

          1. Once the products are downloaded how to create a runtime products with collider and joints.
          2. Need to modify the workflow to add these runtime products in the categories
          3. Use them in JSON with some other references.

          Let's see, @Anthony Any suggestions?

          Rohit

            powergamer you can have a script that adds the Module component on your object at runtime, and a box collider, for the joints you can probably guess the back edges of the box collider. Or you could skip the joints and just snap the objects on the floor without worrying about snapping to the walls.

            For the json generation there are many ways to do that. if the user upload his models before he loads the application (different page basically) then you can generate the json on the server side at runtime including all the modules he uploaded.

            If your user uploads his models in the same application, I would skip the json and just generate the ModuleList object and feed the application with it.

              Write a Reply...