Lord_Greywolf;712006 said:
actualy your way also does nopt work either
in all cases - yours and theres - the only answer is 1 or 0 and with yours 1 only (yor min is always at least 4 and woth max of 1 = 1)
so they have something realy screwed up there with that formula
Seems fine to me.
TreasureMapChest.Fill( chest, Math.Max( 1, Math.Min( 4, sos.Level ) ) );
TreasureMapChest.Fill( chest, Math.Max( 1, Math.Min( 4, 0 ) ) );
TreasureMapChest.Fill( chest, Math.Max( 1, 0 ) );
TreasureMapChest.Fill( chest, 1 );
TreasureMapChest.Fill( chest, Math.Max( 1, Math.Min( 4, 1 ) ) );
TreasureMapChest.Fill( chest, Math.Max( 1, 1 ) );
TreasureMapChest.Fill( chest, 1 );
TreasureMapChest.Fill( chest, Math.Max( 1, Math.Min( 4, 2 ) ) );
TreasureMapChest.Fill( chest, Math.Max( 1, 2 ) );
TreasureMapChest.Fill( chest, 2 );
TreasureMapChest.Fill( chest, Math.Max( 1, Math.Min( 4, 3 ) ) );
TreasureMapChest.Fill( chest, Math.Max( 1, 3 ) );
TreasureMapChest.Fill( chest, 3 );
TreasureMapChest.Fill( chest, Math.Max( 1, Math.Min( 4, 4 ) ) );
TreasureMapChest.Fill( chest, Math.Max( 1, 4 ) );
TreasureMapChest.Fill( chest, 4 );
TreasureMapChest.Fill( chest, Math.Max( 1, Math.Min( 4, 5 ) ) );
TreasureMapChest.Fill( chest, Math.Max( 1, 4 ) );
TreasureMapChest.Fill( chest, 4 );
This is the same formula they use in SOS.cs to set the level. Keeps the level in the range of 1-4.