Game Concept Glossary
Active Household
The Household that is currently being played, allowing the Sims to be selectable in the skewer.
Affordance
Interchangable with "Interaction" and represents actions that are available to a Sim. In the Simulation Server, "interaction" usually represents an affordance (or interaction type) that has been instanced and queued up.
Buff
Often called a "moodlet", is a Sim mood effect that can be displayed near the Sim's portrait. The mood with the highest weight is chosen. Hidden buffs are usually not associated with a mood and drive a lot of the autonomy modifiers for Sims given by traits, interactions, and loot. They can provide temporary affordances to a Sim, even change their appearance.
Call to Action
The flashy color outline around special objects like the Eco Lifestyle Community Board or the Strangerville Lab Door.
Client & UI
The game is split into the two main components. The Client represents everything you "see", and is comprised of multiple technologies and languages like C, and Flash. The Client code cannot be decompiled except for UI files and is the hardest to mod. UI mods are overrides and will always conflict with each other and need to be updated with new code introduced in patches.
You can use Sims4Studio to extract the GFX files and use JPEXS to read/edit the files. Open the GFX file and expand "images" in the sidebar. Select each DefineExternalImage asset and locate the File name in the Basic tag info panel. Open the UI.package file from the game files in S4S and find the sprite matching the UI element. Export it with the File name located before and include it in the same folder as the GFX file, then reload the GFX file to be able to see the sprites in action.
(Thanks to thepancake1 for explaining this dark magic)
Commodity
Commodities are a type of statistic value that can decay over time. They have a minimum, maximum and convergence value. Convergence represents the value that it will decay towards. This could be a negative or positive direction depending on the current value. The decay rate is always a positive value in tuning and internally changes its sign based on the direction its going.
Commodities can be attached to many types of objects to represent a wide range of concepts that change over time like Hunger and Bladder, but most importantly they provide the autonomy desire for Sims to search for interactions that put their commodities in their best values like Mischieveous Sims seeking out pranks. Interactions can then reset commodity values to decrease their desire.
Constraints
Interactions must have a set of constraints which describe where a Sim positions themselves related to their target, and what posture they can be in. Usually if your Sim route fails, it's because a constraint was missing or misconfigured. Often, even when an EA interaction does not have a constraint and you clone it, you will need to at least add an animation constraint that references the primary animation defined in the basic_content
Continuation
Interactions can run in a chain by using a continuation within the outcome. The continued interaction will replace the current one in the queue and inherit the existing context (like SavedActors).
Coordinate System
In The Sims 4 X and Z represent the ground plane coordinates, and Y represents height.
Dev Category Flags
A field in Object Catalogs that sets whether the object is visible in the the build/buy catalog and/or visible in Live mode.
| Description | Value | Flags |
|---|---|---|
| Normal Visibility | 00000080 | 7 |
| Normal Visibility, Set as Default Swatch | 000000A0 | 7 & 5 |
| Visible in Catalog, Hidden in Live Mode | 000000C0 | 7 & 6 |
| Visible in Catalog only with bb.showhiddenobjects enabled (Debug) | 000000B0 | 7 & 5 & 4 |
| Visible in Catalog only with bb.showhiddenobjects enabled (Hidden) | 00000090 | 7 & 4 |
| Visible in Catalog only with bb.showliveeditobjects enabled (Debug) | 00000081 | 7 & 1 |
| Not Visible in Catalog | 00000088 | 7 & 3 |
| Not Visible in Catalog | 00000232 | 5 & 4 & 1 |
Distributor
Controls "Ops", or data, being sent to the Client by the Simulation Server. You sometimes may need to manually distribute ops to trigger special dialogs or effects in the client that aren't easily available through other services.
Drama Node
Events automatically (or manually) scheduled in the background and on the calendar based on scoring and weekly schedule. They can show a dialog, phone call, text message, or trigger a Situation on the current lot like a vampire break in. Only certain Drama Node classes support being added to the calendar.
Game Clock
There are at least two different clocks in the simulation you would need to successfully schedule actions.
The Game Clock maintains the expected Sim time that you see in the UI. This clock can be used to detect time jumps and bail out in your code to prevent simulation lag.
The TimeService controls the global timeline that ultimately runs every action in the game in sequence. Once the timeline simulates to the game clock time it updates the sim_now property in the service which represents the simulated time. This is generally the time you should base your scheduling on, however when you experience simulation lag, its because these two clocks are out of sync with elements and alarms piling up using the simulated time, unable to catch up to the game clock due to time slicing.
GameObject
While a Definition and Catalog describes how an object looks and can be placed in the Client, the GameObject tuning tells the Simulation how the object works and can be used by a Sim (or not). Multiple Object Definitions can reference the same tuning file.
Geometry State
Objects can have different models controlled by Object States to change the shape on-the-fly while inheriting the existing texture, for example smashing a dollhouse.
Injection
The act of hot-replacing EA code with modded code in the Simulation Server. This is the preferred method of modifying existing tuning to prevent conflicts with overrides being a last resort. Not all systems support injections especially if a SimData is involved (ergo why the Venue list by Basemental exists)
A community made injector is available that lets you easily decorate functions while providing the original function to fallback and retrieve existing results.
LastException
When an uncaught error occurs in the Simulation Server, it will be printed to the lastException.txt file in The Sims 4 folder in your Documents. "BetterExceptions" by TwistedMexi can generate pretty html reports with detailed trace information. When an uncaught error occurs in the Client, it will be printed to the lastUIException.txt file. UI errors usually don't give a lot of information but can allude to the underlying problem, for example a typo in a Career Track SimData could cause an error related to the Career Panel, or a Trait SimData could cause an error related to the Simology panel.
Loot (Actions)
Loot can be considered the treasure you get for completing an Interaction, however they can be used in a wide range of contexts. Ultimately Loot is the final step of the cycle of a Sim searching for something to do, completing the action, and receiving the reward. They can set statistic values, change relationship values between the actor and target, apply traits, show dialogs and notifications and so much more!
Material State
Objects can have different textures for each swatch to represent special states of an object like changing the color of the Thermostat based on setting to Warm or Cool.
Material Variant
Objects can have different textures usually to provide different color swatches in build/buy, however Object States can control the material to change the appearance on-the-fly, for example, giving Llamas a treat will change their fur color temporarily.
Mixer Interaction
A sub interaction that can run at the same time and in the same context as a Super Interaction. Most socials that you see in the pie menu are mixers. A Mixer must be associated with a Super Interaction to be able to run. It also cannot be defined as a super_affordance, you usually either need to define the mixer in an Interaction's content_set within basic_content, add it to an existing Affordance List associated with sim_Chat (i.e. Friendly, Flirty, Mean lists), or as an outcome of a Super Interaction.
Module Tuning
Module tuning loads data directly onto class properties so they are global across all their instances and can be accessed like static properties. If you plan on importing the module tuning across multiple files, it's a common pattern by EA in their larger modules to create a dedicated file for the tuned class to prevent recursion errors when importing.
NPC
In terms of how the Simulation "thinks" and runs tests, any Sim that is not in the active household is an NPC regardless of whether they are a "Played Sim". EA uses "Townie" to represent the Sims that are not created by the Player.
Object Catalog
A special file type that represents common attributes for an in-game object like, the price, how it can be placed in the world, what it can be slotted into, tags that categorize it in build/buy, and its visibility in world and catalog. This file can only be edited in Sims4Studio or TSR Workshop. Information from this file is accessible from the Simulation Server on the GameObject instance.
Object Definition
A special file type that represents an in-game object and assigns the Tuning, Models, Rigs, and Swatch variant. Each swatch must have its own Definition and Catalog. The Definition is the resource you reference in the Simulation Server to spawn an object, not the GameObject Tuning.
Object States
Object functionality is often controlled by states, for example an object can be Unbroken or Broken. An ObjectState tuning named "Brokenness", would reference two ObjectStateValue tuning files representing the two different "modes". These state values are then referenced in the object's GameObject tuning together to set the default values and allow the state to be used on the object. If the states are not set/injected in the object tuning then the values will not persist when traveling or restarting the game.
You will also never reference the ObjectState tuning, it simply needs to exist to create the connections between the values.
An ObjectStateValue cannot be used for more than one ObjectState. Create new values for every object state.
States can be set by Sims performing Interactions through basic_extras, outcomes, or loot. In the case of Brokenness, it is a CommodityObjectState, which assigns ObjectStateValues based on the value of a commodity. The Cottage Living animals use timers in the state component to control their behaviors through state values.
Open Street
Represents the routable area outside the active lot boundary. NPC autonomy is usually limited to this area as defined in their Situation Roles.
Package
A special file type that holds game resources like images, animations, tuning, object definitions, etc. You can create and edit packages using Sims 4 Toolkit, Sims4Studio, or S4PE
Participant
When editing tuning you will often need to set the "subject" or "target" of an Interaction or Test. Participants represent Objects and Sims that are "participating" in a specific context, for instance in a hug Interaction. The Sim who initiates the Interaction would be the Actor, while the Sim who is receiving the hug would be the Object or TargetSim. It all depends on the perspective that something has been initiated in. There are dozens of participant types that allow you target multiple Sims or Objects, even the Lot object itself. In Python you will often need to distinguish between different types of Resolver classes to retrieve specific participant types. These also limit the participant types that are available to Tuning. For example, a SingleObjectResolver only supports participant types that retrieve one object.
Pie Menu
The "Choice Menu" that appears when clicking on a Sim/Object/Terrain that holds interactions and mixers. Interactions that have cheat set to True will only appear when holding Shift and clicking (after enabling testing cheats). Interactions that have debug set to True will never appear in a production build of the game.
Pie Menu Category
Most interactions in the Pie Menu are organized within categories. You can definine the category within Interaction tuning and the category will automatically appear in the pie menu anytime the Interaction passes its tests.
Plex
A special Zone type that has sub-zones. This is used for apartment lots and the Selvadorada Temple. Only really important for testing a Sim's location and getting the correct Zone ID for travel.
Residential Rentals also use the Plex system however the client gives the ability to create the sub-zones when assigning rooms. The lot still has a "master" zone id that is used for build mode to see all units.
Python
The scripting language that powers the simulation server. Not all packages from the standard library are available, for example ssl. The Sims 4 currently uses version 3.7 so it's recommended to match your workspace to the same version. Compiling in a different version has no affect on the version used in game.
Region
Often called a "World" in the community, represents a large location like Willow Creek, Henford-on-Bagley, etc. The Region class in the Simulation Server can provide information like seasonal weather forecasts, sunset and sunrise time.
Simulation Server
The game is split into two main components. The Server is written in Python and configured using Tuning. Virtually all gameplay is managed through the simulation and sends data to the Client to visually display whats happening. Script Mods can prevent conflicts with Tuning by performing code injections.
SimData
An evil file type that maps to a Tuning file for Client use following a very specific schema. It is usually stored in binary format however the TDESC Browser and Sims4Studio allow you to edit in XML. Only specific classes need a SimData file and can cause UI problems if there is an issue with the contents.
Situation
Any NPC Sim that is spawned in the world is controlled by a Situation that tells that what to do, and where they can go. Situations are also used to control how a party functions, when an invited Sim leaves, and for many other gameplay scenarios like a Played Sim visiting a Restaurant. Situations have Situation Jobs that are filled by Sims and can transition between different Role States that control the Buffs that are given to a specific Job.
Social Super Interaction
A Super Interaction that can run in groups and allow Sims to touch, with the target Sims being controlled by an optional alternate Interaction.
Swatch
Represents an Object Definition with a standalone Material Variant that can be selected in build/buy.
Street
Often called a "world" in tuning, represents a neighborhood within a Region. EA will usually include three streets in a Region. There are usually multiple Zones within a Street (Sixam excluded), and any object spawned in the Open Street area will be persisted and accessible across all the different Zones in the same street. The world coordinate system is also consistent within each Zone to easily spawn objects in the Open Street without needing coordinates for each Zone.
String Table
A special file type that stores text used in the game with a reference key. There is a string table per language. Missing strings can be a result of the specific language not matching the original language you edited in. These files can only be edited in STBL Studio, Sims 4 Toolkit, Sims4Studio
ts4script
A zip containing compiled Python scripts. The game supports loading "loose" files in the Mods folder using a special folder structure, but is recommended to compile for distribution. Modding Workspaces are available to decompile EA code, and compile your scripts.
Tunable
A special type of Python class (unique to TS4) that represents a value that can be tuned by an XML Tuning file. The specific Tunable class used represents the final value and type when the class template is constructed and stored in the instance manager.
Tunables generally cannot be instantiated to their resolved value using the class factory like MyTunable() as that prepares it for the instance loader. Instead, use MyTunable.TunableFactory().default().
TunableTuples (<U></U>) are actually more like dicts than tuples, and TunableMappings are dicts!
Tuning
XML files that map to Python classes and power almost all of the gameplay aspects of the game, for example, Buffs, Interactions, Traits, Zone Modifiers (Lot Traits).
Each file is loaded into their respective instance manager based on the t="" attribute as a unique class derived from the base class defined in the c="" attribute, and can be instantiated with the XML values automatically set as the class properties. Passing kwargs into the factory will override the associated tunable values.
Including a Tuning file in a package with the same ID as an EA file will override the EA tuning (it must have the same Group ID as well). The same method applies when two mods with the same ID exist and one will override the other.
Walkby Sims
These are special situations controlled by the Ambient Service for Sims that walk along the paths outside, socialize, and check their phones between spawn points. They generally do not have autonomous access to the Open Streets.
XML
A common file format and "markup language" that follows a schema. The Sims 4 uses XML for Tuning files which has a schema that represents the base "Tunables" classes like Lists L, Variants V, Tuples U and Tunables T. Additional tags include Instance I, Module M, and Class C.
Zone
Often interchangable with "Lot", Zone is the Python class used to control and persist data about every object within the bounding area of the lot, including the owning household, venue type, etc.
This class is often used as an injection point to trigger code when the zone loads, and unloads. It does also hold a Lot object that has a statistic/commodity tracker, lot size info, and the Lot Levels with their own trackers and size properties.
The zone.py file is often difficult to decompile however you can use the inspect module to print the available methods and their arguments.
Pack Safety
When a tunable is marked as Pack Safe in the TDESC this means that you can reference any tuning in packs that a user may not have.
If a tunable is not Pack Safe and you reference a tuning file that does not exist the game will most likely throw an exception when accessing the value.
Generally Pack Safety is used on TunableLists and will remove the reference when loading the tuning rather than inserting a NULL value in the final list.