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!
    🛣️ Road Profile Builder | Generate roads, curbs and pavements easily Download

    [Plugin] LÖVR export

    Scheduled Pinned Locked Moved Plugins
    3 Posts 2 Posters 15 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.
    • I Offline
      immortalx
      last edited by

      This won't be of interest to many but I thought of posting it here just in case.
      I'm doing a VR game with the LÖVR framework and using Sketchup as a level-editor.
      I wanted to export custom data for pickups, trigger zones, spawn points, etc. so I've made this simple extension that exports coordinates/matrices in text files.
      I've never touched the Sketchup API or Ruby before so excuse me if there's some atrocious code in there 💚

      The way it works is it gets components with predefined tags and exports either 4x4 matrices or just their positions, in an easy to parse CSV format.
      NOTE: It overwrites files without warning! Anyone knows how I could check for that and display a prompt?

      Link Preview Image
      GitHub - immortalx74/lovr_export

      Contribute to immortalx74/lovr_export development by creating an account on GitHub.

      favicon

      GitHub (github.com)

      1 Reply Last reply Reply Quote 0
      • TIGT Offline
        TIG Moderator
        last edited by

        if File.exist?(some_full_file_path_you_are_exporting_to)
          ### yn = UI.messagebox() ### to ask if you want to overwrite
          ### look at API methods...
          ### if yn ### == "yes"
                ### overwrite file
          ### else
                ### leave file alone
          ### end
        end
        
        

        TIG

        1 Reply Last reply Reply Quote 0
        • I Offline
          immortalx
          last edited by

          Thank you very much TIG! Updated.

          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