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.

Scrub object’s animation with a draggable div?

Home Forums Graphics / Blender Scrub object’s animation with a draggable div?

Tagged: ,

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #87094
    jefferywright2194
    Participant

    I have a div constrained within a container, movement limited to the x axis, via jquery on the web page

    $( “#draggable” ).draggable({ axis: “x”, containment: “#drag”, scroll: false });

    When the div is dragged right, I want a few object’s animations to play forward, and back when the div is dragged back to its default left justified starting position.

    The only solution a search uncovered was:

    Get the slider’s value or position. (um, okay?)

    Map to Animation: Use a math block to map the position (\(x\) or \(y\)) of the dragged object to the set animation frame puzzle. (what math block?)

    …with no further explanation or description of the specific steps.

    Has anyone managed to get a draggable slider to scrub through an object’s animation sequence?

    How did you do it?

    Thanks!

    #87107
    jefferywright2194
    Participant

    I have added to the jquery on my page code that reports the relative x position of the draggable element:

    
    $( function() {
        $( "#draggable" ).draggable({ axis: "x", containment: "#drag", scroll: false });
    
    $("#draggable").draggable({
        drag: function(event, ui) {
            // ui.position.left gives the relative x value
            console.log("Relative X:", ui.position.left);
    		let dragPos = ui.position.left;
        }
    });
    
      } );
    

    It’s unclear how I can get Verge3D puzzles to capture that value, assuming this is the next logical step in the process.

    I have a variable puzzle “dragPositionX” who’s value should be ui.position.left. I set dragPositionX to dragPos .

    puzzle

    The console logs Relative X but does not log the value for dragPositionX.

    #87113
    jefferywright2194
    Participant

    I have added to the jquery on my page code that reports the relative x position of the draggable element:

    
    $( function() {
        $( "#draggable" ).draggable({ axis: "x", containment: "#drag", scroll: false });
    
    $("#draggable").draggable({
        drag: function(event, ui) {
            // ui.position.left gives the relative x value
            console.log("Relative X:", ui.position.left);
    		let dragPos = ui.position.left;
        }
    });
    
      } );
    

    It’s unclear how I can get Verge3D puzzles to capture that value, assuming this is the next logical step in the process.

    I have a variable puzzle “dragPositionX” who’s value should be ui.position.left. I set dragPositionX to dragPos .

    puzzle

    The console logs Relative X but does not log the value for dragPositionX.

    #87114
    jefferywright2194
    Participant

    This forum is not displaying what I submit.

    There is something wrong, there should be 3 posts as seen in this view.
    3

    But here in the post, there is only two?
    2

    If I try to resubmit my post that is not appearing I get this:
    dup

    If it already exists, why does it not appear here?

    • This reply was modified 5 days, 1 hour ago by jefferywright2194. Reason: This forum has no preview function
    • This reply was modified 5 days, 1 hour ago by jefferywright2194. Reason: This forum has no preview function
    • This reply was modified 5 days, 1 hour ago by jefferywright2194. Reason: This forum has no preview function
    • This reply was modified 5 days, 1 hour ago by jefferywright2194. Reason: This forum has no preview function
    #87123

    Sorry for the troubles. The post was mistakenly marked as spam – restored it!

    Chief 3D Verger | LinkedIn | X

    #87124

    Hi,

    “variable value by name” works only for the variables defined in Puzzles. To retrieve a JavaScript variable assign it to the “window” object (to make it global) and then use the “javascript object → window” puzzle to retrieve it. See the example:

    An alternative approach would using API calls or message passing as described here.

    Soft8Soft Tech Chief
    Want more Verge3D updates? Follow me on X, Facebook, or LinkedIn

    #87154
    jefferywright2194
    Participant

    Thanks, I am using Google AI to create a detailed, step by step process to achieve the outcome I want, but it has posted this issue:

    If the get prop puzzle in your version of Verge3D lacks a gear icon, it is because you are using a version where “flexible input” is not enabled via a menu. Instead, you must use a specific combination of puzzles to “force” a manual property entry.

    https://www.soft8soft.com/wp-content/uploads/2026/05/get-prop-01.png

    https://www.soft8soft.com/wp-content/uploads/2026/05/get-prop-02.png

    https://www.soft8soft.com/wp-content/uploads/2026/05/get-prop-03.png

    What version of Verge3D has a blue gear icon on get prop?

    • This reply was modified 4 days, 1 hour ago by jefferywright2194. Reason: This forum has no preview function or simple add image function
    #87159

    What version of Verge3D has a blue gear icon on get prop?

    Unfortunately none. The entire answer looks like an AI hallucination. I’d suggest going with the global variable approach.

    Soft8Soft Tech Chief
    Want more Verge3D updates? Follow me on X, Facebook, or LinkedIn

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