More Awesome Than You!
Welcome, Guest. Please login or register.
2024 December 23, 00:04:05

Login with username, password and session length
Search:     Advanced search
540287 Posts in 18067 Topics by 6546 Members
Latest Member: choodno
* Home Help Search Login Register
+  More Awesome Than You!
|-+  Ye Olde Simmes 2 Archives: Dead Creators
| |-+  Ye Olde Syberspunke Archives (Moderator: syberspunk)
| | |-+  Reduced % Chance for Pregnancy
0 Members and 1 Chinese Bot are viewing this topic. « previous next »
Pages: [1] THANKS THIS IS GREAT Print
Author Topic: Reduced % Chance for Pregnancy  (Read 13017 times)
syberspunk
Heretic
Moderator
**
Posts: 2365


ISTJ - what a crazy random happenstance


View Profile WWW
Reduced % Chance for Pregnancy
« on: 2008 September 22, 06:54:19 »
THANKS THIS IS GREAT


Reduced Pregnancy Hack v1.0 for TS2NL v1.0p1
Made by: syberspunk


This hack reduces the chance of pregnancy by HALF the regular % for "Try for Baby" interaction.

NOTE: If you use this hack, it ALWAYS reduces the chance by HALF of whatever % chance is passed to the "Pregnant - Try to Get Pregnant" BHAV. Essentially this is a sligth rewriting of kzlyh1947's random 15% chance pregnancy hack. The only difference is that the % is not hardcoded into that BHAV. In other words, for those of you who use the RanPreg1_0xEC17C4.package hack, pregnancy will ALWAYS have a 15% chance. If you used sweatm's older version of Risky Woohoo together with the random 15% chance (which is what I had been doing but did not realize they conflicted until I actually looked at the code myself), theoretically, regardless of whatever % values were set in Risky Woohoo, it would always use 15% (or whatever value you used, if you changed that value yourself). This is because that value was hardcoded into the random 15% chance pregnancy hack. Basically I changed it so it simply reduces the value of whatever gets passed into that BHAV by half, instead of always using that value.

:!!: Compatibility Notice: If you are using TwoJeffs' Preg for All Genders mod, you MUST use the zzreducedchancepreghackPreg4All version!

Instructions on how to change the value of reduction using SimPE

1. Open the hack using SimPE

2. In the resource window, click on the single line:
   "Behavior Function: Pregnancy - Try To Get Pregnant"

3. Click on the "Plugin" view tab (should be already visible with default layout)

4. In the "Behaviour Editor" window, click on line 1:

[prim 0x0002] Expression (Param 0x0002 /= Literal 0x0002) true: 2 false: FFFD

It should highlight as blue.

5. In the "Instruction Settings" box, look at the values for the Operands field.

The top row is as follows:

02 00 02 00 00 07 09 07
      ^^

NOTE: ONLY change the 3rd box!!! This is the value that the % change will be reduced (DIVIDED) by. DO NOT USE 0!!! This will cause ERRORS!

A valid value can be anything from 1 to 100 decimal (01-64 Hex). You can use a simple calculator (even the Windows XP calculator) to convert a decimal value to its HEX value.

The Operands field ONLY takes HEX values!!! Keep this in mind as 64 does NOT mean 64, it means 100!!!

If you use 100 or greater, this greatly reduces the chances of getting pregnant, essentially setting it to 0 chance (i.e. your sims will most likely NEVER get pregnant)!

The greater the number you use, your Sims will have a much more REDUCED or LOWER chance of getting pregnant!

6. Once you are satisfied with your choice, click on the Commit File button.

7. Click on the "Save" button OR Go to "File" in the menu, and then "Save" to OVERWRITE the hack.

Alternatively, you can choose to "Save As" and name the file whatever you want
(e.g. YOURNAME_reducedchancepreghack.package").

However, you should MOVE or BACKUP the original file somewhere else on your computer.
DO NOT keep BOTH files in your Downloads directory!!!
(It is most likely harmless, but you may not observe expected behaviour - i.e. your changes may not take effect).

* reducedchancepreghack.zip (2.52 KB - downloaded 668 times.)
Logged

syberspunk
Heretic
Moderator
**
Posts: 2365


ISTJ - what a crazy random happenstance


View Profile WWW
Re: Reduced % Chance for Pregnancy
« Reply #1 on: 2008 September 22, 06:54:31 »
THANKS THIS IS GREAT

RESERVED
Logged

Emma
Goopy Lover
Dead Member
*
Posts: 6109


All Pescados Suck.


View Profile WWW
Re: Reduced % Chance for Pregnancy
« Reply #2 on: 2008 September 22, 12:34:11 »
THANKS THIS IS GREAT

So, this is okay to use with Risky Woohoo? I hope so. I am sick of a guaranteed babby being formed when 'try for baby' is selected.

*Emma presses 'thanks' button.
Logged

syberspunk
Heretic
Moderator
**
Posts: 2365


ISTJ - what a crazy random happenstance


View Profile WWW
Re: Reduced % Chance for Pregnancy
« Reply #3 on: 2008 September 23, 01:07:47 »
THANKS THIS IS GREAT

Yes, I designed this purposefully to work together with the risky woohoo hacks.  FYI - as it states in the rtfm, this reduces all chance of pregnancy.  It basically modifies the BHAV function that attempts to get the sim pregnant.  This function is like the global/base/root function that gets called for any type of "Try for Baby" interaction.  The % chance that is passed to the function is typically set in the individual BCON (constant) values of the calling interaction.

This mod just divides whatever number that is passed to it, by 2, essentially reducing the chance by half.

The risky woohoo mods insert a call to this mod, and passes whatever value I sorta arbitrarily set.  In most cases, I picked half of what the "Try for Baby" option does (i.e. if the "Try for Baby" option had a 60% chance, then I set the the "Woohoo" option to have a 30% chance).  When combined with this hack, both of those chances get halved ("Try for Baby" becomes 30% and "Woohoo" becomes ~ 15%).  The original mod from MTS2 had a hard coded value so the % chance was the same for every option, so you couldn't use the hack with any risky woohoo mod.

Anyways, you can follow the instructions if you want to change that value, instead of dividing by 2, put whatever you want.  You can also customize the BCON values of the Risky Woohoo mods.  I'm pretty sure I went and put labels on the values so you know which ones to change. Smiley


Ste
Logged

Emma
Goopy Lover
Dead Member
*
Posts: 6109


All Pescados Suck.


View Profile WWW
Re: Reduced % Chance for Pregnancy
« Reply #4 on: 2008 September 23, 05:49:39 »
THANKS THIS IS GREAT

No, the values are fine just as you did them, Ste Wink I looked at the file and have it stashed away for future reference just in case, but I think I will be happy with this. Thanks again. Grin

[edit] This works really great, it took my couple about a sim week to get pregnant Grin Excellent!
« Last Edit: 2008 September 30, 09:45:37 by Emma » Logged

Pages: [1] Print 
« previous next »
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines Valid XHTML 1.0! Valid CSS!
Page created in 0.05 seconds with 20 queries.