diff options
| author | Shauren <shauren.trinity@gmail.com> | 2018-12-09 14:45:03 +0100 |
|---|---|---|
| committer | Shauren <shauren.trinity@gmail.com> | 2018-12-09 14:45:03 +0100 |
| commit | f94deace764f0b8d99249760d2bc2e85c891c387 (patch) | |
| tree | 4c7c56f34768fc7aef05268061a12845c5bf67ce /src/server/scripts/Commands | |
| parent | 8725eec9c1c15f3e76bd9d524d4a5d8d0b3f0a44 (diff) | |
| parent | a70030ff252b266d12023ffada2a309409c1ccdb (diff) | |
Merge branch 'bfa'
Diffstat (limited to 'src/server/scripts/Commands')
| -rw-r--r-- | src/server/scripts/Commands/cs_character.cpp | 2 | ||||
| -rw-r--r-- | src/server/scripts/Commands/cs_cheat.cpp | 4 | ||||
| -rw-r--r-- | src/server/scripts/Commands/cs_debug.cpp | 2 | ||||
| -rw-r--r-- | src/server/scripts/Commands/cs_lookup.cpp | 12 | ||||
| -rw-r--r-- | src/server/scripts/Commands/cs_misc.cpp | 8 | ||||
| -rw-r--r-- | src/server/scripts/Commands/cs_modify.cpp | 5 | ||||
| -rw-r--r-- | src/server/scripts/Commands/cs_quest.cpp | 8 | ||||
| -rw-r--r-- | src/server/scripts/Commands/cs_reset.cpp | 8 | ||||
| -rw-r--r-- | src/server/scripts/Commands/cs_titles.cpp | 2 |
9 files changed, 31 insertions, 20 deletions
diff --git a/src/server/scripts/Commands/cs_character.cpp b/src/server/scripts/Commands/cs_character.cpp index f62ae5f45ca..e2a29b62bea 100644 --- a/src/server/scripts/Commands/cs_character.cpp +++ b/src/server/scripts/Commands/cs_character.cpp @@ -235,7 +235,7 @@ public: { player->GiveLevel(newLevel); player->InitTalentForLevel(); - player->SetUInt32Value(PLAYER_XP, 0); + player->SetUInt32Value(ACTIVE_PLAYER_FIELD_XP, 0); if (handler->needReportToTarget(player)) { diff --git a/src/server/scripts/Commands/cs_cheat.cpp b/src/server/scripts/Commands/cs_cheat.cpp index b9c2e78b98a..c4100d84438 100644 --- a/src/server/scripts/Commands/cs_cheat.cpp +++ b/src/server/scripts/Commands/cs_cheat.cpp @@ -276,9 +276,9 @@ public: for (uint16 i = 0; i < PLAYER_EXPLORED_ZONES_SIZE; ++i) { if (flag != 0) - handler->GetSession()->GetPlayer()->SetFlag(PLAYER_EXPLORED_ZONES_1+i, 0xFFFFFFFF); + handler->GetSession()->GetPlayer()->SetFlag(ACTIVE_PLAYER_FIELD_EXPLORED_ZONES + i, 0xFFFFFFFF); else - handler->GetSession()->GetPlayer()->SetFlag(PLAYER_EXPLORED_ZONES_1+i, 0); + handler->GetSession()->GetPlayer()->SetFlag(ACTIVE_PLAYER_FIELD_EXPLORED_ZONES + i, 0); } return true; diff --git a/src/server/scripts/Commands/cs_debug.cpp b/src/server/scripts/Commands/cs_debug.cpp index f29a12eb029..ef9007bac85 100644 --- a/src/server/scripts/Commands/cs_debug.cpp +++ b/src/server/scripts/Commands/cs_debug.cpp @@ -985,7 +985,7 @@ public: if (m) if (uint32 um = (uint32)atoi(m)) - phaseShift.AddUiWorldMapAreaIdSwap(um); + phaseShift.AddUiMapPhaseId(um); PhasingHandler::SendToPlayer(handler->GetSession()->GetPlayer(), phaseShift); return true; diff --git a/src/server/scripts/Commands/cs_lookup.cpp b/src/server/scripts/Commands/cs_lookup.cpp index 1c235bb8483..d1eaa9198f5 100644 --- a/src/server/scripts/Commands/cs_lookup.cpp +++ b/src/server/scripts/Commands/cs_lookup.cpp @@ -658,7 +658,11 @@ public: } if (handler->GetSession()) - handler->PSendSysMessage(LANG_QUEST_LIST_CHAT, qInfo->GetQuestId(), qInfo->GetQuestId(), qInfo->GetQuestLevel(), title.c_str(), statusStr); + handler->PSendSysMessage(LANG_QUEST_LIST_CHAT, qInfo->GetQuestId(), qInfo->GetQuestId(), + handler->GetSession()->GetPlayer()->GetQuestLevel(qInfo), + handler->GetSession()->GetPlayer()->GetQuestMinLevel(qInfo), + qInfo->GetQuestMaxScalingLevel(), qInfo->GetQuestScalingFactionGroup(), + title.c_str(), statusStr); else handler->PSendSysMessage(LANG_QUEST_LIST_CONSOLE, qInfo->GetQuestId(), title.c_str(), statusStr); @@ -706,7 +710,11 @@ public: } if (handler->GetSession()) - handler->PSendSysMessage(LANG_QUEST_LIST_CHAT, qInfo->GetQuestId(), qInfo->GetQuestId(), qInfo->GetQuestLevel(), title.c_str(), statusStr); + handler->PSendSysMessage(LANG_QUEST_LIST_CHAT, qInfo->GetQuestId(), qInfo->GetQuestId(), + handler->GetSession()->GetPlayer()->GetQuestLevel(qInfo), + handler->GetSession()->GetPlayer()->GetQuestMinLevel(qInfo), + qInfo->GetQuestMaxScalingLevel(), qInfo->GetQuestScalingFactionGroup(), + title.c_str(), statusStr); else handler->PSendSysMessage(LANG_QUEST_LIST_CONSOLE, qInfo->GetQuestId(), title.c_str(), statusStr); diff --git a/src/server/scripts/Commands/cs_misc.cpp b/src/server/scripts/Commands/cs_misc.cpp index 9be3ff64559..a5a3fe831b2 100644 --- a/src/server/scripts/Commands/cs_misc.cpp +++ b/src/server/scripts/Commands/cs_misc.cpp @@ -1203,8 +1203,8 @@ public: } uint32 val = uint32((1 << (area->AreaBit % 32))); - uint32 currFields = playerTarget->GetUInt32Value(PLAYER_EXPLORED_ZONES_1 + offset); - playerTarget->SetUInt32Value(PLAYER_EXPLORED_ZONES_1 + offset, uint32((currFields | val))); + uint32 currFields = playerTarget->GetUInt32Value(ACTIVE_PLAYER_FIELD_EXPLORED_ZONES + offset); + playerTarget->SetUInt32Value(ACTIVE_PLAYER_FIELD_EXPLORED_ZONES + offset, uint32((currFields | val))); handler->SendSysMessage(LANG_EXPLORE_AREA); return true; @@ -1247,8 +1247,8 @@ public: } uint32 val = uint32((1 << (area->AreaBit % 32))); - uint32 currFields = playerTarget->GetUInt32Value(PLAYER_EXPLORED_ZONES_1 + offset); - playerTarget->SetUInt32Value(PLAYER_EXPLORED_ZONES_1 + offset, uint32((currFields ^ val))); + uint32 currFields = playerTarget->GetUInt32Value(ACTIVE_PLAYER_FIELD_EXPLORED_ZONES + offset); + playerTarget->SetUInt32Value(ACTIVE_PLAYER_FIELD_EXPLORED_ZONES + offset, uint32((currFields ^ val))); handler->SendSysMessage(LANG_UNEXPLORE_AREA); return true; diff --git a/src/server/scripts/Commands/cs_modify.cpp b/src/server/scripts/Commands/cs_modify.cpp index a17824a0127..6dc2d9b84f2 100644 --- a/src/server/scripts/Commands/cs_modify.cpp +++ b/src/server/scripts/Commands/cs_modify.cpp @@ -493,7 +493,10 @@ public: if (CheckModifySpeed(handler, args, target, Scale, 0.1f, 10.0f, false)) { NotifyModification(handler, target, LANG_YOU_CHANGE_SIZE, LANG_YOURS_SIZE_CHANGED, Scale); - target->SetObjectScale(Scale); + if (Creature* creatureTarget = target->ToCreature()) + creatureTarget->SetFloatValue(UNIT_FIELD_DISPLAY_SCALE, Scale); + else + target->SetObjectScale(Scale); return true; } return false; diff --git a/src/server/scripts/Commands/cs_quest.cpp b/src/server/scripts/Commands/cs_quest.cpp index 6691158360c..cb9cacdcc7b 100644 --- a/src/server/scripts/Commands/cs_quest.cpp +++ b/src/server/scripts/Commands/cs_quest.cpp @@ -64,7 +64,7 @@ public: } // .addquest #entry' - // number or [name] Shift-click form |color|Hquest:quest_id:quest_level|h[name]|h|r + // number or [name] Shift-click form |color|Hquest:quest_id:quest_level:min_level:max_level:scaling_faction|h[name]|h|r char* cId = handler->extractKeyFromLink((char*)args, "Hquest"); if (!cId) return false; @@ -112,7 +112,7 @@ public: } // .removequest #entry' - // number or [name] Shift-click form |color|Hquest:quest_id:quest_level|h[name]|h|r + // number or [name] Shift-click form |color|Hquest:quest_id:quest_level:min_level:max_level:scaling_faction|h[name]|h|r char* cId = handler->extractKeyFromLink((char*)args, "Hquest"); if (!cId) return false; @@ -170,7 +170,7 @@ public: } // .quest complete #entry - // number or [name] Shift-click form |color|Hquest:quest_id:quest_level|h[name]|h|r + // number or [name] Shift-click form |color|Hquest:quest_id:quest_level:min_level:max_level:scaling_faction|h[name]|h|r char* cId = handler->extractKeyFromLink((char*)args, "Hquest"); if (!cId) return false; @@ -268,7 +268,7 @@ public: } // .quest reward #entry - // number or [name] Shift-click form |color|Hquest:quest_id:quest_level|h[name]|h|r + // number or [name] Shift-click form |color|Hquest:quest_id:quest_level:min_level:max_level:scaling_faction|h[name]|h|r char* cId = handler->extractKeyFromLink((char*)args, "Hquest"); if (!cId) return false; diff --git a/src/server/scripts/Commands/cs_reset.cpp b/src/server/scripts/Commands/cs_reset.cpp index 10c924b89ed..1c62712f5bd 100644 --- a/src/server/scripts/Commands/cs_reset.cpp +++ b/src/server/scripts/Commands/cs_reset.cpp @@ -83,8 +83,8 @@ public: if (!handler->extractPlayerTarget((char*)args, &target)) return false; - target->SetUInt32Value(PLAYER_FIELD_KILLS, 0); - target->SetUInt32Value(PLAYER_FIELD_LIFETIME_HONORABLE_KILLS, 0); + target->SetUInt32Value(ACTIVE_PLAYER_FIELD_KILLS, 0); + target->SetUInt32Value(ACTIVE_PLAYER_FIELD_LIFETIME_HONORABLE_KILLS, 0); target->UpdateCriteria(CRITERIA_TYPE_EARN_HONORABLE_KILL); return true; @@ -117,7 +117,7 @@ public: player->SetUInt32Value(UNIT_FIELD_FLAGS, UNIT_FLAG_PVP_ATTACKABLE); //-1 is default value - player->SetUInt32Value(PLAYER_FIELD_WATCHED_FACTION_INDEX, uint32(-1)); + player->SetUInt32Value(ACTIVE_PLAYER_FIELD_WATCHED_FACTION_INDEX, uint32(-1)); return true; } @@ -143,7 +143,7 @@ public: target->InitStatsForLevel(true); target->InitTaxiNodesForLevel(); target->InitTalentForLevel(); - target->SetUInt32Value(PLAYER_XP, 0); + target->SetUInt32Value(ACTIVE_PLAYER_FIELD_XP, 0); target->_ApplyAllLevelScaleItemMods(true); diff --git a/src/server/scripts/Commands/cs_titles.cpp b/src/server/scripts/Commands/cs_titles.cpp index b493f810e13..c910d9ca8ce 100644 --- a/src/server/scripts/Commands/cs_titles.cpp +++ b/src/server/scripts/Commands/cs_titles.cpp @@ -234,7 +234,7 @@ public: titles &= ~titles2; // remove non-existing titles - target->SetUInt64Value(PLAYER__FIELD_KNOWN_TITLES, titles); + target->SetUInt64Value(ACTIVE_PLAYER_FIELD_KNOWN_TITLES, titles); handler->SendSysMessage(LANG_DONE); if (!target->HasTitle(target->GetInt32Value(PLAYER_CHOSEN_TITLE))) |
