Time & Space and More

Daggerfall Tools for Unity has good fundamentals. It can load any texture, model, sound effect, city, dungeon, season, and climate. It has weapons, skies, enemies, combat, building interiors, tons of editor options, and a solid API for reading anything else you need from Daggerfall into Unity.

The big missing piece right now is loading up the right city based on world position and automatically applying things like time of day and seasonal effects. Starting from 1.1, many of these additional extras will be included in the tools. This post talks a little bit about the new features with some technical bits thrown in.

If you’ve already used Daggerfall Tools for Unity, then you know it uses a singleton object called DaggerfallUnity as an interface and broker between Unity and the Arena2 binary data. There are several components attached to DaggerfallUnity for various tasks. In 1.1 you will find a couple of new components in the mix that bring proper time and space handling. These are PlayerGPS and WorldTime. Let’s take a look at PlayerGPS first.



PlayerGPS is fairly basic on the surface. It exposes two variables to manage a virtual player position anywhere in the Illiac Bay. The world map in Daggerfall is 1000×500 “world pixels”, with each “pixel” being 32768×32768 native units in size. This means the total world size ranges from 0,0 (bottom-left, or south-west corner of map) through to 32768000, 16384000 (top-right, or north-west corner of map) The numbers you see above (6782976, 9371648) are world coordinates for the city of Daggerfall.

At code level, PlayerGPS exposes more functionality. It can provide information about climate and politics, check to see if a location is present, etc. New static methods in the MapsFile class also provide the ability to move between different coordinate systems used by Daggerfall – such as longitude and latitude, world pixel, world coordinate, and location ID. The location ID is actually a special number derived from the longitude and latitude. It allows for any location to be looked up quickly via hash. PlayerGPS exposes this via lookup functions into a Dictionary collection.

To help support all this from editor and code, the internal DaggerfallLocation component (a self-assembling map layout for cities and dungeons) now hold additional metadata with locations.

Location Metadata

Most of what you need to know about a location is either in this metadata, or can be read from the API using this information as a starting point. The good news is that you don’t need to worry about any of this if you don’t want to. The toolset automates all of this for you in different ways. More on this shortly.

Next comes WorldTime. This component is an actual Daggerfall-styled Tamrielic calendar.


When you start a game, WorldTime starts counting the seconds using whatever timescale you have set. You can set timescale at 0.5 to make world time run at half speed, or at 100,000,000 to watch months flip by in moments. To make it easy to use, the individual time units are broken down in a very human-readable format (year, month, day, etc.).

This is far more than just a timer. WorldTime exposes real information about seasons, birth signs, month names, and so on. When coupled with PlayerGPS, it becomes possible to pinpoint the exact climate, season, and time of day for player position and make the world react as expected.

This means everything from rotating the sun through an animated sky, to making it snow, to setting the correct sky by climate and season, to lighting up windows at night, to turning street lights on and off. You’ve probably seen this video already, but here is WorldTime in full effect. You don’t see the seasons change, but that is in and working. If you let the simulation run long enough, seasons will roll by as expected.

You don’t need to do anything special to benefit from any of this. Just tick the new boxes below and the tools do the rest for you.

Time & Space Options

More automation will be added as the feature set expands.

Time and space aren’t the only new feature coming in 1.1. There are huge improvements to import speed and the beginnings of true world streaming, a feature scheduled for version 1.2. My goal for 1.2 is to allow you to walk around a fully streaming, fully time-automated world. For now though, world streaming is still in early testing stages, and looks a bit like this.


Each of these tiles represent a single “world pixel”. In this test, locations are streamed in around the player’s world position. As the player moves, new world pixels are read in or disposed as required.

In case you’re wondering, yes that actually is the entire city of Daggerfall on a single tile. All the models are rendered as normal, I just have the camera pointing straight down from a high position. The gray tiles will eventually be replaced by a simple terrain system, also scheduled for version 1.2.

You won’t have long to wait for all this stuff. The 1.1 release should be ready within the next week, and 1.2 (which I’m working on now) will only be a few weeks away. When 1.2 is ready you’ll be able to just drop in a few prefabs (or load a premade scene) and hit Play to explore the entire of Illiac Bay.

I’m very excited to get all this through to you as soon as possible.

Posted in Daggerfall Tools, Daggerfall Tools for Unity, Featured, Movie, Technical Content.


  1. This is really amazing 🙂 I’m looking forward to the release 😀

    I’m also very excited what you will anounce next 🙂 and hope that you will continue working on the tools even after this hole world/dungeon/city/climate (I call it “world”) thing is done 😉

    Daggerfall Tools for Unity gives the community a very good base to recreate the game. But the problem is that I cant see a community using this powerful tools to do so.
    You say that you just want to give us a powerful API, but I belive that if you want it, you can do way more than that.


  2. Thanks Eric! I definitely have more planned after the world thing is done. 🙂

    I believe DaggerXL already has us covered in the remake department. What I really want to see are new experiences based on Daggerfall’s world and style.

    In that spirit, my next steps will be to turn out a couple of small (but complete) games using Daggerfall Tools for Unity as a foundation. These won’t be anything earth-shattering, but I hope they will be something tangible and fun that Daggerfall fans will enjoy.

    As usual, I will release everything open source for others to build on however they like. Hopefully I can get more people interested in creating stuff in the process. 🙂

  3. Man this look crazy!

    ”My goal for 1.2 is to allow you to walk around a fully streaming, fully time-automated world.”

    By that, are you saying that we were gonna be able to load Daggerfall BLOCKS in run time. and be able to travel to one city to another ? Cause if so… X_x

    Looking forward 1.2 !!

  4. Yep, that’s the plan. 🙂 You just need to drop in a few prefabs and hit play. The streaming component will build the world around you at runtime using WorldTime and PlayerGPS to work out what to stream and how it should look – right down to whether city lights should be on or off, what direction the sun is coming from, and whether birds or crickets should play in the ambient player.

    I basically have this working now, but need to build a terrain system to hold everything together. I also have a lot of little things to test and fix. That’s why I’m delivering the time & space stuff in 1.1, then streaming in 1.2. It gives me a few more weeks to get it rounded out.

  5. Hi, its me again 😀
    since here is no forum i’ll ask my question here:
    I tried to create a standalone build to play on adroid a little bit using your tools, but i wasn’t able to load textures correctly. It worked for the sounds and the bsa but not for the textures. I tried to add “.bytes” as extensoin but that dindt work as well.

    I look around in the api a little bit and wonder now, if its possible at this to load textrues from memory (the resource folder)


  6. Hey that’s awesome! I’d love to see if someone could get a standalone dungeon running on Android. It is possible to load textures from memory (at least, I do it all the time in web and PC builds). Are you able to send me a zip of your project? I’ll take a look and see if I can troubleshoot. My email address is in the Contact menu page up top.

  7. Maybe I just missed a file.

    I got


    I’m also not able to load Daggerfall or Privateers Hold (Error: Unknown location),
    loading blocks from rmbs work, and models work too, but they are just red.
    When I want to make a standalone build, where should I set arena2 to?

    My project config is just standart, I just followed your City tutorial.

    I made a short batch-file to rename the textures (I’m obviously to lazy to rename 472 files)

    set /a i=0
    ren TEXTURE.00%i% TEXTURE.00%i%.bytes
    set /a i=%i%+1
    if %i% EQU 10 goto b
    goto a
    ren TEXTURE.0%i% TEXTURE.0%i%.bytes
    set /a i=%i%+1
    if %i% EQU 100 goto c
    goto b
    ren TEXTURE.%i% TEXTURE.%i%.bytes
    set /a i=%i%+1
    if %i% EQU 512 goto end
    goto c

    Eric 🙂

  8. Well done mate, it looks like you’re almost there now. Below are some quick pointers that might help. If these still don’t help fix, please email me at interkarma@dfworkshop.net. Email is a bit more roomy than comments for tougher problems and we can attach stuff back and forth. 🙂

    – A red texture can be a good thing. This means at least some of the textures loaded but the palette file is missing (empty palette is cleared bright red to indicate not loaded). Be sure to include at least “ART_COL.PAL.bytes” (the main palette file) in your Resources folder. This one is an essential file, as are the ones you already have.

    – You will also need the “CLIMATE.PAK.bytes” and “POLITIC.PAK.bytes” files. These contain more information required by the content reader and are also considered essential files.

    – If you see an “unknown location” error, this can mean one of the map-related files are missing (like “MAPS.BSA.bytes” or the climate and politic files above). It can also mean the fields aren’t entered exactly. For example, “Daggerfall/Privateer’s Hold” will load the dungeon, but “daggerfall/privateers hold” will give you an error. This needs to be improved on my side.

    – When I set up my Resources folder, I use something like the following for setting up the “TEXTURE.xxx.bytes” files:

    copy Arena2\TEXTURE.* Resources\TEXTURE.*.bytes

    That one line will copy all the TEXTURE.000 – TEXTURE.511 files and append .bytes on the end.

    – When developing, set your Arena2 path to a full install of Daggerfall as normal. Get everything working then create a build and see if it works OK. Test the build on another PC, or just rename your full Arena2 folder when testing builds.

    – Web builds are a fantastic way to test standalone, as they can’t access the filesystem and are always considered fully standalone. Web builds are also very quick and small, and really portable.

    I hope that helps! I definitely will put together a tutorial for standalone builds soon.

  9. Worked 😀

    So I included the files and compiled for Android:

    Worked,but the skies dont… maybe forgot to include something or its just android… On web player there were skyies but they where somehow buggy…

    Controls on android are a bit ugly:
    I can look around with my fingers but to walk I needed to plug in an external keyboard… maybe someday when I know enough about Unity I can create buttons that make the player move.

    Transition to indoors works greate as well, and sound was there, too.

  10. Eric this is amazing! Well done, my friend!

    The sky issue is probably a bug on my end. I’m sure this can be worked out. If I put together a couple of different variations of the sky component, would you be able to test them out for me?

    The controls can probably be smoothed out with virtual thumbsticks of some kind (there are a few paid solutions on the Unity Asset Store). I need to overhaul the input system anyway to fix bugs and support controllers. I’ll see what I can do about laying the foundation of first-person tablet controls.

    Maybe between the two of us, we could put together a demo build (such as Direnni demo) for Android. I’d be happy to send you any project files needed.

    So cool. 🙂

    Edit: Hope you don’t mind, I’m going to show off what you’ve accomplished on the blog and Twitter. 🙂

Comments are closed.