Multiple Spouses?

Users who are viewing this thread

Revanstein

Regular
Background: I am working on a historical ancient mod.  The mod attempts to replace generic quest system, with one set in a real-character based world.  When it occurred to me that polygamy was not just a practice, but a core institution to the ruling politics of the ancient world... which of course, presents a problem...

Question: Does anyone know of a way to remove the one-spouse limit in M&B (or an effective way around it)?
 
You'll need to re-write the code that deal with marriage (including tons of spouse checks and references scattered through the module system).
 
If you just want to make multiple multiple wives possible, you could reset the wive counter after marrying one, so that the game doesn't register, that you are married. As such, you could keep marrying over and over. But I think, this would mess up loads of dialogues.
 
That might work.  Now to work out a script that does that automatically, so it can be a political feature to the mod (maybe figure out how to increase the "right to rule" for each marriage.
 
Fire_and_Blood said:
If you just want to make multiple multiple wives possible, you could reset the wive counter after marrying one, so that the game doesn't register, that you are married. As such, you could keep marrying over and over. But I think, this would mess up loads of dialogues.
And cause all kinds of bugs.

The proper way would be to dedicate a number of slots for wives, and go through the module system code to adapt it to the fact that a husband can have several.
 
Revanstein said:
Too bad I haven't found any code that simplifies it as simply changing a MAX value for spouses.

Since the default is monogamous there isn't a max number for it.

Assuming you only marry single women, the max you can have is 72 (8 daughter and 4 sister from each kingdom and 6 kingdoms in Warband) excluding claimants and heroes (7 of them in total)... kind of ominous somehow
The number of women in the game is 127 including the 2 claimants and the 5 companions if you prefer using boolean datatype instead of referencing.  Again, some other ominous number.

Now I am not sure whether you can just add variables or something but the best practice should probably involve
[list type=decimal]
[*]changing spouse info to an array. If you need to separate concubines from wife (wife as in the one managing the concubines), you probably would add an array instead of replacing it.
[*]Find the character notes screen (no idea where that is) and change it to look for the array.
[*]Change the check condition of the lady talk in module dialogues. You might want to have some extra condition such as ambitious ladies might not want to settle as concubines.
[*]Check whether the resulting family relations is what you would expect/want when you renounce vassalship after a female player married to a lord of some faction (I have no idea what happens).  If it isn't you might want to make claimants and companions unavailable.  If it looks like you can change that to what you want, you can add dialogues to claimant and female companions about marriage.
[/list]

The initialization and dialogue tells us getting bettothed and setting spouse is unidirectional (so you need to run twice):
Code:
(troop_set_slot, ":cur_troop", slot_troop_spouse, ":cur_lady"),
(troop_set_slot, ":cur_lady", slot_troop_spouse, ":cur_troop"),
Code:
(troop_set_slot, "$g_talk_troop", slot_troop_betrothed, "trp_player"),
(troop_set_slot, "trp_player", slot_troop_betrothed, "$g_talk_troop"),
I'd keep betrothal to one at a time (marry that girl before you engage to another) atm for simplicity
So now in dialogues you might want to change one of them to adding to the array if you are married (clone the dialogue to check if you are already got a wife)

I am looking for ways to do something like that too (except I want other features as well, such as female player to marry girls, ability to change your wife/concubine's clothes, able to "recourt" with the same girl after you part with her (sometimes you have to part with the girl in order to get permission from lord, which means you can't see the girl anymore and that kind of defeats the whole purpose of getting permission), and possibly base on vex native)
 
Now this seems like its on the right track.  Sounds like you have some great ideas, love to see how it turns out for you.
 
so far I am still working on fixing who is being called husband and who is being called wife. (I am doing female player marrying girls too)

Looking up the wiki (people don't use arrays) seems the easiest way to do concubines is:
[list type=decimal]
[*]When you take a girl while you have a wife, you don't change the spouse,  just change the girl's spouse to point to you.
[*]On the character notes screen, Concubines are all the ladies to see whose spouse points to you while your spouse don't point to them.  The bidirectional one is your wife.
[/list]

Working features so far:
  • Changing my wifes' clothing works.
  • Reset courtship after getting permission from lord works.

Questions I am having:
How do I change so the AI lord will/will not take concubines?  Specifically I want the AI lord who married you (female player) not to take concubines (I stop having clues what you call those people) while other AI lord might take concubines (If it is simpler for AI lords to be monogamous, I'll take it.  Right now I have no clue what happens).  I have yet a clue where the courtship/marriage is arranged for AI lords takes place (Players' are done in dialogs) so if someone point me to the place where AI lords do courtship/marriages it should be sufficient.

Edit:  so far I am hitting a wall with the player portion.  There are things  I am not able to solve:
  • Let's say I eloped with a second lady or marry a second woman legitimately (I asked permission beforehand) the 2nd women does not seem to be appearing in my court (her location is in faction capital and is not showing up when I go to castle.  I have no idea why the location for the first woman is correctly set but not the second one. )  Debug (cheatmenu) mode says each of the ladies "is present at the center and in place of honor" If my faction only got 1 town but I only see one of them.
  • script_courtship_event_bride_marry_groom is triggered, but the spouse slot for neither the bride nor the groom are set.

I can post the diffs if anyone needs them.
 
WIP posted at pastebin (diff).  I use the linux version from steam so I am not sure whether the compiled files are compatible cross-platform.  Caveat -- Only manual changes are put into the diff.  I do not track automatic changes made to other files.  (to those of you who use windows, Cygwin or Gnu for win32 has the diff tool for automatic patching from the native module.  If you happen to use that, run your command prompt as admin to avoid modifying program files content wihtout permission.)

Working features:
  • wife + multiple concubine works (tested up to 1:cool:
  • Change clothes for your spouse by talking to each of them.
  • Talk to your wife to set whether your concubines should be seen in public
  • If your concubines are not to be seen in public, your town menu has a separate entry for your "harem".
  • Visit each of your spouse(s) alone in your court.  This time, without the annoying nurse.
  • Cheat menu to make peace (so your courtship can resume without problems in case War was declared.) and to make ladies like you.
  • If you ask for a lady's guardian for courtship permission, the meeting status resets so you can part with a lady and re-court the same lady after you get permission.  If you don't want the lords to annoy you by bringing that up, uncomment the lines  (neg|troop_slot_ge, ":lady", slot_troop_met, 4), in module_dialogs.py shortly before the lines of {"By the way, I hope you get a chance to meet my {s11}, {s14}.  ", "lord_start",} and {"By the way, I am sure that my {s11}, {s14}, would be delighted were you to pay her a visit. She awaits you in her chambers.", "lord_start",} (without the braces)
  • Female players still can marry their favourite single AI dude lord.  However, once you are stuck with a man you will no longer be able to take on additional spouses.  If your female player marries a lady your female player can still court/marry additional women.  Not yet tested is whether you can marry female AI lords (you shouldn't be able to as a dude (takes too much effort to add lordly spouse talk for dude players atm), not sure if you can as a female player)
  • Your concubines will not have her family listed on your character notes, and her family member will not list you (as they are not listed, they don't get the relation strength/penalty from being your wife's extended family).  Your concubines will list you has husband so you can chain to the families that way.  May take a lot of rewrite to implement that (you have to get the young lady in the family to see if she is married to you, instead of pulling girls from your spouse slot)
  • Feast and household inventory management is removed from dialogues with concubines.  They can still give you quests.

I am in need of help in the following:
  • Currently it has a 16 spouse limit of your harem view.  I am not sure whether it is simpler to use page numbers or pick and choose like sparring practice. (choosing 15 might be a bit of a pain while using page numbers means I might not get the combination I want)/li]
 
Hi, I'm also interested in a polygamy mod, Vikings use to had Thrall as concubines outside their marriage, so I don't see any reason for not having that option in this game (or at least as a Nord).
I was trying to start learning some basic about Warband coding (i use to mod in other games and I want to migrate to warband and probably Bannerlord from the beginning), and then I found this. ... I know I should read aaaaalll the documentation about Warband coding before asking, but... you know, is pretty easy to open a .txt with notepad++ (I made a few changes here and there... in my game).
So, is there a way to implement those changes by command in the cheat menu? for example by adding the proper line in the corresponding txt.
 
k61824 said:
WIP posted at pastebin (diff).  I use the linux version from steam so I am not sure whether the compiled files are compatible cross-platform.  Caveat -- Only manual changes are put into the diff.  I do not track automatic changes made to other files.  (to those of you who use windows, Cygwin or Gnu for win32 has the diff tool for automatic patching from the native module.  If you happen to use that, run your command prompt as admin to avoid modifying program files content wihtout permission.)

How do I install it or where shall I copy paste the coding? I am kinda new to the Game just my 3 month in it. Can you guys make a Installer?

Thanks for any help  :mrgreen:
 
Revanstein said:
Background: I am working on a historical ancient mod.  The mod attempts to replace generic quest system, with one set in a real-character based world.  When it occurred to me that polygamy was not just a practice, but a core institution to the ruling politics of the ancient world... which of course, presents a problem...

Question: Does anyone know of a way to remove the one-spouse limit in M&B (or an effective way around it)?

I wouldn't call it ac ore institution of the ancient world. Plenty of people didn't practice it.
 
kalarhan said:
LAST_ACTION_HERO said:
Can you guys make a Installer?

its not like in Fallout/Skyrim. You need to actually work with the game code, merge the changes, and compile it yourself.

See https://forums.taleworlds.com/index.php/topic,240255.0.html if you want to learn how. And visit the tutorial subforum to learn more.

Read that before I found the topic but honestly I do not completely understand the Mechanics, so how would I install this mod he made in a NATIVE module and just mod from there?
 
Back
Top Bottom