s = [[v 1.000000 0.000000 -1.000000
v 1.000000 0.000000 1.000000
v -1.000000 0.000000 1.000000
v -1.000000 0.000000 -1.000000
v -0.000000 2.000000 0.000000
vn 0.0000 -1.0000 0.0000
vn 0.8944 0.4472 0.0000
vn -0.0000 0.4472 0.8944
vn -0.8944 0.4472 -0.0000
vn 0.0000 0.4472 -0.8944]]
i = 1
for word in
string.gmatch(s, "v [0-9.-]* [0-9.-]* [0-9.-]*") do
--print(word)
-- outputFile:write("Node"..i.. "= {" ..word.. "}\n")
-- outputFile:write("Node"..i.. "= {" ..string.gsub(word, "(%s)", "x=", 1).. "}\n")
print("Node"..i.. "= {" ..string.gsub(word, "([^%s]) ([^%s]) ([^%s])", "x=%1 y=%2 z=%3", 1).. "}")
i = i + 1
end
cyA9IFtbdiAxLjAwMDAwMCAwLjAwMDAwMCAtMS4wMDAwMDAKdiAxLjAwMDAwMCAwLjAwMDAwMCAxLjAwMDAwMAp2IC0xLjAwMDAwMCAwLjAwMDAwMCAxLjAwMDAwMAp2IC0xLjAwMDAwMCAwLjAwMDAwMCAtMS4wMDAwMDAKdiAtMC4wMDAwMDAgMi4wMDAwMDAgMC4wMDAwMDAKdm4gMC4wMDAwIC0xLjAwMDAgMC4wMDAwCnZuIDAuODk0NCAwLjQ0NzIgMC4wMDAwCnZuIC0wLjAwMDAgMC40NDcyIDAuODk0NAp2biAtMC44OTQ0IDAuNDQ3MiAtMC4wMDAwCnZuIDAuMDAwMCAwLjQ0NzIgLTAuODk0NF1dCgppID0gMQpmb3Igd29yZCBpbgogIHN0cmluZy5nbWF0Y2gocywgInYgWzAtOS4tXSogWzAtOS4tXSogWzAtOS4tXSoiKSBkbwogICAgLS1wcmludCh3b3JkKQogICAgLS0gb3V0cHV0RmlsZTp3cml0ZSgiTm9kZSIuLmkuLiAiPSB7IiAuLndvcmQuLiAifVxuIikKICAgIC0tIG91dHB1dEZpbGU6d3JpdGUoIk5vZGUiLi5pLi4gIj0geyIgLi5zdHJpbmcuZ3N1Yih3b3JkLCAiKCVzKSIsICJ4PSIsIDEpLi4gIn1cbiIpCiAgICBwcmludCgiTm9kZSIuLmkuLiAiPSB7IiAuLnN0cmluZy5nc3ViKHdvcmQsICIoW14lc10pIChbXiVzXSkgKFteJXNdKSIsICJ4PSUxIHk9JTIgej0lMyIsIDEpLi4gIn0iKQogICAgaSA9IGkgKyAxIAplbmQ=