Closed TheBadListener closed 4 years ago
IsStringNoneOrEmpty() is a custom method from TaleWorlds. string.IsNullOrEmpty() on the other hand is directly from the .Net. If I choose between them, probably my choice goes to IsStringNoneOrEmpty().
IsStringNoneOrEmpty() is a custom method from TaleWorlds. string.IsNullOrEmpty() on the other hand is directly from the .Net. If I choose between them, probably my choice goes to IsStringNoneOrEmpty().
Sounds good, we will go through that later then.
Ok, here is the diference between IsStringNullOrEmpty($) and $.IsStringNoneOrEmpty() .. The first one is a method so it can evaluate if an string is empty or if its pointer ref is null. The second one is an extension method and the object it extends cannot be null.
Some ProceedToSharedCallBacks are not actually shared, and refer to different things ConsequenceSlavery, ConsequenceChangeHealth, ConsequenceLeaveSpouse, ConsequenceProstitute, ConsequenceRenown, ConsequenceChangeTrait, ConsequenceChangeSkill, ConsequenceGold refer to captives, when a captor. Seems like ProceedToSharedCallBacks is only used in captive and random events.
ChangeMorale should refer to the main party when random or captor.
Will double check when this is fixed. Will let you fix this as you might be refactoring it further, and I might put it in the wrong place lol.
Ok from what I can see, random and captor have the same code, but captive have a different PartyBase.
From that point, what I can do is something like that:
There is a method that check if the Player is captive and select the proper party automatically. And I added another one where you can specify manually the PartyBase value.
I'll push that modif for testing. If it doesn't works, I'll have to set specific methods for each case.
Further testing is needed for now, will be able to do more testing tomorrow.