Advertisement
Guest User

Untitled

a guest
Sep 2nd, 2016
93
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Ruby 1.06 KB | None | 0 0
  1. #------------------------------------------------------------------------  
  2. mod = Sketchup.active_model # Open model
  3. ent = mod.entities # All entities in model
  4. sel = mod.selection # Current selection
  5.  
  6. require 'sketchup.rb'
  7. #------------------------------------------------------------------------  
  8.  
  9. UI.menu("Plugins").add_item("Bemat Iwall") {
  10.  
  11.   #importing the model from source location
  12.   model = Sketchup.active_model
  13.   model.import 'C:\Users\sande\Desktop\Bematrix skp plugin\606 ++++ ++++ 30.skp'
  14.  
  15.   #Creating an input textbox for rows and collums
  16.   prompts = ["Horizontal", "vertical"]
  17.   defaults = ["1","1"]
  18.   input = UI.inputbox(prompts, defaults, "Wall specifications")
  19.   horizontal = input[0]
  20.   vertical = input [1]
  21.  
  22.  
  23.   #for loop create multible copies  
  24.   for i in 0..horizontal
  25.  
  26.     #importing the model from source location
  27.     model = Sketchup.active_model
  28.     model.import 'C:\Users\sande\Desktop\Bematrix skp plugin\606 ++++ ++++ 30.skp'
  29.  
  30.   end
  31. }
  32. #------------------------------------------------------------------------
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement