Pregnancy Doc
Pregnancy is split into different sections of JavaScript
- storyFunctions.js - Functions that are used in scenes, related to player or npc pregnancies
- childrenStoryFunctions.js - Functions that are used in scenes, related to either player's or npc's children
- pregnancyTypes.js - Generates a pregnancy object to be used to start a new pregnancy
- pregnancy.js - Functions that start, progress and end existing non-parasite pregnancies
- parasite.js - Functions that start, progress and end existing parasite pregnancies
Important References
Please take these into consideration before changing any of the code.
- When referring to player character in the code, the string
"pc"
should be used in a similar way that"Robin"
could be used for named NPCs. These are case sensitive. - Search this doc for
Requires update to add new species
when looking to add a new pregnancy species. - Search this doc for
Requires update to add new locations
when looking to add a place for children to go.
storyFunctions.js Usage
Player Functions
getPregnancyObject(mother, returnGenital)
Will return the pregnancy object of the mother for either the pc for named npc's.
<<set _playerPregnancyObject to getPregnancyObject()>>
<<set [_pregnancyObject, _genital] to getPregnancyObject("pc", true)>>
<<set _robinPregnancyObject to getPregnancyObject("Robin")>>
playerIsPregnant()
Will return true
if the player is pregnant with a non-parasite.
<<if playerIsPregnant()>>
playerAwareTheyCanBePregnant()
Will return true
if the player knows they can become pregnant. Used specifically for male pregnancy.
<<if playerAwareTheyCanBePregnant()>>
playerAwareTheyArePregnant()
Will return true
if the player knows they are pregnant.
<<if playerAwareTheyArePregnant()>>
playerPregnancyProgress(percent)
Will return between 0.00 and 1.00 based on how far the players pregnancy is. Providing false, will return the raw value, tho not expected to be used this way normally.
<<if playerPregnancyProgress() gte 0.5>>
<<if between(playerPregnancyProgress(), 0.1, 0.4)>>
playerNormalPregnancyTotal()
Will return the number of times the pc has gotten pregnant.
<<set _pregnancyCount to playerNormalPregnancyTotal()>>
<<if playerNormalPregnancyTotal() gte 5>>
playerBellySize(pregnancyOnly)
Will return the players belly size, ranges from 0 to 24. Include true to make it pregnancy specific.
<<set _bellySize to playerBellySize()>>
<<set _bellySizeFromPregnancy to playerBellySize(true)>>
<<if playerBellySize(true)>>
playerBellyVisible(pregnancyOnly)
Will return true
if the player's belly is visible. Include true to make it pregnancy specific.
<<if playerBellyVisible()>>
<<if playerBellyVisible(true)>>
isPlayerNonparasitePregnancyEnding()
Will return true
if the players non-parasite pregnancy is ending.
<<if isPlayerNonparasitePregnancyEnding()>>
playerNormalPregnancyType()
Will return the players pregnancy type as long as its not parasite
.
<<set _type to playerNormalPregnancyType()>>
<<if playerNormalPregnancyType() is "human">>
<<if playerNormalPregnancyType() isnot "wolf">>
wakingPregnancyEvent()
Will return a random event type relating to menstruation/pregnancy, look to the <<widget "wakingEffects">>
for usage.
dailyPregnancyEvent()
Will return a random event type relating to menstruation/pregnancy, look to the <<widget "pregnancyDailyEvent">>
for usage.
playerPregnancyRisk()
Will return the player current risk of pregnancy ranging from 0 to 6. 0 Being high chance of pregnancy, 6 being extremely low chance or zero chance depending on pregnancy type.
<<if playerPregnancyRisk() lte 1>>
playerHeatMinArousal()
Will return the minimum arousal increase from being in heat. Will only be above 0 if the player is able to get pregnant, at high risk of pregnancy, and current is not. Once the player is pregnant, if in heat, the values will say as if they are not pregnant, but at any point it stops, it will not start up again till the player is no longer pregnant. Fertility pills can cause a mild form to occur at any point outside of pregnancy. Minimum arousal is capped to 4000
for all sources.
<<if playerHeatMinArousal() gte 1000>>
playerAwareTheyAreInHeat()
A combination usage of playerHeatMinArousal() && playerAwareTheyCanBePregnant()
as male's may not yet be aware they can be pregnant.
<<if playerAwareTheyAreInHeat()>>
playerRutMinArousal()
Will return the minimum arousal increase from being in rut. Will only be above 0 if the player has a penis. The chance of rut occurring is random, but more likely the longer since the last time it occurred. Fertility pills can increase the frequency of rut occurring. Minimum arousal is capped to 4000
for all sources.
<<if playerHeatMinArousal() gte 1000>>
Named NPC Functions
npcIsPregnant(npc)
Will return true
if the named npc is pregnant.
<<if npcIsPregnant("Robin")>>
<<set _isPregnant to npcIsPregnant("Avery")>>
npcPregnancyEnding(npc)
Will return true
if the named npc pregnancy is ending.