I have been able to tweak the spyglasses code in order to give just an "aproximate" information, depending on the quality og the spyglasses.
So, when you look, lets say, the number of sailors, you see variable numbers... so you only can guess how many they will be.
Idem with hulls or sails
Unfortunately, I was expecting that you will get a diferent data each time you opened or closed the spyglass.... no, the numbers are changing continuously.....
... I'll try to fix.
Feel proud. First try with the mods and no crashes (still
)
Code in BATTLEINTERFACE/ispyglass.c
-------------------------------------------------
void SetSpyGlassData()
{
int chrIdx = GetEventData();
if(chrIdx<0) return;
int shipHull = -1;
int shipSail = -1;
int shipCrew = -1;
int shipCannons = -1;
int shipCharge = -1;
int shipNation = -1;
float shipSpeed = -1.0;
string shipName = "";
string shipType = "";
int shipDistance = 0; // meh
int shipMorale = 45; // NK
int spyglassacc = 0; //KB
int shipCaliber = -1; //KB
string stemp = "" //KB
int vtemp = 0; //KB
......
.......
......
//KB Spyglasses
switch (arScopeItm.id) {
case "spyglass1":
spyglassacc = 4;
break;
case "spyglass2":
spyglassacc = 3;
break;
case "spyglass3":
spyglassacc = 2;
break;
case "spyglass4":
spyglassacc = 1;
break;
}
//KB Spyglasses
.......
.......
else
{
if( !CheckAttribute(arScopeItm,"scope.show.cannons") || sti(arScopeItm.scope.show.cannons)!=0 )
{
vtemp = GetCannonQuantity(chref);
shipCannons = vtemp + makeint(vtemp/10) * (rand( 2* spyglassacc) - spyglassacc);
vtemp = 0;
// Number of cannons variates... so you can't be sure how many... 32 o 44... nice
}
if( !CheckAttribute(arScopeItm,"scope.show.ship_name") || sti(arScopeItm.scope.show.ship_name)!=0 )
{
shipName = XI_ConvertString(GetShipTypeName(chref)) + " : " + chref.Ship.Name;
}
if( !CheckAttribute(arScopeItm,"scope.show.ship_type") || sti(arScopeItm.scope.show.ship_type)!=0 )
{
shipType = "Class " + GetCharacterShipClass(chref);
}
// I'm thinking about make possible to confound similar ships i.e a yacht and a barque, or all the variants of Frigates or Galleons.... it will not the same fight against a Light Frigate or against a Frigate
if( !CheckAttribute(arScopeItm,"scope.show.hull") || sti(arScopeItm.scope.show.hull)!=0 )
{
vtemp = rand(2*spyglassacc*5) - spyglassacc*5;
shipHull = makeint(GetHullPercent(chref)) + vtemp;
vtemp = 0;
// I've made harder to guess damage in hull
}
if( !CheckAttribute(arScopeItm,"scope.show.sail") || sti(arScopeItm.scope.show.sail)!=0 )
{
vtemp = rand(2*spyglassacc*2) - spyglassacc*2;
shipSail = makeint(GetSailPercent(chref)) +vtemp;
vtemp = 0;
}
// OTOH, it's really easier to see the real damage in the riggings
if( !CheckAttribute(arScopeItm,"scope.show.crew") || sti(arScopeItm.scope.show.crew)!=0 )
{
vtemp = GetCrewQuantity(chref);
shipCrew = vtemp + makeint(vtemp/10) * (rand( 2* spyglassacc) - spyglassacc);
vtemp = 0;
}
if( !CheckAttribute(arScopeItm,"scope.show.speed") || sti(arScopeItm.scope.show.speed)!=0 )
{
vtemp = rand (2*spyglassacc*3) - 3*spyglassacc;
shipSpeed = stf(chref.Ship.speed.z) + vtemp;
vtemp = 0;
// meh -->
vtemp = rand (2*spyglassacc*5) - 5*spyglassacc;
shipDistance = ( Ship_GetDistance2D(GetMainCharacter(), chref) ) / 10 ;
shipDistance *= 10;
shipdistance = shipdistance + vtemp;
shipType = shipType + ", " + shipDistance + " yards";
// meh <--
}
if( !CheckAttribute(arScopeItm,"scope.show.charge") || sti(arScopeItm.scope.show.charge)!=0 )
{
shipCharge = sti(chref.Ship.Cannons.Charge.Type);
// NK -->
if(shipCrew != -1)
{
if(CheckAttribute(chref,"Ship.Crew.Morale"))
{
shipMorale = sti(chref.Ship.Crew.Morale);
}
shipName = shipName + ", Crew's Morale: " + GetMoraleName(shipMorale);
}
// NK <--
}
}
So, when you look, lets say, the number of sailors, you see variable numbers... so you only can guess how many they will be.
Idem with hulls or sails
Unfortunately, I was expecting that you will get a diferent data each time you opened or closed the spyglass.... no, the numbers are changing continuously.....
... I'll try to fix.
Feel proud. First try with the mods and no crashes (still

Code in BATTLEINTERFACE/ispyglass.c
-------------------------------------------------
void SetSpyGlassData()
{
int chrIdx = GetEventData();
if(chrIdx<0) return;
int shipHull = -1;
int shipSail = -1;
int shipCrew = -1;
int shipCannons = -1;
int shipCharge = -1;
int shipNation = -1;
float shipSpeed = -1.0;
string shipName = "";
string shipType = "";
int shipDistance = 0; // meh
int shipMorale = 45; // NK
int spyglassacc = 0; //KB
int shipCaliber = -1; //KB
string stemp = "" //KB
int vtemp = 0; //KB
......
.......
......
//KB Spyglasses
switch (arScopeItm.id) {
case "spyglass1":
spyglassacc = 4;
break;
case "spyglass2":
spyglassacc = 3;
break;
case "spyglass3":
spyglassacc = 2;
break;
case "spyglass4":
spyglassacc = 1;
break;
}
//KB Spyglasses
.......
.......
else
{
if( !CheckAttribute(arScopeItm,"scope.show.cannons") || sti(arScopeItm.scope.show.cannons)!=0 )
{
vtemp = GetCannonQuantity(chref);
shipCannons = vtemp + makeint(vtemp/10) * (rand( 2* spyglassacc) - spyglassacc);
vtemp = 0;
// Number of cannons variates... so you can't be sure how many... 32 o 44... nice

}
if( !CheckAttribute(arScopeItm,"scope.show.ship_name") || sti(arScopeItm.scope.show.ship_name)!=0 )
{
shipName = XI_ConvertString(GetShipTypeName(chref)) + " : " + chref.Ship.Name;
}
if( !CheckAttribute(arScopeItm,"scope.show.ship_type") || sti(arScopeItm.scope.show.ship_type)!=0 )
{
shipType = "Class " + GetCharacterShipClass(chref);
}
// I'm thinking about make possible to confound similar ships i.e a yacht and a barque, or all the variants of Frigates or Galleons.... it will not the same fight against a Light Frigate or against a Frigate
if( !CheckAttribute(arScopeItm,"scope.show.hull") || sti(arScopeItm.scope.show.hull)!=0 )
{
vtemp = rand(2*spyglassacc*5) - spyglassacc*5;
shipHull = makeint(GetHullPercent(chref)) + vtemp;
vtemp = 0;
// I've made harder to guess damage in hull
}
if( !CheckAttribute(arScopeItm,"scope.show.sail") || sti(arScopeItm.scope.show.sail)!=0 )
{
vtemp = rand(2*spyglassacc*2) - spyglassacc*2;
shipSail = makeint(GetSailPercent(chref)) +vtemp;
vtemp = 0;
}
// OTOH, it's really easier to see the real damage in the riggings
if( !CheckAttribute(arScopeItm,"scope.show.crew") || sti(arScopeItm.scope.show.crew)!=0 )
{
vtemp = GetCrewQuantity(chref);
shipCrew = vtemp + makeint(vtemp/10) * (rand( 2* spyglassacc) - spyglassacc);
vtemp = 0;
}
if( !CheckAttribute(arScopeItm,"scope.show.speed") || sti(arScopeItm.scope.show.speed)!=0 )
{
vtemp = rand (2*spyglassacc*3) - 3*spyglassacc;
shipSpeed = stf(chref.Ship.speed.z) + vtemp;
vtemp = 0;
// meh -->
vtemp = rand (2*spyglassacc*5) - 5*spyglassacc;
shipDistance = ( Ship_GetDistance2D(GetMainCharacter(), chref) ) / 10 ;
shipDistance *= 10;
shipdistance = shipdistance + vtemp;
shipType = shipType + ", " + shipDistance + " yards";
// meh <--
}
if( !CheckAttribute(arScopeItm,"scope.show.charge") || sti(arScopeItm.scope.show.charge)!=0 )
{
shipCharge = sti(chref.Ship.Cannons.Charge.Type);
// NK -->
if(shipCrew != -1)
{
if(CheckAttribute(chref,"Ship.Crew.Morale"))
{
shipMorale = sti(chref.Ship.Crew.Morale);
}
shipName = shipName + ", Crew's Morale: " + GetMoraleName(shipMorale);
}
// NK <--
}
}