Guest User

Untitled

a guest
Jul 19th, 2018
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.39 KB | None | 0 0
  1. while Maya:
  2. {
  3. my (line) =
  4. string.rstrip(line)
  5.  
  6. elif line in re.search("library_geometries"):
  7.  
  8. {
  9. start == 1
  10. }
  11.  
  12. if (line == float.array)
  13. {
  14. end == 1
  15. }
  16.  
  17. if ((start == 1), (end == 0))
  18. {
  19. if (line)
  20. {
  21. print('Line n')
  22.  
  23.  
  24. if [(start == 1), end == 0)]
  25.  
  26. if(line)
  27. {
  28. print('Line n')
  29.  
  30. Split = [split(line)]
  31. array.index(Split) = split(line)
  32. list.append[(xCoords), Split(0)]
  33. list.append[(yCoords), Split(1)]
  34. list.append[(zCoords), Split(2)]
  35.  
  36. while (<MAYA>)
  37. {
  38.  
  39. my ($line) = $_;
  40. chomp($line);
  41.  
  42. if ($line =~ /library_geometries/)
  43. {
  44. $start = 1;
  45. }
  46.  
  47. if ($line =~ /</float_array>/)
  48. {
  49. $end = 1;
  50. }
  51.  
  52. if (($start == 1) && ($end == 0))
  53. {
  54. if ($line !~ /</)
  55. {
  56. #print GRID "$linen";
  57.  
  58. if (($start == 1) && ($end == 0))
  59. {
  60. if ($line !~ /</)
  61. {
  62. #print GRID "$linen";
  63.  
  64. @Split = split(/ /,$line);
  65. push @xCoords, $Split[0];
  66. push @yCoords, $Split[1];
  67. push @zCoords, $Split[2];
  68.  
  69. for line in MAYA:
  70. line = line.rstrip()
  71.  
  72. if "library_geometries" in line: start = True
  73. if "</float_array>" in line: end = True
  74.  
  75. if start and not end:
  76. if '<' not in line:
  77. # GRID.write(line + 'n')
Add Comment
Please, Sign In to add comment