Jump to content

Recommended Posts

Posted

Hey, I was curious if there is a way for Fertility Mode to work in conjunction with Milk Mod Economy.  I currently have both loaded, but only Fertility Mode seems to be affecting my character while she's pregnant.  If this has already been covered I apologize.  Just point me to the relevant posts and I'll figure it out from there.

 

Edit: Never mind, I figured out what was wrong.  

  • 4 weeks later...
Posted

Fertility mode does not recognize futa insemination and seems to treat such actors still as female even if said actor is set to male in sexlab. Is there a way to adjust that?

Posted
On 7/25/2020 at 2:31 AM, mikovic76 said:

Fertility mode does not recognize futa insemination and seems to treat such actors still as female even if said actor is set to male in sexlab. Is there a way to adjust that?

 

I am getting this as well. Tried to reinstall both mods to make sure the plugin is loaded and also ran LOOT, I have GenderBender_SE but that only changes a female to male if they have a SOS object, not Flower Girls.

You can set Flower Girls to treat female as male but it still not getting the "X came in side X" and sperm count is 0.

Edit: I am reading in the change notes, v1.5.0 was supposed to fix this but I still can't father as a woman.
"Removed the gender check for "fathers" in the insemination spell script. Now a female player can "father" children with NPCs."

I have FG 3.0.2 installed (no plugins from FG) and only dialog to start event in FG is with followers "Do you remember that you said you would do anything to serve me?" dialog option.

I also have in FM Verbose Messages on but no message appears.

Edit2: Have confirmed Sexlab is still working for sperm as long as the player is listed as Female in animation settings.
Just can't get FG to work.

Posted
8 hours ago, Jaysjunk said:

Edit2: Have confirmed Sexlab is still working for sperm as long as the player is listed as Female in animation settings.
Just can't get FW to work.

Do you have version 2.9.1 of Fertility Mode? It was only updated a week ago so I have to ask. Also, what is FW? Redacted

Posted
23 hours ago, Scholarly Badger said:

Do you have version 2.9.1 of Fertility Mode? It was only updated a week ago so I have to ask. Also, what is FW?

Sorry was a typo, that was FG. Yes I am running 2.9.1

Posted
15 hours ago, Jaysjunk said:

 

I am getting this as well. Tried to reinstall both mods to make sure the plugin is loaded and also ran LOOT, I have GenderBender_SE but that only changes a female to male if they have a SOS object, not Flower Girls.

You can set Flower Girls to treat female as male but it still not getting the "X came in side X" and sperm count is 0.

Edit: I am reading in the change notes, v1.5.0 was supposed to fix this but I still can't father as a woman.
"Removed the gender check for "fathers" in the insemination spell script. Now a female player can "father" children with NPCs."

I have FG 3.0.2 installed (no plugins from FG) and only dialog to start event in FG is with followers "Do you remember that you said you would do anything to serve me?" dialog option.

I also have in FM Verbose Messages on but no message appears.

Edit2: Have confirmed Sexlab is still working for sperm as long as the player is listed as Female in animation settings.
Just can't get FG to work.

While that change note isn't incorrect in the latest version, I will mention that Fertility Mode was largely rewritten between version 1.x and 2.x. ;)

 

In terms of tracking, the CK gender is used if the SexLab patch isn't installed and otherwise will use the SexLab gender setting:

int function GetActorGender(Actor akActor)
{Convenience function to isolate SexLab as much as possible}
    int sex = akActor.GetLeveledActorBase().GetSex()
    
    if (Game.GetFormFromFile(0x00000D62, "SexLab.esm"))
       sex = (Game.GetFormFromFile(0x00000D62, "SexLab.esm") as SexLabFramework).GetGender(akActor)
    endIf
    
    return sex
endFunction

The SexLab orgasm handlers always use SexLab's gender setting. A good way to check that you're the correct gender is to look at the tracking list in the MCM page. If the player is listed, you're treated as female, otherwise you're treated as male.

 

I'll run some additional tests, because looking at the code I have some concerns about the SexLab and Flower Girls orgasm handlers. For SexLab, I use animation tags where the primary insemination tags are Vaginal, Creampie, and VaginalCum. Anal, AnalCreampie, and AnalCum are also used but only have a 2% chance of triggering insemination. My concern here is whether the primary tags are used with a male player that's set in SexLab to be female.

 

For Flower Girls I have a similar concern about the animation matches and will need to do some testing. The algorithm uses the animation type where CowGirl, Doggy, Missionary, Standing, and Threesome all unconditionally match for insemination. Anal has a 3% chance of matching for insemination (which is a frustrating discrepancy I need to fix), and the random scene checks vaginal animation tokens. All that said, the Flower Girls script has a glaring bug in that it doesn't use the above GetActorGender function and instead unconditionally uses the CK gender for the participating actors, which is a huge oopsie on my part:

