View Full Version : How to Make Social Mods
9th Dec 2006, 09:27 AM
How To Make a Conflict-Free Social mod:
It's one thing to make an object that changes how a sim interacts with it, it's quite another for an object to change how sims interact with each other (or with themselves).
You could change the Pie Menu Functions for the Person Globals object (which I actually did once upon a time), but this can cause conflicts with other mods and will definitely cause problems with future EPs.
Fortunately, you can also do this via the "Social Plug In". Simply by creating an object that has this category, you can add interactions between sims.
To create your own social object, clone the SocialDownloadTest (0x7FB44ED9), and change the Hug behavior to whatever social your object performs.
Macrotastics is a good example of a mod that uses this feature, albeit that mod only changes a sim's self-interactions. Social objects you create this way can change the way a sim interacts with any sim.
Object trees (functions):
CT - Object Menu(person, mode)
To test whether a particular group of interactions should occur between the Me person and the person indicated in the parameter, the above function is used to check the conditions that permit these actions, then add the interaction strings when appropriate. The mode specifies whether the interactions are autonomous (1 = yes, 0 = no).
CT - Object Menu Command(person, index)
To perform an interaction, the above function is used. The interaction to be performed is between the Me person and the person indicated in the parameter. The index shows which particular function is being selected.
The above was originally posted on Variousimmers Forum (July 16th, 2005).
9th Jan 2007, 09:18 PM
Forgive my possibly stupid questions (I would like some clarification whether or not this is in fact what I am looking for), but is this how I would make my own custom interaction between two Sims via an object?
(In other words: If I had an object where Sim A goes to the object and goes through a loop of animations until certain motives reach certain levels, I could click--either on the object or on Sim B--and have Sim B join Sim A who then do something together?)
From my clone of the SocialDownloadTest, I just change and export the "CT - Object Menu" and "CT - Object Menu Command" BHAVs and insert them into my object? Then I just make Pie Menus for the interaction? I can't help but feel I'm wrong, because it sounds a little too easy. :)
So, I would have a BHAV "CT - Object Menu(Sim B, 0)"
and another called "CT - Object Menu Command(Sim B, Name of my Custom BHAV for the Interaction?)"? Or is the "CT - Object Menu Command(person, index)" BHAV the actual BHAV for the interaction between two Sims via the object?
11th Jan 2007, 10:50 AM
If you already have an object which isn't a Social, then you have no need to clone the SocialDownloadTest. Simply make that interaction part of your existing object.
11th Jan 2007, 05:16 PM
Errr...okay. I had a feeling I was doing something wrong. :lol:
But, I think this has given me a push in the right direction towards what I am trying to do since it showed me how to alter Pie Menus via BHAVs. Thank you. :)
17th Sep 2007, 01:15 AM
Would it be the tutorial I am looking for ?...I would like to add " join casual group" for toddlers...so they can go shopping with their parents, or go to any outing...
17th Oct 2007, 05:08 AM
so this would allow me to, oh say, make a mod for OFB so sims can't quit?
17th Oct 2007, 07:39 AM
The basic upshot of this is that it lets you modify the sim menu without having to change the personglobal TTAB/TTAs (which is what you would have to do otherwise).
For the mentally challenged, this means the menu you get when you click on a sim. :P
4th Apr 2008, 03:25 AM
Does this still work? I've tired it for hours, many ways, to the best I can understand but no new menu. Or is that even what I'm looking for? Please help.
4th Apr 2008, 03:36 AM
Yep, still works. If you can post your object someone here can take a look. :)
4th Apr 2008, 06:42 AM
When you post you have the option to add attachments. Just do it there. I wouldn't stress about it being posted, the number of people who even make it into this forum is pretty low, and even fewer would go to the trouble of actually opening a file which doesn't work. :) But once it's fixed, you can always edit the post and remove the attachment, if you so desire!
4th Apr 2008, 10:30 AM
Okay, try this:
- Open the objd file
- Find the "Obj. Type" field
- Change that to "SimType"
- Commit, save, and try in game.
I can't test it at the moment, but I have a feeling that might get it working. :)
Lady of Ravens
2nd May 2008, 05:15 AM
I'm fairly new at modding on sims 2 (though not new to modding or programming in general), and I'm having trouble with my current project, which is to create a few basic spells that sims can cast. I'm using the social download test object as suggested in this thread, but I can't get it to show up. Despite hours of trying different things and looking at mods which do similar things, I've been unable to get the new command to appear on a sim's pie menu.
So, I'd like some help looking over my mod file, and maybe answers to a couple of questions that I've been trying to figure out.
First, I've noticed that temp 0x0000 is always set right before the add/change action string command, but I can't figure out why (though it does seem to be set with a number corresponding to the text of the add/change action string command being added). How is this useful/necessary?
Secondly, both of the other mods I've examined have SLOT files, but it seems empty. I added such a file to my mod to see if it's lack was my problem, but it didn't seem to help. Is there any reason to have a SLOT file in a mod of this nature?
Thanks for your help.
9th May 2008, 02:17 AM
Hoping to see answers on this one myself since I seemed to end up back trying this and having similar issues.
Hopefully we'll get more information soon.
19th May 2008, 08:55 AM
With this method, what happens about settings that would usually appear in a TTAB, such as the ticks for which types of sims can use the interation - eg "visitors". What I am getting at is, is the interaction considered automatically eligible to *all* sims unless you restrict it in the test BHAV? What about attenuation also?
JokersWild and Lady of Ravens, I don't think this type of object would want SLOTs because it's not an object the sims use like a bathtub or coffee maker. It's an abstract object just used for carrying some code.
Also in addition to Echo's advice about setting to "Sim Type" in OBJD, there is another field on the Raw Data tab, "Is global sim object", which needs to be set to value 1
19th May 2008, 11:11 AM
First, I've noticed that temp 0x0000 is always set right before the add/change action string command, but I can't figure out whyBecause value of Temp0 is get passed to the interaction bhav, as Param1 (sorry, was MISTAKE here - Param0 is stack object, Param1 is Temp0 :(). I'm not sure if it's applicable for social mods, but when you are using it in normal objects, it's handy to be able to pass different params.
Your mod probably doesn't work because it is not set as global object (thus noone loads it, thus its functions never executed).
It's not mentioned in the title post somehow, but it was mentioned somewhere else - here (http://www.modthesims2.com/showpost.php?p=1483023&postcount=39) - that you need to make 2 changes to the clone: first, change type to SimType (you did it), second, set it to be a global object (you didn't it).
19th May 2008, 07:42 PM
Bleah my interaction shows up on the menu ok, but it never makes it as far as the sim's queue after clicking it :(
20th May 2008, 12:20 AM
Inge - is the "CT - Object Menu Command(person, index)" being called at all?
20th May 2008, 08:09 AM
I don't think so, because for testing purposes I made the first line of it return error, but no error is occurring. The test BHAV is definitely running, because the option appears and disappears in line with the test condition.
20th May 2008, 01:21 PM
You're changing the SO ID to the target Sim, but you're not changing it back again before you run the "add/change". I have a feeling you need to do that, so that it knows which object to run the "CT - Object Menu Command" on... But I'm not certain, and too short of time to test. :) Worth a try though?
20th May 2008, 03:13 PM
Ok I'll try that, thanks.
21st May 2008, 03:10 AM
Inge Jones, actually the slots wasn't on my list of issues but thanks a ton for the second setting in RAW data information, that seemed to fix the menu showing problem for me.
Now I can move on to other puzzles and mysteries of package making.
21st May 2008, 08:58 AM
Echo, thank you! That was it :)
21st May 2008, 11:19 AM
22nd May 2008, 12:35 AM
Can't seem to get the autonomous turned off. Can someone point out exactly where the mode change in CT Object Menu for autonomous is?
22nd May 2008, 01:28 AM
First line should be something like:
Expression (param 0x1 == 0x0)
then make the false target of that point to false.
22nd May 2008, 03:00 AM
I've edited this post that was asking for help because, I'm guessing this thread has died yet again. Thanks for the information that was shared here. Have a good day. :D
5th Jun 2009, 06:29 AM
I've been looking for a mod that would change the invite list for parties but since I can't find it, I was going to make it myself. I read the tutorial for "BHAVs" and Semi-Globals but I can't find the globals to control the party invite list. I want the list to include ALL Sims acquainted with my household who have a daily relationship rating over 50. Any suggestions?
vBulletin v3.0.14, Copyright ©2000-2013, Jelsoft Enterprises Ltd.