Textures

Images for Daggerfall Unity can be provided from asset bundles (StreamingAssets/Mods) as textures or materials, or from loose files (StreamingAssets/Textures) as png textures. Xml files can also be used for some customization.

Materials

Daggerfall Imaging 2

Opens and exports Daggerfall’s image files.

Materials can be bundled directly inside a mod, placed inside any folder and named archive_record-frame.mat. The first number is the name of the package where corresponding classic textures are stored (ARCHIVE.XXX), the second number is the index inside the archive and the third number is the frame, used only for animated billboards. An example is 009_1-0.mat. Textures for static models always have frame -0. See unity docs for textures and materials for all options. Note that only textures maps listed below are enabled in game for the standard shader.

  • Albedo
  • Normal
  • Emission (white for windows, actual color is set for daytime)
  • MetallicGloss

Alternatively, individual textures can be imported as loose files, from the StreamingAssets/Textures folder. They must be named archive_record-frame.png for albedo and archive_record-frame_MapTag.png for others (for example 009_1-0_Normal.png). Loose files are placed at the end of the load order, so they virtually “override” all mods. Xml files can also be used to edit Metallic and Smoothness parameters from loose files. Provide a text file named archive_record-0.xml as shown in the example below.

<?xml version="1.0"?>
<properties>
    <metallic>0.5</metallic>
    <smoothness>0.5</smoothness>
</properties>

Terrain

It is possible to import albedo, normal and metallicgloss maps for terrain, provided the texture array system is supported on the local platform and enabled (you can check it from the advanced settings window). There are two ways to provide terrain textures:

  • Include a Texture2DArray asset with a mod, created with Daggerfall Tools > Texture Array Creator or third party tools. The asset must include all textures of a classic archive and be named after it (i.e. XXX-TexArray).
  • Provide all 56 individual textures with a mod or loose files to generate a texture array at runtime. All textures must be included and have the same resolution and format. MetallicGloss is an exception as a default map for all the missing textures will be created automatically. If you want to support older platforms (without support for what Unity calls CopyTextureSupport.DifferentTypes) you also need to enable Read/Write flag on all textures, at the cost of higher memory usage. This flag is always enabled for loose files.

Billboards

Billboard textures can be imported via dfmods or loose files (StreamingAssets/Textures). In both cases textures must be named archive_record-frame.png and, when required, archive_record-frame_Emission.png. When you pack a dfmod remember to set alpha transparency on textures.

Optionally, xml files can be included to provide billboard configuration. Individual keys can be safely omitted to always use default value.

Static Interior

Static billboards inside houses and dungeons are replaced on a per-record basis, meaning that all frames for a given record must be provided. The same is true for emission maps.

Archive_Record-0.xml

<?xml version="1.0"?>
<info>
    <renderMode>Cutout</renderMode>
    <emission>False</emission>
    <uvX>0</uvX>
    <uvY>0</uvY>
    <scaleX>1</scaleX>
    <scaleY>1</scaleY>
</info>

Static Exterior

All textures from an archive are placed on a 4096×4096 atlas, so the total size of your textures must not exceed this value or they will be silently resized. If you don’t provide the entire archive, imported textures are used together with vanilla without issues.

Archive_Record-0.xml

<?xml version="1.0"?>
<info>
    <scaleX>1</scaleX>
    <scaleY>1</scaleY>
</info>

Mobile

Mobile billboards, such as wandering npcs and enemies, are replaced on a per-archive basis. Texture replacement is enabled for a given archive if the first record (archive_0-0) is provided. Similarly, an archive is marked as emissive if the emission map for the first record is provided (archive_0-0_Emission) or if enabled from xml configuration. Albedo is reused as an emission map when the latter is not provided.

Archive.xml

<?xml version="1.0"?>
<info>
    <renderMode>Cutout</renderMode>
    <emission>False</emission>
</info>

Archive_Record-0.xml

<?xml version="1.0"?>
<info>
    <uvX>0</uvX>
    <uvY>0</uvY>
    <scaleX>1</scaleX>
    <scaleY>1</scaleY>
</info>

UI Images

The following are the names to use for UI images for both mods and loose files, including the directories for the latter. A good import option for ui images provided by mods is Texture Type: GUI with mipmaps disabled and Alpha is Transparency if required.

  • .IMG: filename.png (ex: MAP100I0.IMG.png) in StreamingAssets\Textures\Img
  • .CIF, .RCI: filename_record-frame.png (ex: INVE16I0.CIF_3-0.png) in StreamingAssets\Textures\CifRci

Weapons

Weapons used by the player have several variations for different kinds of metal. Vanilla textures use a color tint to achieve this; when importing custom textures, we use entirely different images. The full name is WEAPON**.CIF-Record-Frame_MetalType for weapons with metal type variations, WEAPON**.CIF_Record-Frame for others such as hands and feet.

Metal types

  • Iron
  • Steel
  • Elven
  • Dwarven
  • Mithril
  • Adamantium
  • Ebony
  • Orcish
  • Daedric

Inventory Items

Variations

Daggerfall uses the same texture for several variations of an item, applying different color tints. Custom texture should be provided with an additional tag to identify which variation they are meant to replace; the full name is Archive_Record-Frame for Chain and Silver (no tint) and Archive_Record-Frame_DyeColor for all other dyes.

Clothing

  • Blue
  • Grey
  • Red
  • DarkBrown
  • Purple
  • LightBrown
  • White
  • Aquamarine
  • Yellow
  • Green

