mirror of
https://github.com/mangosfour/server.git
synced 2025-12-15 10:37:02 +00:00
Now BG honor marks not reawrded in BG
* And related spells not create items. * Update code for allow creat marks for single existed case: outfield bg that not yet implemented in mangos.
This commit is contained in:
parent
7f7d0624e8
commit
b37933454d
3 changed files with 22 additions and 26 deletions
|
|
@ -882,7 +882,6 @@ void BattleGround::RewardMark(Player *plr,uint32 count)
|
|||
break;
|
||||
case BATTLEGROUND_EY:
|
||||
IsSpell = false;
|
||||
mark = ITEM_EY_MARK_OF_HONOR;
|
||||
break;
|
||||
default:
|
||||
return;
|
||||
|
|
|
|||
|
|
@ -68,13 +68,15 @@ enum BattleGroundQuests
|
|||
|
||||
enum BattleGroundMarks
|
||||
{
|
||||
SPELL_WS_MARK_LOSER = 24950,
|
||||
SPELL_WS_MARK_WINNER = 24951,
|
||||
SPELL_AB_MARK_LOSER = 24952,
|
||||
SPELL_AB_MARK_WINNER = 24953,
|
||||
SPELL_AV_MARK_LOSER = 24954,
|
||||
SPELL_AV_MARK_WINNER = 24955,
|
||||
ITEM_EY_MARK_OF_HONOR = 29024
|
||||
SPELL_WS_MARK_LOSER = 24950, // not create marks now
|
||||
SPELL_WS_MARK_WINNER = 24951, // not create marks now
|
||||
SPELL_AB_MARK_LOSER = 24952, // not create marks now
|
||||
SPELL_AB_MARK_WINNER = 24953, // not create marks now
|
||||
SPELL_AV_MARK_LOSER = 24954, // not create marks now
|
||||
SPELL_AV_MARK_WINNER = 24955, // not create marks now
|
||||
|
||||
SPELL_WG_MARK_VICTORY = 24955, // honor + mark
|
||||
SPELL_WG_MARK_DEFEAT = 58494, // honor + mark
|
||||
};
|
||||
|
||||
enum BattleGroundMarksCount
|
||||
|
|
|
|||
|
|
@ -3172,20 +3172,12 @@ void Spell::DoCreateItem(SpellEffectIndex eff_idx, uint32 itemtype)
|
|||
}
|
||||
|
||||
// bg reward have some special in code work
|
||||
uint32 bgType = 0;
|
||||
bool bg_mark = false;
|
||||
switch(m_spellInfo->Id)
|
||||
{
|
||||
case SPELL_AV_MARK_WINNER:
|
||||
case SPELL_AV_MARK_LOSER:
|
||||
bgType = BATTLEGROUND_AV;
|
||||
break;
|
||||
case SPELL_WS_MARK_WINNER:
|
||||
case SPELL_WS_MARK_LOSER:
|
||||
bgType = BATTLEGROUND_WS;
|
||||
break;
|
||||
case SPELL_AB_MARK_WINNER:
|
||||
case SPELL_AB_MARK_LOSER:
|
||||
bgType = BATTLEGROUND_AB;
|
||||
case SPELL_WG_MARK_VICTORY:
|
||||
case SPELL_WG_MARK_DEFEAT:
|
||||
bg_mark = true;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
|
@ -3275,19 +3267,22 @@ void Spell::DoCreateItem(SpellEffectIndex eff_idx, uint32 itemtype)
|
|||
|
||||
// send info to the client
|
||||
if(pItem)
|
||||
player->SendNewItem(pItem, num_to_add, true, bgType == 0);
|
||||
player->SendNewItem(pItem, num_to_add, true, !bg_mark);
|
||||
|
||||
// we succeeded in creating at least one item, so a levelup is possible
|
||||
if(bgType == 0)
|
||||
if(!bg_mark)
|
||||
player->UpdateCraftSkill(m_spellInfo->Id);
|
||||
}
|
||||
|
||||
// for battleground marks send by mail if not add all expected
|
||||
if(no_space > 0 && bgType)
|
||||
// FIXME: single existed bg marks for outfield bg and we not have it..
|
||||
/*
|
||||
if(no_space > 0 && bg_mark)
|
||||
{
|
||||
if(BattleGround* bg = sBattleGroundMgr.GetBattleGroundTemplate(BattleGroundTypeId(bgType)))
|
||||
bg->SendRewardMarkByMail(player, newitemid, no_space);
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
void Spell::EffectCreateItem(SpellEffectIndex eff_idx)
|
||||
|
|
@ -4579,7 +4574,7 @@ void Spell::EffectEnchantItemTmp(SpellEffectIndex eff_idx)
|
|||
uint32 duration;
|
||||
|
||||
// rogue family enchantments exception by duration
|
||||
if(m_spellInfo->Id == 38615) // Poison
|
||||
if(m_spellInfo->Id == 38615)
|
||||
duration = 1800; // 30 mins
|
||||
// other rogue family enchantments always 1 hour (some have spell damage=0, but some have wrong data in EffBasePoints)
|
||||
else if(m_spellInfo->SpellFamilyName == SPELLFAMILY_ROGUE)
|
||||
|
|
@ -4596,9 +4591,9 @@ void Spell::EffectEnchantItemTmp(SpellEffectIndex eff_idx)
|
|||
// shaman rockbiter enchantments
|
||||
else if(m_spellInfo->SpellVisual[0] == 0)
|
||||
duration = 1800; // 30 mins
|
||||
else if(m_spellInfo->Id == 29702) // Greater Ward of Shielding
|
||||
else if(m_spellInfo->Id == 29702)
|
||||
duration = 300; // 5 mins
|
||||
else if(m_spellInfo->Id == 37360) // Consecrated Weapon
|
||||
else if(m_spellInfo->Id == 37360)
|
||||
duration = 300; // 5 mins
|
||||
// default case
|
||||
else
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue