[10979] Add extra ghost speed rate for BGs: Death.Ghost.RunSpeed.Battleground

Also recently added option renamed to Death.Ghost.RunSpeed.World

Signed-off-by: VladimirMangos <vladimir@getmangos.com>
This commit is contained in:
Pat S 2011-01-07 07:33:20 +03:00 committed by VladimirMangos
parent a7f784f676
commit 46fdc3af97
5 changed files with 12 additions and 5 deletions

View file

@ -8271,7 +8271,7 @@ void Unit::UpdateSpeed(UnitMoveType mtype, bool forced, float ratio)
else else
{ {
if (getDeathState() == CORPSE) if (getDeathState() == CORPSE)
speed *= sWorld.getConfig(CONFIG_FLOAT_GHOST_RUN_SPEED); speed *= sWorld.getConfig(((Player*)this)->InBattleGround() ? CONFIG_FLOAT_GHOST_RUN_SPEED_BG : CONFIG_FLOAT_GHOST_RUN_SPEED_WORLD);
} }
// Apply strongest slow aura mod to speed // Apply strongest slow aura mod to speed

View file

@ -708,7 +708,8 @@ void World::LoadConfigSettings(bool reload)
setConfig(CONFIG_BOOL_DEATH_CORPSE_RECLAIM_DELAY_PVE, "Death.CorpseReclaimDelay.PvE", true); setConfig(CONFIG_BOOL_DEATH_CORPSE_RECLAIM_DELAY_PVE, "Death.CorpseReclaimDelay.PvE", true);
setConfig(CONFIG_BOOL_DEATH_BONES_WORLD, "Death.Bones.World", true); setConfig(CONFIG_BOOL_DEATH_BONES_WORLD, "Death.Bones.World", true);
setConfig(CONFIG_BOOL_DEATH_BONES_BG_OR_ARENA, "Death.Bones.BattlegroundOrArena", true); setConfig(CONFIG_BOOL_DEATH_BONES_BG_OR_ARENA, "Death.Bones.BattlegroundOrArena", true);
setConfigMinMax(CONFIG_FLOAT_GHOST_RUN_SPEED, "Death.Ghost.RunSpeed", 1.0f, 0.1f, 10.0f); setConfigMinMax(CONFIG_FLOAT_GHOST_RUN_SPEED_WORLD, "Death.Ghost.RunSpeed.World", 1.0f, 0.1f, 10.0f);
setConfigMinMax(CONFIG_FLOAT_GHOST_RUN_SPEED_BG, "Death.Ghost.RunSpeed.Battleground", 1.0f, 0.1f, 10.0f);
setConfig(CONFIG_FLOAT_THREAT_RADIUS, "ThreatRadius", 100.0f); setConfig(CONFIG_FLOAT_THREAT_RADIUS, "ThreatRadius", 100.0f);

View file

@ -269,7 +269,8 @@ enum eConfigFloatValues
CONFIG_FLOAT_CREATURE_FAMILY_ASSISTANCE_RADIUS, CONFIG_FLOAT_CREATURE_FAMILY_ASSISTANCE_RADIUS,
CONFIG_FLOAT_GROUP_XP_DISTANCE, CONFIG_FLOAT_GROUP_XP_DISTANCE,
CONFIG_FLOAT_THREAT_RADIUS, CONFIG_FLOAT_THREAT_RADIUS,
CONFIG_FLOAT_GHOST_RUN_SPEED, CONFIG_FLOAT_GHOST_RUN_SPEED_WORLD,
CONFIG_FLOAT_GHOST_RUN_SPEED_BG,
CONFIG_FLOAT_VALUE_COUNT CONFIG_FLOAT_VALUE_COUNT
}; };

View file

@ -1268,7 +1268,11 @@ Visibility.Distance.Grey.Object = 10
# 0 (disabled) # 0 (disabled)
# #
# Death.Ghost.RunSpeed # Death.Ghost.RunSpeed
# Modifies the speed of player's ghosts, removed upon reviving, not permanent/saved # Modifies the speed of player's ghosts, removed upon reviving, not permanent/saved, NOT in BGs/arenas
# Default: 1.0 (normal speed)
#
# Death.Ghost.RunSpeed.InBGOrArena
# Modifies the speed of player's ghosts, removed upon reviving, not permanent/saved, ONLY in BGs/arenas
# Default: 1.0 (normal speed) # Default: 1.0 (normal speed)
# #
################################################################################################################### ###################################################################################################################
@ -1330,6 +1334,7 @@ Death.CorpseReclaimDelay.PvE = 1
Death.Bones.World = 1 Death.Bones.World = 1
Death.Bones.BattlegroundOrArena = 1 Death.Bones.BattlegroundOrArena = 1
Death.Ghost.RunSpeed = 1.0 Death.Ghost.RunSpeed = 1.0
Death.Ghost.RunSpeed.InBGOrArena = 1.0
################################################################################################################### ###################################################################################################################
# BATTLEGROUND CONFIG # BATTLEGROUND CONFIG

View file

@ -1,4 +1,4 @@
#ifndef __REVISION_NR_H__ #ifndef __REVISION_NR_H__
#define __REVISION_NR_H__ #define __REVISION_NR_H__
#define REVISION_NR "10978" #define REVISION_NR "10979"
#endif // __REVISION_NR_H__ #endif // __REVISION_NR_H__