We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.

Please help–Cannot remove loaded GLTF After moving them

Home Forums General Questions Please help–Cannot remove loaded GLTF After moving them

Viewing 13 posts - 1 through 13 (of 13 total)
  • Author
    Posts
  • #78332
    Micdsn
    Customer

    I have a scene I use in VR where I load several GLTF fliles when a button is clicked on in the scene. If I dont ‘grab’ the imported models they will be removed at a second pressing of the button as the puzzle indicates, however if I pick up and move them, the second button press loads another instance of the model. What am i doing wrong?

    (If you’re wondering why the two groups–the puzzle has 2 types of objects I want to interact with in the scene–‘slidable’ and ‘pickable’. I want some objects to be able to be moved, and some to be moved but ‘stick’ to the floor )

    Attachments:
    You must be logged in to view attached files.
    #78350

    Hi Micdsn,

    It’s difficult to understand what’s wrong from the screenshot. Perhaps you could try to isolate the issue step by step by simplifying your scenario to find out the root of the problem.

    Chief 3D Verger | LinkedIn | Twitter

    #78354
    kdv
    Participant

    What am i doing wrong?

    your grabbed objects are parented to the main scene after releasing and already aren’t children of the appended scenes. thus they won’t be removed when you remove those appended scenes.

    Puzzles and JS coding. Fast and expensive.

    If you don’t see the meaning in something it primarily means that you just don’t see it but not the absence of the meaning at all.

    #78356
    Micdsn
    Customer

    Thank you kdv! is there a way to delete the imported models another way? Or should i parent to an empty when released? Any suggestions to fix?

    #78357
    kdv
    Participant

    Just remove parenting.

    Puzzles and JS coding. Fast and expensive.

    If you don’t see the meaning in something it primarily means that you just don’t see it but not the absence of the meaning at all.

    #78364
    Micdsn
    Customer

    I tried this–parenting is how the controller ‘grabs’ object. Is there a way to parent it back to the main scene without sticking to anything else in the scene?

    #78365
    kdv
    Participant

    Is there a way to parent it back to the main scene

    they are already parented to the main scene. objects will be parented to Scene if you leave the second argument empty. But initially (before grabbing) they were parented to Display1.

    Puzzles and JS coding. Fast and expensive.

    If you don’t see the meaning in something it primarily means that you just don’t see it but not the absence of the meaning at all.

    #78366
    Micdsn
    Customer

    on ‘squeezeend’ I already parent it to an empty second argument. Is it possible to parent the picked object back to itself?

    I’m thinking of giving up ‘removing’ the appended model and just hiding it. But if I cant call the object back by it’s alias to remove that might not be possible either.

    To clarify–all i want to do now is just remove the object I loaded with the first click of the button. I used ‘append scene’ puzzle with an alias but I cannot ‘remove object’ on this alias if I have moved it at all with the controllers. — Everything works perfect if I dont touch the object at all with the controllers

    • This reply was modified 8 hours, 38 minutes ago by Micdsn.
    • This reply was modified 8 hours, 37 minutes ago by Micdsn.
    #78370
    kdv
    Participant

    on ‘squeezeend’ I already parent it to an empty second argument

    and that’s the main question: why instead of parenting back to Display1 you’re parenting your objects to the main scene? The second argument empty = Scene

    Puzzles and JS coding. Fast and expensive.

    If you don’t see the meaning in something it primarily means that you just don’t see it but not the absence of the meaning at all.

    #78372
    Micdsn
    Customer

    I’ll have to figure out how to do it. There are a possible 3 different models that are able to be picked up. Trying to figure how to avoid excess drawn out logic to handle all 3 just to unparent from the controller.

    #78373
    kdv
    Participant

    I’ll have to figure out how to do it

    put them back from where you took them

    Puzzles and JS coding. Fast and expensive.

    If you don’t see the meaning in something it primarily means that you just don’t see it but not the absence of the meaning at all.

    #78376
    Micdsn
    Customer

    But there are 3 possible displays — how do i put logic for this in the grabbing?

    #78377
    kdv
    Participant

    remember from where you took objects. use some variable (a dictionary) to save initial parent objects for picked objects.

    Puzzles and JS coding. Fast and expensive.

    If you don’t see the meaning in something it primarily means that you just don’t see it but not the absence of the meaning at all.

Viewing 13 posts - 1 through 13 (of 13 total)
  • You must be logged in to reply to this topic.