mirror of
https://github.com/EQEmu/Server.git
synced 2026-11-27 12:32:17 +00:00
Changes so that blind effects like those in Flash of Light work.
This commit is contained in:
1 parent
1170b57fd5
commit
73a23e9f9d
5 files changed
+16
-5
No files matched your search
+7
-1
@@ -130,7 +130,7 @@ void Mob::ProcessFlee() {
|
||||
}
|
||||
|
||||
float Mob::GetFearSpeed() {
|
||||
if(flee_mode) {
|
||||
if(flee_mode || is_blind) {
|
||||
//we know ratio < FLEE_HP_RATIO
|
||||
float speed = GetBaseRunspeed();
|
||||
float ratio = GetHPRatio();
|
||||
@@ -141,6 +141,12 @@ float Mob::GetFearSpeed() {
|
||||
|
||||
speed = speed * ratio * multiplier / 100;
|
||||
|
||||
// A blinded mob should be pretty slow when running amuck.
|
||||
if (is_blind)
|
||||
{
|
||||
speed = speed/3.0;
|
||||
}
|
||||
|
||||
//NPC will eventually stop. Snares speeds this up.
|
||||
if(speed < 0.09)
|
||||
speed = 0.0001f;
|
||||
|
||||
Reference in new issue
Block a user