Hi there! You are currently browsing as a guest. Why not create an account? Then you get less ads, can thank creators, post feedback, keep a list of your favourites, and more!
Mesh Maestro
Original Poster
#1 Old 7th Aug 2005 at 9:37 AM Last edited by Nysha : 28th May 2015 at 4:04 PM.
Modding InfoCenter - The "Repository" Technique
CREATING A REPOSITORY, LINK TO IT, AND ENABLE SLAVE OBJECTS



DISCLAIMER: This is NOT a tutorial; it is intended to help average-experienced object creators performing specific tasks, or to give users a deeper in-sight on specific modding-related subjects. So, don't expect to find step-by-step explanations, to be performed "blindly". Please DO NOT REPOST the following info, or part of them, on other sites.
All the "Modding InfoCenter" threads are created and maintained by Numenor and JWoods. Everyone is welcome to post his own questions or additional information about the specific thread subject.

SUMMARY: This article gives in depth details on how to prepare a “repository” object, link to it with “slave” objects, and “enable” the slave objects. It applies to all sets that a creator wishes to use the repository feature.The provided snapshots have been taken from UVMapper Pro and SimPE v.042.
This InfoCenter article is also provided in PDF format. To view it, we strongly suggest to download the Foxisoft PFD Viewer: it's free and small, less than 1Mb!

-------------------------------------------------------------------------------------

In this lesson you will learn how to create a “Repository Object” and link to it with your “Slave Object”, and how to “color enable” the “Slave Objects”.
FAQ: “What is a Repository object?” A “Repository Object” is a central object containing all of the “texture related” files needed for an entire set of objects.
FAQ: “What is a Slave object?” A “Slave Object” is one which relies on another object (Repository Object) for its texture related files.
FAQ: “What is the benefit of using the repository feature?” Using this feature allows for “lighter” packages, easy 1 step “full set” re-coloring and, an “efficient” way to perfectly match all the pieces in your set by using the Repository texture(s).
FAQ: “Will the Repository object contain all the textures used by the entire set?” NO: the Repository only contains the recolourable subsets that multiple objects will share; not recolourable textures (e.g. the shadows) will still be contained into the slave objects



Picking an object as the “Repository”

There are a few things to keep in mind when choosing your “Repository” object. The first thing you need to determine is what object in your new set “you” want to be the “Repository” object. I lean toward my “showcase” piece in most cases but sometimes we may want to choose an object with two subsets. In this tutorial we will use a table as the “Repository” object and link to it with our chair object.


Before we can start you must UV map both of your objects to the same texture.I have chosen to create a new Table as the “Repository Object” and a new chair which will be the “Slave Object”.


Part A: Creating and Linking to the "Repository"

Step 1. “Repository Object”: Be sure you have created a texture map that has all the textures in place you need. Here I have UV Mapped my table and constructed a texture map with my wood grain running horizontally and vertically. I also have the same two portions darkened a bit for shadowing effect.



Step 2. Slave Object: Here is my dining chair which is one of the “Slave Objects” in my set. I have UV mapped it to the “Repository Object’s” texture map. You will notice the map also has an area for the chair cushion which is now utilized.



Step 3. Go into your “Repository Object’s” GMDC (Geometric Data Container)/Plugin View/Groups and copy the “Subset” name into the same location in your “Slave Object’s” GMDC /Plugin View/Groups/Subset Name field and click “Commit”.




Step 4. Copy the “Subset Name” from the Repository Objects SHPE/Plugin/Content/Subset Name to the same location in your “Slave Object” SHPE file and click “Commit”.



Step 5. Delete the following files:

TXMT (Material Definition): All but the shadow.

MMAT (Material Override): All.

TXTR (Texture Image): All but shadows.

Step 6. Open your repository object and locate the SHPE (Shape) File/Content/Parts/”your repository shape. Below the “Subset Name” you see the “Material Definition File”, copy that into the same place in your “Slave Object’s” Material Definition File field and click “Commit”. (See image bellow)



That’s it we can go in game and you will see that your “Slave Object” is using the files for the texture from the “Repository Object”.



Part B: Enabling the “Slave Objects”

Step 1. Open the GMND (Geometric Node) and in the “Plugin View”/”Blocklist”/”tsDesignModeEnabled” and enter your objects “Subset Name” in the appropriate field’s and click “Commit”. (See below image).



Step 2. Again in the “Blocklist” pull-down go to the “tsNoShadow (cDataListExtension)” and enter your “Subset Name” in the appropriate field and click “Commit”. (See image below).



Step 3. Click on the “cObjectGraphNode” tab then click the “add” link. In the “Enabled” field enter a “1” for the last digit. In the “Index” field enter the number sequentially as I did in the image by adding “5” then click “Commit”. (Follow numeric instructions in the image below).


FAQ: “What is the 'DataList Extension Reference' shown above, and why should I edit it?" The 'DataList Extension Reference' tells to the game how many 'cDataListExtensions' blocks there are in the GMND; if you open the pull-down Blocklist, you'll see that there are 5 cDataListExtension blocks (don't count blocks that are NOT of the cDataListExtension type!). The 'DataList Extension Reference' must have the exact number of lines as the number of cDataListExtension blocks in the GMND: if there is a line less, then the last block of the GMND will not be read by the game (as if it doesn't even exist!); if there is a line more, the game will crash.


Step 4. Click the “Edit Blocks” tab and then the pull down to find the (cDataListExtension). Next, click the “Add” button and then “Commit”. After you click commit a small error box will appear just ignore this and click “OK” then “OK” again.



Step 5. We need to edit our new DataListExtension so, in the “Blocklist” pull-down menu highlight the new “cDataListExtension” and click on it. Now enter in the “Name” field on the left “tsMaterialsMeshName”. Now we need to add a string so down on the bottom right click the pull down to find the entry “String” and click “Add”. Enter your objects “Subset” name in the “Name” field on the right. Now you need to open your “Repository Object”/Resource Node/Plugin View/Content/cObjectGraphNode tab and copy it’s “filename” without the “_cres” extension and click “Commit” (See image for numeric instructions bellow).



Step 6. Save your package and when you get in-game your “Slave Object” will also be “enabled”.
HINT: In this example, the "Repository" contains only 1 "shared" texture; you can easily add a second shared subset, following the very same steps explained above (if you choose as a Repository an object that already has 2 recolourable subsets, it will be easier).
But the Repository can contain any number of shared textures, even more than 2, providing a particular structure of the package. Examine the Grand Trianon Floor Mirror to have a working example of a 4-subsets Repository object.



-------------------------------------------------------------------------------------

OTHER USEFUL RESOURCES

Modding InfoCenter Index - Comprehensive list of all the InfoCenter threads
Object Creation Workshop and Repair Center - If your object doesn't work, no matter what you try
Colour Options for "EP-ready" packages - About the texture linking tecniques
Sims 2 start to finish Object Creation Tutorial - Learn how to create your own object




-------------------------------------------------------------------------------------




.
Screenshots
Attached files:
File Type: rar  Creating and Utilizing the Repository Technique.rar (3.53 MB, 1269 downloads) - View custom content

Reading is the key to all knowledge, math is the key to everything.
Advertisement
Inventor
#2 Old 7th Aug 2005 at 1:13 PM
Thank you so much!
Forum Resident
#3 Old 7th Aug 2005 at 1:54 PM
I suggest using a totally seperate, catalogless object as repository.
Mesh Maestro
Original Poster
#4 Old 7th Aug 2005 at 11:41 PM
Maybe I mis understood your post... The idea of creating a seperate repository object that does not show in the "catalogue" or non-object package as a repository is another option. It can be pursuited by the creator after learning the easiest procedure I could give.

Re-cap: If you are capable of utilizing the "Repository" feature then you have the knowledge and freedom to extend the feature. On the other hand if you have no knowledge of it I think it's fair to say the above guide is a good start.
The ModFather
retired moderator
#5 Old 8th Aug 2005 at 1:18 AM
Well said, JWoods

Anyway, as an academic excercise (since I'm not sure that FATD's idea may have practical uses), I'd like to elaborate on this subject.

Warning: this is intended as an advanced application of the Repository technique; as they say in TV, "Don't do this at home!" :D

If an object is designed as a "pure" Repository, and therefore it doesn't need to appear in the catalog, nor in game, it needs a simplified Scenegraphic chain, composed only by a Resource node (the simplest you can find), a Shape and a GMND.
Obviously, since it is a texture Repository, we need also one texture and one Material Definition for each shared subset (as said in the main post, there can be multiple shared subset, even more than 2).

Since the Repository is to be intended as a recolourable object, then we need to include a Material Override for each shared subset, too.
But the Material Overrides contain a reference to the object GUID, and this forces us to add an Object Data to our package, in order to register and store a unique GUID for our Repository.
If we don't add the Object Data, the Repository will work anyway, but all the "slave" objects won't be selectable and recolourable using the "Design Tool": the gam would respond "This object is not recolourable".

So, we'd better add a OBJD, and register a unique GUID, but all the catalog placement options should be unchecked, otherwise we could have unpredictable results

Infact, our "pure" Repository lacks many files: GMDC, BHAVs, BCONs, Pie Menus, Name Reference (will it work without a Name Reference? :confused, Object Functions, and some other "minor" files.

To tell the truth, I'm not absolutely sure that such an object would actually work... In theory it should, though.
As said, "Don't try this at home"! :D

Sorry for clogging the thread with these (probably) useless info, but academic excercises are what I like most! :mag:

I've finally started my Journal. Information only, no questions.

My latest activity: CEP 9.2.0! - AnyGameStarter 2.1.1 (UPD) - Scriptorium v.2.2f - Photo & Plaques hide with walls - Magazine Rack (UPD) - Animated Windows Hack (UPD) - Custom Instrument Hack (UPD) - Drivable Cars Without Nightlife (UPD) - Courtesy Lights (FIX) - Custom Fence-Arches - Painting-TV - Smarter Lights (UPD)


I *DON'T* accept requests, sorry.
Lab Assistant
#6 Old 8th Aug 2005 at 3:35 AM
Thank You!! As always, very useful information for those of us still in the learning stages and extremely easy to follow. You're an excellent teacher and I so appreciate all the free lessons :D

You can find all of my creations here

"The eye sees only what the mind is prepared to comprehend" Robertson Davies
Forum Resident
#7 Old 8th Aug 2005 at 9:45 AM Last edited by Fat D : 8th Aug 2005 at 10:25 AM.
a pure repository may also be a normal object that is just remuved from the catalog. I might try your suggestions to save disk space.

many downloaders are quite selective what they download, so that their catalog won't be clogged. Using my repository style, this allows players to delete ANY of the objects.

For example, if someone wants a clean catalog and downloads the grand trianon bunk beds, he would also need the floor mirror, which he/she would think of as an unneccesary decorative item that clogs the catalog.

Your description works, name references are unneccessary.
The ModFather
retired moderator
#8 Old 8th Aug 2005 at 2:35 PM
Glad to know Sometimes, academic subjects can have practical uses, then! :D

I've finally started my Journal. Information only, no questions.

My latest activity: CEP 9.2.0! - AnyGameStarter 2.1.1 (UPD) - Scriptorium v.2.2f - Photo & Plaques hide with walls - Magazine Rack (UPD) - Animated Windows Hack (UPD) - Custom Instrument Hack (UPD) - Drivable Cars Without Nightlife (UPD) - Courtesy Lights (FIX) - Custom Fence-Arches - Painting-TV - Smarter Lights (UPD)


I *DON'T* accept requests, sorry.
Mesh Maestro
Original Poster
#9 Old 8th Aug 2005 at 4:18 PM
Quote: Originally posted by Fat D
a pure repository may also be a normal object that is just remuved from the catalog. I might try your suggestions to save disk space.

many downloaders are quite selective what they download, so that their catalog won't be clogged. Using my repository style, this allows players to delete ANY of the objects.

For example, if someone wants a clean catalog and downloads the grand trianon bunk beds, he would also need the floor mirror, which he/she would think of as an unneccesary decorative item that clogs the catalog.

Your description works, name references are unneccessary.


I am curious as to where I could find your utilization of "your" repository style, I have searched this entire site and yet nothing, please direct me to it as I am curious. If you have in fact come up with such a "style" wouldn't it be a good idea to share it in tutorial form on MTS2?

It seems to me that having any package in your download folder will slow load time weather it shows in the catalouge or not. If we take all our objects and make them so they don't show in the catalogue will the game load faster? I would think using the package in it's entirety would be more resourceful then keeping them hidden... Your example of the floor mirror really makes no sense to me. If you create a non catalogued item as the repository the downloader is still forced to have the package in his/her download folder. This in turn adds the same added weight to thier folder/game. With the downloading traits I see here it seems the users would rather have a useful package they can visually see then a package they can't see. These are the things we must responsibly keep in mind as creator's...

Reading is the key to all knowledge, math is the key to everything.
Inventor
#10 Old 8th Aug 2005 at 4:24 PM
I like Fat D's idea... So if you make a set, not only will it match, there is no mandatory object. You could just say 'The 0d2RespBV.package file is required.'
Forum Resident
#11 Old 8th Aug 2005 at 4:32 PM
I use it for my Half-Walls (new meshes-build mode).
I don't feel like I'm skilled enough to wirte a tutorial.
Yes, it doesn't change the load time, but it changes the catalog length.
One horse disagreer of the Apocalypse
#12 Old 8th Aug 2005 at 5:39 PM
Interesting info in this thread, thanks. I intend to try it some time.

Thing is, if I come back to look for it at a later date, I'd probably look for it in the Object Creation and Texturing forum or the Meshing tutorials, not here. I don't know if anyone else thinks that way?
Forum Resident
#13 Old 8th Aug 2005 at 5:46 PM
i have tried to find it there multiple times.
The ModFather
retired moderator
#14 Old 8th Aug 2005 at 6:25 PM
These are not Tutorials, it's more like a Wiki (actually, the InfoCenter will host Wiki data, later on)
Forum Resident
#15 Old 8th Aug 2005 at 7:40 PM
but I think they are closer to tutorials than to ideas/question etc., which is usually here.
The ModFather
retired moderator
#16 Old 8th Aug 2005 at 9:40 PM
Well, yes, sometimes they looks like tutorials (but only because we use a lot of pics), but basically they are intended to be a mine on information

Few people know the wiki because... it has no pics! We wanted to create a reference point for modders. Now we are just at the beginning, but later on we'll create a thread for each filetype, e.g. the Material Definition, the Geometry Node, etc...
Instructor
#17 Old 9th Aug 2005 at 2:04 PM
Thank you, JWoods!

I already investigated some packages of the Grand Trianon Collection which was quite difficult as I got error messages and couldn't open/save the cloned packages, including the repository - is this caused by the 'ignored' error message during the slave object creation??? (Or are just some of my downloaded objects currupt? Oh well...) Anyway, without this tutorial I still would have been lost so thanks again, Jack
Quote: Originally posted by Numenor
Now we are just at the beginning, but later on we'll create a thread for each filetype, e.g. the Material Definition, the Geometry Node, etc...

Great news! :thumb:
So far the wiki isn't helpful to me (tried to find out what's this LIFO for but the listed 'infos' are even more confusing...) Will you include a "what's this good for" for (dumb) starting creators like me who don't know anything about programming languages, don't know what the listes entries like "4 unknown x(Always a power of 2 aka 16,32,64 etc)" should tell them? In this case the wiki can become helpful to more people - even without pics

Yes, I am serious though I'm not serious at all. I'm serious about this!
Even the joker can be deadly serious...
Wichtig ist, was hinten raus kommt!
Entscheidend daran ist, wie?
The ModFather
retired moderator
#18 Old 9th Aug 2005 at 2:08 PM
Quote: Originally posted by Khaibit
I already investigated some packages of the Grand Trianon Collection which was quite difficult as I got error messages and couldn't open/save the cloned packages, including the repository - is this caused by the 'ignored' error message during the slave object creation??? (Or are just some of my downloaded objects currupt? Oh well...)


The "error" reported in the article is only an information: it simply says that the name of the newly added cDatalistExtension block is empty (it will be filled in the next step).
The problem you are having opening the packages aren't related to that: it's either a bad download or a bad installation of SimPE/.NET.

I've finally started my Journal. Information only, no questions.

My latest activity: CEP 9.2.0! - AnyGameStarter 2.1.1 (UPD) - Scriptorium v.2.2f - Photo & Plaques hide with walls - Magazine Rack (UPD) - Animated Windows Hack (UPD) - Custom Instrument Hack (UPD) - Drivable Cars Without Nightlife (UPD) - Courtesy Lights (FIX) - Custom Fence-Arches - Painting-TV - Smarter Lights (UPD)


I *DON'T* accept requests, sorry.
Instructor
#19 Old 9th Aug 2005 at 2:36 PM Last edited by Khaibit : 9th Aug 2005 at 3:13 PM. Reason: *blind*
:laugh: I read the tutorials/infos on my "workspace" PC carefully when I can follow the steps - should have taken a closer look first *shame*

Hopefully this problem will be fixed with version 0.44 - downloading the required managed DirectX 9c. A clean install seems to be helpful, too. And reading! Didn't notice problems with my game.

Yes, I am serious though I'm not serious at all. I'm serious about this!
Even the joker can be deadly serious...
Wichtig ist, was hinten raus kommt!
Entscheidend daran ist, wie?
Field Researcher
#20 Old 29th Aug 2005 at 7:08 PM Last edited by Samekh : 29th Aug 2005 at 8:42 PM.
Hia, I recently discovered I could (infact) make things appear smooth when before they had looked angular. That's thanks to something I found yesterday about Numenor using Wings where he said how he auto smoothed things. (How did I ever miss that - it works like a dream with the output from GMAX). So I've decided to redo all of my meshes as low poly with this smoothing effect. Since I have to map everything again I thought I'd go for the repositry technique (the one that Fat D was talking about) with a maximum of about three repositry items (simple cubes should save space I thought), one for soft furnishings, one for plumbing etc. Therefore I could have texture images with complimentary patterns and colours and people would be able to download the repositry item and it's colour options and make matching sets from my things without clogging up their folder too much with multiple texture images that were very close copies of eachother. I cloned the ming vase for my repositry cube and, using SimPE version 44, I'm trying to link the first of my remakes to it. Now it's recolourable but the chair from the connectable set I made isn't. The chair shows the initial texture of the cube. When the chair was borrowing from the Club sofa set in the prior version, it was recolourable.

I'm finding it a little hard (I thought I knew how to do this but...). This tut (technically a non tut) at the top, created before version 44?

If the cube is recolourable but the chair no longer is, do I need to tsdesignmode enable the chair too?

I know this is a controversial thing to do, is it more efficient and economical or not? Don't know yet. It might happen that us meshers all start to use the same images, some for hard items, some for soft, wood, plastics etc. and map our items accordingly. The image for my repositry cube is quite big, I know, but I'm hoping to be able to use if for most of my meshes and I thought carefully about spaces for colour blocks and fabric, plastic and wood textures. I thought about the things I made and how many textures were involved. Obviously I'll have to have seperate repositry items for my frame and picture meshes. I would love to stick them up here but it would be too close to breaching copyright. That's why I didn't do it in the first place. Ukranian modernist art. Wonderful stuff. And, ofcourse, the pages from my Lewis Carroll book, those brilliant engravings. Can't do that either sorry.

Thanks too, Numenor! You don't know how much you helped me with those few words about Wings but it will revolutionise things for me! Actually, it might have been J Woods talking about what Numenor did but thanks to both of you anyway.

