Author Topic: What are Mods?  (Read 18836 times)

Offline Seabody

  • Global Moderator
  • Watcher
  • ******
  • Posts: 5071
What are Mods?
« on: December 02, 2013, 06:11:47 PM »
What are Mods?

Ever since the dawn of Sims, people have been drawn to make their own ways in the game. Anything is possible, within reason. Wherever someone wants to create something that is outside the reason, Mods come into play. If you find yourself asking, "just what are these Mods anyway", this post aims to reduce the confusion and explain Mods as best as possible.

So, what is a Mod?

The word "mods" is a contraction for "modifications". A mod is a file that, when placed inside a certain folder, will add in new features to the game. They can come in many shapes or sizes, but it's important to understand what Mods are before you get into using them.

Please note that you may hear people discussing Mods that involve editing files that end in .sgr or .ini. While these are Mods technically, we are going to keep this definition simple and in line with what the definition of Mods is on this forum.

So, for the purposes of this post, and the forum, a Mod is:
  • Something that goes into the folder Mods > Packages
  • Something that modifies the game in some way
  • And something that does not simply alter the appearance of, or add in new, objects. This is something else entirely (called "3rd party Custom Content" or, more simply "Custom Content" or "CC").



Different Kinds of Mods

There are two different kinds of Mods. Each has their own pros and cons, which we'll cover below. The two types of Mods are Tuning Mods and Script Mods.

Tuning Mods
Tuning Mods exist to allow Modders to alter minor details about the game, such as the length of time the Divine Meal buff lasts, or the chance a Unicorn will spawn, or the price of a Chun Co. Teppanyaki Grill.

