public int GetNumberOfSides()
{
int ret = 0;
bool hasCut;
bool hasHollow;
bool hasDimple;
bool hasProfileCut;
PrimType primType = GetPrimType();
HasCutHollowDimpleProfileCut(primType, Shape, out hasCut, out hasHollow, out hasDimple, out hasProfileCut);
switch (primType)
{
case PrimType.BOX:
ret = 6;
if (hasCut) ret += 2;
if (hasHollow) ret += 1;
break;
case PrimType.CYLINDER:
ret = 3;
if (hasCut) ret += 2;
if (hasHollow) ret += 1;
break;
case PrimType.PRISM:
ret = 5;
if (hasCut) ret += 2;
if (hasHollow) ret += 1;
break;
case PrimType.SPHERE:
ret = 1;
if (hasCut) ret += 2;
if (hasDimple) ret += 2;
if (hasHollow) ret += 1;
break;
case PrimType.TORUS:
ret = 1;
if (hasCut) ret += 2;
if (hasProfileCut) ret += 2;
if (hasHollow) ret += 1;
break;
case PrimType.TUBE:
ret = 4;
if (hasCut) ret += 2;
if (hasProfileCut) ret += 2;
if (hasHollow) ret += 1;
break;
case PrimType.RING:
ret = 3;
if (hasCut) ret += 2;
if (hasProfileCut) ret += 2;
if (hasHollow) ret += 1;
break;
case PrimType.SCULPT:
ret = 1;
break;
}
return ret;
}