Results 1 to 11 of 11

Thread: Why every third patrician being adopted is called "Sergivs Orata" and how to fix that.

  1. #1

    Icon4 Why every third patrician being adopted is called "Sergivs Orata" and how to fix that.

    I noticed that roughly every third patrician being adopted or married into the family is called Sergivs Orata. Today, I took a look into trigger section of the traits and realized why this is.

    The way the triggers work is you have a list of names and probability pi:

    Name1 p1
    Name2 p2
    ...
    Name38 p38
    Name39 p39 (=100%)


    Now, the engine throws a dice if Name1 gets drawn with probability p1. If not, it jumps to Name2 and so on. Now, the task is how to assign the right probabilities such that every name is drawn with roughly the same probability. Well, the answer the EB-Code gives is the following:

    ; Assign gens and cognomen to patrician marriage suitors
    ;
    ; RandomPercent values are assigned assuming the order of these
    ; triggers doesn't change. New triggers must be added at the top
    ; and the RandomPercent value must be 1/N * 100, where N is the
    ; total number of triggers.
    ;
    ; Possible Patrician Names: 39
    However, this answer is wrong, unfortunately. If you give every name the same probability 1/39~3%, then the newly adopted patrician will be called Mr. "Sergivs Orata" (= Name 39) with the following probability 0.97^38 ~ 31%. And this is exactly why every third patrician gets that name.

    Now, the right answer is to distribute the probabilities inversely proportional to the position in the list, i.e. as follows:

    Name1 p1 (=1/39)
    Name2 p2 (=1/38)
    ...
    Name38 p38 (=1/2)
    Name39 p39 (=1/1)

    This fixes the problem. With this probability distribution, every name gets drawn with roughly the same probability on average.



    edit: I implemented this for myself and started testing. So far, works really terrifically. Diversity of assigned names has vastly improved!
    Last edited by Danny087; September 02, 2023 at 04:26 PM.

  2. #2

    Default Re: Why every third patrician being adopted is called "Sergivs Orata" and how to fix that.

    I've flagged that to the team. We don't have anyone looking at traits at the moment.

  3. #3

    Default Re: Why every third patrician being adopted is called "Sergivs Orata" and how to fix that.

    Hm, I just took a quick glance at the new version v2.4a. Apparently, this issue is still not fixed. Yet, the fix would be so simple. One would only need to change the probabilities as I described above. Thus, even with the new update, still every third general continues to get the same name. What a shame...

  4. #4

    Default Re: Why every third patrician being adopted is called "Sergivs Orata" and how to fix that.

    I thought someone might have applied it, but as I noted, no one is dedicated to traits at the moment.

  5. #5
    The_Praetor's Avatar Foederatus
    Join Date
    Oct 2011
    Location
    The Battlefield
    Posts
    40

    Default Re: Why every third patrician being adopted is called "Sergivs Orata" and how to fix that.

    @Danny087

    I had actually noticed the same thing when EBII 2.3 released. I was in a Romani campaign and saw the same names continuously popping up (gens Sergia and the cognomen Orata).
    Kudos to you for figuring this out!

  6. #6

    Default Re: Why every third patrician being adopted is called "Sergivs Orata" and how to fix that.

    Quote Originally Posted by Danny087 View Post
    edit: I implemented this for myself and started testing. So far, works really terrifically. Diversity of assigned names has vastly improved!
    anyone know which file you'd modify, and if it would be savegame compatible?

  7. #7

    Default Re: Why every third patrician being adopted is called "Sergivs Orata" and how to fix that.

    Quote Originally Posted by cowrecked View Post
    anyone know which file you'd modify, and if it would be savegame compatible?
    data\export_descr_character_traits.txt

    And not savegame compatible.

  8. #8

    Default Re: Why every third patrician being adopted is called "Sergivs Orata" and how to fix that.

    Sorry, everyone could me explain, I dont understand what I have to modifi

  9. #9

    Default Re: Why every third patrician being adopted is called "Sergivs Orata" and how to fix that.

    Ok guys, I quickly implemented it and attached the file for the new 2.4a Version. Have fun :-)

    Simply copy it into your folder "...\Medieval II Total War\mods\ebii\data" (CAUTION: DO NOT put it into the folder "...\Medieval II Total War\data"! Also, as you should always do, backup the original file first.)

    I haven't tested it (I don't have 2.4a installed yet since I haven't adopted all my personal changes I like to play with to the new version yet.), but I tried to be really careful. So, I'm confident it should work.



    As for savegame compatibility: Since it's just a simple change of some numbers in the trigger section of the file, it should be savegame compatible.

    In any case, there is a way by which you can make most things (except changes in script or such) savegame compatible in general:

    Open the config file ("...\Medieval II Total War\mods\ebii\ebii.cfg") and change the line "validate_data = 1" to "validate_data = 0". That way you can even add new traits and stuff and it will be savegame compatible.
    (If you add new traits, though, ALWAYS add them after the latest trait that already is in the file, right before the trigger section! If you don't do that, the traits your generals have will get completely messed up!)
    Only problem is, switching validation of data off very unfortunately is savegame incompatible itself, sorry. But if you switch it off, savegame compatibility will be vastly increased for all future savegames. I highly recommend always doing this. Very unfortunately, EBII has it initially switched on, sorry...

    @EBII-team: Of course you can use my fix as you deem fit, if you like. :-)
    Attached Files Attached Files
    Last edited by Danny087; February 23, 2024 at 01:17 PM.

  10. #10

    Default Re: Why every third patrician being adopted is called "Sergivs Orata" and how to fix that.

    Thanks a bunch!

  11. #11

    Default Re: Why every third patrician being adopted is called "Sergivs Orata" and how to fix that.

    Quote Originally Posted by Danny087 View Post
    Ok guys, I quickly implemented it and attached the file for the new 2.4a Version. Have fun :-)
    Nicely done. EB2 trigger system is riddled with some wonky probabilities from time to time. When I was actively working as a traiter I tried fixing these as soon as I spotted them - a similar problem as you described was plagueing several ethnicity systems - but this probably slipped under the radar: and then I stopped being active (that's what adult life does to most of us I guess) and couldn't finish my long to-do list. The fact that Roman traits and triggers are often considered as "completed", because they've been in the game for so long, doesn't help. So keep a watchful eye every time you see something fishy, you may easily happen upon one of these miscalculations!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •