Difference between revisions of "Using kits"

From the Fallout3 GECK Wiki
Jump to navigation Jump to search
imported>DewiMorgan
m (→‎Rolling your own: Adding to MP category.)
imported>Omzy
 
(4 intermediate revisions by one other user not shown)
Line 31: Line 31:


However, looking more carefully, you notice that with both kits:
However, looking more carefully, you notice that with both kits:
* you can't create rooms with convex corners, since they only have concave corners.
* You can't create rooms with convex corners, since they only have concave corners.
* You can't create rooms with both a door and a window on one corner piece.
* You can't create rooms with both a door and a window on one corner piece.
* You can't create long thin rooms or passages that are one square wide.
* You can't create long thin rooms or passages that are one square wide.
* You can't create "cupboard" rooms that are one square in total.
* You can't create "cupboard" rooms that are one square in total.


"Can't" is a strong term. You certainly CAN create these things, by using similar pieces. For example, by using a WasteRmWindow01 and a WasteRmDoorFrame01 in the same space, one of them turned by 90 degrees, you will begin to emulate a corner with both a window and a door on it. By using two WasteRmWall01 pieces in the same square, one rotated completely around, you could get a 1-square wide corridor.
Well, "can't" is a strong term. You certainly CAN create these things, by using similar pieces. For example, by using a WasteRmWindow01 and a WasteRmDoorFrame01 in the same space, one of them turned by 90 degrees, you will begin to emulate a corner with both a window and a door on it. By using two WasteRmWall01 pieces in the same square, one rotated completely around, you could get a 1-square wide corridor.


But don't try that. That way lies madness, for the ceilings and floors will be in the same place, giving you the dreaded texture-flicker. If you move one or the other of the pieces up or down by one unit, you will fix this problem, only to expose another: one-unit gaps, through which the "void" can be seen. Even if you fix these with careful positioning of mats and pipes to hide the cracks, the shading will still be off: most kit pieces are designed to be darker, or dirtier, towards the walls. So you can tell by looking at the floor or ceiling that it doesn't line up with its neighbors.
But don't try that. That way lies madness, for the ceilings and floors will be in the same place, giving you the dreaded texture-flicker. If you move one or the other of the pieces up or down by one unit, you will fix this problem, only to expose another: one-unit gaps, through which the "void" can be seen. Even if you fix these with careful positioning of the kit pieces, and mats and pipes to hide the cracks, the shading will still be off: most kit pieces are designed to be darker, or dirtier, towards the walls. So you can tell by looking at the floor or ceiling that it doesn't line up with its neighbors.


Instead, be aware of the limitations of your kit, and design your cells to use only what is available.
Instead, be aware of the limitations of your kit, and design your cells to use only what is available.
Line 54: Line 54:
Avoid this where you can, partly for performance reasons. Different kits have different lighting needs, different sound settings, and so forth, to make them convincing. Also, they have different textures and meshes, of course, and it makes sense to load only the resources for the area the player is currently in.
Avoid this where you can, partly for performance reasons. Different kits have different lighting needs, different sound settings, and so forth, to make them convincing. Also, they have different textures and meshes, of course, and it makes sense to load only the resources for the area the player is currently in.


There are other reasons, too: the player's local map becomes nonsense, so it's unfriendly to the player. Then there are technical issues: creating and tweaking your navmesh, and placing items, becomes a lot harder with a two-level map; you may also find that the kit you want to use on the bottom floor is too tall, given the height of your stairs, and its ceiling would clip through the floor of the rooms above. Even if the kit pieces themselves don't clip, clutter that you sank into the floor of the upper rooms may poke through the ceiling of the cellar, or wires from lightfittings in the cellar might reach up into the rooms above.
There are other reasons, too: with multiple levels, the player's 'local map' in the GECK becomes nonsense, so it's unfriendly to the player. Then there are technical issues: creating and tweaking your navmesh, and placing items, becomes a lot harder with a two-level map; you may also find that the kit you want to use on the bottom floor is too tall, given the height of your stairs, and its ceiling would clip through the floor of the rooms above. Even if the kit pieces themselves don't clip, clutter that you sank into the floor of the upper rooms may poke through the ceiling of the cellar, or wires from lightfittings in the cellar might reach up into the rooms above.


So it is very often better, for the player, for optimisation, and for preventing designer headaches, to have a static teleport door between two areas, with each one being in a separate cell. This is especially true where they are on separate levels.
So it is very often better, for the player, for optimisation, and for preventing complications for designers, to have a static teleport door between two areas, with each one being in a separate cell. This is especially true where they are on separate levels.


In the example given - a house and its basement - very little advantage is gained from having a regular door. The player can't typically see from a basement room, up the stairs, to a room upstairs.
In the example given - a house and its basement - very little advantage is gained from having a regular door. The player can't typically see from a basement room, up the stairs, to a room upstairs.
Line 109: Line 109:


If you do this, ceilings and floors will typically require six types, assuming you shade them a little towards the walls:
If you do this, ceilings and floors will typically require six types, assuming you shade them a little towards the walls:
  * shaded on one side (for a floor/ceiling by a straight wall)
  * Shaded on one side (for a floor/ceiling by a straight wall).
  * shaded on opposite sides (corners)
  * Shaded on opposite sides (corners).
  * shaded on two adjacent sides (corridors)
  * Shaded on two adjacent sides (corridors).
  * shaded on three sides (ends of corridors)
  * Shaded on three sides (ends of corridors).
  * shaded on all four sides (cupboards, airlocks)
  * Shaded on all four sides (cupboards, airlocks).
  * unshaded (middle of a room)
  * Unshaded (middle of a room).
If convex corners are likely to be needed, then that would add another nine possibilities:
If convex corners are likely to be needed, then that would add another nine possibilities:
  * shaded on one side and one free corner
  * Shaded on one side and one free corner.
  * shaded on one side and the other free corner
  * Shaded on one side and the other free corner.
  * shaded on one side and both free corners
  * Shaded on one side and both free corners.
  * shaded on two adjacent sides and the free corner
  * Shaded on two adjacent sides and the free corner.
  * shaded on one corner
  * Shaded on one corner.
  * shaded on opposite corners
  * Shaded on opposite corners.
  * shaded on adjacent corners
  * Shaded on adjacent corners.
  * shaded on three corners
  * Shaded on three corners.
  * shaded on all corners
  * Shaded on all corners.
If your textures are directional, then that number could double or quadruple.
If your textures are directional, then that number could double or quadruple.


Walls will always need shading at the top and bottom, but will still need four types:
Walls will always need shading at the top and bottom, but will still need four types:
  * Unshaded
  * Unshaded.
  * Shaded to the left
  * Shaded to the left.
  * Shaded to the right
  * Shaded to the right.
  * Shaded on both sides.
  * Shaded on both sides.


Line 141: Line 141:
But there is a solution: [[Bethsoft Tutorial Static Collections|static collections]]!
But there is a solution: [[Bethsoft Tutorial Static Collections|static collections]]!