XML Tuning Mods are arguably the simplest type of Mod.
They modify certain game values. Remember Algebra, from school; x+y=z. This also happens in game. The tuning will say what x and y are. The script (which we'll discuss later) will say that we are adding the two together. The combination (tuning plus script) gives us z, which is the game.

XML Tuning Mods are the most likely to conflict with other mods (statistically), due to the sheer quantity of them out there. Sims 3 will attempt to load the Mods that you have, and since the Mods try to alter the same file, the game gets confused and will throw a tantrum.

ITUN Overrides are mods which override the ITUN resources within the code. ITUN is "Interaction Tuning" and basically functions as scripts which configure autonomous interactions. For instance, an ITUN file controls which age ranges can perform a given interaction. Changing this will mean that the properties of an interaction are modified, but no extra behavior will be created (that's a Script Mod).

OBJD Resources are less common, but they definitely still exist. Each object in game is assigned it's own OBJD resource, which configures the object. What this means is, a mod that edits the OBJD resource will essentially change the properties of an object. Examples of this are making objects draggable in Live Mode (ie portable), re-categorizing an object (ie moving it from Decorative to Comfort), and adjusting an object's price.

And finally there are STBL Edits. I was reluctant to include this as it is a very rare kind of mod. But, since we are discussing different kinds of Mods, I figured I'd include it. Strings are the text that make up the game. For instance "Friendly Hug" and "Join Culinary Career" are strings. Each individual piece of text is generated by creating a special and unique value, called a "hash". TS3 has a list of hashes and what they mean inside the game, inside String Tables. So, when a modder wants to modify what a string says, they find the hash, and replace the string, creating an STBL Edit.

Script Mods
Script Mods are more complicated. They require full blown coding to create -- you simply change a 1 to a 3 and your basic Tuning Mod is created. With Script Mods there are caveats for Modders and conventions, plus a complicated language to learn (C#).

Core Mods are Mods which rewrite the EA script entirely. They are created by extracting EA's code, then editing the Intermediate Language -- there is no better way to explain it than bluntly: when code is executed, it is first transformed from the original language (C#) into an Intermediate Language (IL), then into Machine Language (ML) which is executed as ones and zeros that the computer can understand. The IL is what is edited. Some examples are Pescado's AwesomeMod, and NRaas ErrorTrap.

Scripted Objects are objects which have been scripted to add extra functionality. An infamous example is "Girl Doll Dressed", which was a doll that was scripted to introduce new interactions. Their features are usually accessed through an interaction. For instance, a cloned Teddy Bear I created, had an interaction injected, which displayed a notification. That's a Scripted Object. If the code just ran, without the interaction, it's a Pure Scripting Mod.

Pure Scripting Mods are the same as Scripted Objects, but they are not tied to an object. So, an object is not needed to run their scripts. For instance, the introductory tutorial to Pure Script Modding at ModTheSims is creating a Pausinator, which is a mod that, on the loading of the game, pauses it. That's a really basic example but Pure Scripting Mods can be very complex. For instance, most NRaas Mods are Pure Scripting Mods.



Mod Creation (or: why certain Mods are more volatile than others)
So, we now know about the two kinds of Mods, we can start discussing them and comparing them.

Firstly, let's see what all Mods have in common.

All Mods are in one location: Mods/Packages, and are packaged using the .package file format. Think of it like this: A box sealed with tape. Both a Modder and EA hold craft knives, but nobody else does. This means that EA and Modders both can open the box, but not anyone else. The Mod is the box. Modders can open the Mods and look at them, because they have special tools, and EA/Sims 3 can open them and use them because they have special tools. The convenient thing about boxes are, we can store multiple objects in it. Same with .package files. If you've ever zipped a file, then you've used something similar: it's essentially a file, containing many other files.

There are a few reasons why some Mods are more volatile than others.

Tuning Mods have a priority. The Sims 3 keeps it's own tuning internally, so if no Mods alter that particular tuning, it has its' own to use. However, if a Mod is found, that tuning is used instead. When two Mods use the SAME tuning at the same priority (ie they are both loaded at the same time), then the game gets confused and that's where so-called "Mod Conflicts" occur. The safest way to run it is to use an "Overrides Folder" which NonaMena explains on her blog. Note that this is not a fool-proof method, but it will work in most cases.

Similarly, the game has a few caveats for Script Modders. The one you're most likely to encounter is namespace collisions. If that confused you, here it is broken down. To uniquely identify different pieces of code, everything is named logically (in what programmers call a "namespace"). For instance, I might name a bit of code "Seabody.AllowAutonomousMarriage.Interaction.Execute". However, if another Modder names their code "Seabody.AllowAutonomousMarriage.Interaction.Execute", then we have a problem.

To combat this, Script Modders by convention use their own unique namespace which is traditionally prefixed by their username. I often create Script Mods for my own use, and the Namespace I use is "Seabody.Sims3". Clearly if someone stole that it'd be obvious! If Carl wanted to create one, he might use "Carl.Sims3". He wouldn't use "Seabody.Sims3" as that has already been taken, by me.

The Dangers
Mods, like all software, have the potential to be dangerous. Let's talk about an example we've touched on before, the infamous "Girl Doll Dressed". This piece of Custom Content achieved Mod status because the author wanted to include custom interactions with the doll. However, she had a piece of code that didn't function properly, which caused the doll to have unsavory implications: whenever a user who had the doll in their game exported something and uploaded it somewhere, the doll came too and would install itself ninja-like into the downloader's game. Since the doll was bugged this would cause games to become corrupt, lag, etc.

There is also the danger of conflicts, but we've covered that enough before that I don't think I need to restate it here. ;) But basically, if two Mods have the same unique identifiers, they WILL conflict.

The Benefits
All too often we hear of people saying "xyz Mod ruined my game". However this is not always true. For every Mod that is badly made, another five are often very well made. There are a few big names in the modding world; however the two "titans" of the modding world are Twallan (who operated NRaas Industries) and J. M. Pescado, who runs More Awesome than You. Both of these creators can be trusted to create trustworthy Mods.

Mods can enrich gameplay, add new features, or fix bugs. For example, where would we be without NRaas? We wouldn't have MasterController, Overwatch, ErrorTrap, Traveler, StoryProgression and several others. And without Pescado? There'd be no AwesomeMod.

Should I use Mods?
It's a matter of personal preference. I, personally, say yes. But first, consider whether or not you actually need the Mod. Think about the name. Research them. See how many Mods they've made (but remember, quantity does not equal quality). Check the comments about that Mod. If large amounts of comments are like "Oh no, my game broke due to this..." or similar, think twice about downloading it. But do take risks. If nobody downloaded new Modders Mods, those Modders would never attain the status of twallan, Pescado, Buzzler or NonaMena (to name just a few). Personally, if the Mod sounds interesting, and you need or want it, and the Mod seems good enough -- do it. If you are able, take a look at how it's made to see if it's all good. And, as always, scan it with a virus scanner. It's always better to be safe than sorry.



Notes
We talk in here a bit about a site called "More Awesome than You". I would like to warn you though; although Pescado is a talented modder, not all of his content is family friendly (especially on his website, but Awesome Mod itself has certain "unsavory" components). I recommend that Awesome Mod is not used by people under 18.

Twallan's Mods are now maintained by a volunteer community, which are obviously not Twallan. ;) Although the community is highly talented, they don't know the code as well as Twallan. I'm not saying "don't use them", but the risk of anything negative happening is higher than before.

Offline Seabody

  • Global Moderator
  • Watcher
  • ******
  • Posts: 5071
Re: What are Mods?
« Reply #1 on: December 02, 2013, 06:12:21 PM »
Mod FAQ

Q) Are Mods bad?
A) Some of them are. It depends on the Mod -- check out what people are saying about the Mod before you download it and you should be good.

Q) Can I stop the negative effects?
A) Not entirely. As the old adage goes, prevention is the best cure. Do your research, and only download Mods you really want. As I said before, scan it with a virus scanner.

Q) What might happen if I download a bad Mod?
A) Almost anything. Your game could use too much memory and crash, your save could be corrupted, or even worse: your computer, sadly, could be infected with a virus.

Q) Then shouldn't all Mods be banned?
A) Absolutely not. Yes, there are bad Mods out there. But that is true for anything -- think about the food you buy. A supermarket will take every precaution they can to make sure that their food is safe to eat -- so does a Modder. Yes there is an element of risk in it, but that risk can be minimized if you take the right precautions. Although this post does talk heavily about negative consequences to using Mods, there are a multitude of positives.

Q) Who is safe to download from?
A) An exhaustive list is not possible. ;) Just use common sense. A one-post uploader on MTS who makes a mod that claims to give your Sims $10,000,000,000,000,000 is probably lying and the mod is probably not safe. ;) As a general rule (and I stress, this will not always apply), if any malware or heavily buggy content is found on a website, the site will remove it from public viewing quickly.

Q) What else can I read to learn more?
A) Google! jeanamariex3 explains installing Mods here, NonaMena talks about safe Mod use here (and again on her blog) and we have a large amount of information on the Game Modifications board. There is also good information here (where we talk about starting with Mods).

Q) Do all Mods go out of date with a patch?
A) No! My Gym Bug Fix and Dartboard Improvement mod went about 8 patches in a row before needing an update. The safest way to go about it is to uninstall your Mods and reinstall them when the creator gives the goahead. Alternatively, you can check some of them yourself, but that's outside the scope of this post.



Registered members do not see ads on this Forum. Register here.

Offline NonaMena

  • Townie
  • ***
  • Posts: 227
    • Nona's Sims
Re: What are Mods?
« Reply #2 on: April 11, 2014, 12:45:07 PM »
Nice thread, Seabody. You clearly put a lot of effort into the thread. Thanks for sharing it. I have some corrections/suggestions.

- There are a lot more than three types of tuning mods. See my thread at Simlogical: Understanding Mod and CC Conflicts with Delphy's Dashboard. Actually, all of these types of tuning mods are very common, even though xml & itun are the most common.

- ITUN mods are really just specially formatted XML mods. I have no idea what you really mean to say with "basically functions as scripts which configure autonomous interactions" but they aren't scripts. ITUN mods govern autonomy and they can be used to fine tune interactions. However, some interactions are hard-coded to be limited in some ways, so ITUN mods cannot always change interaction autonomy/tuning.

- It is impossible to get a virus from a package file. However, you can get a virus from a malicious ad on a website that hosts mods, or if you are deceived into downloading a malicious file/program while trying to download a mod. Package files, however, will not give you a virus. In general, it's best to be vigilant when you visit unfamiliar websites. This applies to everywhere on the internet, not just Sims 3 mods/websites.