Win7x64 v0.7.126 - Spellcasting 45degrees up causes player to crouch

Report specific bugs in Daggerfall Unity. Please read guidelines before posting.
User avatar
King of Worms
Posts: 1482
Joined: Mon Oct 17, 2016 11:18 pm
Location: Scourg Barrow
Contact:

Win7x64 v0.7.126 - Spellcasting 45degrees up causes player to crouch

Post by King of Worms » Wed May 15, 2019 4:22 pm

This one is funny and probably was going on for a while.

Every casted spell - if casted 45 degrees towards the sky - will cause a player to crouch for a split of the second.

Stay by some wall or anything giving you a reference to your height, and check for yourself.

If you cast straight infront of you horizontally, its ok, if you cast towards the sky its ok, but in the middle... this bug manifests.

EASY WAY TO REPRODUCE:
toggle god mode TGM
cast a spell repeatedly, start while looking forwards, and every next cast look 10 more degrees up... end up casting str8 up to the sky


ANOTHER THING:
The spell HIT effects play at the same volume no matter how distant the hit occurs. 1m or 100m. Should I create a separate report?
This can get bothersome in some cases, like mobs infighting and you observe it from distance, and everything is low volume but their spells...

User avatar
pango
Posts: 1007
Joined: Wed Jul 18, 2018 6:14 pm
Location: France
Contact:

Re: Win7x64 v0.7.126 - Spellcasting 45degrees up causes player to crouch

Post by pango » Wed May 15, 2019 5:13 pm

King of Worms wrote:
Wed May 15, 2019 4:22 pm
Every casted spell - if casted 45 degrees towards the sky - will cause a player to crouch for a split of the second.
I must verify my hypothesis, but I suspect it's related to recent "head dipping": when the spell orb is right in front of your head, your character dips as it would to avoid an obstacle.

On the other hand that's a nice feature, if a missile arrives right in front of your head, with some luck you'll just dodge it :D


Interesting things can happen with spell orbs, for example last time I checked you can destroy an incoming one with by shooting an arrow at it...

I submitted a PR
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart

User avatar
pango
Posts: 1007
Joined: Wed Jul 18, 2018 6:14 pm
Location: France
Contact:

Re: Win7x64 v0.7.126 - Spellcasting 45degrees up causes player to crouch

Post by pango » Wed May 15, 2019 7:15 pm

King of Worms wrote:
Wed May 15, 2019 4:22 pm
ANOTHER THING:
The spell HIT effects play at the same volume no matter how distant the hit occurs. 1m or 100m. Should I create a separate report?
This can get bothersome in some cases, like mobs infighting and you observe it from distance, and everything is low volume but their spells...
This seems to have been done on purpose in the sources (DaggerfallMissile.PlayImpactSound):

Code: Select all

        void PlayImpactSound()
        {
            if (audioSource && ImpactSound != SoundClips.None)
            {
                // Using doppler of zero as classic does not appear to use 3D sound for spell impact
                if (!isArrow)
                    audioSource.PlayOneShot(ImpactSound, 0);
                else
                    audioSource.PlayOneShot(ImpactSound);
            }
        }
(something wrong here is "doppler" in comment, this turns off spatialBlend, not doppler effect.)
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart

User avatar
King of Worms
Posts: 1482
Joined: Mon Oct 17, 2016 11:18 pm
Location: Scourg Barrow
Contact:

Re: Win7x64 v0.7.126 - Spellcasting 45degrees up causes player to crouch

Post by King of Worms » Wed May 15, 2019 7:42 pm

Shooting spell projectiles with a bow sounds quite like Chuck Norris :lol:
Thanks for looking at it! Yes it might be the new crouch feature implemented.

About the sound...
It might be on purpose. I think its vanila like.
But it doesnt make much sense to keep it that way?
Only reason I guess might be that the range of sounds seem very low in general.
So the default settings for projectile hit would make it impossible to hear at 15m distance which would sound strange.
Spell hit sounds should have higher range of audability

User avatar
pango
Posts: 1007
Joined: Wed Jul 18, 2018 6:14 pm
Location: France
Contact:

Re: Win7x64 v0.7.126 - Spellcasting 45degrees up causes player to crouch

Post by pango » Wed May 15, 2019 7:59 pm

Yes, I'm very unsure about how to balance all sound volumes, it looks more tricky than one would expect...