I don't expect an answer soon (a yes or no). I must apologise for living in the (is this right?) temperate zone. Not many hurricanes here. Very small earthquakes. I hope everything is alright in S.E. America. Florida, Louisiana, Mississippi, etc. I love Florida. I loved Boca Grande and Coco Beach. On Coco Beach there are little shell fish that come up every time the waves recede. And the pelicans. They're fab. Where we stopped in Lemon Avenue on the Gulf of Mexico was just fantastic, Edward Hopper houses that had been there since the turn of the century. Are they gone now? Those weatherboard constructions? I would love to live in Florida but how on earth can anyone stand the storms?

I hope you're OK J woods, you and your family.
The ModFather
retired moderator
#21 Old 29th Aug 2005 at 10:16 PM
The Repository only need a tsDesignModeEnabled block; all the "slave" objects, on the other hand, need a tsDesignModeEnabled block and a tsMaterialsMeshName block, pointing to the CRES of the Repository.

In my personal experience, I've found that it's very easy to mispell the blocks names (in particular, I usually mispell the tsMaterialsMeshName: only "Materials" is plural, while "Name" is singular).

If your object borrows the default texture from the repository, then the Shape is OK: the problem must be in the tsMaterialsMeshName block (either in the block name or in the CRES reference within the block). Double check it. Be sure that the CRES reference has the ##0x1C050000! prefix.

Remember also that slave objects don't have Material Overrides.

I've finally started my Journal. Information only, no questions.

My latest activity: CEP 9.2.0! - AnyGameStarter 2.1.1 (UPD) - Scriptorium v.2.2f - Photo & Plaques hide with walls - Magazine Rack (UPD) - Animated Windows Hack (UPD) - Custom Instrument Hack (UPD) - Drivable Cars Without Nightlife (UPD) - Courtesy Lights (FIX) - Custom Fence-Arches - Painting-TV - Smarter Lights (UPD)


I *DON'T* accept requests, sorry.
retired moderator
#22 Old 31st Aug 2005 at 3:34 PM
I have a question, and I'm sorry if it sounds stupid, but I just don't understand.

When you say "UV mapped it to the repository object"... what exactly does that mean or entail?

Does that mean that you add your slave object to the repository object's UV map?

I'm really confused on this one.
Fluffy
retired moderator
#23 Old 31st Aug 2005 at 4:01 PM
Grapholina,
basically, you're thinking in terms of texture image, and making your UV-maps 'fit'. At least, that's how I do it
First, take a look at all the objects you want to use in your repository set.
Then, count the number of different textures you'll need.
Say, a darker texture for the shadowy sides, a lighter on top, and a third for differentiating.
That means that your texture image will consist of three parts.
The top left corner will be that dark texture, the top right corner the light texture, and the bottom half will be the rest.
Now, uv-map all your objects in function of that texture image.
Make sure that when uv-mapping, all the dark parts go in the top right corner of the map, the light parts in the top left corner, etc.
So all your objects are uv-mapped separately, but 'fit' the same texture image, that of the main repository object.
Does that make sense?
retired moderator
#24 Old 31st Aug 2005 at 5:31 PM
That makes a lot of sense. Thank you for the explanation. So... just to make sure I have this right... I'm only going to create one map, making sure that it fits all the objects; right?
Fluffy
retired moderator
#25 Old 31st Aug 2005 at 6:54 PM
Um, no (darn, I'm not good at this explaining thing, am I)

The whole point is to make only one texture image,
but, you need to make a uv-map for every object you have, otherwise it won't be textured.
So if you have, say, six objects. That will leave you with a repository set with six uv-maps and one texture image. The texture image will be attached to the 'repository object'.
The 'slave objects' still have their own uv-maps, but those uv-maps are geared toward the one texture image.
So, for a normal object, what you'd do is have a uv-map, and then build the texture around it.
For repository objects, it's safest to do it the other way round.
Um, let me give you some examples: (should have thought of this before )

This is my repository texture image:


this is the uv-map of the repository object:


and this one, is the uv-map of one of the slave objects. It's a smaller, simpler mesh than the repository object, but note how it's spread out to 'fit' the texture image of the repository object.
Page 1 of 4
Back to top