sketchucation logo sketchucation
    • Login
    Oops, your profile's looking a bit empty! To help us tailor your experience, please fill in key details like your SketchUp version, skill level, operating system, and more. Update and save your info on your profile page today!
    🫛 Lightbeans Update | Metallic and Roughness auto-applied in SketchUp 2025+ Download

    Moving objects

    Scheduled Pinned Locked Moved SketchyPhysics
    2 Posts 2 Posters 424 Views 2 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • D Offline
      Derek mason
      last edited by

      Hi
      I want to move a box down a packing line and send it at 90 degrees at the end. I can send it down the line but how do i make it change direction and keep moving

      1 Reply Last reply Reply Quote 0
      • M Offline
        mptak
        last edited by

        Push works well. Something like this inside the Sketchy Physics UI for the object.

        xpos=0.0
        ypos=0.0
        xturn=150.0
        yturn=150.0
        ontick{
        if frame%60 == 0
            if xpos < xturn || ypos > yturn
              push([1,0,0])
              puts ("pushx")
            else
              push([0,2,0])
              puts ("pushy")
            end
            xpos=position().x
            ypos=position().y
            puts(ypos)
        end
        }
        

        This will push towards the x direction for awhile then push towards the y and then back to the x. You could also change the logic so the push direction changed based on touching the bumpers using the ontouch event.


        downtrack.skp

        1 Reply Last reply Reply Quote 0
        • 1 / 1
        • First post
          Last post
        Buy SketchPlus
        Buy SUbD
        Buy WrapR
        Buy eBook
        Buy Modelur
        Buy Vertex Tools
        Buy SketchCuisine
        Buy FormFonts

        Advertisement