Advertisement
Guest User

Untitled

a guest
Jan 14th, 2016
165
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. rollout test "Spline optimizator:)" width:162 height:300
  2. (
  3.    
  4.     button btn3 "Check" pos:[9,7] width:145 height:28
  5.     GroupBox grp1 "GroupBox" pos:[10,41] width:142 height:250
  6.     label lbl1 "" pos:[17,60] width:130 height:22
  7.     label lbl2 "" pos:[17,75] width:130 height:22
  8.     button btn8 "Optimize" pos:[16,258] width:132 height:28
  9.    
  10.  
  11.     on btn3 pressed do
  12.     (
  13.             x = selection[1].name
  14.             sKnots = numknots selection[1]
  15.             lbl1.text = "Spline : " + x
  16.             lbl2.text = "Vertex : " + (sKnots as string)
  17.         )
  18.        
  19.    
  20.     on btn8 pressed do
  21.     (      
  22.         for s = 1 to (numSplines $) do
  23.         (
  24.             step = 0;
  25.            
  26.             for k = 1 to (numKnots $ s)  do
  27.             (
  28.                
  29.                 step+=1
  30.                 print step
  31.  
  32.                 if step== 2 then (
  33.                     deleteKnot $ s k
  34.                     step = 0
  35.                 )
  36.             )
  37.         )
  38.        
  39.         updateshape $
  40.     )
  41.  
  42. )
  43.  
  44. CreateDialog test 162 300
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement