Determinism
Posted: Sun Aug 26, 2018 3:23 pm
Hi all,
I wonder if you're aware of the use of determinism in games, and what's your take on it. Let me try to explain what I have in mind.
Daggerfall uses randomness for many things, like who will give you quests, what random quests a quest giver will provide, the exact monsters you'll find in dungeons, their loot, etc.
But not everything is random either; For example the way each dungeon looks is stored in the game files, so everybody playing Daggerfall, today or ten years from now, going to the same place, will get lost in the same corridors, with the same textures, furnitures, etc. (obviously talking about non altered game here)
But there's something in between. Since in computers we're usually using pseudo-random generators instead of real random numbers, if we force a specific seed value in a generator we'll get the same sequence of numbers every time. In other words, the generated sequences will look just as random, except they're a function of the seed value.
This can have several uses, to give some examples:
- terrain generator: if we seed the random generator used for height with its absolute (X, Y) coordinates in the world, then the same location will always be created/altered the same way, without having to store anything. That's basically what's used to generate very large or even infinite universes;
- weather (as an example of time based world property): imagine saving your game, traveling to some remote place, and finding an heavy fog on arrival. If you don't like it, a cheap way around is to reload and hope a different weather will be drawn. But if the weather is deterministic, the only way to get a different weather after reload is to go somewhere else, or at a different time.
- NPCs/monsters behavior: if after saving you fail to sneak past a monster whose unperturbed behavior is deterministic, then after reload you'll have to try something different: go another route, distract the monsters instead,... You can't rely so much on luck, but on the other hand each time you retry you have more information and make better decisions. I think this is an interesting way to make game mechanics deeper.
I'm sure they're other interesting uses I didn't think of...
I wonder if you're aware of the use of determinism in games, and what's your take on it. Let me try to explain what I have in mind.
Daggerfall uses randomness for many things, like who will give you quests, what random quests a quest giver will provide, the exact monsters you'll find in dungeons, their loot, etc.
But not everything is random either; For example the way each dungeon looks is stored in the game files, so everybody playing Daggerfall, today or ten years from now, going to the same place, will get lost in the same corridors, with the same textures, furnitures, etc. (obviously talking about non altered game here)
But there's something in between. Since in computers we're usually using pseudo-random generators instead of real random numbers, if we force a specific seed value in a generator we'll get the same sequence of numbers every time. In other words, the generated sequences will look just as random, except they're a function of the seed value.
This can have several uses, to give some examples:
- terrain generator: if we seed the random generator used for height with its absolute (X, Y) coordinates in the world, then the same location will always be created/altered the same way, without having to store anything. That's basically what's used to generate very large or even infinite universes;
- weather (as an example of time based world property): imagine saving your game, traveling to some remote place, and finding an heavy fog on arrival. If you don't like it, a cheap way around is to reload and hope a different weather will be drawn. But if the weather is deterministic, the only way to get a different weather after reload is to go somewhere else, or at a different time.
- NPCs/monsters behavior: if after saving you fail to sneak past a monster whose unperturbed behavior is deterministic, then after reload you'll have to try something different: go another route, distract the monsters instead,... You can't rely so much on luck, but on the other hand each time you retry you have more information and make better decisions. I think this is an interesting way to make game mechanics deeper.
I'm sure they're other interesting uses I didn't think of...