cmangos / issues

This repository is used as a centralized point for all issues regarding CMaNGOS.
180 stars 47 forks source link

🚀 [Feature Request] Npc/Creatures/etc Turning Fix #2630

Closed al3xc1985 closed 2 years ago

al3xc1985 commented 2 years ago

Feature Details

In not so recent trinity core updates, as I remember, there was topic with a merge pull fix for creatures/npc/etc turning right/left smooth, not like we have in present, robotic way. They should turn left or right more human way.

I am 100% sure u guys know what I am talking about, but I let this here only for reference

Visualizations

No response

Benefits and Purpose

Nicer game enviroment play

Core Versions

insunaa commented 2 years ago

I'm pretty sure rigid turning is accurate to the source. Current versions do it differently by interpolating orientations, but that's not original behavior iirc.

It looks much better, I agree on that. Just not sure if it's desired.

Edit:

https://monkeysee.com/world-of-warcraft-learning-cities/

This video at a few points shows the rigid turning that is also present in CMaNGOS, but it's really hard to find video proof of this, and even in this video you have to really look hard to see it

Tobschinski commented 2 years ago

more info here: https://github.com/cmangos/issues/issues/2050

al3xc1985 commented 2 years ago

So, basically this is a feature that is from wotlk and further expansion, if I understand correct?

Tobschinski commented 2 years ago

I read it as cata+.

insunaa commented 2 years ago

in theory this could be added to the movement system in core and instead of relying on the client to do the interpolation of orientations we could do it serverside. there are a few problems with this. First and foremost: This is not a behavior of the era we are replicating. 2) This would massively increase the amount of movement update packets we need to send to clients 3) this would require a pretty significant rework of the movement system, because the turn would need to be initiated before reaching the waypoint and end some time after reaching the waypoint, based on a dynamic turning rate calculated from the vector of the path to the waypoint and the vector of the path from the waypoint. That's a lot of intense calculations that would have to be applied to all NPCs which follow waypoints.

This would massively increase code complexity as well as computational costs serverside.

When this is done clientside the client only has to do these calculations for creatures within its FOV so if you have to calculate this for 1-15 creatures at once it's not that computationally demanding. If you have to calculate that for every creature that is spawned on the entire server however that is a different matter. I'm not sure if we have some way of changing these calculations if players are near, but even then with increasing player-count the computational cost would rise exponentially

killerwife commented 2 years ago

Unless someone shows me a spline flag associated with it in WOTLK (TBC 100% doesnt have it), I can say for certain its not in WOTLK. TC doesnt have it, Acore doesnt have it. I will close this. If someone provides side by side evidence, with a wotlk dated video (classic is not enough by any means even if wotlk comes out) compared to how ours works, I will gladly reopen this and work on it.

killerwife commented 2 years ago

Also, do not mistake this for smooth flying movement which we already have as Movement Type 3. You can fake ground smooth movement with it in tbc, but it isnt blizzlike.