Last active
August 29, 2015 13:57
-
-
Save callmephil/9448929 to your computer and use it in GitHub Desktop.
TC : Remove Player Resurrect Timer and Spawning at GY
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/server/game/Entities/Player/Player.cpp b/src/server/game/Entities/Player/Player.cpp | |
index 0625a65..b1d14c8 100644 | |
--- a/src/server/game/Entities/Player/Player.cpp | |
+++ b/src/server/game/Entities/Player/Player.cpp | |
@@ -134,7 +134,7 @@ enum CharacterCustomizeFlags | |
#define DEATH_EXPIRE_STEP (5*MINUTE) | |
#define MAX_DEATH_COUNT 3 | |
-static uint32 copseReclaimDelay[MAX_DEATH_COUNT] = { 30, 60, 120 }; | |
+// Change the 3 value as you whises. if you want only more values please change MAX_DEATH_COUNT. | |
+static uint32 copseReclaimDelay[MAX_DEATH_COUNT] = { 15, 25, 30 }; | |
uint32 const MasterySpells[MAX_CLASSES] = | |
{ | |
@@ -5577,22 +5577,25 @@ void Player::RepopAtGraveyard() | |
// if no grave found, stay at the current location | |
// and don't show spirit healer location | |
- if (ClosestGrave) | |
- { | |
- float const* orientation = sObjectMgr->GetGraveyardOrientation(ClosestGrave->ID); | |
- TeleportTo(ClosestGrave->map_id, ClosestGrave->x, ClosestGrave->y, ClosestGrave->z, orientation ? *orientation : GetOrientation()); | |
- if (isDead()) // not send if alive, because it used in TeleportTo() | |
- { | |
- WorldPacket data(SMSG_DEATH_RELEASE_LOC, 4*4); // show spirit healer position on minimap | |
- data << ClosestGrave->map_id; | |
- data << ClosestGrave->x; | |
- data << ClosestGrave->y; | |
- data << ClosestGrave->z; | |
- GetSession()->SendPacket(&data); | |
- } | |
- } | |
- else if (GetPositionZ() < zone->MaxDepth) | |
- TeleportTo(m_homebindMapId, m_homebindX, m_homebindY, m_homebindZ, GetOrientation()); | |
+ if (ClosestGrave) | |
+ { | |
+ if (GetBattleground() || GetInstanceScript()) | |
+ { | |
+ float const* orientation = sObjectMgr->GetGraveyardOrientation(ClosestGrave->ID); | |
+ TeleportTo(ClosestGrave->map_id, ClosestGrave->x, ClosestGrave->y, ClosestGrave->z, orientation ? *orientation : GetOrientation()); | |
+ } | |
+ else if (isDead()) // not send if alive, because it used in TeleportTo() | |
+ { | |
+ WorldPacket data(SMSG_DEATH_RELEASE_LOC, 4*4); // show spirit healer position on minimap | |
+ data << ClosestGrave->map_id; | |
+ data << ClosestGrave->x; | |
+ data << ClosestGrave->y; | |
+ data << ClosestGrave->z; | |
+ GetSession()->SendPacket(&data); | |
+ } | |
+ } | |
+ else if (GetPositionZ() < zone->MaxDepth) | |
+ TeleportTo(m_homebindMapId, m_homebindX, m_homebindY, m_homebindZ, GetOrientation()); | |
} | |
bool Player::CanJoinConstantChannelInZone(ChatChannelsEntry const* channel, AreaTableEntry const* zone) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment