Summary: When the player donates a prisoner to an allied npc's settlement the prisoner is actually given to the garrison party rather than the settlement. When a prisoner is contained in the dungeon of an npc's fief they should be using the base daily escape chance of 7.5%, but instead they use the chance associated with the garrison party, which is classified as a "mobile party." Since the chance of escaping from a mobile party is higher than from a settlement, the prisoners escape more rapidly than intended.
All other cases tested seem to be working properly, including putting a prisoner in a player owned dungeon and an npc putting a prisoner in an npc owned dungeon.
How to Reproduce: Start the game in debug mode. As a player, donate a prisoner to any npc owned settlement, either a castle or a town. Insert a breakpoint in the DailyHeroTick() function of the PrisonerEscapeCampaignBehavior class at the EndCaptivityAction.ApplyByEscape(hero, null) line. Wait until the specific prisoner escapes and examine the related variables and properties of the hero object. You will see that the escape chances saved in the "num" variable reflect that of a mobile party with a size matching that of the settlement's garrison. The PartyBelongedToAsPrisoner property of the hero object will also say "Garrison of X."
Media:
Notice that the value of "num" in the first screenshot is 0.22928768 and the equation from .IsMobile [0.075 x (6 - (75^0.25))] = 0.22928768 also.
Version: 1.4.2 Beta Branch
All other cases tested seem to be working properly, including putting a prisoner in a player owned dungeon and an npc putting a prisoner in an npc owned dungeon.
How to Reproduce: Start the game in debug mode. As a player, donate a prisoner to any npc owned settlement, either a castle or a town. Insert a breakpoint in the DailyHeroTick() function of the PrisonerEscapeCampaignBehavior class at the EndCaptivityAction.ApplyByEscape(hero, null) line. Wait until the specific prisoner escapes and examine the related variables and properties of the hero object. You will see that the escape chances saved in the "num" variable reflect that of a mobile party with a size matching that of the settlement's garrison. The PartyBelongedToAsPrisoner property of the hero object will also say "Garrison of X."
Media:
Notice that the value of "num" in the first screenshot is 0.22928768 and the equation from .IsMobile [0.075 x (6 - (75^0.25))] = 0.22928768 also.
Version: 1.4.2 Beta Branch