Workaround for mesh to correct the number of faces in GetNumberOfSides(). Meshs are handeled as sculpts but can have up to 8 faces (SL restriction the collada format can handle even more). The patch enables all LSL function that adressing faces to behave correct. Like llGetNumberOfSides(); llSetLinkPrimitiveParamsFast(); llSetPrimitiveParams(); llSetColor();

Signed-off-by: marc <mare@sounddog.net>
iar_mods
marc 2011-11-25 15:21:42 +01:00 committed by Justin Clark-Casey (justincc)
parent 585fc5e79d
commit e75bcd4c59
1 changed files with 9 additions and 1 deletions

View File

@ -3272,7 +3272,15 @@ namespace OpenSim.Region.Framework.Scenes
if (hasHollow) ret += 1;
break;
case PrimType.SCULPT:
ret = 1;
// Special mesh handling
if (this.Shape.SculptType == 5)
{
ret = 7; // its a mesh then max 8 faces
}
else
{
ret = 1; // its a sculpt then max 1 faces
}
break;
}
return ret;