Page 1 of 1

0.7.91: Mobile town NPCs spawning in front of player[RESOLVED]

Posted: Mon Apr 15, 2019 8:53 am
by Ferital
In DFU, I frequently see NPCs suddenly popping out of nowhere while walking in towns or villages, whereas this is not the case in classic. Maybe a check should be added to ensure NPCs spawn at a reasonable distance from the player and especially outside his current view frustum.

Re: 0.7.91: Mobile town NPCs spawning in front of player

Posted: Mon Apr 15, 2019 9:34 am
by Interkarma
That check already exists, and it operates most of the time. You're only noticing it when it doesn't. ;)

Not sure why it's not working 100% of the time. Could be some kind of latency. I'll drill into more when I can, it's just not a priority right now.

Re: 0.7.91: Mobile town NPCs spawning in front of player

Posted: Mon Apr 15, 2019 10:05 am
by Ferital
Yes of course, sorry I just looked very quickly at the code and did not notice the check. Actually I did not dig further as it is out of my current understanding of DFU codebase :)

Re: 0.7.91: Mobile town NPCs spawning in front of player

Posted: Mon Apr 15, 2019 10:49 am
by Interkarma
All good, it's still definitely a bug. :)

Re: 0.7.91: Mobile town NPCs spawning in front of player

Posted: Mon Apr 15, 2019 11:57 am
by pango
Ferital wrote: Mon Apr 15, 2019 10:05 am Yes of course, sorry I just looked very quickly at the code and did not notice the check. Actually I did not dig further as it is out of my current understanding of DFU codebase :)
I don't have an IDE at hand, but I think that's https://github.com/Interkarma/daggerfal ... er.cs#L280

Re: 0.7.91: Mobile town NPCs spawning in front of player

Posted: Mon Apr 15, 2019 12:49 pm
by BansheeXYZ
Is there a lot of overhead in just spawning all the townsfolk at once the moment the player is in the city or in sight of it? They're not 3d models, so why is the code trying so hard to conditionally show them?

Re: 0.7.91: Mobile town NPCs spawning in front of player

Posted: Sun Apr 28, 2019 8:02 am
by pango
I submitted a PR

Re: 0.7.91: Mobile town NPCs spawning in front of player

Posted: Wed May 01, 2019 7:37 am
by pango
Should be fixed in 0.7.120