slp13at420
Mad Scientist
Rather than cluttering up the VIP release thread I will be instead releasing any external mods in there own threads like this.
This is an external mod dependent on my VIP Engine:
This requires you have installed my VIP Engine Found Here -> VIP Engine
[Minimum required ver. 2.10]
Search you source for these files to edit:
/src/server/game/Entities/Creature/GossipDef.cpp
/src/server/game/Entities/Player/Player.cpp
Modify Quest Reward rates:
/src/server/game/Entities/Creature/GossipDef.cpp
first add:
with the rest of the includes.
find Function:
add at the top:
then find:
and replace with:
then find:
and replace with:
then find:
and replace with:
find Function:
add at the top of the function:
then find:
and replace with:
then find:
and replace with:
then find:
and replace with:
find function:
add at the top:
then find:
and replace with:
then find:
and replace with:
then find:
and replace with:
/src/server/game/Entities/Player/Player.cpp
first add:
with the rest of the includes.
find function
add at the top of the function:
then find:
and replace with:
then find:
and replace with:
then find:
and replace with:
then find:
and replace with:
then find:
and replace with:
find function:
add at the top:
then find:
and replace with:
then find:
and replace with:
After you have completed adding these edits and compiling,
players will now see the modified values and receive the modified rewards
This is an external mod dependent on my VIP Engine:
This requires you have installed my VIP Engine Found Here -> VIP Engine
[Minimum required ver. 2.10]
Search you source for these files to edit:
/src/server/game/Entities/Creature/GossipDef.cpp
/src/server/game/Entities/Player/Player.cpp
Modify Quest Reward rates:
/src/server/game/Entities/Creature/GossipDef.cpp
first add:
Code:
[COLOR="#808080"]
#include "Grumboz_VIP_Core.h"
[/COLOR]
with the rest of the includes.
find Function:
Code:
[COLOR="#808080"]
void PlayerMenu::SendQuestGiverQuestDetails(Quest const* quest, ObjectGuid npcGUID, bool activateAccept) const
[/COLOR]
add at the top:
Code:
[COLOR="#808080"]
float VIP_OFFSET = VIP::GetVIPOFFSET();
uint32 acctId = GetSession()->GetAccountId();
uint8 Pvip = VIP::GetPlayerVIP(acctId);
float MOD = (Pvip * VIP_OFFSET);
Player* player = GetSession()->GetPlayer();
float rate = (sWorld->getRate(RATE_XP_QUEST) + (sWorld->getRate(RATE_XP_QUEST) * MOD));
[/COLOR]
then find:
Code:
[COLOR="#808080"]
data << uint32(quest->RewardChoiceItemCount[i]);
[/COLOR]
and replace with:
Code:
[COLOR="#808080"]
uint32 Item_Choice_Reward_Count = quest->RewardItemIdCount[i];
uint32 extra_Item_Choice_Reward_Count = Item_Choice_Reward_Count * MOD;
data << uint32(quest->RewardChoiceItemCount[i] + extra_Item_Choice_Reward_Count);
[/COLOR]
then find:
Code:
[COLOR="#808080"]
data << uint32(quest->RewardItemIdCount[i]);
[/COLOR]
and replace with:
Code:
[COLOR="#808080"]
uint32 Item_Reward_Count = quest->RewardItemIdCount[i];
uint32 extra_Item_Reward_Count = Item_Reward_Count * MOD;
data << uint32(quest->RewardItemIdCount[i] + extra_Item_Reward_Count);
[/COLOR]
then find:
Code:
[COLOR="#808080"]
data << uint32(quest->GetRewOrReqMoney() + quest->GetRewOrReqMoney());
data << uint32(quest->XPValue(_session->GetPlayer()) * sWorld->getRate(RATE_XP_QUEST));
[/COLOR]
and replace with:
Code:
[COLOR="#808080"]
uint32 XP = quest->XPValue(player);
float xp_rate = sWorld->getRate(RATE_XP_QUEST);
uint32 MONEY = quest->GetRewOrReqMoney();
uint32 extra_XP = XP * xp_rate + (xp_rate * MOD);
uint32 extra_MONEY = MONEY + (MONEY * MOD);
data << uint32(MONEY + extra_MONEY);
data << uint32(XP + extra_XP);
[/COLOR]
find Function:
Code:
[COLOR="#808080"]
void PlayerMenu::SendQuestQueryResponse(Quest const* quest) const
[/COLOR]
add at the top of the function:
Code:
[COLOR="#808080"]
float VIP_OFFSET = VIP::GetVIPOFFSET();
uint32 acctId = GetSession()->GetAccountId();
uint8 Pvip = VIP::GetPlayerVIP(acctId);
float MOD = (Pvip * VIP_OFFSET);
Player* player = GetSession()->GetPlayer();
[/COLOR]
then find:
Code:
[COLOR="#808080"]
if (quest->HasFlag(QUEST_FLAGS_HIDDEN_REWARDS))
data << uint32(0); // Hide money rewarded
else
data << uint32(quest->GetRewOrReqMoney()); // reward money (below max lvl)
[/COLOR]
and replace with:
Code:
[COLOR="#808080"]
uint32 MONEY = quest->GetRewOrReqMoney();
uint32 extra_MONEY = MONEY * MOD;
if (quest->HasFlag(QUEST_FLAGS_HIDDEN_REWARDS))
data << uint32(0); // Hide money rewarded
else
data << uint32(MONEY + extra_MONEY); // reward money (below max lvl)
[/COLOR]
then find:
Code:
[COLOR="#808080"]
data << uint32(quest->RewardItemIdCount[i]);
[/COLOR]
and replace with:
Code:
[COLOR="#808080"]
uint32 Item_Reward_Count = quest->RewardItemIdCount[i];
uint32 extra_Item_Reward_Count = Item_Reward_Count * MOD;
data << uint32(quest->RewardItemIdCount[i] + extra_Item_Reward_Count);
[/COLOR]
then find:
Code:
[COLOR="#808080"]
data << uint32(quest->RewardChoiceItemCount[i]);
[/COLOR]
and replace with:
Code:
[COLOR="#808080"]
uint32 Item_Choice_Reward_Count = quest->RewardItemIdCount[i];
uint32 extra_Item_Choice_Reward_Count = Item_Choice_Reward_Count * MOD;
data << uint32(quest->RewardChoiceItemCount[i] + extra_Item_Choice_Reward_Count);// data << uint32(quest->RewardChoiceItemCount[i]);
[/COLOR]
find function:
Code:
[COLOR="#808080"]
void PlayerMenu::SendQuestGiverOfferReward(Quest const* quest, ObjectGuid npcGUID, bool enableNext) const
[/COLOR]
add at the top:
Code:
[COLOR="#808080"]
float VIP_OFFSET = VIP::GetVIPOFFSET();
uint32 acctId = GetSession()->GetAccountId();
uint8 Pvip = VIP::GetPlayerVIP(acctId);
float MOD = (Pvip * VIP_OFFSET);
Player* player = GetSession()->GetPlayer();
[/COLOR]
then find:
Code:
[COLOR="#808080"]
data << uint32(quest->RewardChoiceItemCount[i]);
[/COLOR]
and replace with:
Code:
[COLOR="#808080"]
uint32 Item_Choice_Reward_Count = quest->RewardItemIdCount[i];
uint32 extra_Item_Choice_Reward_Count = Item_Choice_Reward_Count * MOD;
data << uint32(quest->RewardChoiceItemCount[i] + extra_Item_Choice_Reward_Count);
[/COLOR]
then find:
Code:
[COLOR="#808080"]
data << uint32(quest->RewardItemIdCount[i]);
[/COLOR]
and replace with:
Code:
[COLOR="#808080"]
uint32 Item_Reward_Count = quest->RewardItemIdCount[i];
uint32 extra_Item_Reward_Count = Item_Reward_Count * MOD;
data << uint32(quest->RewardItemIdCount[i] + extra_Item_Reward_Count);
[/COLOR]
then find:
Code:
[COLOR="#808080"]
data << uint32(quest->GetRewOrReqMoney());
data << uint32(quest->XPValue(_session->GetPlayer()) * sWorld->getRate(RATE_XP_QUEST));
[/COLOR]
and replace with:
Code:
[COLOR="#808080"]
uint32 XP = quest->XPValue(player);
float xp_rate = sWorld->getRate(RATE_XP_QUEST);
uint32 MONEY = quest->GetRewOrReqMoney();
uint32 extra_XP = XP * xp_rate + (xp_rate * MOD);
uint32 extra_MONEY = MONEY + (MONEY * MOD);
data << uint32(MONEY + extra_MONEY);
data << uint32(XP + extra_XP);
[/COLOR]
/src/server/game/Entities/Player/Player.cpp
first add:
Code:
[COLOR="#808080"]
#include "Grumboz_VIP_Core.h"
[/COLOR]
with the rest of the includes.
find function
Code:
[COLOR="#808080"]
void Player::RewardQuest(Quest const* quest, uint32 reward, Object* questGiver, bool announce)
[/COLOR]
add at the top of the function:
Code:
[COLOR="#808080"]
float VIP_OFFSET = VIP::GetVIPOFFSET();
uint32 acctId = GetSession()->GetAccountId();
uint8 Pvip = VIP::GetPlayerVIP(acctId);
float MOD = (Pvip * VIP_OFFSET);
Player* player = GetSession()->GetPlayer();
[/COLOR]
then find:
Code:
[COLOR="#808080"]
SendNewItem(item, quest->RewardItemIdCount[i], true, false);
[/COLOR]
and replace with:
Code:
[COLOR="#808080"]
uint32 RewardItemCount = quest->RewardItemIdCount[i];
SendNewItem(item, RewardItemCount + (RewardItemCount * MOD), true, false);
[/COLOR]
then find:
Code:
[COLOR="#808080"]
uint32 XP = rewarded && !quest->IsDFQuest() ? 0 : uint32(quest->XPValue(this)*sWorld->getRate(RATE_XP_QUEST));
[/COLOR]
and replace with:
Code:
[COLOR="#808080"]
uint32 XP = rewarded && !quest->IsDFQuest() ? 0 : uint32(quest->XPValue(this)*sWorld->getRate(RATE_XP_QUEST));
XP = XP + (XP*MOD);
[/COLOR]
then find:
Code:
[COLOR="#808080"]
moneyRew = int32(quest->GetRewMoneyMaxLevel());
[/COLOR]
and replace with:
Code:
[COLOR="#808080"]
moneyRew = int32(quest->GetRewMoneyMaxLevel() + (quest->GetRewMoneyMaxLevel() * MOD));
[/COLOR]
then find:
Code:
[COLOR="#808080"]
if (uint32 honor = quest->CalculateHonorGain(getLevel()))
RewardHonor(NULL, 0, honor);
[/COLOR]
and replace with:
Code:
[COLOR="#808080"]
if (uint32 honor = quest->CalculateHonorGain(getLevel()))
{
honor = honor + (honor * MOD);
RewardHonor(NULL, 0, honor);
}
[/COLOR]
then find:
Code:
[COLOR="#808080"]
if (quest->GetRewArenaPoints())
ModifyArenaPoints(quest->GetRewArenaPoints());
[/COLOR]
and replace with:
Code:
[COLOR="#808080"]
if (quest->GetRewArenaPoints())
{
int32 ArenaPoints = quest->GetRewArenaPoints();
int32 RewardArenaPoints = ArenaPoints + (ArenaPoints * MOD);
ModifyArenaPoints(RewardArenaPoints);
}
[/COLOR]
find function:
Code:
[COLOR="#808080"]
void Player::SendQuestReward(Quest const* quest, uint32 XP)
[/COLOR]
add at the top:
Code:
[COLOR="#808080"]
float VIP_OFFSET = VIP::GetVIPOFFSET();
uint32 acctId = GetSession()->GetAccountId();
uint8 Pvip = VIP::GetPlayerVIP(acctId);
float MOD = (Pvip * VIP_OFFSET);
Player* player = GetSession()->GetPlayer();
[/COLOR]
then find:
Code:
[COLOR="#808080"]
if (getLevel() < sWorld->getIntConfig(CONFIG_MAX_PLAYER_LEVEL))
{
data << uint32(XP);
data << uint32(ModRewMoney);
}
[/COLOR]
and replace with:
Code:
[COLOR="#808080"]
int32 RewMoney = quest->GetRewOrReqMoney();
int32 ModRewMoney = RewMoney + (RewMoney * MOD);
XP = XP + (XP * MOD);
if (getLevel() < sWorld->getIntConfig(CONFIG_MAX_PLAYER_LEVEL))
{
data << uint32(XP);
data << uint32(ModRewMoney);
}
[/COLOR]
then find:
Code:
[COLOR="#808080"]
data << uint32(quest->GetRewOrReqMoney() + int32(quest->GetRewMoneyMaxLevel() * sWorld->getRate(RATE_DROP_MONEY)));
[/COLOR]
and replace with:
Code:
[COLOR="#808080"]
float DropMoneyRate = sWorld->getRate(RATE_DROP_MONEY);
DropMoneyRate = DropMoneyRate + (DropMoneyRate * MOD);
data << uint32(ModRewMoney + int32(quest->GetRewMoneyMaxLevel() * DropMoneyRate));
[/COLOR]
After you have completed adding these edits and compiling,
players will now see the modified values and receive the modified rewards
Last edited: