Difference between revisions of "Sims 3:0x4D1A5589"

From SimsWiki
Jump to: navigation, search
 
(9 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 +
{{TS3AdvancedModdingHeader}}
 +
{{TS3Resource
 +
|name=Object Instances - OBJN
 +
|typeid= 0x4D1A5589
 +
|expansion=The Sims 3
 +
}}
 +
<br clear="all">
 +
 +
==Overview==
 
Research by Tiger - work in progress
 
Research by Tiger - work in progress
  
Line 4: Line 13:
  
 
This is a very rough draft, there are some key pieces of information missing.
 
This is a very rough draft, there are some key pieces of information missing.
 +
 +
 +
==Format==
  
 
==Header==
 
==Header==
Line 34: Line 46:
 
  DWORD count
 
  DWORD count
 
  REP COUNT
 
  REP COUNT
     QWORD guid?
+
     QWORD object guid
 
     DWORD
 
     DWORD
 
     DWORD count3
 
     DWORD count3
Line 40: Line 52:
 
         DWORD component
 
         DWORD component
 
     WORD residx catalog object
 
     WORD residx catalog object
     WORD residx ?
+
     WORD residx ? (Seems like it's always 0:0:0)
 
     WORD residx VPXY
 
     WORD residx VPXY
 +
    [Component specific data]
 +
The component specific data depends on what components are listed.  The order is fixed, and completely unrelated to the order the components are listed in.  Each section appears in the order here, only if the named component is included.  ''This order is inferred by comparing different selections of components from different resources.  In some places the order may not be exact when the components in neighboring locations never appear together, such as "Tree", "Effect" and "Steering".''
 +
===Location===
 
     3 FLOAT location
 
     3 FLOAT location
     4 FLOAT rotation
+
===Transformation===
     D/F
+
     4 FLOAT rotation (Quaternion)
     D?F
+
     QWORD guid (Containing object)
 +
     IF containing guid != 0
 +
        DWORD hash containment slot name
 +
        WORD
 +
===Model===
 
     WORD residx model
 
     WORD residx model
 
     WORD residx compositor prop file
 
     WORD residx compositor prop file
Line 61: Line 80:
 
         REP count5
 
         REP count5
 
             DWORD
 
             DWORD
     WORD residx
+
     WORD complate xml residx
     DWORD 2
+
     IF complate xml is not 0:0:0
    DWORD 2
+
        DWORD 2
   
+
        DWORD 2
DWORD offset // from here to after TGI Block List
+
        DWORD offset // from here to after TGI Block List
WORD
+
        OF offset is not 0
DWORD tgi offset // see [[Sims 3:Key table]]
+
            WORD
DWORD tgi size // see [[Sims 3:Key table]] - always 4
+
            DWORD tgi offset // see [[Sims 3:Key table]]
--insert [[Sims_3:Catalog_Resource#Material_Block]]
+
            DWORD tgi size // see [[Sims 3:Key table]] - always 4
--insert TGI Block List // see [[Sims 3:Key table]] - empty
+
            --insert [[Sims_3:Catalog_Resource#Material_Block]]
DWORD
+
            --insert TGI Block List // see [[Sims 3:Key table]] - empty
+
        BYTE count6
    BYTE count6
+
        REP count6
    REP count6
+
            WORD residx for material list section
        WORD residx for material list section
+
     IF VisualState in components
     3 BYTES (Seen 0x80 in first)
+
        --insert Model/VisualState data
     DWORD hash ("default") or 0
+
====Model/VisualState====
 +
This is seperate from the regular VisualState section, and only appears when both Model and VisualState components are present.
 +
    4 BYTES (Seen 0x80 in first, 0 or 1 in last)
 +
     DWORD hash (From [[Sims 3:0x02019972|MTST]]) or 0
 
     BYTE
 
     BYTE
 
     6 FLOATS
 
     6 FLOATS
Line 83: Line 105:
 
     WORD residx
 
     WORD residx
 
     BYTE
 
     BYTE
 +
 +
===Animation===
 +
    WORD residx skeletal animation rig
 +
    BYTE activeanimation (Flag? Or count?  Only seen 0/1)
 +
    IF activeanimation != 0
 +
        DWORD 1
 +
        DWORD count
 +
        REP count
 +
            DWORD animation priority
 +
            REP (Until first dword 0)
 +
                DWORD (If 0, exit loop)
 +
                DWORD data type
 +
                IF data type = 1
 +
                    DWORD actual data type (Apply this data then exit loop without a 0)
 +
                [type specific data]
 +
====Data types====
 +
IF data type = 0
 +
    DWORD 0
 +
    DWORD 0
 +
    DWORD 0
 +
    DWORD 0
 +
 +
IF data type = 0x60caeef
 +
    DWORD 1
 +
    DWORD (Seems to be some sort of ID)
 +
    BYTE (0/1)
 
     DWORD
 
     DWORD
 +
    DWORD
 +
    DWORD
 +
    DWORD flags?
 +
    FLOAT
 +
    FLOAT
 +
(Animation clip info will not be present)
 +
 +
IF data type = 0x664ed68
 +
    DWORD 1
 +
    DWORD (Seems to be some sort of ID)
 +
    BYTE (0/1)
 +
    DWORD count1
 +
    DWORD 1
 +
    DWORD count2
 +
    REP count1
 +
        REP count2
 +
            FLOAT
 +
    DWORD
 +
    DWORD flags?
 +
    FLOAT
 +
    FLOAT
 +
(Animation clip info will not be present)
 +
 +
IF data type = 0x664fb68
 +
    DWORD 1
 +
    DWORD (Seems to be some sort of ID)
 +
    BYTE (0/1)
 +
    DWORD
 +
    DWORD
 +
    DWORD flags?
 +
    FLOAT
 +
    FLOAT
 +
 +
IF data type = 0x67c5cab
 +
    DWORD 1
 +
    DWORD (Seems to be some sort of ID)
 +
    BYTE (0/1)
 +
    DWORD
 +
    DWORD
 +
    FLOAT
 +
    FLOAT
 +
(Always the first data element)
 +
 +
IF data type = 0x681c688
 +
    DWORD 1
 +
    DWORD (Seems to be some sort of ID)
 +
    BYTE (0/1)
 +
    DWORD
 +
 +
IF data type = 0x73b9d8c
 +
    DWORD 1
 +
    DWORD (Seems to be some sort of ID)
 +
    BYTE (0/1)
 +
    DWORD
 +
 +
IF data type = 0x7a11ba8
 +
    DWORD 1
 +
    DWORD (Seems to be some sort of ID)
 +
    BYTE (0/1)
 +
    DWORD
 +
 +
IF data type = 0x34f49f94
 +
    DWORD 1
 +
    DWORD (Seems to be some sort of ID)
 +
    BYTE (0/1)
 +
    DWORD
 +
 +
IF data type = 0xb489fc2c (Active animation clip)
 +
    DWORD 2
 +
    DWORD flag
 +
    TGI64 clip
 +
    TGI64 track mask
 +
    DWORD count1?
 +
    DWORD count2?
 +
    DWORD -1
 +
    IF (count2 > 0)
 +
        REP until actor = 0 and slot = 0
 +
            QWORD guid
 +
            REP until value = 0
 +
                DWORD value
 +
            DWORD actor
 +
            DWORD slot
 +
    QWORD guid
 +
    IF flag != 0
 +
        DWORD paramcount
 +
        REP paramcount
 +
            DWORD hash actor name
 +
            DWORD
 +
            DWORD flags (Usually 0x40000001, also seen 0x40000003)
 +
            DWORD
 +
            QWORD guid assigned actor
 +
            DWORD 0
 +
    FLOAT
 +
    FLOAT
 +
    FLOAT
 +
    DWORD
 +
    DWORD
 +
    DWORD
 +
    BYTE (0/1)
 +
    BYTE (0/1)
 +
    BYTE (0/1)
 +
    IF type 0x681c688, 0x73b9d8c, or 0x34f49f94 data present
 +
    AND number of type 0x681c688, 0x73b9d8c, or 0x34f49f94 not more than number of type 0xb489fc2c
 +
        (On the first occurrence)
 +
            END type 0xb489fc2c data here
 +
        (On occurrence after second but before the last)
 +
            FLOAT
 +
            FLOAT
 +
            END type 0xb489fc2c data here
 +
        (On last occurence)
 +
            FLOAT
 +
            FLOAT
 +
            (Finish to end of type 0xb489fc2c data)
 +
    DWORD
 +
    DWORD flags?
 +
    FLOAT
 +
    FLOAT
 +
 +
===Script===
 +
    DWORD (6)
 
     DWORD length
 
     DWORD length
 
     CHAR[length] (Script class)
 
     CHAR[length] (Script class)
     BYTE
+
     BYTE (0/1)
 
     DWORD
 
     DWORD
 +
    DWORD script object ID (References [[Sims_3:0x06B981ED]])
 +
===Physics===
 +
    BYTE Physics enabled
 +
===Tree===
 +
    WORD residx speedtree data
 
     DWORD
 
     DWORD
 +
    DWORD count
 +
    REP count
 +
        12 FLOATs transformation (3x4 transformation matrix)
 +
        3 FLOATs location
 +
        FLOAT (1.0)
 +
        FLOAT tree scale
 +
===Effect===
 +
    WORD
 
     BYTE
 
     BYTE
     WORD residx
+
    BYTE length
     WORD residx
+
    CHAR[length] effect name
 +
===Sim===
 +
    Word residx sim outfit
 +
    Word unk (residx?)
 +
 
 +
===Steering===
 +
    BYTE
 +
    DWORD
 +
===Sacs===
 +
    WORD
 +
    BYTE
 +
    BYTE count
 +
    REP count
 +
        DWORD sacs driver
 +
===Slot===
 +
     WORD residx RSLT data
 +
===Lighting===
 +
     WORD residx LITE data
 
     4 FLOATS
 
     4 FLOATS
     6 BYTES (WORD/DWORD in some order?)
+
===VisualState===
 +
     3 WORDS (Might be WORD/DWORD or DWORD/WORD)
 
     DWORD -1?
 
     DWORD -1?
 +
===Footprint===
 
     BYTE
 
     BYTE
     WORD residx
+
     WORD residx FTPT data
 
     DWORD count7
 
     DWORD count7
 
     REP count7
 
     REP count7
 +
        DWORD
 +
    WORD residx FTPT data (Alternate?)
 +
    DWORD count
 +
    REP count
 
         DWORD
 
         DWORD
 
     BYTE
 
     BYTE
 
     FLOAT
 
     FLOAT
     DWORD (count?)
+
===Audio===
     2 FLOAT
+
     DWORD (2)
     QWORD guid
+
     2 FLOATs
 +
     DWORD
 +
    FLOAT
 +
 
 +
{{TS3AdvancedModdingHeader}}

Latest revision as of 01:46, 5 May 2010

Modding Reference by Category

Sims 3 :DBPF | File Types | RCOL(Scene) | Catalog Resource | String Table | Key Table | TS3 Programmer's Reference 

Object Instances - OBJN
TypeID:0x4D1A5589
Game Version:The Sims 3



Contents

[edit] Overview

Research by Tiger - work in progress

Parts of the data contained in this resource follows the format of Sims_3:Catalog_Resource#Material_List and Sims_3:0xCF84EC98. The lot objects section references resources indexed by Sims_3:0x05ED1226.

This is a very rough draft, there are some key pieces of information missing.


[edit] Format

[edit] Header

DWORD version 0x14
DWORD unk 1
DWORD 0x02dc343f
DWORD count1
REP count1
   QWORD object catalog ID
   DWORD
DWORD 1
DWORD 0x736884f1
DWORD count2
REP count2
   DWORD
   DWORD
   DWORD
FLOAT
FLOAT
FLOAT
FLOAT
DWORD offset to 'NOBJ'
DWORD 0x1c
DWORD -1
DWORD length
[length BYTES #Lot Objects]
DWORD
[data like Sims_3:0xCF84EC98 starting in the Components section]

[edit] Lot Objects

DWORD count
REP COUNT
    QWORD object guid
    DWORD
    DWORD count3
    REP count3
        DWORD component
    WORD residx catalog object
    WORD residx ? (Seems like it's always 0:0:0)
    WORD residx VPXY
    [Component specific data]

The component specific data depends on what components are listed. The order is fixed, and completely unrelated to the order the components are listed in. Each section appears in the order here, only if the named component is included. This order is inferred by comparing different selections of components from different resources. In some places the order may not be exact when the components in neighboring locations never appear together, such as "Tree", "Effect" and "Steering".

[edit] Location

    3 FLOAT location

[edit] Transformation

    4 FLOAT rotation (Quaternion)
    QWORD guid (Containing object)
    IF containing guid != 0
        DWORD hash containment slot name
        WORD

[edit] Model

    WORD residx model
    WORD residx compositor prop file
    WORD residx compositor prop file
    DWORD count4
    REP count4
        WORD residx
        DWORD 8 offset? (To after next dword)
        DWORD length - 1 (Of rest of this entry)
        6 BYTES (Last sometimes 4, not clear data sizes)
        DWORD 0
        DWORD count5
        BYTE 1
        BYTE 0/1
        REP count5
            DWORD
    WORD complate xml residx
    IF complate xml is not 0:0:0
        DWORD 2
        DWORD 2
        DWORD offset		// from here to after TGI Block List
        OF offset is not 0
            WORD
            DWORD tgi offset	// see Sims 3:Key table
            DWORD tgi size		// see Sims 3:Key table - always 4
            --insert Sims_3:Catalog_Resource#Material_Block
            --insert TGI Block List	// see Sims 3:Key table - empty
        BYTE count6
        REP count6
            WORD residx for material list section
    IF VisualState in components
        --insert Model/VisualState data

[edit] Model/VisualState

This is seperate from the regular VisualState section, and only appears when both Model and VisualState components are present.

    4 BYTES (Seen 0x80 in first, 0 or 1 in last)
    DWORD hash (From MTST) or 0
    BYTE
    6 FLOATS
    3 BYTES (First 1)
    WORD residx
    BYTE

[edit] Animation

    WORD residx skeletal animation rig
    BYTE activeanimation (Flag? Or count?  Only seen 0/1)
    IF activeanimation != 0
        DWORD 1
        DWORD count
        REP count
            DWORD animation priority
            REP (Until first dword 0)
                DWORD (If 0, exit loop)
                DWORD data type
                IF data type = 1
                    DWORD actual data type (Apply this data then exit loop without a 0)
                [type specific data]

[edit] Data types

IF data type = 0
    DWORD 0
    DWORD 0
    DWORD 0
    DWORD 0
IF data type = 0x60caeef
    DWORD 1
    DWORD (Seems to be some sort of ID)
    BYTE (0/1)
    DWORD
    DWORD
    DWORD
    DWORD flags?
    FLOAT
    FLOAT
(Animation clip info will not be present)
IF data type = 0x664ed68
    DWORD 1
    DWORD (Seems to be some sort of ID)
    BYTE (0/1)
    DWORD count1
    DWORD 1
    DWORD count2
    REP count1
        REP count2
            FLOAT
    DWORD
    DWORD flags?
    FLOAT
    FLOAT
(Animation clip info will not be present)
IF data type = 0x664fb68
    DWORD 1
    DWORD (Seems to be some sort of ID)
    BYTE (0/1)
    DWORD
    DWORD
    DWORD flags?
    FLOAT
    FLOAT
IF data type = 0x67c5cab
    DWORD 1
    DWORD (Seems to be some sort of ID)
    BYTE (0/1)
    DWORD
    DWORD
    FLOAT
    FLOAT
(Always the first data element)
IF data type = 0x681c688
    DWORD 1
    DWORD (Seems to be some sort of ID)
    BYTE (0/1)
    DWORD
IF data type = 0x73b9d8c
    DWORD 1
    DWORD (Seems to be some sort of ID)
    BYTE (0/1)
    DWORD
IF data type = 0x7a11ba8
    DWORD 1
    DWORD (Seems to be some sort of ID)
    BYTE (0/1)
    DWORD
IF data type = 0x34f49f94
    DWORD 1
    DWORD (Seems to be some sort of ID)
    BYTE (0/1)
    DWORD
IF data type = 0xb489fc2c (Active animation clip)
    DWORD 2
    DWORD flag
    TGI64 clip
    TGI64 track mask
    DWORD count1?
    DWORD count2?
    DWORD -1
    IF (count2 > 0)
        REP until actor = 0 and slot = 0
            QWORD guid
            REP until value = 0
                DWORD value
            DWORD actor
            DWORD slot
    QWORD guid
    IF flag != 0
        DWORD paramcount
        REP paramcount
            DWORD hash actor name
            DWORD
            DWORD flags (Usually 0x40000001, also seen 0x40000003)
            DWORD
            QWORD guid assigned actor
            DWORD 0
    FLOAT
    FLOAT
    FLOAT
    DWORD
    DWORD
    DWORD
    BYTE (0/1)
    BYTE (0/1)
    BYTE (0/1)
    IF type 0x681c688, 0x73b9d8c, or 0x34f49f94 data present
    AND number of type 0x681c688, 0x73b9d8c, or 0x34f49f94 not more than number of type 0xb489fc2c
        (On the first occurrence)
            END type 0xb489fc2c data here
        (On occurrence after second but before the last)
            FLOAT
            FLOAT
            END type 0xb489fc2c data here
        (On last occurence)
            FLOAT
            FLOAT
            (Finish to end of type 0xb489fc2c data)
    DWORD
    DWORD flags?
    FLOAT
    FLOAT

[edit] Script

    DWORD (6)
    DWORD length
    CHAR[length] (Script class)
    BYTE (0/1)
    DWORD
    DWORD script object ID (References Sims_3:0x06B981ED)

[edit] Physics

    BYTE Physics enabled

[edit] Tree

    WORD residx speedtree data
    DWORD
    DWORD count
    REP count
        12 FLOATs transformation (3x4 transformation matrix)
        3 FLOATs location
        FLOAT (1.0)
        FLOAT tree scale

[edit] Effect

    WORD
    BYTE
    BYTE length
    CHAR[length] effect name

[edit] Sim

    Word residx sim outfit
    Word unk (residx?)

[edit] Steering

    BYTE
    DWORD

[edit] Sacs

    WORD
    BYTE
    BYTE count
    REP count
        DWORD sacs driver

[edit] Slot

    WORD residx RSLT data

[edit] Lighting

    WORD residx LITE data
    4 FLOATS

[edit] VisualState

    3 WORDS (Might be WORD/DWORD or DWORD/WORD)
    DWORD -1?

[edit] Footprint

    BYTE
    WORD residx FTPT data
    DWORD count7
    REP count7
        DWORD
    WORD residx FTPT data (Alternate?)
    DWORD count
    REP count
        DWORD
    BYTE
    FLOAT

[edit] Audio

    DWORD (2)
    2 FLOATs
    DWORD
    FLOAT
Modding Reference by Category

Sims 3 :DBPF | File Types | RCOL(Scene) | Catalog Resource | String Table | Key Table | TS3 Programmer's Reference 

Personal tools
Namespaces

Variants
Actions
Navigation
game select
Toolbox