Back Previous Next

Making an object from scratch

When I start IFF Pencil, it presents me with an empty IFF file, rather like the empty document a word processor opens at startup. Still, I think very few Sims object programmers use this empty file to make an object by adding all the necessary blocks; most of them clone an existing object and then modify the clone. There is something to be said for this: you don't have to reinvent the wheel, you can alter the code you're interested in and leave the rest, and T-Mog, if that's the cloning utility used, inserts a nice new object ID based on your magic cookie. (To reiterate, as not everyone has understood this: an object creator needs only one (1) magic cookie, from which T-Mog will produce endless unique IDs. Sadly, with people requesting a cookie for each new object, I hear the cookies available from the T-Mog site are already being recycled, which means object ID unicity is no longer 100% guaranteed.)

However. Looking at the code of some cloned objects, I see a lot has been left in which could have been thrown out. The Virtuoso Chair, obviously cloned from a multi-chair IFF, contains internal references to all the other chairs. Maxis' Stray-Away sign was clearly cloned from the flamingo, and still contains all the sound file references. The painting IFFs made with Art Studio, being a copy of "paintings.iff", have headings for several paintings, although they only show one. So, cloned objects can be inflated with unnecessary code.


Q.E.D.

In this howto, I'm going to assemble an object from scratch. (As the word "assemble" suggests, I'm not going to write all the code myself. IFF Pencil has a handy Import/Export menu option, and I'll be mostly stripping existing objects of un-needed code and importing the resulting bits into the various blocks of the new objects.) The object to be made is a "Snack J" sign for a character from the anime series "Gatchaman". The sign, a "J" cast in cement, has already been made in a 3D program, and most of the code will come from "PartyBalloons.iff", which attracts visitors; or, in this case, customers.

To create a framework, I'm first going to add every block the object may need, with its initial block id and, in some cases, label:

(I've found that the BCON block made by IFF Pencil is called "corrupt" by IFF Pencil itself when I try to edit it! In this case the block proved unnecessary, but to get a properly working constants block, I should have to import it from an existing object.)

Why would a chunk of cement need a reference to a soundfile? Although the sign is sure to make no sound, it may elicit sounds of admiration from a Sim viewing it. Catalogue-technically, it is, after all, in the decorations category. That's why it gets a GLOB block: to connect it with "ArtGlobals.iff". This block is already present in "paintings.iff", from which I can export STR# blocks 129 and 130, the GLOB block and FWAV blocks #0 to #4, complete with header information, to be re-imported in the empty IFF, where they will overwrite the existing blocks. The file can now be saved as "snackjsign.iff". And that's four headings done.

The TTAB and TTAs blocks from "paintings.iff" shouldn't be used, as they are a bit iffy. Making one's own menu items is very easy, and should preferably be done after filling the BHAV block. So I'll leave those for now, and instead think up a spiffy catalogue name/text for the CTSS block. Like:

Snack J sign

No sentai anime show snackbar can be complete without a concrete cast of its owner's initial. This 3D monogram will attract customers from all over the neighbourhood to drink, dance and party at your snazzy hangout. With a bit of luck, it may even bring in a helpful Galactor spy.

Translated into every language used in The Sims. Haha. No, I just copy the text into all the language blocks. This goes into the CTSS block. How to make the necessary CTSS entries is explained in Wrong names/descriptions. This description is a reference to Dave ("spy V"), a friendly old geezer who comes to help out at the Snack J, and who just happens to be a Galactor trying to discover the Gatchaman team's civilian identities. The sign won't attract anything unusual.

That's five headings done. The catalogue pictures I can't add just yet, and the catalogue values are in the next block to be edited: the OBJD block. This block contains that most vital of information: the unique object ID. I'll edit the values by hand, opening another IFF file's OBJD blocks to copy most of the values; then I'll clone "snackjsign.iff" and copy the resulting generated object ID into the original file. How to clone an object is explained in the documentation that comes with T-Mog. (Mac users can use IFFsnooper to clone objects as explained on Persimmon Grove.) The clone can be thrown away or kept as a spare to import the sprites into later on; I'm keeping it both to put the sprites in (as T-Mog can muck up the OBJD block) and to edit the BHAV block in, so I don't risk doing anything regrettable to the original object.

Looking at the OBJD block in IFF Pencil, I see a long list of things I can fill in values for. Since this block is used in almost every IFF file in the game (houses, objects, interactions, the Sims themselves), it has to cover every possible object property. Most values won't apply to this simple sign. I'll go down the list subheading by subheading.

--- Version information
Version                           138
Object version                    0

The first value is always 138 (this will be already filled in).

--- Multitile info
Master ID                         0
Sub index                         0
--- GUID info
Global Unique ID                  53C6CBB4
Original GUID                     D1EF8174
Original suit GUID                00000000

The Global Unique ID (GUID) is the new number I copied from the cloned object; the original GUID is that of the original object, "PartyBalloons.iff". Since I'll be taking a lot of code from this object, I thought it would be appropriate to put its GUID in this field.

--- ID # values
Base Graphic ID #                 100
Tree Table ID #                   129
Animation table ID #              129
Body strings ID #                 0
Slots ID #                        128
Catalog ID #                      2000
Motive Effects ID#                0
Catalog popup ID #                0
Dynamic sprite base ID #          000
Custom wall style ID #            0

Here, I fill in a number of default values that connect to other blocks. "100" connects to the first DGRP resource, the first "129" to the adult animation STR# resource, the second "129" to the TTAB and TTAs menu blocks, "128" to the SLOT block (which I don't know well enough to tamper with), and "2000" to CTSS, the block with the catalogue description.

--- Price information
Price                             900
Sale price                        0
Initial depreciation              10
Daily depreciation                1
Self depreciation                 1
Depreciation limit                500
--- Graphics
Number of graphics                1
Number of dynamic sprites         0
Thumbnail graphic index           0

Only the first price field matters, the second can be ignored. Since an object's price contributes to its room score, I'm going to make the initial price quite high. The depreciation values I've copied from the "PartyBalloons.iff", but the minimum value the sign can ever have is 500, still quite high. The number of graphics is simply "1"; this sign isn't going to change its appearance.

--- Other
Initial Stack Size                4
Interaction group                 0
Type                              4
Disabled                          0
Global simulation object          0
Wall style                        0
Level offset                      0
Shadow                            0
Number of attributes              0
Front face direction              0
Lead object                       0
Chair entry flags                 0
Tile width                        0
Suit not copyable                 0
Build mode type                   0
Shadow flags                      1
Footprint inset mask              0
Shadow brightness                 150
Number of type attributes         0
Miscellaneous flags               0
Type attribute GUID               00000000
Room flags                        16
Function flags                    64
Category flags (HD+)              16
Unknown HD value 1                0
Unknown HD value 2                0

The values down to "Type attribute GUID" I copied straight from "PartyBalloons.iff", which is a one-tile object and has the same dimensions as the Snack J sign. I set "Shadow" from "-1" to "0", because an object this solid definitely has a shadow! The "Shadow brightness" value was copied from a one-square statue. How to fill Room, Function and Category flags is explained in Making objects buyable and Uncategorized buyables. I changed the values to 16, 32, 2. The Downtown and other buyable flags I've left empty, as this sign attracts neighbours and you can't really have neighbours on a public lot, so the effect would be unreliable or none. This also means I won't have to hex-edit the OBJD block to set non-residential lot flags, since this editor only edits the Downtown flag ("Unknown HD value 1").

--- Old function table
Uses function table (OBJf)        1
Tree ID #: main                   0
Tree ID #: gardening              0
Tree ID #: wash hands             0
Tree ID #: portal                 0
Tree ID #: allow intersection     0
Tree ID #: prepare food           0
Tree ID #: cook food              0
Tree ID #: place on surface       0
Tree ID #: dispose                0
Tree ID #: eat food               0
Tree ID #: pick up from slot      0
Tree ID #: wash dish              0
Tree ID #: eating surface         0
Tree ID #: sit                    0
Tree ID #: stand                  0
Tree ID #: init                   0
Tree ID #: placement              0
Tree ID #: user pickup            0
Tree ID #: load                   0
Tree ID #: placement              0
Tree ID #: room changed           0
Tree ID #: cleanup                0
Tree ID #: level info request     0
Tree ID #: serving surface        0
Tree ID #: clean                  0
Tree ID #: queue skipped          0
Tree ID #: wall adjacency changed 0
Tree ID #: pickup                 0
Tree ID #: update adjacent        0
Tree ID #: repair                 0

Apart from the top value, which should always be "1", this list can be ignored, as these values are now entered into another block, the OBJf block.

--- Ratings
Rating: hunger                    0
Rating: comfort                   0
Rating: hygiene                   0
Rating: bladder                   0
Rating: energy                    0
Rating: fun                       0
Rating: room                      2
Rating: skill flags               0

This is where I fill in the catalogue values. Any zero values are ignored, while positive or negative values show up as "Room: 2" or "Comfort: -1" in the catalogue. These values have nothing to do with how the object presents itself to a Sim (the so-called "advertisement") or how it actually affects a Sim. It's purely an indication for the buyer.

And that's the sixth block, OBJD, done. The OBJf block is tied up with both ArtGlobals and the BHAV block, so I'll leave that one for a bit and tackle the most complicated block of all: BHAV, the code block.

In the newly cloned Party Balloons object, I'm going to toss out all the BHAV resources I obviously don't need. The Party Balloons do three things: lure neighbours, create a "party" mood and pop one by one until they're all gone and the object loses its effectivity, becoming instead a depressing trash-heap.

The initial list of BHAV trees is:

4096 main
4097 Interaction - Clean up
4098 Interaction - Clean up TEST
4099 initialization
4100 Update Balloons
4101 Try Random Neighbour
4102 adjust motives
4103 functional clean
4104 bring a neighbour
4105 can this person visit?
4106 is person at work?
4107 compute child count
4108 is neighbour already over?
4109 flip person around
4110 need neighbours?
4111 can adjust?
4116 clean

Clearly, the following can be deleted straight away: 4097, 4098, 4100, 4103, 4109 (flipping the Sim around is only needed for cleaning), and 4116. That leaves me with:

4096 main
4099 initialization
4101 Try Random Neighbour
4102 adjust motives
4104 bring a neighbour
4105 can this person visit?
4106 is person at work?
4107 compute child count
4108 is neighbour already over?
4110 need neighbours?
4111 can adjust?

The remaining sections I'll have to go through line by line and prune what's unnecessary. How the programming language in the BHAV block works is explained in the Basics. I'll summarize what each tree does:

4096, "main": this one is executed after initialization (after placing the object in the Sim world) and does all the things the object is supposed to do while existing. In this case, it calls the trees that attract neighbours (4101) and set the party mood (4102) while occasionally popping a balloon. When the balloons are popped, it revalues itself to "trash", adjusts the room score accordingly and goes into a perpetually idle stage until cleaned up. This block will need heavy pruning.

4099, "initialization": this one sets all the object's characteristics, such as how heavy it is and whether it can be stolen. I may import the initialization block of a sculpture object over this, as a block of cement is obviously nothing like a group of balloons.

4101, "Try Random Neighbour": as long as the hour isn't smaller than "6" (meaning, between 06:00 and 23:59) it will check if it "can adjust", meaning, if there's any balloons left on the premises (4111), see if there should be more neighbours (4110) and if so, flip a coin to decide whether to bring some over (4104). This one can be kept almost in its entirety.

4102, "adjust motives": after a "can adjust" (4111), every Sim on the premises has his/her motives altered. Comfort, Hygiene, Bladder and Hunger go up, while Social is brought sharply down to make sure the guests start socializing busily. This change is only applied to Sims for whom the following is not true:

stack obj's person data Person Type Equals? Constant 8196:2

Presumably these are "real" Sims as opposed to NPCs and ghosts. The constant value referred to is from "PersonGlobals.iff", and is accessed via the Sims affected by the Snack J sign.

4104, "bring a neighbour": this one first calls 4107 for a child count, then 4105 to see if a targeted neighbour can visit, and then brings that neighbour over. This one will need no alteration.

4105, "can this person visit?": to check if a Sim neighbour is able to come over, it calls 4106 ("is person at work?") and 4108 ("is neighbour already over?") whose titles speak for themselves. Another one that needs no altering.

4106, "is person at work?": speaks for itself, needs no alteration.

4107, "compute child count": this one counts all children, puts the outcome in its own "Attribute 1" (which I therefore shouldn't use to permanently store values; Attribute 0, for instance, stores the total number of balloons and also shouldn't be used for such arithmetic) and then holds this proof of infant presence against what neighbours it finds. It's a security check, but too subtle for my understanding. Best leave it as it is.

4108, "is neighbour already over?": speaks for itself, needs no alteration.

4110, "need neighbours?": counts guests to see if there are five or more guests yet. "Five" is a variable value that can be changed.

4111, "can adjust?": checks if there are any Party Balloons on the premises that haven't all popped. This one can obviously go, as can all calls to it.

So, working backwards, I'll first delete 4111. Then, in 4110, I'll alter the variable that Local Variable 0 may be smaller than, to "10"; that should be patronage enough for a Japanese "snack" (which, though its name suggests "snackbar", is more like a pub/disco). Then there's a number of routines that don't need changing, up to 4102 which I have to change for two reasons: first, the call to the deleted 4111 has to go (the lines will automatically renumber themselves) and secondly, I really don't want "snack" customers getting less hungry! So in what is now line 6, the Hunger motive is decreased, not increased, by changing the third parameter from 768 to 1024. The second parameter goes from 1 to 4 for some real appetite. Incidentally, browsing code like this can be useful for collecting the right fourth-parameter value to create one's own effects. For instance, "1807" stands for "stack object's motives".

However, I don't want any Sims starving to death or breaking down sobbing as a result of the snack's ambiance. So I insert lines that check the actual needs and don't decrease them when they're under 10; that way, both Hunger and Social stay at a minimum value. I'll also increase Energy, as this mood stuff affects the Snack J's patrons too, and I don't want them dropping dead with fatigue from serving and chatting with their customers (who will have to be greeted like ordinary guests; so an easy way of getting rid of unwanted guests is to ignore them until they leave of their own accord). Incidentally, although guests are only called over between 06:00 and 23:59, the mood effect is continuous; it was made for balloons which pop within the hour anyway, but those concrete signs just last and last, and it's scary to have one's needs adjusted while one is asleep and defenceless. So I'll put the time check in the "main" block, and also make it variable so the snackbar staff don't have to be on their feet for eighteen hours. More on that below.

In 4101 I'll delete both the time check and the call to 4111. These are on lines 0 and 1, connected to other lines, so first I have to set their outcomes to False and change the outcomes of any line referring to them. Then a quick delete, and the line numbers will renumber themselves.

Initialization, 4099: this one needs a big overhaul. I'll just open a real sculpture file and compare values. Line 1, "my weight", will be 250 rather than 2. That the object can be neither stolen nor billed is only realistic (what thief would heft that weight?) but the line "cannot be billed" points to another line "cannot be billed", which is superfluous, so I'll change the second one, line 11, to "My flags Set Flag disallow person intersection" (function: 2, parameters: 8, 2, 2559, 1795). This object doesn't need its attributes 0, 1 and 2 (the number of balloons) set, so the "weight" line will point straight to 5 instead of 8, and lines 8, 9 and 10 can be deleted. Line 3 is also unnecessary, but can be changed to "My surface value assign to 0" (function: 2, parameters: 33, 0, 1535, 1795). Lines 5 and 6 are superfluous, since the room score will be refreshed in "main", so line 1's True outcome can be set to 4, and lines 5 and 6 deleted.

Saving the most horrid for last: "main" (4096). This just defeats me. Time to look in "ArtGlobals.iff". Here, I see the following BHAV trees:

8192 adjust value
8193 init painting common
8194 main - painting
8195 react
8196 Interaction - View
8197 Interaction - View TEST
8198 init - sculptures common

Looking at BHAV 8192, I see it looks much like my BHAV 4099; the only thing added in 4099 is that it can't be stolen. So I'm going to take the shortcut of referring to the BHAV tree in the global file and only adding what I want. The result looks like this:


The outlined function calls a routine in ArtGlobals.iff, all parameters set to "FF FF".

The ArtGlobals contain other routines I can use: "View", "View TEST" and "adjust value". "react" is another useful routine that is called from the "View" routine. I can't simply call the "main" routine in the cloned party balloon object, however, because it keeps repeating itself and so would never get round to any extra code that followed it. "main" is something I'll have to recreate from the ArtGlobals example, with the mood-adjusting and neighbour-luring stuff spliced in. I'll copy the lines from BHAV 8194 in "ArtGlobals.iff" in a sensible order and add my stuff at the bottom. The result: once the object is initialized, the "main" routine sets the first-time room score and starts cycling from line 6 every 10 minutes, resetting the value and, if the time is right, doing its "party" thing. The value is not in fact being adjusted every ten minutes; the method "adjust value" in ArtGlobals.iff checks if the object has aged a full day yet, before doing anything with value and room score. (And, as I found out, it uses the object's Attribute 0 for this. That's another attribute I can't use for my own purposes.) The time check - is it six a.m. yet - will be replaced after all the BHAVs have been renumbered contiguously.


