Page 1 of 2

Underwhelming haunting

Posted: Tue Aug 20, 2019 9:06 am
by pango
Inspired by Clearing Monsters from house quests broken? thread...

I've found Daggerfall City haunting rather underwhelming, beside Lysandus' voice; You got to stay on the same spot for a while to have a chance to witness a ghost or a wraith. Not exactly how I picture a spectral army.

It seems to work better in classic, but I'm not sure why. Higher effective spawn rate, enemies spawning closer, or immediately aggravated at the player? Certainly not better path finding ;)

Re: Underwhelming haunting

Posted: Tue Aug 20, 2019 10:06 am
by Interkarma
Yeah, I've wondered about that too. DFU is technically following the same timers and scripts, but classic just feels more dangerous.

I'd be happy for spawn rate to be tweaked up a bit in DFU. Those streets should feel dangerous. :)

Re: Underwhelming haunting

Posted: Fri Aug 23, 2019 10:41 pm
by Madae
Interkarma wrote:
Tue Aug 20, 2019 10:06 am
DFU is technically following the same timers and scripts
That may be the case, but I too remember it being much faster on the spawns, and seeing several ghosts at a time.

On a side note, I also don't remember, strongly even, AI monsters fighting each other like they do here, so that seems off to me as well. I do remember creatures dying without me being the cause, but that was because flying creatures got stuck in a wall, or fell through the floor, and just eventually ended up poofing with a notice on screen.

Re: Underwhelming haunting

Posted: Fri Aug 23, 2019 11:13 pm
by Ommamar
Madae wrote:
Fri Aug 23, 2019 10:41 pm
Interkarma wrote:
Tue Aug 20, 2019 10:06 am
DFU is technically following the same timers and scripts
That may be the case, but I too remember it being much faster on the spawns, and seeing several ghosts at a time.

On a side note, I also don't remember, strongly even, AI monsters fighting each other like they do here, so that seems off to me as well. I do remember creatures dying without me being the cause, but that was because flying creatures got stuck in a wall, or fell through the floor, and just eventually ended up poofing with a notice on screen.

Re: Underwhelming haunting

Posted: Sun Aug 25, 2019 1:16 am
by Madae
Ommamar wrote:
Fri Aug 23, 2019 11:13 pm
Madae wrote:
Fri Aug 23, 2019 10:41 pm
Interkarma wrote:
Tue Aug 20, 2019 10:06 am
DFU is technically following the same timers and scripts
That may be the case, but I too remember it being much faster on the spawns, and seeing several ghosts at a time.

On a side note, I also don't remember, strongly even, AI monsters fighting each other like they do here, so that seems off to me as well. I do remember creatures dying without me being the cause, but that was because flying creatures got stuck in a wall, or fell through the floor, and just eventually ended up poofing with a notice on screen.
The creature infighting is a DFU advanced option, you can turn it off if you like. I think it is a logical addition that adds to the game but no wasn't in classic. I noticed this in Daggerfall as well if I loiter I will see a ghost/wraith but only one so just hear the vengeance with no teeth to it.
Ah, that makes sense then. Still on the fence about whether I like it or not, but I certainly don't really mind it, was just something different I noticed.

Re: Underwhelming haunting

Posted: Sat Oct 12, 2019 3:50 am
by pango
Interkarma wrote:
Tue Aug 20, 2019 10:06 am
Yeah, I've wondered about that too. DFU is technically following the same timers and scripts, but classic just feels more dangerous.

I'd be happy for spawn rate to be tweaked up a bit in DFU. Those streets should feel dangerous. :)
Just saw some guy streaming classic Daggerfall, he got dropped off Daggerfall city for vagrancy at night, and a ghost was there the moment he regained control.
So it seems that periodic spawns do not start by waiting for a random period of time before the first spawn, but trigger immediately, then start waiting for random periods?

Re: Underwhelming haunting

Posted: Sun Oct 13, 2019 10:56 am
by pango
pango wrote:
Sat Oct 12, 2019 3:50 am
So it seems that periodic spawns do not start by waiting for a random period of time before the first spawn, but trigger immediately, then start waiting for random periods?
I noticed a bug in CreateFoe:

Code: Select all

            // Check for a new spawn event - only one spawn event can be running at a time
            if (gameSeconds > lastSpawnTime + spawnInterval && !spawnInProgress)
            {
                // Update last spawn time
                lastSpawnTime = gameSeconds;

                // Roll for spawn chance
                float chance = spawnChance / 100f;
                if (UnityEngine.Random.Range(0f, 1f) > chance)
                    return;
So every spawnInterval an enemy can be spawned with a spawnChance% chance, okay...
The only small issue here is that because of ">" there must be at least spawnInterval + 1 seconds between checks, so spawning rate is slightly weakened.

Code: Select all

            // Init spawn timer on first update
            if (lastSpawnTime == 0)
                lastSpawnTime = gameSeconds + (uint)UnityEngine.Random.Range(0, spawnInterval + 1);
We initialize the cycle by simulation a random initial phase.
Well first, as seen before, I'm not sure it's what classic does;
And second, there's a bug, it's a "nextSpawnTime" formula not a "lastSpawnTime" formula: If next spawn check must happen randomly between gameSeconds and gameSeconds + spawnInterval, then since we compare gameSeconds against lastSpawnTime + spawnInterval, lastSpawnTime should be initialized with a random value between gameSeconds - spawnInterval and gameSeconds:

Code: Select all

            // Init spawn timer on first update
            if (lastSpawnTime == 0)
                lastSpawnTime = gameSeconds - (uint)UnityEngine.Random.Range(0, spawnInterval + 1);
This bugs delays the first spawn by one spawnInterval. That may have contributed to House cleaning quests unbalancing.

Re: Underwhelming haunting

Posted: Sun Oct 13, 2019 1:03 pm
by pango
I submitted a PR

Re: Underwhelming haunting

Posted: Fri Feb 21, 2020 11:20 pm
by pango
Actually in classic, the first spawn of such periodic spawns is almost immediate. If you enter Daggerfall City at night, both first ghost and first wraith are on your trail within 2 seconds. It probably helps make infestation quests less confusing too, as you're facing the first vermin almost immediately.

However changing above line like

Code: Select all

lastSpawnTime = gameSeconds - (uint)spawnInterval + (uint)Math.Min(spawnInterval, UnityEngine.Random.Range(12, 36));
does not currently work very well, because not all code calling CreateFoe() expects that new behavior. If you rest in town, you immediately have 10 guards ready to arrest you, etc...

Re: Underwhelming haunting

Posted: Sun Feb 23, 2020 9:54 pm
by Hazelnut
No idea if it's related, but low level quests like clear bats or when you go to a house and get beset by baddies are different to how I remember. They are brutal now, and I am wondering if the spawning mechanics have changed and that's why... like in the quest script it says "every 1 minutes 7 times with 100% success" well I was seeing several bats quicker than 7 minutes I think.

Maybe it is also conflicting with Jay's changes to core quests. In M0B21Y19 he changed time to 0 to make it more like an ambush. Getting mobbed by 4 assassins at level 3 is death basically.