aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Framework/PrimitiveBaseShape.cs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Framework/PrimitiveBaseShape.cs11
1 files changed, 6 insertions, 5 deletions
diff --git a/OpenSim/Framework/PrimitiveBaseShape.cs b/OpenSim/Framework/PrimitiveBaseShape.cs
index 4c36819..c1e1a4f 100644
--- a/OpenSim/Framework/PrimitiveBaseShape.cs
+++ b/OpenSim/Framework/PrimitiveBaseShape.cs
@@ -622,6 +622,8 @@ namespace OpenSim.Framework
622 } 622 }
623 } 623 }
624 624
625 // This is only used at runtime. For sculpties this holds the texture data, and for meshes
626 // the mesh data.
625 public byte[] SculptData 627 public byte[] SculptData
626 { 628 {
627 get 629 get
@@ -1147,14 +1149,13 @@ namespace OpenSim.Framework
1147 1149
1148 public void ReadSculptData(byte[] data, int pos) 1150 public void ReadSculptData(byte[] data, int pos)
1149 { 1151 {
1150 byte[] SculptTextureUUID = new byte[16]; 1152 UUID SculptUUID;
1151 UUID SculptUUID = UUID.Zero; 1153 byte SculptTypel;
1152 byte SculptTypel = data[16+pos];
1153 1154
1154 if (data.Length+pos >= 17) 1155 if (data.Length-pos >= 17)
1155 { 1156 {
1156 _sculptEntry = true; 1157 _sculptEntry = true;
1157 SculptTextureUUID = new byte[16]; 1158 byte[] SculptTextureUUID = new byte[16];
1158 SculptTypel = data[16 + pos]; 1159 SculptTypel = data[16 + pos];
1159 Array.Copy(data, pos, SculptTextureUUID,0, 16); 1160 Array.Copy(data, pos, SculptTextureUUID,0, 16);
1160 SculptUUID = new UUID(SculptTextureUUID, 0); 1161 SculptUUID = new UUID(SculptTextureUUID, 0);