The new "main".

With all these deleted trees, the remaining trees can be renumbered to BHAV 4096 through to 4105. First, I'll make a list of the old numbers, then I'll renumber them by editing the properties, then I'll go through all the calls, which are pointing either to the wrong procedure or a number like "4110" of a tree that no longer exists, and fill in the new numbers. (4110, for instance, would now be 4105.)

Now I can start thinking about opening hours. I'll divide the day into four times six hours, making four menu options, plus a fifth for "Closed" to turn that diabolical mood-maker off once in a while. That makes five BHAV blocks to change the times, plus five "test" blocks. For the five opening-hour states I'll use Attribute 2, which doesn't seem to be used anywhere else yet. "Closed" will have value 0, the four times of day will have values 1 to 4. With this in mind, I add ten empty BHAV blocks for the menu options that will set the opening hours, plus an eleventh, "Check if open", to replace the "Global (from Simulation) Hour < 6" in "main". Note that the line number outcomes will have to be reversed, as the new routine means "yes, we're open" instead of "no, it's too early". The True line becomes 9 (do party stuff) and the False line, 6.


BHAV renumbered.

Now, to fill these BHAV blocks. As explained in the mailbox hack, the Action Tree is what a menu option does, the Check Tree is what allows the menu option to show up at all. The only thing these menu options do is change the value of Attribute 2, and the only thing to check is whether Attribute 2 has that value yet. A new line of code added in IFF Pencil automatically has the value:

