Random enemies don't exactly match classic at level 1 [Intended]

Narf the Mouse
Posts: 833
Joined: Mon Nov 30, 2015 6:32 pm

Random enemies don't exactly match classic at level 1 [Intended]

Post by Narf the Mouse »

I noticed this because I literally have Privateer's Hold memorized. ...I make a lot of new characters. :)

Starting from the room with the rogue and the coffin, on the right-hand elevated side from the grand staircase (left-hand when facing the staircase from the top), there is a side-door that leads to the top of a ramp. On the other side of the top of the ramp, is a little room that *normally holds a bear. Instead, there was, IIRC, a bat.

At the bottom of the grand staircase, facing the back wall, through the door on the right of the back wall, down the small hallway, into the room at the end of the hallway (left side, but there's only one), there is normally a bear. There was, IIRC, a warrior.

Through the secret door to the left of the grand staircase, at the bottom of the grand staircase (do not go up the grand staircase), keep going straight past the cross hallway into a small hallway with a door. Open the door, half-way around the curved hallway, there is a tiny perpendicular hallway with two doors branching off of it. These normally hold archers. One held a mage of some sort, and the other, a knight.

* For any "normally", read "nearly always"; I can only recall seeing other enemies there after I have gained a couple of levels.
Previous experience tells me it's very easy to misunderstand the tone, intent, or meaning of what I've posted. If you have questions, ask.

User avatar
Interkarma
Posts: 7247
Joined: Sun Mar 22, 2015 1:51 am

Re: Incorrect enemy placement

Post by Interkarma »

Daggerfall has two types of enemies - fixed and random.

The fixed enemies are the same in every playthrough, at any level. Random enemies are rolled from an encounter table based on dungeon type that increases in overall level over time. If you return to Privateer's Hold at a higher level, you will have different enemy types in those random encounter spots.

Daggerfall Unity exhibits a little more variability with random enemies on the encounter table right from the start. I don't see this as a bug, I see it as better using the encounter tables. It's just a slightly different random setup than classic uses. :)

Try going back with characters at different levels. You'll find those spawn positions can host quite a few different types of enemies in both classic and Daggerfall Unity.

CM August
Posts: 86
Joined: Fri Jul 14, 2017 11:11 am

Re: Random enemies don't exactly match classic at level 1 [Intended]

Post by CM August »

Is there any documentation on Daggerfall's monster placement and scaling? Online resources for Daggerfall's systems seem less comprehensive than later games. I'd love to read more about this, and how Daggerfall Unity's tweaked things, in more detail.

User avatar
Interkarma
Posts: 7247
Joined: Sun Mar 22, 2015 1:51 am

Re: Random enemies don't exactly match classic at level 1 [Intended]

Post by Interkarma »

You'll find some good information in the Daggerfall Chronicles guide book, it's well worth a purchase. Has a good amount of technical data about the game, including a summary of the encounter tables.

The actual encounter tables are a set of 20x entries for each dungeon type hard-coded into executable. This was recently extracted by Allofich and data merged here. There are duplicate entries to "load the dice" and ensure certain enemy types appear more than others.

Inside map layout data, there are two markers which indicate monster placement. A "monster" marker (like the skeleton by the throne) will always have the same creature attached to it (which is defined in the marker's data).
fixed-monster-marker.jpg
fixed-monster-marker.jpg (88.56 KiB) Viewed 4064 times
A "random mon" marker (scattered all through dungeons), will select a random monster from the encounter table. A low-level character will get a low-level monster (or humanoid enemy, which scale to player's level). A high level character will get a higher level monster or scaled humanoid enemy.
random-monster-marker.jpg
random-monster-marker.jpg (82.22 KiB) Viewed 4064 times
Privateer's Hold is a "Human Stronghold" type dungeon. Statistically speaking, it's encounter table is loaded with more humanoids than a lot of other dungeons.

I don't use the exact same random method for selecting monsters as Daggerfall (in part because this is a black box). I could emulate it fairly easily, because the difference is only really noticeable at level 1. Like I said in my previous post, the encounters start to become shuffled once the player increases in level anyway. I'm actually quite happy that DF Unity will give you a bit more variety from the outset.

It's not like these particular monsters are fixed. They're supposed to be random, and they are in Daggerfall as well. Just the random method DF uses happens to throw the same enemies at level 1, leading to the misconception they are fixed enemies when they actually aren't. :)

Narf the Mouse
Posts: 833
Joined: Mon Nov 30, 2015 6:32 pm

Re: Incorrect enemy placement

Post by Narf the Mouse »

Interkarma wrote:Daggerfall has two types of enemies - fixed and random.

The fixed enemies are the same in every playthrough, at any level. Random enemies are rolled from an encounter table based on dungeon type that increases in overall level over time. If you return to Privateer's Hold at a higher level, you will have different enemy types in those random encounter spots.

Daggerfall Unity exhibits a little more variability with random enemies on the encounter table right from the start. I don't see this as a bug, I see it as better using the encounter tables. It's just a slightly different random setup than classic uses. :)

Try going back with characters at different levels. You'll find those spawn positions can host quite a few different types of enemies in both classic and Daggerfall Unity.
I'm well aware that different monsters spawn at higher levels, although I can see how I wasn't clear, there. :)

