mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-02-03 02:53:48 +00:00
feat(Core/Time): Implement saparated manager for game time (#8630)
This commit is contained in:
@@ -107,14 +107,16 @@ namespace Movement
|
||||
|
||||
struct CommonInitializer
|
||||
{
|
||||
CommonInitializer(float _velocity) : velocityInv(1000.f / _velocity), time(minimal_duration) {}
|
||||
float velocityInv;
|
||||
int32 time;
|
||||
CommonInitializer(float _velocity) : velocityInv(1000.f / _velocity), _time(minimal_duration) {}
|
||||
|
||||
inline int32 operator()(Spline<int32>& s, int32 i)
|
||||
{
|
||||
time += (s.SegLength(i) * velocityInv);
|
||||
return time;
|
||||
_time += (s.SegLength(i) * velocityInv);
|
||||
return _time;
|
||||
}
|
||||
|
||||
float velocityInv;
|
||||
int32 _time;
|
||||
};
|
||||
|
||||
void MoveSpline::init_spline(const MoveSplineInitArgs& args)
|
||||
|
||||
Reference in New Issue
Block a user