diff options
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/PhysicsModules/ubOdeMeshing/SculptMesh.cs | 21 |
1 files changed, 9 insertions, 12 deletions
diff --git a/OpenSim/Region/PhysicsModules/ubOdeMeshing/SculptMesh.cs b/OpenSim/Region/PhysicsModules/ubOdeMeshing/SculptMesh.cs index bc1375b..184221d 100644 --- a/OpenSim/Region/PhysicsModules/ubOdeMeshing/SculptMesh.cs +++ b/OpenSim/Region/PhysicsModules/ubOdeMeshing/SculptMesh.cs | |||
@@ -165,8 +165,8 @@ namespace PrimMesher | |||
165 | f2 = new Face(p1, p4, p2); | 165 | f2 = new Face(p1, p4, p2); |
166 | } | 166 | } |
167 | 167 | ||
168 | this.faces.Add(f1); | 168 | faces.Add(f1); |
169 | this.faces.Add(f2); | 169 | faces.Add(f2); |
170 | } | 170 | } |
171 | } | 171 | } |
172 | } | 172 | } |
@@ -203,18 +203,15 @@ namespace PrimMesher | |||
203 | return; | 203 | return; |
204 | String fileName = name + "_" + title + ".raw"; | 204 | String fileName = name + "_" + title + ".raw"; |
205 | String completePath = System.IO.Path.Combine(path, fileName); | 205 | String completePath = System.IO.Path.Combine(path, fileName); |
206 | StreamWriter sw = new StreamWriter(completePath); | 206 | using(StreamWriter sw = new StreamWriter(completePath)) |
207 | |||
208 | for (int i = 0; i < this.faces.Count; i++) | ||
209 | { | 207 | { |
210 | string s = this.coords[this.faces[i].v1].ToString(); | 208 | for (int i = 0; i < faces.Count; i++) |
211 | s += " " + this.coords[this.faces[i].v2].ToString(); | 209 | { |
212 | s += " " + this.coords[this.faces[i].v3].ToString(); | 210 | sw.Write(coords[faces[i].v1].ToString()); |
213 | 211 | sw.Write(coords[faces[i].v2].ToString()); | |
214 | sw.WriteLine(s); | 212 | sw.WriteLine(coords[faces[i].v3].ToString()); |
213 | } | ||
215 | } | 214 | } |
216 | |||
217 | sw.Close(); | ||
218 | } | 215 | } |
219 | } | 216 | } |
220 | } | 217 | } |