// NK realistic sailing -->
float RS_GetRigTypeDivisor(string sDet, float fOffWind)
{
float fDivisor = 1.0;
switch(sDet)
{
case "Fsc": return(RS_GetRigTypeDivisor("Gat", fOffWind) + RS_GetRigTypeDivisor("Slo", fOffWind))/2; break; // NK new div for JMV's fast sch.
case "shn": return RS_GetRigTypeDivisor("bri", fOffWind); break; //return(RS_GetRigTypeDivisor("Gat", fOffWind) + RS_GetRigTypeDivisor("Slo", fOffWind))/2; break; // NK new div for AM shnyava
case "btn": return(RS_GetRigTypeDivisor("bri", fOffWind) + RS_GetRigTypeDivisor("Slo", fOffWind))/2; break; // NK new div for AM brigantine
case "Xeb":
if(fOffWind > 0.01) { fDivisor = sqrt(sqrt(sqrt(sqrt((fOffWind * 0.9) ^ 3)))) * 0.9785; }
else { fDivisor = 0.25; }
break;
case "Tar":
if(fOffWind > 0.01) { fDivisor = sqrt(sqrt(sqrt(sqrt((fOffWind * 0.9) ^ 3)))) * 0.9785; }
else { fDivisor = 0.25; }
break;
case "Sch":
if(fOffWind > 0.01) { fDivisor = sqrt(sqrt(sqrt(sqrt((fOffWind * 0.9) ^ 3)))) * 0.9785; }
else { fDivisor = 0.25; }
break;
case "Lug":
if(fOffWind > 0.01) { fDivisor = 1.2433*fOffWind ^ 3 - 2.7092*fOffWind ^ 2 + 2.0879*fOffWind + 0.3779; }
else { fDivisor = 0.38; }
break;
case "Gal":
if(fOffWind > 0.01) { fDivisor = 0.7467 * fOffWind ^ 3 - 1.9657*fOffWind ^ 2 + 1.839*fOffWind + 0.3803; }
else { fDivisor = 0.38; }
break;
case "Gat":
if(fOffWind > 0.01) { fDivisor = 1.2433*fOffWind ^ 3 - 2.7092*fOffWind ^ 2 + 2.0879*fOffWind + 0.3779; }
else { fDivisor = 0.38; }
break;
case "Cor":
if(fOffWind > 0.01) { fDivisor = 1.2433*fOffWind ^ 3 - 2.7092*fOffWind ^ 2 + 2.0879*fOffWind + 0.3779; }
else { fDivisor = 0.39; }
break;
case "Car":
if(fOffWind > 0.01) { fDivisor = 1.2433*fOffWind ^ 3 - 2.7092*fOffWind ^ 2 + 2.0879*fOffWind + 0.3779; }
else { fDivisor = 0.39; }
break;
case "Bar":
if(fOffWind > 0.01) { fDivisor = 1.2433*fOffWind ^ 3 - 2.7092*fOffWind ^ 2 + 2.0879*fOffWind + 0.3779; }
else { fDivisor = 0.39; }
break;
case "Yac":
if(fOffWind > 0.01) { fDivisor = 1.2433*fOffWind ^ 3 - 2.7092*fOffWind ^ 2 + 2.0879*fOffWind + 0.3779; }
else { fDivisor = 0.39; }
break;
//default: // scheffnow - bfd
if(fOffWind > 0.01) { fDivisor = 0.7467 * fOffWind ^ 3 - 1.9657*fOffWind ^ 2 + 1.839*fOffWind + 0.3803; }
else { fDivisor = 0.38; }
}
return fDivisor;
}