My Attribute 0 Assign to: My Attribute 0

Two quick changes are needed: Attribute 0 must become Attribute 2 (change the 0 in the first parameter field to a 2) and it must be not "my" attribute but "Stack object's attribute" since this code operates from the menu and "me" is not the sign, but the Sim who has been ordered to perform some action on it. The latter requires that the fourth parameter goes from 1792 to 1793, or that the seventh hex byte field changes from 00 to 01; this hex field determines whose attributes are being fiddled with. Sometimes, the hex fields are clearer than the decimal fields.

For the test "can snackbar be closed" I ask: "is it closed yet (Attrib2 = 0)?" If so, return false (do NOT show the menu option). Else, return true. In code, this is: Function=2, Parameter1=2, Parameter2=0, Parameter3=512, Parameter1=1793, TrueLine=False, FalseLine=True, or, even more compactly: 2: 2, 0, 512, 1793: 255, 254. The Action Tree code is "set Attrib2 to 0", written as 2: 2, 0, 1280, 1793: 254, 253. The same is done for values 1 to 4, where Parameter 2 contains the value. The bar can now be opened in the morning, in the afternoon, in the evening, at night, or not at all. The opening hours are 06:00 to 12:00, 12:00 to 18:00, 18:00 to 00:00 and 00:00 to 06:00. Whether the snack is open is queried every ten Sim-minutes via #4116, "check if open". This one works through elimination: if Attrib2=0 then return false. Else if Attrib2=4 and Hour<6 then true else false. Else if Attrib2=3 and Hour>18 then true else false. And so on. All this tree has to do is return true when the Snack J ought to be open at the time of query, and false when closed; and as it's called from the "main" routine, this one does use "my" attribute. The code is:

#0 2: 2, 0, 512, 1792: 255, 1
#1 2: 2, 4, 512, 1792: 2, 3
#2 2: 2, 6, 256, 1798: 254, 255
#3 2: 2, 3, 512, 1792: 4, 5
#4 2: 2, 18, 0, 1798: 254, 255
#5 2: 2, 2, 512, 1792: 6, 8
#6 2: 2, 12, 0, 1798: 7, 255
#7 2: 2, 18, 256, 1798: 7, 255
#5 2: 2, 1, 512, 1792: 9, 255
#6 2: 2, 6, 0, 1798: 10, 255
#7 2: 2, 12, 256, 1798: 254, 255

The BHAV block is now completely finished. And as the BCON block only contains "Balloon tuning" values which are not used anywhere in the BHAV routines, this block is now unnecessary, and the empty BCON block in "SnackJsign.iff" can be deleted. The cloned object that I did the hacking in has served one of its purposes - I'll still be using it for sprite manipulations - and its BHAV block can now be exported in one big chunk and imported in "SnackJsign.iff".

(That wasn't a very detailed description of how to hack code, was it? This was just to give a rough idea of customizing existing code. For the curious: the Snack J object is available on the Custom objects page and may be cut open and analyzed to your heart's content. Hacking code is always a matter of trying something, testing it, finding it doesn't work, trying something else, testing it etc. Subsequent hacking howtos will go more deeply into syntax.)

The values from the BHAV blocks in both "SnackJsign.iff" and "ArtGlobals.iff" can now be used to fill in values in the block OBJf. This block is a list of possible things to do with and around an object, for which BHAV numbers may be filled in if applicable. Two items that should always have a number filled in are "init" and "main", and the numbers clearly are "4097" and "4096", referring back to those routines in the BHAV block. And that's the OBJf block done.

Another place that needs BHAV numbers filled in is TTAB, the menu table. For this, I did the following: I exported the TTAs block (it doesn't matter if it has TTAs number #129 or #130, exporting it as "data only" gets rid of the number) from any painting or other object that has "View" translated to all languages. Next, in the TTAB block in "SnackJsign.iff", I created a single interaction: "View". The values for this interaction I copied from the other "view" object. A new, empty TTAs was automatically generated, with number #129. I imported the old, exported TTAs over it, setting its name to "" and its number to #129. In the TTAB block, I filled in "8196" for the Action Tree, and "8197" for the Check Tree; these are the view routines from ArtGlobals.

The opening times will be presented through a submenu. This one, like the CTSS block, will be copied to all languages but not translated; a string in a foreign language is better than no string at all. To get the menu right the first time, I make a new TTAB entry: "Opening hours/Morning". This is followed by "Opening hours/Afternoon", "Opening hours/Evening", "Opening hours/Night" and "Opening hours/Closed". The TTAs (menu option strings) are automatically created along with the TTAB entries, so in the game I'll see a submenu "Opening hours" unfolding into five entries, only four visible at a time if all goes well. The menu is now complete, that's another two blocks done.

Testing this object in the original Sims game leads to a devastating discovery: the old Sims has no ArtGlobals! They were added in Hot Date and are therefore present in Deluxe, but to use this game in older versions, I have to take the ArtGlobals IFF from a later version, take out anything that might be incompatible with the original Sims, and put it in GameData\Global. (I ended up having to import the whole "react" BHAV from an Art Studio painting and putting the thought balloons back in to prevent strange things happening when a Sim didn't like the sign, though.) The adapted ArtGlobals can now be used with the Sims, LL and HP and make most decorative fan objects hacked from HD or later, compatible with these early versions, provided there is no game version check in the objects themselves. How to neutralize game version checks (a trick by the makers to render incompatible an object that can work perfectly well with earlier game versions) is described in Between Deluxe and Livin' Large, where I hacked supposedly Deluxe-only objects to work with LL.

A block that has to be exported from somewhere, because I wouldn't know how to make one myself, is SLOT. For this, I want a single-tile object that covers a whole square and doesn't have a usable surface. The "Caesar Psychopathus" statue will do nicely. I simply export its SLOT block and import it in the Snack J sign IFF.

(Actually, I don't even know if this block is necessary; most objects have it, but not all. It defines the object's outer boundaries; for instance, if it's a table, at which position its surface is.)

The only blocks now remaining are those to do with the graphic: BMP_, SPR2, DGRP and PALT. The most important two are SPR2 and PALT, which will be created through a combination of Blueprint (for the z-buffers) and Transmogrifier.

BluePrint requires an existing object to clone, although it doesn't, to my knowledge, create a new object ID, and it certainly doesn't create new catalogue/speech bitmaps. I already have a 3D shape, UV-mapped and exported in 3D Studio format so that I can import it in Blueprint. First, I'm asked to select a "skeleton" object to clone so that I can import my new sprites into it once I've made them. The cloned party balloons had unfortunately disappeared in the Big Bit Bin, so I cloned the grandfather clock. Not a wise choice, as I found later; it's best to take something like an end table, which has only one draw group.

This isn't going to be a Blueprint manual, so I'll just say the import function is a bit weird - the J came out stripy and lying on its size, and I had to do a fair bit of scaling and rotating until it was correctly placed. The striping wasn't so bad, since the graphic itself can be replaced with T-Mog; it's the z-buffer that I need Blueprint for. This is created when the sprite in the cloned object is replaced with the 3D creation made in Blueprint, and the whole object is imported.

I now opened the grandfather clock in IFF Pencil to delete all the sprites that I didn't need - to wit, all those dealing with the clock hands in their many positions - and so found out that when the sprites are deleted, it's very hard to delete the drawgroups that refer to them. Fortunately, the object wasn't saved yet, so I closed without saving, re-opened it and deleted the extra junk, first the SPR2 items, then the DGRP items. (It's because of inevitable beginner's mistakes like this that I prefer mucking about in some cloned spare object and importing the blocks into the real object when they're completely done.)


Time for T-Mog.

(Unfortunately, the z-buffer produced by Blueprint was very inadequate, so I ended up having to make something using the shower z-buffer. The alpha buffer also wasn't too good, and needed some softening. Still, having Blueprint create base graphics that I can edit rather than having to start from scratch, speeds up the object-making considerably.)

And after endless frustrating T-Mog sessions and fiddlings with the object's X, Y and Z offsets, the finishing touch: the BMP_ block, adding the catalogue/speech bitmaps usind a screenshot of the object at its smallest zoom. And now the object is really, completely finished.

Those are the steps involved in making an object from scratch. There are more complicated steps, like including suits and animations (both of the object itself and of Sims interacting with it), and building life cycles into objects, like the blossoming and dying garden plants, and calling Named Trees etc. etc. This is just a starting point.





Back Previous Next