2A51171B
From SimsWiki
2A51171B | |
---|---|
Short name: | 3DARY |
Long name: | 3D Array |
Contents |
Format
Header
As specified in WDB.
- DWORD
- Block ID (2A51171B)
- DWORD
- Block version (only known version is 1)
- 7BITSTR
- Block name (c3DArray)
Data Section
- DWORD
- Count X
- DWORD
- Count Y
- DWORD
- Count Z
- variable
- Array[Z,X,Y] (see below)
- Array format
- Array[Z,X,Y] is a 3-dimensional array *of Objects* with depth Z, height X, and width Y. The type of data contained within the Object varies by Instance ID. Z is the outer loop, X is the middle loop, and Y is the inner loop, ie:
- Repeat Z times
- Repeat X times
- Repeat Y times
- Object
- Repeat Y times
- Repeat X times
_______________________________________________________________
Instance ID 0x00
- It is for the location of floor tiling, including road tiles.
- DWORD
- Count X [offset ranges: 81-84 / 0x51-0x54] (Width = n1 x 10)
- DWORD
- Count Y [offset ranges: 85-88 / 0x55-0x58] (Height = n2 x 10)
- DWORD
- Count Z [offset ranges: 89-92 / 0x59-0x5C] (number of levels/stories)
- Data storage format
- Note: W = West; N = North; E = East; S = South; "?" = Unknown where Known values of "?" = 0
- 8 Bytes
- Format = W? N? E? S? , where W, N, E, S = any of the floor tile map reference number found in String Map file instance 0x0E
- Based on the pattern, this is apparently the array for floor tile pattern and the value may be the floor tile map reference number (found in instance 0x0E of String Map (SMAP; CAC4FC40) files); 0x0000 = untiled;
- empty3x2= Width=30 & Height=30; LO = Lot Origin; @ = at; F = Front; B = Back; R = Right; L = Left
- eg1 = empty3x2-LO@FR [ 120(0x0001)-120(0x0000)-120(0x0002)-120(0x0003)-120(0x0004)-120(0x0005)-120(0x0003)-120(0x0006)-120(0x0000)-120(0x0001)-2400(0x0000) ]
- eg2 = empty3x2-LO@BR [ 30{80(0x0000)-4(0x0001)-4(0x0000)-4(0x0006)-4(0x0003)-4(0x0005)-4(0x0004)-4(0x0003)-4(0x0002)-4(0x0000)-4(0x0001)-} ]
- eg3 = empty3x2-LO@BL [ 2400(0x0000)-120(0x0001)-120(0x0000)-120(0x0006)-120(0x0003)-120(0x0005)-120(0x0004)-120(0x0003)-120(0x0002)-120(0x0000)-120(0x0001) ]
- eg4 = empty3x2-LO@FL [ 30{4(0x0001)-4(0x0000)-4(0x0002)-4(0x0003)-4(0x0004)-4(0x0005)-4(0x0003)-4(0x0006)-4(0x0000)-4(0x0001)-80(0x0000))-} ]
- empty3x2= Width=30 & Height=30; LO = Lot Origin; @ = at; F = Front; B = Back; R = Right; L = Left
Instance ID 0x01
- Array contains the elevation of the grid points for each level on the lot.
- DWORD
- Count X [offset ranges: 81-84 / 0x51-0x54] (Width = [n1 x 10] + 1)
- (number of grid point along the Width)
- DWORD
- Count Y [offset ranges: 85-88 / 0x55-0x58] (Height = [n2 x 10] + 1)
- (number of grid point along the Height)
- DWORD
- Count Z [offset ranges: 89-92 / 0x59-0x5C] (number of levels/stories)
- Repeat Z times
- Repeat X times
- Repeat Y times
- Float (in singles)
- Elevation
Notes:
- The elevation of each grid point is relative to the Z-Value of the LDEF Lot Description in the neighborhood package.
- The standard elevation for the ground level and roads is 0.
- The standard elevation for each level is 3.0 more than the previous level, or 16-click-high/16-step-high. In other words, each click (in terms of elevation tools)/step (in terms of modular stairs) is 0.1875 in singles.
- The height of walls is determined by the difference in elevations from one level to the next.
- A basement is built at ground level, which is why the ground slopes down when creating a basement.
- A negative elevation means that the grid point is lower than the standard elevation of the lot (usually the elevation of the road). For example, creating a basement will usually move the ground level below the road, so the elevation of those grid points will be negative.
- There is an optional underground level. To determine whether this level exists, check the minimum level of the lot in the WGRA Wall Graph. The only known underground level is the swimming pool; but an underground level can continue to exist even after the swimming pool has been removed.
- If the underground level exists, then:
- The minimum level specified in WGRA will be -1
- Depth = 0 of the Array will contain the elevations of the underground level
- Depth = 1 of the Array will contain the elevations of the ground level
- Otherwise (default):
- The minimum level specified in WGRA will be 0
- Depth = 0 of the Array will contain the elevations of the ground level
- If the underground level exists, then:
- To store arrays of the height values of grid points in singles. And, the story/level of grid point is presumed probably based on values of W, H and story/level probably partly dependent on the same 3D array instance file.
- Negative value can exist in singles and later values can be smaller than the previous values for every story/level as V!ND!CARE's <4-click wall tutorial suggests.
Instance ID 0x03
- Array contains information about locked road tiles on the lot.
- DWORD
- Count X [offset ranges: 81-84 / 0x51-0x54] (Width = n1 x 10)
- DWORD
- Count Y [offset ranges: 85-88 / 0x55-0x58] (Height = n2 x 10)
- DWORD
- Count Z [offset ranges: 89-92 / 0x59-0x5C] (number of levels/stories)
- Data storage format
- BYTE
- Unknown
- Guesses: This may be a road pattern array or tiled grid array?
- (Lot origin is the 'corner point' the shadow points at, and it is the origin a lot rotates at.)
- eg1 = 30 repeats of 20(0x00)-10(0x01) for a lot (Width=30 & Height=30; lot origin @ right & back corner; an empty 3x2 lot)
- eg2 = 30 repeats of 10(0x01)-20(0x00) for a lot (Width=30 & Height=30; lot origin @ left & front corner; an empty 3x2 lot)
- eg3 = 600(0x00)-300(0x01) for a lot (Width=30 & Height=30; lot origin @ left & back corner; an empty 3x2 lot)
- eg4 = 300(0x01)-600(0x00) for a lot (Width=30 & Height=30; lot origin @ right & front corner; an empty 3x2 lot)
- eg5 = 300(0x01)-900(0x00) for a lot (Width=40 & Height=30; lot origin @ right & front corner; an empty 3x3 lot)
- eg6 = 400(0x01)-1200(0x00) for a lot (Width=40 & Height=40; lot origin @ right & front corner; an empty 4x3 lot)
- (Lot origin is the 'corner point' the shadow points at, and it is the origin a lot rotates at.)
Instance ID 0x09, 0x0A, or 0x0B
- They are related to a closed room as data are added into them upon formation of a closed room. Values for room (light, load, place) matches values in instances 0x0B, 0x0A and 0x09 respectively. Not all three will be used or marked when a given closed room is made. The raise in numeric value is accumulative dependent on how many times one is used along the history of undeleted closed rooms in a lot.
- for instance, a wall1 room was made first, it happened all three were employed, then (1,1,1) resulted inside such room. Thirdly, a foundation block was made, (2,2,2) resulted for the inside of the foundation. Fourthly, a room of screen deck was made, (3,3,0) resulted inside the screen room.
Fifthly, a room of column deck was formed, (0,4,0) resulted inside it. Sixthly, a roof room was built , (4,0,3) resulted inside the attic room. Seventhly, a wall1 room was built, (5,5,4) resulted inside the room. Note, the unclosed rooms and the "outside" had (0,0,0) for the three of "room".
- DWORD
- Count X [offset ranges: 81-84 / 0x51-0x54] (Width = n1 x 10)
- DWORD
- Count Y [offset ranges: 85-88 / 0x55-0x58] (Height = n2 x 10)
- DWORD
- Count Z [offset ranges: 89-92 / 0x59-0x5C] (number of levels/stories)
- Data storage format
- Unknown
- repeat count = 2^3 x W x H
- eg1 = 7200(0x00) for empty unbuilt lots of Width=30 & Height=30
- eg2 = 9600(0x00) for empty unbuilt lots of Width=40 & Height=30
- eg3 = 12800(0x00) for empty unbuilt lots of Width=40 & Height=40
- eg4 = 14400(0x00) for empty built lots of Width=30 & Height=30 with the only ground wall deleted
- repeat count = 2^3 x W x H
Instance ID 0x0C
- It is for the location of objects. Unlike floor tile, it stores the instance numbers of object (ObjT) files instead of object IDs or lot-individually assigned reference numbers.
- DWORD
- Count X [offset ranges: 81-84 / 0x51-0x54] (Width = n1 x 10)
- DWORD
- Count Y [offset ranges: 85-88 / 0x55-0x58] (Height = n2 x 10)
- DWORD
- Count Z [offset ranges: 89-92 / 0x59-0x5C] (number of levels/stories)
;DWORD :Count n ;''for each entry'' ;DWORD :unknown
- Data storage format
- Unknown
- Known "values"
- 0x00000001
- 0x00000002
- 0x00000003
- 0x00000004
- 0x00000005
- 0x00000006
- 0x00000007
- 0x00000008
- 0x0000008c (140)
- Array format
- length = 3636 offsets for a 3x2 empty lot
- length = 3648 offsets for a 3x2 lot with 4 extra singly-tiled objects
Instance ID 0x14
- DWORD
- Count X [offset ranges: 81-84 / 0x51-0x54] (Width = n1 x 10)
- DWORD
- Count Y [offset ranges: 85-88 / 0x55-0x58] (Height = n2 x 10)
- DWORD
- Count Z [offset ranges: 89-92 / 0x59-0x5C] (0x00000000)
- Data storage format
- 16 bytes
- Unknown
- Array format
- empty3x2= Width=30 & Height=30; LO = Lot Origin; @ = at; F = Front; B = Back; R = Right; L = Left
- eg1 = empty3x2-LO@FR [(nil/null)]
- eg2 = empty3x2-LO@BR [(nil/null)]
- empty3x2= Width=30 & Height=30; LO = Lot Origin; @ = at; F = Front; B = Back; R = Right; L = Left
Instance ID 0x15
- DWORD
- Count X [offset ranges: 81-84 / 0x51-0x54] (Width = n1 x 10)
- DWORD
- Count Y [offset ranges: 85-88 / 0x55-0x58] (Height = n2 x 10)
- DWORD
- Count Z [offset ranges: 89-92 / 0x59-0x5C] (number of levels/stories)
- Data storage format
- 4 bytes
- unknown (Unlikely Singles)
- Array format
- 4(Width x Height)
- empty3x2= Width=30 & Height=30; LO = Lot Origin; @ = at; F = Front; B = Back; R = Right; L = Left
- eg1 = empty3x2-LO@FR [3600(0x01)]
- eg2 = empty3x2-LO@BR [3600(0x01)]
- empty3x2= Width=30 & Height=30; LO = Lot Origin; @ = at; F = Front; B = Back; R = Right; L = Left
See Also
This article is imported from the old MTS2 wiki. It's original page, with comments, can be found at http://old_wiki.modthesims2.com/2A51171B