However, this was a first run-through of Privateer's Hold from character creation, so when the monsters "didn't match", I posted a bug report. :)

If it's due to more randomness in spawns, that sounds good, too. :)
Previous experience tells me it's very easy to misunderstand the tone, intent, or meaning of what I've posted. If you have questions, ask.

User avatar
Interkarma
Posts: 7247
Joined: Sun Mar 22, 2015 1:51 am

Re: Random enemies don't exactly match classic at level 1 [Intended]

Post by Interkarma »

Yep, Daggerfall Unity just has more randomness in spawns. I've considered matching PH at level 1 exactly for nostalgia reasons, and maybe I'll still tweak it for that later. But I'm kind of hoping people will eventually enjoy some of the small ways Daggerfall Unity is "differently random". :)

Narf the Mouse
Posts: 833
Joined: Mon Nov 30, 2015 6:32 pm

Re: Random enemies don't exactly match classic at level 1 [Intended]

Post by Narf the Mouse »

Interkarma wrote:Yep, Daggerfall Unity just has more randomness in spawns. I've considered matching PH at level 1 exactly for nostalgia reasons, and maybe I'll still tweak it for that later. But I'm kind of hoping people will eventually enjoy some of the small ways Daggerfall Unity is "differently random". :)
Well, I guess this can be closed, then. :)

I have to admit, now that I'm thinking about it, classic PH is feeling a bit tedious. ;)
Previous experience tells me it's very easy to misunderstand the tone, intent, or meaning of what I've posted. If you have questions, ask.

CM August
Posts: 86
Joined: Fri Jul 14, 2017 11:11 am

Re: Random enemies don't exactly match classic at level 1 [Intended]

Post by CM August »

@Interkarma:
Thanks so much for the comprehensive reply. I've developed a habit of regularly peeking at the github for some time, but hadn't seen that PR yet - too distracted by the shiny new build. ;) Based on what a level one player can see in PH, am I right in thinking Daggerfall selects monsters up to 7 levels higher than the player for the random mon marker? And that should a player encounter Dreughs or Daedroth at level 2, it is a sure sign of a monster marker for that particular map?

I have a digital copy of the Daggerfall Chronicles; it was included as part of GOG's Daggerfall package - talk about a steal. I'll give it another read when I get home.

P.S. Allofich is a champion. I always get excited when I see a PR with his name on it :D

User avatar
Interkarma
Posts: 7247
Joined: Sun Mar 22, 2015 1:51 am

Re: Random enemies don't exactly match classic at level 1 [Intended]

Post by Interkarma »

Daggerfall definitely appears to select monster levels much higher than the player should feasibly be able to handle.

As part of this conversation, I've taken another look at how this is generated in Daggerfall Unity, and I'm not setting the monster power level correctly. I wrote this in my test build well over a year ago, and the code appears to have never made it into live (it's still the simplified version I started with. Whoops!

Edit: I've posted this code now.

The way my random selection works is that it calculates a monster power level between 0 and 1 based on player level (monsterPower = playerLevel / 20f). This sets the base index into the encounter array for that dungeon. I then apply a random variance index of +/- 4 to the selected base index (clamped to within array range).

For example, a level one player could roll between 0-4, which in PH (human stronghold) includes monsters (Warrior, Rogue, Rat, GrizzlyBear, Archer). It's a fairly simple setup that should be variably challenging for players.
CM August wrote: P.S. Allofich is a champion. I always get excited when I see a PR with his name on it :D
True that. He's a fantastic contributor and this project is lucky to have someone like him helping.

CM August
Posts: 86
Joined: Fri Jul 14, 2017 11:11 am

Re: Random enemies don't exactly match classic at level 1 [Intended]

Post by CM August »

Lol, awesome. It looks as if Daggerfall Unity will be a little fairer than vanilla too.

And if I understand correctly, going up in levels simply extends the array, so a level 20 player will randomly encounter the full enemy variety of that dungeon type, including the lower-level monsters. Sounds good to me.

Locked