int actor1Sex = actor1.GetLeveledActorBase().GetSex()
int actor2Sex = actor2.GetLeveledActorBase().GetSex()

The insemination spell and debug MCM are self-contained, so they should fully recognize the "correct" gender.

 

So it seems I have some work to do, and I'll make sure everything is working as intended in the next release (I haven't yet decided on a version number[1]). And apologies for the technical mind dump, but I like to give folks insight on what I'm thinking and why. ;)

 

[1] I have complete permission to steal assets from TKAA (no patch, no TKAA needed, just direct support), and the next version number will be 3.0 if I can get them incorporated to my liking. Otherwise it will probably be 2.9.<something greater than 1>.

Posted

Hello Narue, thanks for the great mod.

 

I've been waiting for this for a long time in SE

 

Are you planning on adding sendmodevents for developers?

 

Like modifying fertility possibility, adding cum, change phases?

 

I want to make a patch for Fill Her Up to integrate your mod.

Posted
58 minutes ago, Narue said:

While that change note isn't incorrect in the latest version, I will mention that Fertility Mode was largely rewritten between version 1.x and 2.x. ;)

 

In terms of tracking, the CK gender is used if the SexLab patch isn't installed and otherwise will use the SexLab gender setting:


int function GetActorGender(Actor akActor)
{Convenience function to isolate SexLab as much as possible}
    int sex = akActor.GetLeveledActorBase().GetSex()
    
    if (Game.GetFormFromFile(0x00000D62, "SexLab.esm"))
       sex = (Game.GetFormFromFile(0x00000D62, "SexLab.esm") as SexLabFramework).GetGender(akActor)
    endIf
    
    return sex
endFunction

The SexLab orgasm handlers always use SexLab's gender setting. A good way to check that you're the correct gender is to look at the tracking list in the MCM page. If the player is listed, you're treated as female, otherwise you're treated as male.

 

I'll run some additional tests, because looking at the code I have some concerns about the SexLab and Flower Girls orgasm handlers. For SexLab, I use animation tags where the primary insemination tags are Vaginal, Creampie, and VaginalCum. Anal, AnalCreampie, and AnalCum are also used but only have a 2% chance of triggering insemination. My concern here is whether the primary tags are used with a male player that's set in SexLab to be female.

 

For Flower Girls I have a similar concern about the animation matches and will need to do some testing. The algorithm uses the animation type where CowGirl, Doggy, Missionary, Standing, and Threesome all unconditionally match for insemination. Anal has a 3% chance of matching for insemination (which is a frustrating discrepancy I need to fix), and the random scene checks vaginal animation tokens. All that said, the Flower Girls script has a glaring bug in that it doesn't use the above GetActorGender function and instead unconditionally uses the CK gender for the participating actors, which is a huge oopsie on my part:


int actor1Sex = actor1.GetLeveledActorBase().GetSex()
int actor2Sex = actor2.GetLeveledActorBase().GetSex()

The insemination spell and debug MCM are self-contained, so they should fully recognize the "correct" gender.

 

So it seems I have some work to do, and I'll make sure everything is working as intended in the next release (I haven't yet decided on a version number[1]). And apologies for the technical mind dump, but I like to give folks insight on what I'm thinking and why. ;)

 

[1] I have complete permission to steal assets from TKAA (no patch, no TKAA needed, just direct support), and the next version number will be 3.0 if I can get them incorporated to my liking. Otherwise it will probably be 2.9.<something greater than 1>.


No need to apologies for the reply. It was a well written explanation. :)

Looking forward on the update.

Posted
8 minutes ago, factoryclose said:

Hello Narue, thanks for the great mod.

 

I've been waiting for this for a long time in SE

 

Are you planning on adding sendmodevents for developers?

 

Like modifying fertility possibility, adding cum, change phases?

 

I want to make a patch for Fill Her Up to integrate your mod.

There are currently four mod events I fire that other mods can catch (with one being an event added for others that I only stub internally):

 

RegisterForModEvent("FertilityModeAddSperm", "OnFertilityModeAddSperm")
RegisterForModEvent("FertilityModeImpregnate", "OnFertilityModeImpregnate")
RegisterForModEvent("FertilityModeLabor", "OnFertilityModeLabor")
RegisterForModEvent("FertilityModeConception", "OnFertilityModeConception")

 

You can look at _JSW_BB_HandlerQuestAliasScript.psc to see the signature and how I use the events.

 

