MTS has all free content, all the time. Find out how YOU can help to keep it running. Tell me how...

Autonomous gift giving at parties

by kestrellyn Posted 26th Jun 2020 at 11:00 PM - Updated 6th Sep 2021 at 3:42 AM by kestrellyn
44 Comments / replies (Who?) - 16 Feedback Posts, 4 Thanks Posts
  • Added new versions of the social object
  • Fixed problem where gift-giving would interrupt weddings. You will need to use the base game wedding arch for it to work properly.
  • Fixed problem where the active family was charged for all the gifts.

This hack was originally released for a Secret Santa that happened over a year ago, as a gift for Sunrader, who's been helpful with testing since then. I finally polished it up for general release.

Basically: this hack allows sims to autonomously give each other gifts during parties. They will not actually give each other things from their inventories, they will actually purchase a totally new object and give it to the other sim. You can have birthday party style giving, where everyone give gifts to a particular sim, or Christmas party style giving, where everyone gives gifts to everyone else. Moreover, positively received gifts will increase the party score! Rejected gifts will naturally decrease the party score. The whole hack is highly configurable (because that was something Sunrader originally wanted). Details follow.

There are three packages that you need for this hack - the social plugin, the social object, and the controller.

The Social Interaction

This involves a totally new social interaction called Give Party Gift, which is only available during parties. It does require Seasons, however, because the gift box accessory used in the animation is a Seasons object (and the animation itself may require Seasons, too). As such, the success of the social interaction can be customized separately from the regular Give Gift interaction from Seasons. If you open the social object package in SimPE, you will see a BCON called "Gift Accept/Reject Tuning (Modify this one)", which you can modify to change when gifts are accepted or rejected. There are two possible acceptance results - a "good" accept where the sim enthusiastically accepts the gift, and a "meh" accept where they're fairly neutral. There are thresholds of STR, LTR and playfulness for "good" and "meh" accepts - basically, the "good" accept will happen if the sims meet any of the three requirements for it, the "meh" accept will happen if the sim doesn't meet those requirements but does meet at least one of the requirements for the "meh" accept, and a rejection will happen otherwise. Note that for the playfulness requirements the value in the BCON is 100 times the number of playful points, so 800 in the BCON means 8 playful.

When this social interaction is accepted, the game will randomly choose an object from a gift list, charge the giver for it, and put it in the receiver's inventory. Which list is used is chosen by a dialog that you will get at the beginning of the party. These lists are also BCONs in the social object, named starting with "Gift GUIDs", which can be modified. They look like this:

The first line is the number of GUIDs. It's very important that you remember this line, and if you edit the BCON, be sure to update it. An easy way to tell how many GUIDs there are is to take the (decimal) line number of the last line of the BCON and divide it by 2. After that, each GUID is entered on two lines - the first contains the last four digits of the GUID, and the second line contains the first four digits of the GUID. There are also labels for these three lists - the first line is labeled with the in-game name of the object, and the second line is labeled with its EP or SP requirement. Note that if you delete a line of the BCON, the corresponding line of the labels will NOT be deleted, so you will have to go do that separately. There should also not be any blank/0 lines in these BCONs.

There are three versions of the social object: partygiftssocialobject-AllEPs contains GUIDs from all EPs and SPs, including two from the EA Store, and obviously requires either the UC or every EP/SP plus the two EA Store baby toys (which I believe you can download from MATY). partygiftssocialobject-BaseGame contains only objects from the base game, although it still requires Seasons to actually work. partygiftssocialobject-AL also contains only base game objects, but should be used if you also have AL installed. If you have some other combination of EPs and SPs, you can download just the Base Game package (or the AL package if one of the EPs you have is AL), or download both and create custom gift lists with just the items that are actually in your game. You can also add any CC objects you want to these lists, or swap them out for entirely different lists as long as they are formatted the same way. If you want to make some objects more frequent as gifts than other objects, you can add them to the list(s) multiple times.

By default, the lists for Deco and Baby and Child contain only objects that cost up to 500 simoleons, and the Housewares list contains only object that cost up to 1000. If you change this, you will probably also want to change the minimum amount of money that sims need to have in order to give gifts off of that gift list. This is recorded in two places: 1) in the social plugin package there is a BCON you can edit called "Max possible gift price" (one line per gift list) and in the controller package there is a similar BCON called "Maximum gift cost" (similarly one line per gift list). This is the amount of money the sim has to have in order to give a gift, and it should be at least the actual maximum cost of gifts on the list.

If there's an error in a gift list, either one that you introduced by editing it or one that I introduced when I manually entered ~300 GUIDs into SimPE, you won't get an error or a reset, you'll instead get a notification in the upper right. If the game just couldn't create an object with the specified GUID, the notification will tell you the (decimal) line number of the first line (second part) of the GUID, followed by the actual values that are recorded for that object, second part then first part. These latter values will also be in decimal, so you will have to convert them to hex to see what they are in SimPE. If the sim coudn't afford the gift because you set the maximum gift cost too low, you will get a notification telling you where to set that.

The Controller and the Gift Recpient

You will get a second dialog when you start a party, after being asked to choose the gift list, which will ask if you want autonomous gift giving at all. The first option ("Yes, to everyone") will cause all sims on the lot to give gifts completely autonomously to anyone else on the lot. (Note: I've had trouble with this mode on my new computer, although it worked fine on my old Windows 7 computer and Sunrader reports that it works for them. So YMMV.) The third option ("No") will turn off autonomy completely, although the interaction will still be available if you, the player, want to use it. The second option ("Yes, to a designated gift recipient") will ask you to choose a gift recipient and will then cause the controller to run a script which will direct every family member and greeted or invited guest to give one gift to your designated gift recipient (not all at once; they will take turns). In this mode, the controller will interrupt your commands when it is that sims's time to give their gift. It should take a break if the gift recipient has low critical motives, is trying to satisfy critical motives, or is doing something party-critical like getting married or growing up. If the gift recipient leaves the lot during the party, or is off-lot at the time the party starts, gift-giving should resume after they return.

The "critical motives" are bladder, hunger, and energy and you can configure what "low" means by editing the BCON in the controller package called "Minumum motvies for gift recipient". Note that motives in the game actually go from -100 to positive 100, so the setting of -50 means when the bar is 1/4 full.

You can also modify the effects that given gifts have on the party score, by modifying the BCON called "Party scores for gifts" in the controller. There are different values for "good" gifts, "meh" gifts, and rejected gifts. These are scaled by the number of people at the party - the way it works is that if every person at the party gives one "good" gift, the party score will be modified by the "good" gift score times 10, and if every person at the party gives a "meh" gift, the party score is modified by the "meh" gift score times 10, etc. So, the more people there are at the party, the smaller an effect each individual gift has. A roof raiser party is achieved at a score of 175; by default the settings are 10 for a "good" gift, 5 for a "meh" gift, and -5 for a rejected gift. Note that these have effect regardless of whether the gift was given autonomously, or by you, or as part of the controller's script.

There are two versions of the controller: partygiftscontroller-AL is what you need if you have Apartment Life, and partygiftscontroller-Seasons is what you need if you don't have Apartment Life.

Game Compatibility

This hack requires Seasons. Otherwise, you will just need to get the correct social object and controller packages.

Hack Compatibility

This might conflict with hacks that change what happens at the beginning and end of parties, or hacks that change how party score is calculated. It does conflict with simler90's New Parties mod - I thought about making a compatible version for that, but I suspect that simler is going to continue updating that mod to add more and more new parties, and it will be hard to tell if they modify the main part that conflicts with this one (which is the party score calculation), so it will be hard for me to keep that compatible version up to date. I'd be happy to help them make their mod compatible, though, since I don't plan to change the party score calculation of this mod ever again.

Specifically, this mod modified BHAVs 0x1002, 0x1005, and 0x101D in group 0x7FB4DF10, as well as adding a new BCON 0x1010 to that group.

Additional Credits:
Sunrader, for testing

You must have the expansion or stuff packs listed below installed to use this custom content. Please see the post text for any exceptions.

Sims 2 Seasons

This is a multi-part download:

Download one social object, one controller, and the social plugin.
Key: - File was updated after upload was posted
Filename - Tip: You can click the magnifying glass to see the archive contents Size Downloads Date | Social object with basegame objects, for use without AL

Size: 7.3 KB · Downloads: 214 · 6th Sep 2021
7.3 KB 214 6th Sep 2021 | Social object with basegame objects, requires AL

Size: 7.3 KB · Downloads: 250 · 6th Sep 2021
7.3 KB 250 6th Sep 2021 | Social object with objects from all EPs and SPs - requires AL

Size: 13.1 KB · Downloads: 1,327 · 6th Sep 2021
13.1 KB 1,327 6th Sep 2021 | Controller for use with AL

Size: 3.1 KB · Downloads: 1,031 · 28th Aug 2021
3.1 KB 1,031 28th Aug 2021 | Controller for use without AL

Size: 3.1 KB · Downloads: 318 · 28th Aug 2021
3.1 KB 318 28th Aug 2021 | Social plugin

Size: 944 Bytes · Downloads: 1,007 · 26th Jun 2020
944 Bytes 1,007 26th Jun 2020
Don't forget to Thank the creator after downloading! Use the Thanks button located above the screenshots above.
Basic Download and Install Instructions:

1. Download: Click the download link to save the .rar or .zip file(s) to your computer.

2. Extract the zip, rar, or 7z file.

3. Place in Downloads Folder: Cut and paste the .package file(s) into your Downloads folder:
  • Origin (Ultimate Collection): Users\(Current User Account)\Documents\EA Games\The Sims™ 2 Ultimate Collection\Downloads\
  • Non-Origin, Windows Vista/7/8/10: Users\(Current User Account)\Documents\EA Games\The Sims 2\Downloads\
  • Non-Origin, Windows XP: Documents and Settings\(Current User Account)\My Documents\EA Games\The Sims 2\Downloads\
  • Mac: Users\(Current User Account)\Documents\EA Games\The Sims 2\Downloads
  • Mac x64: /Library/Containers/com.aspyr.sims2.appstore/Data/Library/Application Support/Aspyr/The Sims 2/Downloads
Need more information?
44 Comments / Replies (Who?) - 24 Feedback Posts, 19 Thanks Posts
Hide Thanks Posts for this thread (Show only feedback)
Page 2 of 2
Test Subject
#26 Old 28th Nov 2020 at 12:20 AM
Yes, now everything seems fine. Thank you. You're amazing!
Lab Assistant
#27 Old 3rd Dec 2020 at 11:35 PM
What's your advice for those of us using Simler90's New Parties mod in the mean time? Have you sent Simler90 a private message about making your mods compatible? I'd really love to use both.
Original Poster
#28 Old 4th Dec 2020 at 6:43 AM
Simler seems impossible to contact most of the time, but I guess I could try. The advice currently is that they are not compatible. If you use both and load new parties last, the party gifts controller will never get cleaned up and gifts won't count towards party score. From looking at simler's code, if you load this mod last you won't get simler's party score modifications (which based on the description will affect the bonfire party and the slumber party) and no one will give money at the end of the campaign fundraiser, and possibly it won't have an effect on your sim's career.

I might make a compatible version eventually, I don't think New Parties has been updated in a while.
Lab Assistant
#29 Old 4th Dec 2020 at 10:22 PM
Thanks for getting back to me! Simler90 does seem to ignore most comments and messages but I asked MidgeTheTree over on Tumblr and she says that Simler has either gotten back to her or acted upon feedback shes given in direct messages on here - maybe they listen to respectable modders such as yourself and ignore us peasants lol! You probably have the best shot of getting through to them.

I'm really sad to hear they can't work together at all at the moment. I'd really really love a compatible version, but I do understand it would be difficult/frustrating if New Parties then got updated further. Good luck and thanks in advance if you do decide to tackle a compatible version
#30 Old 27th Aug 2021 at 4:39 AM
I threw a wedding party last night and there were about 10 guests. Well, I made the bride the designated gift receiver, and she actually couldn't get married because the interaction overrode the interaction to get married. This kept happening over and over again, until the time was up and the party had a low score because nobody had gotten married! I exited the game and didn't save. Then I tried making her maid the designated receiver, but she got trapped on the stairs and then hardly anyone watched the wedding outside! I really like the mod, so do you have any tips about how I can use it with large weddings? Because something just isn't working!
Original Poster
#31 Old 27th Aug 2021 at 5:20 AM
It should quit if she is trying to get married. Was she using the standard wedding arch, or a custom one? Was it her current interaction, or was it queued after something else?

There's not really a lot I can do about sims getting trapped on the stairs, but if you queue up an interaction that satisfies hunger or involves the bathroom in any way the controller will stop - you can then queue an interaction to go somewhere else and cancel the first one. I think that should work.
#32 Old 27th Aug 2021 at 7:48 PM
Originally Posted by kestrellyn
It should quit if she is trying to get married. Was she using the standard wedding arch, or a custom one? Was it her current interaction, or was it queued after something else?

There's not really a lot I can do about sims getting trapped on the stairs, but if you queue up an interaction that satisfies hunger or involves the bathroom in any way the controller will stop - you can then queue an interaction to go somewhere else and cancel the first one. I think that should work.

Thanks for responding so quickly! At first, I used a custom wedding arch. Then I deleted it and trying just the regular basegame arch, but with both I had the same issues. When I played the maid I tried having her go to the bathroom, and the action did stop, but it happened all over again when another sim tried to give a gift. It basically interrupted whatever I tried to do, and since there was a fair amount of guests at the party, this was excessive. I'm going to stick your files into my game again and see if I can find any conflicts again, but I didn't before so I don't really know what the issue is.
Original Poster
#33 Old 27th Aug 2021 at 8:07 PM
So you're saying the get married interaction is the first interaction in the queue and it still pushes the interaction?
Original Poster
#34 Old 28th Aug 2021 at 1:08 AM
Ok, after some experimentation, I'm not sure why my original attempt didn't work, but I did find a way to make it so that all gift-giving stops if there is a wedding happening anywhere on the lot. That means that if you make the gift recipient a person who isn't getting married, guests will still stop giving gifts and go watch the wedding. Just redownload the controller package. You will have to use the regular base game wedding arch, though. I noticed there also seems to be a wedding arch that possibly came with Celebration Stuff, maybe I will add it in there later too, but I don't think I can possibly hardcode the GUIDs of every CC wedding arch into this.

Also, in general it works to cancel the receive gift interaction and then queue an interaction that should block gift-giving, like eating or using the bathroom or getting married, etc. to stop gift-giving.
#35 Old 28th Aug 2021 at 7:13 PM
Yes, that's what I was saying. Getting married is blocked by getting a gift. Thank you for updating! I will use just the basegame arch from now on. I play a historical game so I can just use invisible recolors.
#36 Old 1st Sep 2021 at 5:43 PM
Just wanted to report back to you that this worked. The guests stopped giving and my couple was able to get married with no issues. Then the gifts resumed again after the ceremony. Thank you for the fix!
Test Subject
#37 Old 5th Sep 2021 at 4:02 PM
Default The recipient is charged for the gifts
Hi @kestrellyn,
first of all, the mod is really great, now parties like wedding, anniversaries, and birthdays are like in real life, especially when a poor sim invites wealthier family members! But I have a problem with the present charging, when my sim receives a gift they are charged for the present, not the giver (and I am talking about givers outside of my active family). I am using the newest versions of partygiftscontroller-AL, partygiftssocialobject-AL and partygiftssocialplugin. I checked my download folder with HDCU but it doesn't shows any conflicts with your mods, and I don't use any party changing mods so I am a little bit clueless why its happening. Thank you for your time, your mod is great!
Original Poster
#38 Old 6th Sep 2021 at 3:43 AM
Oh, that's fun, I guess that function doesn't actually do what EA said it does. Should be fixed now, redownload the social object package.
Test Subject
#39 Old 6th Sep 2021 at 4:30 PM
Thank you so much for the quick fix, it's working now perfectly
Test Subject
#40 Old 26th Sep 2021 at 3:49 PM
this hack is amazing, but i am having serious troubles with graduation parties. if i try throwing one, i get the regular dialog asking me for the gift list and who should be the recipient. the party starts, however at approximately 4.46 time left for the party, i get the same dialog a second time and the timer stops. if i click on the phone, i see the option to throw the party again, so it basically ended (no dialog, no bad memories come from this). this has only happened with graduation parties. has anybody experienced this?
Original Poster
#41 Old 26th Sep 2021 at 5:29 PM
Do you have debug mode turned on?
Test Subject
#42 Old 27th Sep 2021 at 5:30 PM
Originally Posted by kestrellyn
Do you have debug mode turned on?

Yeah, this is the message I get.
Original Poster
#43 Old 28th Sep 2021 at 12:33 AM
Can you post the actual error log?
Test Subject
#44 Old 2nd Oct 2021 at 4:20 PM
where do i find it?
Original Poster
#45 Old 3rd Oct 2021 at 2:47 AM
It gave you the file location in the pop-up.
Page 2 of 2