Weapon and armour

  • Iron
  • Steel
  • Elven
  • Dwarven
  • Mithril
  • Adamantium
  • Ebony
  • Orcish
  • Daedric

Paperdoll

Paperdoll items are placed in a stack where textures on the top hides the layers below. Additionally, some layers requires a mask; for example the helm clears hair that would otherwise visible. For more informations on paperdoll implementation see Items Part 3 – Paper Doll. If Name is the name of the main texture, a texture named Name_Mask can be used to override the default mask, with full opacity on the alpha channel to mark masked area, and trasparency to mark non-masked area. If this texture is provided from a mod, the texture type Single Channel should be chosen to automatically pick format with minimum amount of memory used; additionally, Read/Write Enabled flag must be set.

The position on the paperdoll can also be changed with an xml file, with the same name as the texture, providing a rect in pixels with the origin on the top-left corner. The original paperdoll has a resolution of 110×184, which is scaled eight times in Daggerfall Unity to achieve a resolution of 880×1472. The xml file should define the scale on which the rect is based, which allows the game to correctly convert the rect to the actual paperdoll scale, ensuring compatibility with future resolution changes.

<?xml version="1.0"?>
<info>
    <rect scale="8">
        <x>248</x>
        <y>0</y>
        <width>400</width>
        <height>344</height>
    </rect>
</info>

HUD

Certain UI images need additional informations. These are provided using .xml files, each one with the same name as the texture file it refers to and placed in the same folder. width and height parameters affect the size on screen. Here are provided the defaults values, but it’s possible to customize them.

  • HUD Compass
    COMPASS.IMG.xml
<?xml version="1.0"?>
<info>
    <width>322</width>
    <height>14</height>
</info>
  • COMPBOX.IMG.xml
<?xml version="1.0"?>
<info>
    <width>69</width>
    <height>17</height>
</info>
  • Crosshair
    Crosshair.png and Crosshair.xml in StreamingAssets\Textures
<?xml version="1.0"?>
<info>
    <width>22</width>
    <height>22</height>
</info>

Cursor

Cursor can be overriden with a texture provided by mod using Cursor texture type and Read/Write flag enabled. Import from loose files is not supported.

Transport

Horse and cart textures are, respectively, MRED00I0.CFA and MRED01I0.CFA. While the original textures can’t be exported with Daggerfall Imaging, overrides can be provided inside the CifRci folder (ex: MRED00I0.CFA_0-0.png).

Travel Map

High resolution overlays can be imported along with the main map texture following the naming TRAV0I00.IMG-RegionName. For example, the overlay for the Ilessan Hills region should be named TRAV0I00.IMG-Ilessan Hills.

This is the list of region names:

"Alik'r Desert", "Dragontail Mountains", "Glenpoint Foothills", "Daggerfall Bluffs",
"Yeorth Burrowland", "Dwynnen", "Ravennian Forest", "Devilrock",
"Malekna Forest", "Isle of Balfiera", "Bantha", "Dak'fron",
"Islands in the Western Iliac Bay", "Tamarilyn Point", "Lainlyn Cliffs", "Bjoulsae River",
"Wrothgarian Mountains", "Daggerfall", "Glenpoint", "Betony", "Sentinel", "Anticlere", "Lainlyn", "Wayrest",
"Gen Tem High Rock village", "Gen Rai Hammerfell village", "Orsinium Area", "Skeffington Wood",
"Hammerfell bay coast", "Hammerfell sea coast", "High Rock bay coast", "High Rock sea coast",
"Northmoor", "Menevia", "Alcaire", "Koegria", "Bhoraine", "Kambria", "Phrygias", "Urvaius",
"Ykalon", "Daenia", "Shalgora", "Abibon-Gora", "Kairou", "Pothago", "Myrkwasa", "Ayasofya",
"Tigonus", "Kozanset", "Satakalaam", "Totambu", "Mournoth", "Ephesus", "Santaki", "Antiphyllos",
"Bergama", "Gavaudon", "Tulune", "Glenumbra Moors", "Ilessan Hills", "Cybiades"

Save Manager

This feature is now obsolete and will be eventually removed at some point. Hazelnut introduced support for full UI customization, which supersede this early support for one specific window. Mod authors interested in UI modding are invited to use the UIWindowFactory class to register modifications for window type UIWindowType.UnitySaveGame as a better replacement.

It is possible to customize the window interface used to load saves, placing custom textures inside StreamingAssets\Textures.

  • mainPanelBackgroundColor.png
  • namePanelBackgroundColor.png
  • savesListBackgroundColor.png
  • saveButtonBackgroundColor.png
  • switchClassicButtonBackgroundColor.png
  • cancelButtonBackgroundColor.png
  • screenshotPanelBackgroundColor.png
  • renameSaveButtonBackgroundColor.png
  • deleteSaveButtonBackgroundColor.png
  • switchCharButtonBackgroundColor.png

While it is not required for swapping texture images, it is possible to use xml files to customize the labes of buttons.

<?xml version="1.0"?>
<info>
<customtext>true</customtext>
<r>0.8</r>
<g>0.1</g>
<b>0.1</b>
<a>1.0</a>
</info>
<?xml version="1.0"?>
<info>
<customtext>notext</customtext>
</info>

Limitations

The following is a list of limitations for the current version of Daggerfall Unity, which might be resolved with a future update.

  • Replacement of sky textures (SKYxx.DAT) is not supported.