- Site Map >
- Modding and Creation >
- Sims 4 Creation >
- Object Creation >
- Info | COBJ/OBJD resources
- Site Map >
- Modding and Creation >
- Sims 4 Creation >
- Object Creation >
- Info | COBJ/OBJD resources
Replies: 2 (Who?), Viewed: 30383 times.
#1
21st Mar 2015 at 3:21 PM
Last edited by plasticbox : 16th Feb 2016 at 3:52 AM.
Posts: 11,006
Thanks: 424466 in 1123 Posts
Info | COBJ/OBJD resources
This is a compilation of all I know about the COBJ and OBJD resources: these two resources are linked together by having the same instance ID; together they form an instance of an object (what’s commonly also called “a recolour” or “a swatch”, but they define a lot more than just an object’s visual appearance). The COBJ defines mostly how an object appears in the catalogue, the OBJD mostly links to other resources like the 3d model and footprint. Example screenshots are of the Maxis HipsterHugger sofa, taken in s4pe 0.2d. The current version has more descriptive labels than that.
Update 2015-12-06: Maxis have published the Binary Template for COBJ v25 here:
Quote: Originally posted by SimGuruModSquad
Don't think we've posted this one before, here is the .bt file for the build/buy catalog entry resource. Similar to today's update to the CAS Part Resource, it has been updated to specify pack ID the product is associated with. |
Template
--
COBJ – Catalog Object
- Version
Version number of the COBJ format itself
- CommonBlock
This is a section that all catalogue items have in common:
- CommonBlockVersion
Like 1. / Version.
- NameHash
The key of the dictionary entry in a STBL that contains the localised name for this item. This is the name that shows up in the in-game Buy/Build catalogue in whichever language the player has their game installed in.
- DescriptionHash
Same principle as the NameHash, only for the object description (i.e. the “this beautiful object will make your sim very happy” blurb).
- Price
The price that is listed in the catalogue, in hexadecimal. This is what gets deducted from the sims’ household funds when the object is placed in game. The actual value once the object exists in the world is calculated from the entry in the OBJD though (see below), not from this.
- ThumbnailHash (UnkCommon01, UnkCommon02 in old versions)
Resource ID of the image that is used as a thumbnail (or zero if the object does not have one)
- DevCategoryFlags (UnkCommon03 in old versions)
See here – this plays a role in whether or not objects show up in Buy/Build, but the actual flag values have not been documented AFAIK. Most objects that show in the catalogue have DevCategoryFlags set to 0x00000080, props usually have 0x00000090.
- ProductStyles
These are the styles one can filter by in the in-game catalogue, like "French Country" and the like. Styles as of 1.11.64:
0x9F5CFF10-0x00000000-0x000000000000270B 0xE2EC6B1D: Shotgun
0x9F5CFF10-0x00000000-0x0000000000005367 0xF7479850: Tudor
0x9F5CFF10-0x00000000-0x0000000000005368 0xB33FDF2D: Modern
0x9F5CFF10-0x00000000-0x0000000000005369 0xB61EE322: Mission
0x9F5CFF10-0x00000000-0x0000000000005C03 0xAB6347B0: Basics
0x9F5CFF10-0x00000000-0x0000000000005C04 0xD5566365: Contemporary
0x9F5CFF10-0x00000000-0x0000000000009609 0xEEC386CB: Queen Anne
0x9F5CFF10-0x00000000-0x0000000000009615 0x5240BB87: French Country
0x9F5CFF10-0x00000000-0x000000000000A673 0xB79EE323: Gothic Farmhouse
0x9F5CFF10-0x00000000-0x000000000000A674 0x195E30F9: Cosmolux
0x9F5CFF10-0x00000000-0x000000000000E596 0xDB8D92F8: Suburban Contempo
0x9F5CFF10-0x00000000-0x000000000000115C 0xC1F03007: Double Gallery
0x9F5CFF10-0x00000000-0x0000000000001C2E 0x42C53C51: StyleSHK_01
I would assume the latter two exist for technical reasons.
- Unused2, Unused3 (UnkCommon04 in older versions)
Unused as of 2015-12-04
- Tags
A list of catalogue tags like colour tags, function, category etc. Like with all lists, click on the three dots icon at the right to add/delete entries. The full tag list is defined in /tun/S4_tag_03B33DDF_00000000_D89CB9186B79ACB7.xml; see also this post for a loose file (October 2014). Note that not all tags are valid for all item types; some are CAS specific, some are specific for objects, etc. – colour tags for example are sometimes only used for eye or hair colour so they don’t do anything when used in an object (see e.g. this post).
- SellingPoints
The effects of this object that are listed in the catalogue as key/value pairs, like “Romantic Décor”, “Fun”, “Comedy Skill: 2” etc. Modifying these entries only changes the catalogue text, not the actual functionality of the object (that’s partly in the OBJD, like the Decorative value, and partly in the object and interaction XML tuning, like how fun it is to use or how fast sims will gain skill from it).
- UnlockByHash (UINT32 mGameplayLockedDescriptionKey)
The key of the dictionary entry in a STBL that contains the localised text for instructions on how to unlock this object. Like “Unlock by getting to level X of suchandsuch career”. This is shown in the catalogue while the object is still locked. To make an object available normally, set this and UnlockedByHash to zero.
- UnlockedByHash (UINT32 mGameplayUnlockedDescriptionKey)
The key of the dictionary entry in a STBL that contains the localised text for a description on how this object has been unlocked. Like “Unlocked by getting to level X of suchandsuch career” – this is shown once it’s been unlocked. To make an object available normally, set this and UnlockByHash to zero.
- SwatchColorsSortPriority (UnkCommon06 | SwatchSubsort in older versions)
This is the secondary sort value for the object’s colour swatch – i.e. it governs the order in which the swatches will show, from 0x0000 to 0xFFFF. Note that the swatch panel on catalogue items (i.e. items that aren’t yet placed in the world) is sorted right to left, top to bottom. See this post for a practical example with screenshots.
- VariantThumbImageHash (UnkCommon07 | SwatchTextureIID in older versions)
Instance ID of the texture swatch _IMG resource, for those objects that have one (it’s zero otherwise). See also here.
- CommonBlockVersion
- HashIndicator (struct AuralProperties)
Hash01, Hash02 etc – some of these affect the object sounds; I haven’t tested very much but see this post.
- AuralMaterialsVersion (Unk02 in older versions)
AuralMaterials1
AuralMaterials2
AuralMaterials3
AuralPropertiesVersion
AuralQuality
AuralAmbientObject
Sound stuff.
- PlacementFlagsLow
This governs how an object can be placed/viewed – e.g. attached to walls or ceilings, placeable on water, visible with walls down, etc. A full list of available values is here.
- SlotTypeSet (UnkIID01 | SlotTypeSetIID in older versions)
The instance of an XML and DATA resource that defines object slot behaviour – I don’t recall exactly what the full impact of this is, I only used it once (see this post).
- SlotDecoSize (Unk03 | SlotWeight in older versions)
Object size/weight flag – this defines what kind of container slots an object will fit into: 0x00 for large items that won’t go onto any surface, 0x03 for large deco (like a large TV that will go onto a typical Maxis couch table, but not onto a typical Maxis end table), 0x02 for medium-size deco (like a large vase that will go onto an end table but not onto a shelf), 0x01 for small deco (like the Maxis toothbrush deco which will fit anywhere). See here for examples.
Note that how this works in-game also depends on the footprint of an object: when it’s too large, users will need to turn on bb.moveobejcts to make the object fit into a given slot. Also, GtW has more specific types in addition to these for sellable items like cakes and such (which only go in particular types of displays) -- I don't know if they have a different value here too.
- CatalogGroup (SwatchGrouping in older versions)
The ID of the catalogue thumbnail this object will be found in (grouped with all other objects that have the same CatalogGroup).
- StateUsage
- Colors
List of up to three colour values to use for the colour swatch of this. Will only show when the object has no custom swatch (i.e. a picture with a pattern or somesuch).
- FenceHeight
- IsStackable
- CanItemDepreciate
- FallbackObjectKey
These do what they say.
--
Stuff for TS2 · TS3 · TS4 | Please do not PM me with technical questions – we have Create forums for that.
In the kingdom of the blind, do as the Romans do.
Advertisement
#2
21st Mar 2015 at 8:49 PM
Last edited by plasticbox : 27th Feb 2016 at 2:06 AM.
Posts: 11,006
Thanks: 424466 in 1123 Posts
OBJD – Object Definition
Stuff for TS2 · TS3 · TS4 | Please do not PM me with technical questions – we have Create forums for that.
In the kingdom of the blind, do as the Romans do.
- Name
The internal name of this catalogue instance.
- Tuning
The name of the object tuning for this object. When you extract the XML tuning with velocitygrass’ XML Extractor and have subfolders selected, this will end up in the /object subfolder. What’s defined in that tuning varies a lot by object type – for the couch used for this example, it is not very exciting (it just lists the states like burning/burned and the parts that sims can sit and nap on, defines how comfortable it is and which interactions can be used on it), but for objects with a lot of functions, like computers for example, a lot of stuff can be tweaked by way of customised object and interaction tuning. For more info on editing XML tuning, see the “XML Tuning” walkthrough in Tutorials.
- TuningID
The instance of said object tuning.
- Components
A list of the fnv-32 hashes of the components of this object. The most comprehensive list of valid components I know about is in /simulation_src/objects/components/types.pyo.py – note that the values in this list are hashed from the lowercase names, e.g. “footprint” (0xC807312A), not “Footprint”. ModdingToolkit for example does this conversion automatically (so you will see 0xC807312A for “Footprint” too) but tools like fnvhash.com do not.
Hashes of the example object I took the screenshots of (a sofa) added by me, in bold:
Quote:
0xEE17C6AD – ANIMATION_COMPONENT = component_name_type('Animation', 'animation_component')
0x3FC40859 – AUDIO_COMPONENT = component_name_type('Audio', 'audio_component')
0x73CB32C9 – EFFECTS_COMPONENT = component_name_type('Effects', 'effects_component')
0xC807312A – FOOTPRINT_COMPONENT = component_name_type('Footprint', 'footprint_component')
0x0555BF01 – GAMEPLAY_COMPONENT = component_name_type('Gameplay', 'gameplay_component')
LIVE_DRAG_COMPONENT = component_name_type('LiveDrag', 'live_drag_component')
0x5E19D274 – POSITION_COMPONENT = component_name_type('Position', 'position_component')
0x222E5F81 – RENDER_COMPONENT = component_name_type('Render', 'render_component')
ROUTING_COMPONENT = component_name_type('Routing', 'routing_component')
SIM_COMPONENT = component_name_type('Sim', 'sim_component')
AFFORDANCE_TUNING_COMPONENT = component_name_type('AffordanceTuning', 'affordancetuning_component')
AUTONOMY_COMPONENT = component_name_type('Autonomy', 'autonomy_component')
BUFF_COMPONENT = component_name_type('Buffs', 'buffs_component')
CANVAS_COMPONENT = component_name_type('Canvas', 'canvas_component')
CARRYABLE_COMPONENT = component_name_type('Carryable', 'carryable_component')
CHANNEL_COMPONENT = component_name_type('Channel', 'channel_component')
CENSOR_GRID_COMPONENT = component_name_type('CensorGrid', 'censorgrid_component')
COLLECTABLE_COMPONENT = component_name_type('CollectableComponent', 'collectable_component')
CONSUMABLE_COMPONENT = component_name_type('ConsumableComponent', 'consumable_component')
CRAFTING_COMPONENT = component_name_type('Crafting', 'crafting_component')
CRAFTING_STATION_COMPONENT = component_name_type('CraftingStationComponent', 'craftingstation_component')
ENVIRONMENT_SCORE_COMPONENT = component_name_type('EnvironmentScoreComponent', 'environmentscore_component')
FLOWING_PUDDLE_COMPONENT = component_name_type('FlowingPuddle', 'flowingpuddle_component')
GAME_COMPONENT = component_name_type('Game', 'game_component')
GARDENING_COMPONENT = component_name_type('Gardening', 'gardening_component')
IDLE_COMPONENT = component_name_type('Idle', 'idle_component')
INVENTORY_COMPONENT = component_name_type('Inventory', 'inventory_component')
INVENTORY_ITEM_COMPONENT = component_name_type('InventoryItem', 'inventoryitem_component')
LIGHTING_COMPONENT = component_name_type('Lighting', 'lighting_component')
LINE_OF_SIGHT_COMPONENT = component_name_type('LineOfSight', 'lineofsight_component')
LIVE_DRAG_TARGET_COMPONENT = component_name_type('LiveDragTarget', 'live_drag_target_component')
NAME_COMPONENT = component_name_type('Name', 'name_component')
OBJECT_AGE_COMPONENT = component_name_type('ObjectAge', 'objectage_component')
OBJECT_RELATIONSHIP_COMPONENT = component_name_type('ObjectRelationship', 'objectrelationship_component')
OBJECT_TELEPORTATION_COMPONENT = component_name_type('ObjectTeleportation', 'objectteleportation_component')
OWNABLE_COMPONENT = component_name_type('Ownable', 'ownable_component')
PROXIMITY_COMPONENT = component_name_type('Proximity', 'proximity_component')
0x2EF1E401 – SLOT_COMPONENT = component_name_type('Slot', 'slot_component')
SPAWNER_COMPONENT = component_name_type('Spawner', 'spawner_component')
STATE_COMPONENT = component_name_type('State', 'state_component')
STATISTIC_COMPONENT = component_name_type('Statistic', 'statistic_component')
STORED_SIM_INFO_COMPONENT = component_name_type('StoredSimInfo', 'storedsiminfo_component')
TIME_OF_DAY_COMPONENT = component_name_type('TimeOfDay', 'timeofday_component')
TOOLTIP_COMPONENT = component_name_type('Tooltip', 'tooltip_component')
TOPIC_COMPONENT = component_name_type('Topic', 'topic_component')
VIDEO_COMPONENT = component_name_type('Video', 'video_component')
WELCOME_COMPONENT = component_name_type('Welcome', 'welcome_component')
FISHING_LOCATION_COMPONENT = component_name_type('FishingLocation', 'fishing_location_component')
WAITING_LINE_COMPONENT = component_name_type('WaitingLine', 'waiting_line_component')
EXAMPLE_COMPONENT = component_name_type('Example', 'example_component')
- MaterialVariant
The name of the material variant used for this instance. The fnv-32 of this name is what’s listed in the Type300Entries list in the MODL/MLOD, the index of which points to the relevant material definition.
- SimoleonPrice
This is the price (in hexadecimal) that is used once an object is in the world (you see it e.g. when you pick it up in Build/Buy, at the bottom right of the screen) – this should be the same as in the COBJ, because when these are out of sync sims will e.g. pay 400 (COBJ price) when they buy the object but only get 50 (the price in this field) back when they sell it.
In 1.15 (no idea about earlier versions), only the last four bytes will actually be taken into account (i.e. when an object costs 80.000 = 0x00013880, only 14.464 = 0x3880 will be returned when deleting the object in BuildBuy).
- EnvironmentScoreEmotionTags
This is an object with supernatural abilities (IIRC it gives sims a Focused mood) – regular objects do not have this field.
- EnvironmentScores
The amount of decorative-ness of this object instance. I believe this is probably the radius up until which a sim will get the “Decorated” moodlet when the object is present, but I never tested that theory. It’s definitely not the value that shows up in the catalogue (like “Decorative: 2” – that is defined in the COBJ, not here).
- Icon
Resource key of custom icon? Not sure.
- Rig
Resource key of the _RIG resource for this object instance.
- Slot
Resource key of the RSLT resource for this object instance.
- Model
Resource key of the MODL resource for this object instance.
- Footprint
Resource key of the FTPT resource for this object instance.
Stuff for TS2 · TS3 · TS4 | Please do not PM me with technical questions – we have Create forums for that.
In the kingdom of the blind, do as the Romans do.
#3
9th Sep 2016 at 9:53 AM
Posts: 14
Thanks: 12 in 1 Posts
I was the creator of a bunch of Objects in TS2 (nick was Max3D)... and as I dislike TS3, I really like TS4, I really wish to get back to work, but actually looks like a bit of a mess import 3DS Max mesh in game, ins't it?
Who Posted
|