Fix /setspeedmod: apply per-character, persist across stat recalculation

Previously stomped the shared GServer->MOVE_SPEED_MOD movement-timing
divisor, which character.cpp's UpdatePosition also uses for monster position
interpolation -- GM testing broke movement/attack range server-wide until
restart. Now stores a per-character SpeedModPercent that GetMoveSpeed()
applies on every recompute, so it survives future SetStats() calls instead
of being silently overwritten back to base speed. Also fixes Mspd_base (the
value actually broadcast to clients) never being set while WALKING.
This commit is contained in:
Thomas committed 2026-07-10 14:19:32 +02:00
1 parent 15e562cb04
commit 16dccc94f2
4 files changed
+28 -2

No files matched your search

+1
View File
@@ -40,6 +40,7 @@ CCharacter::CCharacter( )
Stats->Accury = 0;
Stats->Magic_Defense = 0;
Stats->Move_Speed = 0;
Stats->SpeedModPercent = 100;
Stats->Attack_Speed = 0;
Stats->Attack_Distance = 0;
Stats->MaxWeight = 0;