Personally I'd suggest using some spatialBlend just a bit lower than 1f, say 0.9f.
That way the sound is mostly spatialized like other sounds, but there's a constant reminder (0.1f or 10%) that is not spatialized and that will play as an ambient sound no matter how far the impact is.
That may look a bit cheap (compared to "custom volume rolloff" or other Unity features), but could be sufficient to get some balance between realism and gameplay requirement to always know when a spell hits something...

Code: Select all

                // Using weakened spatialBlend, classic does not appear to use 3D sound for spell impact at all
                if (!isArrow)
                    audioSource.PlayOneShot(ImpactSound, 0.9f);
                else
                    audioSource.PlayOneShot(ImpactSound);
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart

User avatar
King of Worms
Posts: 1482
Joined: Mon Oct 17, 2016 11:18 pm
Location: Scourg Barrow
Contact:

Re: Win7x64 v0.7.126 - Spellcasting 45degrees up causes player to crouch

Post by King of Worms » Wed May 15, 2019 11:29 pm

This sounds very fitting, never allow it to be completely muted, but make the lowest value cca 10%
Maybe not 100% realistic, but deffo improvement and from a gameplay POV a good solution IMO

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

Re: Win7x64 v0.7.126 - Spellcasting 45degrees up causes player to crouch

Post by Interkarma » Thu May 16, 2019 12:24 am

Thank you for head-dipping fix Pango. I'm happy to try a small amount of spatial blend on those spell sounds. My memory of trying this during development is it made them feel very weak compared to classic. I like the big explosive sounds regardless of range. If you want to send me a PR to try out, I'll see how it feels. :)

User avatar
pango
Posts: 1007
Joined: Wed Jul 18, 2018 6:14 pm
Location: France
Contact:

Re: Win7x64 v0.7.126 - Spellcasting 45degrees up causes player to crouch

Post by pango » Thu May 16, 2019 9:45 am

Interkarma wrote:
Thu May 16, 2019 12:24 am
I'm happy to try a small amount of spatial blend on those spell sounds. My memory of trying this during development is it made them feel very weak compared to classic. I like the big explosive sounds regardless of range. If you want to send me a PR to try out, I'll see how it feels. :)
Yes, it's likely to feel weaker given it's currently to the max all the time ;)
The only way to compensate for this that I can think of if volume decreases with distance is to use higher base volume.
They're precedents, like base volume of 5f for thunder, so it doesn't seem absurd.
After that if you shoot a spell real close, it'll be even more obvious that was not a good idea ;)

I can experiment with that, but it's hard to tell what volume is right; I feel that current volumes are a bit low, most of the time I set the volume around 2/3 of the max for video and music on my setup, but have to crank it to 100% when I start Daggerfall Unity. But I have no idea if that's a common experience...
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart

User avatar
King of Worms
Posts: 1482
Joined: Mon Oct 17, 2016 11:18 pm
Location: Scourg Barrow
Contact:

Re: Win7x64 v0.7.126 - Spellcasting 45degrees up causes player to crouch

Post by King of Worms » Thu May 16, 2019 10:19 am

I think there should be at least some degree of volume falloff...

Full volome is not good in cases like mobs infighting. You observe a fight from a distance, everything has some volume levels and than BAMM!!! full volume spell hit, feels completely off.

Ok, lets make it 50% at the lowest... but not 100% volume all the time as it is now...
Its about not making it ZERO... that would feel off. For me, 25% seems like a good start.

About the volume Pango. DFU with cleaned soundclips sounds a bit too low on volume. I increased some of the volume in my impending sound mod.
Also, my sound volume ingame is always 100%, and my music is like 10% at the most...
So it might be the sounds are now indeed too low volume, after the Tamriel Mixdown mod process

User avatar
pango
Posts: 1007
Joined: Wed Jul 18, 2018 6:14 pm
Location: France
Contact:

Re: Win7x64 v0.7.126 - Spellcasting 45degrees up causes player to crouch

Post by pango » Thu May 16, 2019 10:10 pm

I did some more tests, so here are my results:
Sound is never actually amplified, so setting volume > 1f seems to be the same as setting it to 1f.
One thing that can be done is increase minDistance, so that sound stays at nominal volume over a larger range. I set it to 8, so all spells in that range should sound as loud as before, just spatialized.
maxDistance sets at what distance the sound stops becoming quieter with distance. This is actually better than setting spatialBlend < 1f, because when the sound source is far, it allows you to keep hearing its direction, which can be important, say to know where are enemies infighting.

I submitted a PR
Last edited by pango on Fri May 17, 2019 5:19 am, edited 1 time in total.
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart

Post Reply