Fertility chance and changing phases in an ad hoc way are borderline impossible given the current implementation. I somewhat regret using game time formulae to manage phases for that very reason. Technically you can alter the phases because I store the game time at the point something happens, then use a calculation against the current game time to identify where the current status is. As an example, this is the calculation for the current cycle day:

 

int cycleDay = Math.Ceiling(Storage.LastGameHours[actorIndex] + Storage.LastGameHoursDelta[actorIndex]) % (CycleDuration.GetValueInt() + 1)

 

The LastGameHours is when the actor was last updated, the LastGameHoursDelta is a random unchanging integer to avoid every woman having a perfectly insync cycle, and the time is wrapped into a rolling window with modulo. You could change the LastGameHours to alter the cycle, but that's a tricky algorithm. The first problem is avoiding setting it into the future because that would seriously break things, so you'd probably need to roll the value backward instead of forward. The second problem is the value is automatically updated at the end of each polling cycle, so your change wouldn't stick. The third problem is how game time is stored. It's a floating point value where the integer part is the day and the fractional part is the hour divided by 24. To introspect into hours and/or make changes, you'd need to carefully do some math mumbo jumbo.

 

Fertility chance is similar in that it uses multiple metrics:

 

bool function IsConceptionPossible(Actor akActor, int actorIndex)
{Checks if the specified actor is in a fertile time of the cycle}
    if (Storage.LastConception[actorIndex] > 0.0)
        return false ; The actor is currently pregnant
    endIf
    
    float birthDay = (Utility.GetCurrentGameTime() - Storage.LastBirth[actorIndex])
    
    if (Storage.LastBirth[actorIndex] != 0.0 && birthDay < RecoveryDuration.GetValueInt())
        ; Recovery from birth, no chance of conception
        return false
    else
        int cycleDay = Math.Ceiling(Storage.LastGameHours[actorIndex] + Storage.LastGameHoursDelta[actorIndex]) % (CycleDuration.GetValueInt() + 1)
        float spermCount = Storage.SpermCount[actorIndex]
        int ovulationDay = ((OvulationEnd.GetValueInt() - OvulationBegin.GetValueInt()) / 2) + OvulationBegin.GetValueInt()
        int viableDayStart = ovulationDay - (SpermLife.GetValueInt() - 1)
        int viableDayEnd = ovulationDay + EggLife.GetValueInt()
        int fertility = 0
        
        if (cycleDay >= viableDayStart && cycleDay < ovulationDay)
            ; Increase fertility percentage up to half the viable period
            fertility = ConceptionChance.GetValueInt() / (ovulationDay - viableDayStart) * (cycleDay - viableDayStart + 1)
        elseIf (cycleDay < viableDayEnd && cycleDay >= ovulationDay)
            fertility = ConceptionChance.GetValueInt()
        endIf
        
        if (akActor.HasMagicEffect(EffectContraception))
            fertility = 3
        elseIf (akActor.HasMagicEffect(EffectFertility))
            fertility += ConceptionChance.GetValueInt()
        endIf
        
        ; Clamp the fertility percentage
        if (fertility > ConceptionChance.GetValueInt())
            fertility = ConceptionChance.GetValueInt()
        elseIf (fertility < 0)
            fertility = 0
        endIf
        
        if (Storage.LastOvulation[actorIndex] != 0.0 && (Storage.LastOvulation[actorIndex] <= EggLife.GetValue() || akActor.HasMagicEffect(EffectFertility)))
            ; We have a viable egg, now check for sperm viability
            if (Storage.SpermCount[actorIndex] > 100.0)
                return Utility.RandomInt(1, 100) < fertility
            else
                return false ; Insufficient sperm for conception
            endIf
        else
            return false ; The actor has no viable egg available
        endIf
    endIf
endFunction

 

The best you could do consistently (at least in the current implementation) is to change the ConceptionChance global variable, but that would apply to all women.

 

These problems have been bugging me, so I've been thinking about setting up a less complex implementation. It's a trade off though. Reducing complexity in the formulae means storing more data, and I'm hesitant to do that because rather than external storage such as PapyrusUtil or JSON I went with parallel dynamic arrays to avoid dependencies, and with parallel arrays the data storage in your save file can explode with too many arrays.

 

What do you need to integrate Fill Her Up? If the current provided events are insufficient, I can look into adding more.

Posted

SendModEvent("OnFertilityModeAddSperm", Actor, "None")

This will work I guess.

 

Thank you. One more request though, if you add additional argument for manipulating SpermCount int, it would be very helpful.

 

Ah, and one more thing. a simple creature support would be awesome.?

But if you add a support for creatures, then string fatherName from the mod events should be replaced with formID rather than string?

Posted
5 hours ago, factoryclose said:

SendModEvent("OnFertilityModeAddSperm", Actor, "None")

This will work I guess.

 

Thank you. One more request though, if you add additional argument for manipulating SpermCount int, it would be very helpful.

I can certainly do that, but it would probably be one-way. I'm not aware of mod events supporting return values, so you'd either be guessing at how much sperm to add/remove, or you'd need to introspect the SpermCount property regardless.

Quote

 

Ah, and one more thing. a simple creature support would be awesome.?

 

Simple creature support is already there, at least where it comes to sperm. But I'm guessing you're talking about creature child actors, I get that request a lot. ;)

Quote

But if you add a support for creatures, then string fatherName from the mod events should be replaced with formID rather than string?

Not really. The father's name is strictly informational and it's discarded after birth. What really matters is the father's race when the mod is configured to use the father's race for the child. And for that I already store the race form ID.

Posted

Okay I gave it a test but for some reason SendModEvent didn't work.

Any argument didn't work beside Event name(String).

It looks like SendModEvent only works with specific arguments.

https://www.creationkit.com/index.php?title=SendModEvent

SendModEvent(string eventName, string strArg = "", float numArg = 0.0)

 

So I used ModEvent and the script was successfully compiled.

 

 

Function FertilityEventGo(string eventname, Form akactor, string fatherName)
    int handle = ModEvent.Create(eventname)
    if (handle)
        ModEvent.Pushform(handle, akactor)
        ModEvent.PushString(handle, fatherName)
        ModEvent.Send(handle)
    endIf
EndFunction

 

Posted

Yup, the arguments have to be exact. Since I expect different arguments, you would indeed need to send a custom event. As an example, here are the functions I use internally to fire the two event variations:

function SendTrackingEvent(string eventName, Form akSender, int iTrackingIndex)
{Fire a custom tracking event where the sender is the tracked actor}
    int handle = ModEvent.Create(eventName)
    
    if (handle)
        ModEvent.PushString(handle, eventName)
        ModEvent.PushForm(handle, akSender)
        ModEvent.PushInt(handle, iTrackingIndex)
        ModEvent.Send(handle)
    endIf
endFunction

function SendDetailedTrackingEvent(string eventName, Form akSender, string motherName, string fatherName, int iTrackingIndex)
{Fire a custom tracking event where the sender is the tracked actor}
	int handle = ModEvent.Create(eventName)
    
    if (handle)
        ModEvent.PushString(handle, eventName)
        ModEvent.PushForm(handle, akSender)
        ModEvent.PushString(handle, motherName)
        ModEvent.PushString(handle, fatherName)
        ModEvent.PushInt(handle, iTrackingIndex)
        ModEvent.Send(handle)
    endIf
endFunction

 

Posted

Okay this might be a slightly stupid idea on how to work around with the birth animations. Why not to use Dynamic animation replacer system where you can give condition that triggers with your mod and DAR will replace the stock animation with one more realistic from Sexlab or Hentai pregnancy (with permissons of course) dnalloh1987 has posted neat guide on how to convert animation or maybe any of the talented people here might be willing to help with animations.

 

With regards MK

Posted
On 7/28/2020 at 10:01 PM, milankovalcik said:

Okay this might be a slightly stupid idea on how to work around with the birth animations. Why not to use Dynamic animation replacer system where you can give condition that triggers with your mod and DAR will replace the stock animation with one more realistic from Sexlab or Hentai pregnancy (with permissons of course) dnalloh1987 has posted neat guide on how to convert animation or maybe any of the talented people here might be willing to help with animations.

 

With regards MK

 

To my knowledge there is no real birth animation with animobject. That's too bad since it would be quite useful as a resource, and now with complex animobjects and HDT vagina it would be more doable than it was a few years ago.

Posted
On 7/28/2020 at 11:33 AM, Narue said:

Simple creature support is already there, at least where it comes to sperm. But I'm guessing you're talking about creature child actors, I get that request a lot. ;)

Untamed (while not great for SE and 2.0 is in dev) manages to do this fairly well but I'm not sure how they manage it vs how you'd have to try and integrate.

Posted

Hello, I was wondering if it was possible to only track your character instead of everyone? I know there is an option to view tracked NPCs or yourself, but I'm not sure if that stops it from scanning everyone. The reason I ask is to cut down on the constant scanning of NPCs that might cause issues with heavily modded games. If that isn't possible no worries! Thank you for the great mod Narue!

Posted
7 minutes ago, toucheeee said:

