- Site Map >
- Modding and Creation >
- Sims 3 Creation >
- Modding Discussion >
- Change where objects are placed on surfaces.
- Site Map >
- Modding and Creation >
- Sims 3 Creation >
- Modding Discussion >
- Change where objects are placed on surfaces.
Posts: 2,932
Thanks: 15574 in 28 Posts
Posts: 209
Thanks: 1943 in 29 Posts
dwords) would translate into Floats that are astronomically huge or microscopically tiny.
and those that translate into reasonable floats make stupid rotation values
such as 0.70710700750351, why rotate 255, when -105 is faster?
I've seen different path slot types, where the only way to know if has a different function is by the value in the 1st dword/float for each coordinate.
Some Path slots even keep one of the coordinates in a different float,
while the value that should have it holds a value that matches or is the opposite of the 1st value.
Then there are the Effect slots, thier usage varies widely, but they follow the same pattern, every effect slot that is used for the same use, has the same
exact values (except for the XZY coords) as every other effect slot with the
same use. no matter what the object is or the slots placement in relation to the mesh.
and then there's container slots, is there a reason to have rotation data on
container slots ??
and why 3 rotation values for the X-coordinate, 3 for the Y-coordinate
and 1 for the Z-coordinate?
That's 9 rotation axiis when there are only 3.
The wikki entry for rslt's needs updating too, it has the names in the wrong
positions and doesn't mention the extra dword the container slots have.
Posts: 108
Thanks: 3466 in 5 Posts
As for container slots needing the rotation, yes that is very likely. When an object is snapped into a slot, its animations should be relative to the local coordinate system of that slot rather than the global coordinate system. This includes position and orientation.
Also, my observations may only be valid in the base game, as I have no expansions.
Posts: 2,932
Thanks: 15574 in 28 Posts
The tougher they make it the more people get frustrated and walk away from modding it. The more people that walk away the more downloaders are forced to get any new content from the EA Store. What you're saying, Raven Shadow goes right along with that theory...they make the thing a ridiculous puzzle and the end result is fewer modders and more sales for them. The programmer attrition in this version of the Sims has been significant as a result. It's a follow the money issue for EA and the community surrounding this game IMO. Just my two cents.
Posts: 209
Thanks: 1943 in 29 Posts
But they have no rotation values stored in the rslt, causing me to believe the game just orients to
the front or back of the mesh.
But container slots, even those for sims only use 2 non-zero values per coordinate.
One is commonly used by doors and paths ( 00 00 80 3F ) and the other is the XYZ cooridinate.
BTW 00 00 80 3F = dec 1 or int 1065353216.
Now the X & Y coordinate blocks usually have 3 zero values each, one of which could be for rotation ,
to make a slot that makes objects lie on thier side. That would have to be tested for.
Don't worry, OrangeMittens. you're not the only one.
It's a shame they don't realize they could make even more money following Creature Labs modding moto.
"If they're gonna mod our game, let's sell them the tools to do so."
Posts: 209
Thanks: 1943 in 29 Posts
Nice find, with just a few lines of C# and that dll, I can read the rig data. Although the actual SDK is quite costly, the dll itself exposes the api barely enough to work with(you get the size of the parameters, but have to guess what they are). |
whelp, I missed this part of your post, sorry.
I also found source code for an Eve Online modding tool that uses the dll
to extract mesh/texture data from thier .gr2 files.
and I've been trying to find out if anyone could use these to,
at the very least, extract data from the TS3 .gr2 files into a format
that can be hex edited?
Do you wan't the source code?
I apologize for asking what is probably a silly question...but I don't know much about coding. I just wonder if the information you just posted is getting us closer to being able to change table heights and slots. Again...I'm sorry to ask...the conversation is a little over my head but I still wanna know. |
Yes, that info is enough to edit table slot heights right now.
I'm currently using the info to convert the pedestal cube into a set of shorter
stackable shelving units, that use an RSLT that I hand made myself.
Posts: 7,898
Thanks: 204721 in 302 Posts
Life Stories || EA Sims 2 Store Items || EA Pre-Order Incentives || Pet Stories || Dog Agility Items || Castaway Stories || Holy Simoly Add-ons || Overrides and Defaults
4esf Archive || Holy Simoly Archive || Sims2Artists || tumblr || CEP-Extras List || Buyable Game Ojbects
If you enjoy the content on s2a or GoS, consider donating to support hosting costs.
Posts: 209
Thanks: 1943 in 29 Posts
Do you want the source code to see if it can help you read the _rig file?
Posts: 2,932
Thanks: 15574 in 28 Posts
And, if anyone ever figures out how to make the whole thing move together, how much of a fix do you figure that would be to the object someone made that doesn't have the slot moving with the object?
Er...and how do you alter the height of a surface? Does it require hex editing right now?
I'm with you RavenShadow...I just want to have stuff at different levels. If that requires manually moving a slotted item placed on a surface that's ok. The alternative is meshing stuff that has things already placed on it in the mesh itself...and that isn't a good solution IMO.
I would also like to thin the slotting...to make surfaces thinner...you know...so something someone puts on it isn't hovering in space in front, at a side, or behind the more narrow surface. Can that be done?
Posts: 108
Thanks: 3466 in 5 Posts
whelp, I missed this part of your post, sorry. I also found source code for an Eve Online modding tool that uses the dll to extract mesh/texture data from thier .gr2 files. and I've been trying to find out if anyone could use these to, at the very least, extract data from the TS3 .gr2 files into a format that can be hex edited? Do you wan't the source code? |
It may be helpful to see some source that re-compresses the data. I already can decompress/read the data, but have had no such luck with any of the functions that would repack it. Luckily, once it is decompressed, there is nothing to decode(the data structure is defined in the dll) and it is very readable; only without the ability to re-compress the data, we are no further than we were using the official radgametools granny file viewer.
Er...and how do you alter the height of a surface? Does it require hex editing right now? |
The current QA version of S3PE can edit the RSLT.
Posts: 209
Thanks: 1943 in 29 Posts
right now you can control the exact X Y & Z Coordinate of every container slot on your surface, period.
Objects will sit as close or as far above the surfave as you want, all you have to do is change the Y coordinate in the RSLT for that
or any slot you want changed.
The only thing that can't be currently done, is edit the settings controlled by the _rig file which allows objects placed on a table to be moved
when you move the table, or dinning room chairs to move when the dinning room table they assigned to is moved.
Other then that you can make a custom surface with any height you want, with container slots positioned at a height that fits that surface.
As an example I've attached my current project for you to look at.
It's 6 wall shelves that were cloned from the trophy case
(thus no container slots to start) each shelf is a different height
and has 14 defined container slots.
It's an early version and can be found under Decor -> Misc Decor
Wall Shelf Kit.zip (123.3 KB, 12 downloads) - View custom content | ||||||||||
209017 03-28-10 21:10 Wall Shelf Kit.package -------- ------- 209017 1 file |
Posts: 209
Thanks: 1943 in 29 Posts
It may be helpful to see some source that re-compresses the data. I already can decompress/read the data, but have had no such luck with any of the functions that would repack it. Luckily, once it is decompressed, there is nothing to decode(the data structure is defined in the dll) and it is very readable; only without the ability to re-compress the data, we are no further than we were using the official radgametools granny file viewer. |
Well as I said this is for Eve Online, and from what I've read, they approve of the app.
But It's an under developed tool and has it's limits, but It does allow
that games' modders to extract Mesh, Texture & Animation data from
EO's .gr2 files, modify them and import the changes back into thier .gr2
file.
I wish you further luck with it, being able to edit the _rig
(even if it's with a hex editor) is an important step in TS3 modding.
I've attached the source with 2 versions of the dll.
Mostly because I've read that dll version can be important if the files your
working with use an older format.
triexporter.zip (6.38 MB, 13 downloads) - View custom content | ||
7776 04-09-08 02:37 TriExporter/3d.cpp 2357 10-20-05 17:13 TriExporter/3d.h 5197 07-15-05 12:03 TriExporter/3ds.h 1048 07-12-05 08:20 TriExporter/AboutDlg.h 793 09-16-05 00:30 TriExporter/arcball.cpp 953 09-16-05 00:30 TriExporter/arcball.h 7640 08-24-09 15:18 TriExporter/d3dhelper.h 0 08-24-09 15:07 TriExporter/DX9/ 151761 10-02-07 09:56 TriExporter/DX9/d3d9.h 23004 10-02-07 09:56 TriExporter/DX9/d3d9caps.h 76649 10-02-07 09:56 TriExporter/DX9/d3d9types.h 1933 10-02-07 09:56 TriExporter/DX9/d3dx9.h 43369 10-02-07 09:56 TriExporter/DX9/d3dx9anim.h 23921 10-02-07 09:56 TriExporter/DX9/d3dx9core.h 42312 10-02-07 09:56 TriExporter/DX9/d3dx9effect.h 59604 10-02-07 09:56 TriExporter/DX9/d3dx9math.h 45267 10-02-07 09:56 TriExporter/DX9/d3dx9math.inl 128409 10-02-07 09:56 TriExporter/DX9/d3dx9mesh.h 46856 10-02-07 09:56 TriExporter/DX9/d3dx9shader.h 7943 10-02-07 09:56 TriExporter/DX9/d3dx9shape.h 61840 10-02-07 09:56 TriExporter/DX9/d3dx9tex.h 12012 10-02-07 09:56 TriExporter/DX9/d3dx9xof.h 0 08-24-09 15:11 TriExporter/DX9/x64/ 5092 10-02-07 09:56 TriExporter/DX9/x64/d3d9.lib 83156 10-12-07 15:14 TriExporter/DX9/x64/d3dx9.lib 83492 10-12-07 15:14 TriExporter/DX9/x64/d3dx9d.lib 4312 10-02-07 09:56 TriExporter/DX9/x64/ddraw.lib 599682 10-22-07 03:09 TriExporter/DX9/x64/dxguid.lib 0 08-24-09 15:11 TriExporter/DX9/x86/ 5210 10-02-07 09:56 TriExporter/DX9/x86/d3d9.lib 89572 10-12-07 15:14 TriExporter/DX9/x86/d3dx9.lib 89910 10-12-07 15:14 TriExporter/DX9/x86/d3dx9d.lib 4540 10-02-07 09:56 TriExporter/DX9/x86/ddraw.lib 570238 10-22-07 03:21 TriExporter/DX9/x86/dxguid.lib 6082 03-05-08 10:29 TriExporter/grannyfile.cpp 2138 01-07-08 11:51 TriExporter/grannyfile.h 0 11-20-08 14:07 TriExporter/grannystuff/ 143391 01-07-08 10:25 TriExporter/grannystuff/AutoGranny.h 4092 01-07-08 11:25 TriExporter/grannystuff/Granny.h 502784 10-10-06 13:45 TriExporter/grannystuff/granny2.dll 9681 12-03-07 16:59 TriExporter/grannystuff/structs.h 25990 01-07-08 11:00 TriExporter/half.cpp 418 01-07-08 11:00 TriExporter/half.h 311 09-16-05 00:06 TriExporter/helper.h 0 08-24-09 15:02 TriExporter/lib3ds/ 7525 08-24-09 14:44 TriExporter/lib3ds/atmosphere.cpp 2596 08-24-09 14:06 TriExporter/lib3ds/atmosphere.h 444 08-24-09 14:06 TriExporter/lib3ds/AUTHORS 6111 08-24-09 14:44 TriExporter/lib3ds/background.cpp 2062 08-24-09 14:06 TriExporter/lib3ds/background.h 5526 08-24-09 14:44 TriExporter/lib3ds/camera.cpp 1887 08-24-09 14:06 TriExporter/lib3ds/camera.h 11663 08-24-09 14:06 TriExporter/lib3ds/ChangeLog 5786 08-24-09 14:44 TriExporter/lib3ds/chunk.cpp 11460 08-24-09 14:06 TriExporter/lib3ds/chunk.h 11708 08-24-09 14:06 TriExporter/lib3ds/chunktable.h 17992 08-24-09 14:06 TriExporter/lib3ds/COPYING 1737 08-24-09 14:44 TriExporter/lib3ds/ease.cpp 1304 08-24-09 14:06 TriExporter/lib3ds/ease.h 44871 08-24-09 14:44 TriExporter/lib3ds/file.cpp 4766 08-24-09 14:06 TriExporter/lib3ds/file.h 9240 08-24-09 14:06 TriExporter/lib3ds/INSTALL 9672 08-24-09 14:49 TriExporter/lib3ds/io.cpp 3715 08-24-09 14:06 TriExporter/lib3ds/io.h 904 08-24-09 14:06 TriExporter/lib3ds/lib3ds.rc 11112 08-24-09 14:44 TriExporter/lib3ds/light.cpp 2362 08-24-09 14:06 TriExporter/lib3ds/light.h 30058 08-24-09 14:44 TriExporter/lib3ds/material.cpp 4754 08-24-09 14:06 TriExporter/lib3ds/material.h 14403 08-24-09 14:44 TriExporter/lib3ds/matrix.cpp 3036 08-24-09 14:06 TriExporter/lib3ds/matrix.h 25767 08-24-09 14:49 TriExporter/lib3ds/mesh.cpp 5529 08-24-09 14:06 TriExporter/lib3ds/mesh.h 11135 08-24-09 14:06 TriExporter/lib3ds/missing 0 08-24-09 14:06 TriExporter/lib3ds/NEWS 28725 08-24-09 14:44 TriExporter/lib3ds/node.cpp 4762 08-24-09 14:06 TriExporter/lib3ds/node.h 7083 08-24-09 14:51 TriExporter/lib3ds/quat.cpp 2642 08-24-09 14:06 TriExporter/lib3ds/quat.h 633 08-24-09 14:06 TriExporter/lib3ds/README 3801 08-24-09 14:44 TriExporter/lib3ds/shadow.cpp 1594 08-24-09 14:06 TriExporter/lib3ds/shadow.h 3242 08-24-09 14:44 TriExporter/lib3ds/tcb.cpp 1913 08-24-09 14:06 TriExporter/lib3ds/tcb.h 1 08-24-09 14:06 TriExporter/lib3ds/TODO 29208 08-24-09 15:02 TriExporter/lib3ds/tracks.cpp 6881 08-24-09 14:06 TriExporter/lib3ds/tracks.h 4542 08-24-09 14:59 TriExporter/lib3ds/types.h 1822 08-24-09 14:06 TriExporter/lib3ds/types.txt 6659 08-24-09 14:44 TriExporter/lib3ds/vector.cpp 2538 08-24-09 14:06 TriExporter/lib3ds/vector.h 14342 08-24-09 14:47 TriExporter/lib3ds/viewport.cpp 3675 08-24-09 14:06 TriExporter/lib3ds/viewport.h 17330 08-24-09 15:32 TriExporter/MainDlg.cpp 3630 01-03-08 18:40 TriExporter/MainDlg.h 0 11-20-08 14:07 TriExporter/res/ 3594 01-03-08 18:08 TriExporter/res/icons.bmp 596 07-12-05 08:20 TriExporter/res/TriExporter.exe.manifest 1078 12-06-03 03:12 TriExporter/res/TriExporter.ico 2204 12-20-05 23:27 TriExporter/resource.h 288 07-12-05 08:20 TriExporter/stdafx.cpp 564 07-30-05 01:27 TriExporter/stdafx.h 1437 07-18-05 07:32 TriExporter/StuffDlg.h 2837 01-03-08 17:49 TriExporter/StuffFile.cpp 640 01-03-08 17:49 TriExporter/StuffFile.h 1375 09-15-05 14:53 TriExporter/TriExporter.cpp 18 07-12-05 08:20 TriExporter/TriExporter.h 16690176 08-24-09 15:35 TriExporter/TriExporter.ncb 8680 01-04-08 12:52 TriExporter/TriExporter.rc 1236 08-24-09 15:12 TriExporter/TriExporter.sln 16049 08-24-09 15:24 TriExporter/TriExporter.vcproj 11868 01-03-08 15:58 TriExporter/TriFile.cpp 1522 01-03-08 18:59 TriExporter/TriFile.h 2028 10-17-05 18:28 TriExporter/UnstuffDlg.h 0 08-24-09 14:53 TriExporter/WTL/ 44457 06-10-07 22:16 TriExporter/WTL/atlapp.h 62001 06-10-07 22:16 TriExporter/WTL/atlcrack.h 271080 06-10-07 22:16 TriExporter/WTL/atlctrls.h 121865 06-10-07 22:16 TriExporter/WTL/atlctrlw.h 128966 06-10-07 22:16 TriExporter/WTL/atlctrlx.h 15705 06-10-07 22:16 TriExporter/WTL/atlddx.h 173511 06-10-07 22:16 TriExporter/WTL/atldlgs.h 28077 06-10-07 22:16 TriExporter/WTL/atlfind.h 103059 06-10-07 22:16 TriExporter/WTL/atlframe.h 100092 06-10-07 22:16 TriExporter/WTL/atlgdi.h 96298 06-10-07 22:16 TriExporter/WTL/atlmisc.h 30094 06-10-07 22:16 TriExporter/WTL/atlprint.h 9837 06-10-07 22:16 TriExporter/WTL/atlres.h 2614 06-10-07 22:16 TriExporter/WTL/atlresce.h 58078 06-10-07 22:16 TriExporter/WTL/atlscrl.h 24573 06-10-07 22:16 TriExporter/WTL/atlsplit.h 34970 06-10-07 22:16 TriExporter/WTL/atltheme.h 32073 06-10-07 22:16 TriExporter/WTL/atluser.h 84643 06-10-07 22:16 TriExporter/WTL/atlwince.h 14493 06-10-07 22:16 TriExporter/WTL/atlwinx.h 106444 03-25-10 17:43 granny2.zip -------- ------- 21684003 136 files |
Posts: 2,932
Thanks: 15574 in 28 Posts
Posts: 209
Thanks: 1943 in 29 Posts
it will be because the data in the _rig will be out of sync with the RSLT file, but the table will hold objects.
Removing slots is a little complicated if you're just learning to work with slots, but, thankfully
the latest QA version of S3PE now displays slot details, and you can use it to add, remove or move slots more easily.
Posts: 11,682
Thanks: 9680 in 11 Posts
"You can do refraction by raymarching through the depth buffer" (c. Reddeyfish 2017)
Posts: 209
Thanks: 1943 in 29 Posts
Really, messing with the RSLT as a non-prammer, has me confused enough, without your mischief ..
In all seriousness tho' .... *sigh* yeah, I've played games that use the Z axis
for height in-game, a real pain to mod.
But too my knowledge, Wes never mentioned his tools needing to rotate
meshes for import into MS.
Part of my confusion stems from the following:
If you split the block into X Y & Z related blocks, you get something like
00 00 80 BF 00 00 00 00 00 00 XX XX 00 00 00 00 00 00 00 00 00 00 80 3F 00 00 00 00 00 00 00 00 00 00 YY YY 00 00 00 00 00 00 80 BF 00 00 ZZ ZZ
If the 1st value, in each of the 3 blocks, is Rotation , I could believe it, since the Z block has no extra
dwords available.
If thats true, what are the other 6 values for?
I know that certain Path Slots use 2 of them (they hold the opposite value
of the 1st float in each block)
Posts: 2,932
Thanks: 15574 in 28 Posts
http://www.modthesims.info/showthread.php?t=382724
she said S3 uses the same x, y, z as Milkshape does.
Posts: 108
Thanks: 3466 in 5 Posts
--[1]-- SlotName: 0xA820F8A7 BoneName: 0x85D6179D TransformMatrix: X: Y: Z: [0:'0'] [4:'0'] [8:'-1'] X Axis Vector [1:'0'] [5:'1'] [9:'0'] Y Axis Vector [2:'1'] [6:'0'] [A:'0'] Z Axis Vector [3:'-0.031603'] [7:'0.486862'] [B:'0.072369'] Origin SlotPlacementFlags: 0x00000100 (Sim)
Looking at one in s3pe, this is how I would arrange it as a 4x3 matrix. The XYZ orientation vectors are normalised(length equals 1 unit) 3d vectors for the axes relative to the origin.
The example is the container slot for a crib(0x5E6BDD4EA80D024C), so you see up is Y(translates up 0,48 units).
Posts: 209
Thanks: 1943 in 29 Posts
any suggestion on where to look for beginner info on converting tranformation matrices into
understandable rotation values?
Posts: 11,682
Thanks: 9680 in 11 Posts
"You can do refraction by raymarching through the depth buffer" (c. Reddeyfish 2017)
Posts: 11,006
Thanks: 422952 in 1121 Posts
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.
Posts: 209
Thanks: 1943 in 29 Posts
I can get the routing slots working (as in change location of them) but I can't seem to affect sim-containing slots such as found in chairs (the sim still sits in exactly the same place when she gets to the object). And even more annoyingly I can't find a sim containing slot at all on a bed - they are all containers for end tables, apparently!! |
Don't know if it's related, but the sim holding objects I looked at used them oddly.
They have 1 containe slot and 1 effect slot for each sitting position
and they have the same exact coordinates, so when viewing the object
in TSRW you only see 1 of them, usually the effect slot.
As amatter of fact, I looked at Chair Living Modern, so if you
clone that one and view it in TSRW, you'll see 3 routing slots
and 2 effect slots.
1 Effect slot is at 0,0,0 and the 2nd one has the same coordinates as the container slot.
Try keeping the effect slot's coords in sync with the container slot's.
edit:
Oh, and just in case, keep the middle routing slot lined up with the
effect/container slots, too (i.e. the same x & y coords, only z is different).
Posts: 209
Thanks: 1943 in 29 Posts
Every time I've seen the words "Transformation Matrix" in reference to TS3's RSLT,
I treated it as if it said "Rotation Matrix".
I still don't really understand exactly what kind of matrices the RSLT is storing,
But I think you're reading it as some sort of Translation matrix.
Yet from what I've read, so far, it looks like a backwards identity matrix
except that the -1 would indicate that the Z-axis is mirrored,
which would make it a Scaling Matrix.
Also sim containers have a 2nd matrix stored in it's associated effect slot,
in the crib's case, the 2nd matrix is exactly the sme as the 1st.
Code:
--[1]-- SlotName: 0xA820F8A7 BoneName: 0x85D6179D TransformMatrix: X: Y: Z: [0:'0'] [4:'0'] [8:'-1'] X Axis Vector [1:'0'] [5:'1'] [9:'0'] Y Axis Vector [2:'1'] [6:'0'] [A:'0'] Z Axis Vector [3:'-0.031603'] [7:'0.486862'] [B:'0.072369'] Origin SlotPlacementFlags: 0x00000100 (Sim) Looking at one in s3pe, this is how I would arrange it as a 4x3 matrix. The XYZ orientation vectors are normalised(length equals 1 unit) 3d vectors for the axes relative to the origin. The example is the container slot for a crib(0x5E6BDD4EA80D024C), so you see up is Y(translates up 0,48 units). |
How did you get at that?
that would put the contents of the sims slot 1.4m (roughly) above the crib.
hhmmm , I also read somewhere that -1 would be a 90 degree counter-clockwise rotation and 1 would be a 90 degree clock-wise rotation.
which would make it a rotation matrix if there were 3 matrices with sin/cosine data instead of zeros
Posts: 108
Thanks: 3466 in 5 Posts
Who Posted
|