Summary:
When in mercenary service for a faction, the conversation option to terminate the contract does not show up.
Reproduce:
Become a mercenary, then talk to any lord of the corresponding faction. Use "There's something I'd like to discuss". There is no leaving option, which there should be.
Fix:
In the following method the first condition of the return statement is wrong,
The dev probably meant to check if the Clan is part of a Kingdom, which is done in the following manner (note the ! to invert the result):
The correct return function of
Tested and confirmed by yours truly.
When in mercenary service for a faction, the conversation option to terminate the contract does not show up.
Reproduce:
Become a mercenary, then talk to any lord of the corresponding faction. Use "There's something I'd like to discuss". There is no leaving option, which there should be.
Fix:
In the following method the first condition of the return statement is wrong,
Clan.IsKingdomFaction
ALWAYS returns false
because its purpose is to differentiate between a Clan IFaction
and a Kingdom IFaction
.
C#:
public bool conversation_player_want_to_end_service_as_mercenary_on_condition()
{
if (Hero.OneToOneConversationHero.MapFaction.IsKingdomFaction)
{
MBTextManager.SetTextVariable("FACTION_NAME", FactionHelper.GetFormalNameForFaction(Hero.OneToOneConversationHero.Clan.Kingdom), false);
}
return Hero.OneToOneConversationHero.Clan.IsKingdomFaction && Hero.MainHero.MapFaction == Hero.OneToOneConversationHero.MapFaction && Hero.OneToOneConversationHero.Clan != Hero.MainHero.Clan && Hero.MainHero.Clan.IsUnderMercenaryService;
}
The dev probably meant to check if the Clan is part of a Kingdom, which is done in the following manner (note the ! to invert the result):
!Hero.OneToOneConversationHero.Clan.IsMapFaction
Clan.IsMapFaction
uses return this._kingdom == null;
, so if the Clan has no Kingdom the property returns true
.The correct return function of
public bool conversation_player_want_to_end_service_as_mercenary_on_condition()
should thus look like this:
C#:
return !Hero.OneToOneConversationHero.Clan.IsMapFaction && Hero.MainHero.MapFaction == Hero.OneToOneConversationHero.MapFaction && Hero.OneToOneConversationHero.Clan != Hero.MainHero.Clan && Hero.MainHero.Clan.IsUnderMercenaryService;
Tested and confirmed by yours truly.