Hello, I was wondering if it was possible to only track your character instead of everyone? I know there is an option to view tracked NPCs or yourself, but I'm not sure if that stops it from scanning everyone. The reason I ask is to cut down on the constant scanning of NPCs that might cause issues with heavily modded games. If that isn't possible no worries! Thank you for the great mod Narue!

Possible, yes. Practical, not really, because it requires a fundamental redesign and would eliminate a great many features. Not that I haven't been seriously considering such a redesign as well as a pared down lite version... Just because something isn't practical doesn't mean I won't do it. :P

 

And to clarify, the cell scan still runs even if you have the player only option enabled. It's more of a filter than a way to avoid the cell scan. However, I've tested with heavy load orders and very rarely experience game breaking issues. Usually those issues come up in things like the civil war or the Miraak fight (two places I like to do stress testing) where the scripted events don't occur properly and you get a soft lock, but I haven't been able to identify Fertility Mode as the culprit in those cases. With a heavy load order, even disabling Fertility Mode temporarily prior to the event still wouldn't fix the intermittent soft lock.

 

Have you experienced issues in a heavily modded game? If so, please let me know when and where so I can add that to my testing spreadsheet. :)

Posted
12 minutes ago, Narue said:

Possible, yes. Practical, not really, because it requires a fundamental redesign and would eliminate a great many features. Not that I haven't been seriously considering such a redesign as well as a pared down lite version... Just because something isn't practical doesn't mean I won't do it. :P

 

And to clarify, the cell scan still runs even if you have the player only option enabled. It's more of a filter than a way to avoid the cell scan. However, I've tested with heavy load orders and very rarely experience game breaking issues. Usually those issues come up in things like the civil war or the Miraak fight (two places I like to do stress testing) where the scripted events don't occur properly and you get a soft lock, but I haven't been able to identify Fertility Mode as the culprit in those cases. With a heavy load order, even disabling Fertility Mode temporarily prior to the event still wouldn't fix the intermittent soft lock.

 

Have you experienced issues in a heavily modded game? If so, please let me know when and where so I can add that to my testing spreadsheet. :)

Thank you for the reply! I haven't personally experienced any issues yet (haven't gotten through a long play through because I have the million alt character curse), it just seems to be the consensus from everyone I talk to that having something constantly scanning in a script heavy list will cause problems in the long term with save corruption. I'm going to do a dedicated play through soon and if I hit any walls I'll let you know. If you do a "lite" version as well I'll be sure to pick that up too! I appreciate your time!

Posted
1 hour ago, DremoraDream said:

Is this still compatible with SLSO (Sexlab Separate Orgasm)

It should be, yes.

Posted

I'm having an issue where the baby item is not spawning into a child. I have a Heartfire compatible housing already blessed and ready to go, not in the same cell, and its been over 24 hrs in game over the day limit on growth (10 days for child from baby, I'm at nearly 12) so I know something is wrong. Running on SE, any ideas?

 

Edit: Hey @Narue I just noticed that my version is 2.7 but haven't gotten a notice on any updates here, but I saw the Nexus has a 3.x build- is this thread not up to date? Or can you direct me to the correct file (the downloads are... just strings of #s XD)

Posted
6 minutes ago, DJShamrock said:

I'm having an issue where the baby item is not spawning into a child. I have a Heartfire compatible housing already blessed and ready to go, not in the same cell, and its been over 24 hrs in game over the day limit on growth (10 days for child from baby, I'm at nearly 12) so I know something is wrong. Running on SE, any ideas?

 

Edit: Hey @Narue I just noticed that my version is 2.7 but haven't gotten a notice on any updates here, but I saw the Nexus has a 3.x build- is this thread not up to date? Or can you direct me to the correct file (the downloads are... just strings of #s XD)

The package is now slightly too large to host directly on LL. :( So I simply link to the Nexus and only host it there. One of the "features" I added recently was a notification message of why baby growth failed, IIRC that was added in version 2.9.1. That may help identify your problem if you're okay with cleaning your save or starting a new game. A 2.7 to 2.9.1 upgrade should be fine, but 3.0 definitely requires a clean save.

Posted
1 minute ago, Narue said:

The package is now slightly too large to host directly on LL. :( So I simply link to the Nexus and only host it there. One of the "features" I added recently was a notification message of why baby growth failed, IIRC that was added in version 2.9.1. That may help identify your problem if you're okay with cleaning your save or starting a new game. A 2.7 to 2.9.1 upgrade should be fine, but 3.0 definitely requires a clean save.

Should I upgrade to 2.9.1 first or is it ok to go straight to latest version assuming I clean the save?

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...