== See Also ==
*[http://www.youtube.com/?v=IO470Cxk3fA Bethesda youtube tutorial] - using the bunker kit and snap to reference.


[[Category:Modding Practices]]
[[Category:Advanced_Modding_Techniques]]

Latest revision as of 03:26, 10 August 2010

In Fallout, most interior cells are built using "kits" - similarly named forms that are designed to fit together in an interlocking way. There are kits for vaults, as you will have seen in the tutorials, and also for the interiors of shacks, offices, and many other building types.

This page is intended as a more advanced discussion of the issues you might run into when using kits in Fallout, and how to make your work with them faster and less painful.

It assumes basic knowledge of kits, experience of using at least one, and understanding of all basic skills taught in the "My First Vault" Tutorial series, such as object palette management, and finding objects by name.

Kit capabilities[edit | edit source]

It should go without saying but... not all kits have the same pieces.

For example, the "WasteRm" kit contains:

WasteRm4way01 - a "center of the room" piece, with no walls.
WasteRm4Corner01 - a "corner of the room" piece.
WasteRm4CornerDoorframe01 - a door on the left, on a concave corner.
WasteRm4CornerDoorframe02 - a door on the right, on a concave corner.
WasteRm4CornerWindow01 - a window on the left, on a concave corner.
WasteRm4CornerWindow02 - a window on the right, on a concave corner.
WasteRm4Doorframe01 - a door onto a straight room wall.
WasteRmWall01 - a straight room wall.
WasteRmWindow01 - a window in a straight room wall.

(there are also some double height pieces, but we'll ignore them)

While the "WasteKitchen" kit contains:

WasteKitchen4way01 - a "center of the room" piece, with no walls.
WasteKitchenCorner01 - a "corner of the room" piece.
WasteKitchenDoorFrame01 - a door onto a straight room wall.
WasteKitchenWall01 - a straight room wall.
WasteKitchenWindow01 - a window in a straight room wall.

A quick glance at that list looks as if it covers most of the bases, though the kitchen will be unable to have windows or doors in the corners.

However, looking more carefully, you notice that with both kits:

  • You can't create rooms with convex corners, since they only have concave corners.
  • You can't create rooms with both a door and a window on one corner piece.
  • You can't create long thin rooms or passages that are one square wide.
  • You can't create "cupboard" rooms that are one square in total.

Well, "can't" is a strong term. You certainly CAN create these things, by using similar pieces. For example, by using a WasteRmWindow01 and a WasteRmDoorFrame01 in the same space, one of them turned by 90 degrees, you will begin to emulate a corner with both a window and a door on it. By using two WasteRmWall01 pieces in the same square, one rotated completely around, you could get a 1-square wide corridor.

But don't try that. That way lies madness, for the ceilings and floors will be in the same place, giving you the dreaded texture-flicker. If you move one or the other of the pieces up or down by one unit, you will fix this problem, only to expose another: one-unit gaps, through which the "void" can be seen. Even if you fix these with careful positioning of the kit pieces, and mats and pipes to hide the cracks, the shading will still be off: most kit pieces are designed to be darker, or dirtier, towards the walls. So you can tell by looking at the floor or ceiling that it doesn't line up with its neighbors.

Instead, be aware of the limitations of your kit, and design your cells to use only what is available.

Doors[edit | edit source]

Another limitation of the "Waste*" kits is that there are no DOOR types that will work with them, which means the cell that uses them cannot have internal doors. There are external static doors that'll work as teleports to get in and out of the cell, but no animated door types for the player to open and walk through.

If your design calls for doors in your kit, and you have not tested them to work, then that should be one of the first things you check: place a single doorframe, and find a suitable door that fits. If you can't find one that works, even with scaling, then you may need to reconsider your design.

Mixing kits[edit | edit source]

Eventually, you will be called upon to "mix kits". You may have a wasteland house using the "WasteRm" kit, and a basement that uses the "BasRm" kit.

Avoid this where you can, partly for performance reasons. Different kits have different lighting needs, different sound settings, and so forth, to make them convincing. Also, they have different textures and meshes, of course, and it makes sense to load only the resources for the area the player is currently in.

There are other reasons, too: with multiple levels, the player's 'local map' in the GECK becomes nonsense, so it's unfriendly to the player. Then there are technical issues: creating and tweaking your navmesh, and placing items, becomes a lot harder with a two-level map; you may also find that the kit you want to use on the bottom floor is too tall, given the height of your stairs, and its ceiling would clip through the floor of the rooms above. Even if the kit pieces themselves don't clip, clutter that you sank into the floor of the upper rooms may poke through the ceiling of the cellar, or wires from lightfittings in the cellar might reach up into the rooms above.

So it is very often better, for the player, for optimisation, and for preventing complications for designers, to have a static teleport door between two areas, with each one being in a separate cell. This is especially true where they are on separate levels.

In the example given - a house and its basement - very little advantage is gained from having a regular door. The player can't typically see from a basement room, up the stairs, to a room upstairs.

However, a teleport is not always possible.

Perhaps you want sounds made in the basement to be audible upstairs, and can't fake it with sound emitting references.

Perhaps you want AI downstairs to react to sounds made upstairs, and can't fake it with scripted triggers to make them come running.

Perhaps you want combats to be resolved upstairs between NPCs, while the player is downstairs, and can't fake it with scripted deaths.

Or of course, most commonly, perhaps you have two areas that DO need to be visible from each other, but must look different.

In that case, you must make the join between the two kits work. This can be tricky: in the example described, the stairs (WasteRmStairsDoorway) have two doorways, one upstairs, one down. The "BasRm" doorways at the bottom are a different size. Also, if you add another door to the basement, then the kit piece sizes are the "wrong size" - the two bottom doorways are not an integer number of "BasRm" kit pieces apart.

What are your options?

Covering the cracks[edit | edit source]

If you are lucky, there will be "joining" kit pieces: it is wise to use them if at all possible, even if it means a slight redesign of your cell. These can be hard to find: they often have the term "trans" in their name, or for places where it's meant to look like something broke through from a cave to another kit, "CaveTo*Broken" (CaveToOfficeBroken, CaveToMetroBroken, CaveToUtilityBroken, CaveToVaultBroken, CaveToFacilityBroken...). But for cases where they just convert between two similar types of kit, they could be called anything: the word "to" is often a clue, as in "UndNRmPitToTallWall*", though even things like "WasteRmStairs01" converts between two parts of a kit.

The piece "FadeToTrans" can often come in handy for generic transitions between kit pieces - it adds a bit of shading, making a transition seem more "real".

But what if there are no transition pieces?

When you are mixing kits, or otherwise making kits do things they are not meant to do, it can often be difficult to place all the kit pieces such that no small crack lets the player see the void, and no area has two items overlapping and giving texture-flicker.

But the Waste is filled with boulders, mats, rubble and debris, filing cabinets and lockers, desks, planks, pipes, and other clutter. Not all of this is there purely for color.

In fact, padding with beams, sticks, pipes or rubble around the larger of the two doors is the only real option in the situation above. If you are lucky, you will find a way to make it look like a deliberate "doorframe". If at all possible, avoid scaling kit pieces, as this will cause them to no longer connect properly with their kin.

Create yourself an object palette for transitional static clutter: linear elements are often best, so search for pipes, beams, posts, sticks, planks, etc, but also add in flat things like the mats, posters and boards.

Beware, though: make sure that your palette contains only statics and other objects which cannot be moved (lights, furniture, containers, static collections...). If you patch with a movable object (NPCs, misc items, weapons, notes...), animatable ones (doors, some terminals...), ones which are transparent or invisible ingame (water, markers...), then your patching will be in vain, because the player will still be able to do something to see the "crack".

Needing to patch the cracks is not always because of something you did yourself: sometimes the kits require it. For example, in the "BasRm" basement kit, the ceiling piece of BasRmMid01 is about one unit too thin compared to its own floor, and the pieces it tiles with: this is not a problem, if you are prepared to line them up and run a pipe along the ceiling to cover up the gap.

Rolling your own[edit | edit source]

Ultimately, there will be things you cannot do without creating your own kit pieces. If you are brave, you might decide to have a bash at this, perhaps copying a windowframe from a straight wall and pasting it into a corner piece; or resizing a door to work in another kit than it was originally made for.

In many cases, you will intend to make these pieces reusable by others: you will want to see your work used and loved by as many people as possible. Sticking to the established naming conventions is good, then, though for new kits, you should prevent conflicts by putting your mod name at the front of the formname: DAVEBasementCornerWindow. If you are adding pieces for an existing kit, by putting your mod name just after the kit name: BasRmDAVECornerWindow or somesuch.

The existing kits have a few inconsistencies in naming. Sometimes R means "Rusty", sometimes it means "Righthand". Sometimes a middle-of-the-room piece is called "Mid" sometimes "4Way". Doorways can be "Door", "Doorway", "Ex" or "Exit". When in doubt, pick what works best for you, but be as consistent as you can.

A good start for making your own kit is to use the "GenRm" kit - this has a range of shapes with all the shading, but no textures. Using these as a base will mean you get the shading, size, and origins to be convincing and consistent with the rest of the game.

Holes (doors, windows, etc) should be centred in the piece. If you are resizing a doorway, resize it equally to either side if you can. This will mean that two of these pieces placed back to back will match up correctly.

Kits are typically made in units with floor, wall and ceiling all in one piece. You may find it easier to create your kit as separate wall pieces, floor pieces, and ceiling pieces: or at least, to create the basic pieces (corner, wall, doorway, etc) and then also create separate fragments for ceiling, wall and floor, to give you full versatility in the future.

If you do this, ceilings and floors will typically require six types, assuming you shade them a little towards the walls:

* Shaded on one side (for a floor/ceiling by a straight wall).
* Shaded on opposite sides (corners).
* Shaded on two adjacent sides (corridors).
* Shaded on three sides (ends of corridors).
* Shaded on all four sides (cupboards, airlocks).
* Unshaded (middle of a room).

If convex corners are likely to be needed, then that would add another nine possibilities:

* Shaded on one side and one free corner.
* Shaded on one side and the other free corner.
* Shaded on one side and both free corners.
* Shaded on two adjacent sides and the free corner.
* Shaded on one corner.
* Shaded on opposite corners.
* Shaded on adjacent corners.
* Shaded on three corners.
* Shaded on all corners.

If your textures are directional, then that number could double or quadruple.

Walls will always need shading at the top and bottom, but will still need four types:

* Unshaded.
* Shaded to the left.
* Shaded to the right.
* Shaded on both sides.

You might also want to include door and window types, bringing that to twelve wall types, and if convex corners are needed, a small "convex wall corner" piece might also be needed, shaded on the top and bottom.

Once you had this kit, placing unusual elements like "a 1-square cupboard" or "a corridor corner with a window and a door" will be as simple as picking three walls, a ceiling and a floor.

The downside of this all this, and of kits in general, is that there are a lot more objects, which makes them slower to place and edit, and also slower to render.

But there is a solution: static collections!

See Also[edit | edit source]